Authentication
All API requests require authentication using an API key.
Authorization: Bearer YOUR_API_KEY
# Example
curl -H "Authorization: Bearer sk_live_xxx" \
https://api.bczcentral.com/proxies
Base URL
All API endpoints are available at: https://api.bczcentral.com
Proxy Endpoints
List Proxies
GET /proxies
curl https://api.bczcentral.com/proxies \
-H "Authorization: Bearer YOUR_API_KEY"
Response:
{
"proxies": [
{
"id": "prx_123",
"name": "us-east-proxy",
"region": "us-east",
"status": "active"
}
]
}
Create Proxy
POST /proxies
curl -X POST https://api.bczcentral.com/proxies \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "my-proxy",
"region": "us-west",
"protocol": "http"
}'
CDN Endpoints
List Origins
GET /cdn/origins
Create Origin
POST /cdn/origins
Purge Cache
POST /cdn/purge
curl -X POST https://api.bczcentral.com/cdn/purge \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"paths": ["/images/*", "/api/*"]
}'
Cloud Endpoints
List VMs
GET /compute/instances
Create VM
POST /compute/instances
Manage Storage
GET /storage/buckets
POST /storage/buckets
Search Endpoints
Create Index
POST /search/indexes
Index Document
POST /search/indexes/{id}/documents
Query
GET /search/indexes/{id}/search
curl "https://api.bczcentral.com/search/indexes/prod/search?q=widget" \
-H "Authorization: Bearer YOUR_API_KEY"
Response:
{
"hits": [
{
"id": "doc_123",
"title": "Premium Widget",
"score": 0.95
}
],
"total": 1234
}
Error Handling
API errors are returned with appropriate HTTP status codes and error messages.
{
"error": {
"code": "INVALID_REQUEST",
"message": "Missing required field: name"
}
}