Admin API¶
Admin endpoints manage tenants, API keys, namespaces, and usage. All admin endpoints require the engine service key (HX_GATE_ENGINE_SERVICE_KEY) passed via Authorization: Bearer.
Create tenant¶
Provision a new tenant with an API key and namespace ACL.
Request body¶
| Field | Type | Required | Description |
|---|---|---|---|
tenant_id |
string | Yes | Unique tenant identifier |
plan |
string | No | Billing tier: starter, builder, pro, enterprise (default: starter) |
namespaces |
list[string] | No | Allowed namespaces (default: ["default"]) |
email |
string | No | Tenant contact email |
Example¶
curl -X POST https://gate.holonomx.com/gate/onboard/create \
-H "Authorization: Bearer $SERVICE_KEY" \
-H "Content-Type: application/json" \
-d '{
"tenant_id": "acme-corp",
"plan": "builder",
"namespaces": ["default", "staging", "production"],
"email": "[email protected]"
}'
Response — 201 Created¶
{
"tenant_id": "acme-corp",
"api_key": "hx_live_a1b2c3d4e5f6...",
"plan": "builder",
"namespaces": ["default", "staging", "production"],
"monthly_quota": 50000,
"rate_limit": {"requests": 100, "window_s": 60}
}
Warning
The api_key is shown once. Store it securely — it cannot be recovered.
Rotate API key¶
Invalidate the current key and issue a new one. The old key stops working immediately.
Request body¶
| Field | Type | Required | Description |
|---|---|---|---|
tenant_id |
string | Yes | Target tenant |
Response — 200 OK¶
Add namespace¶
Grant a tenant access to an additional namespace.
Request body¶
| Field | Type | Required | Description |
|---|---|---|---|
tenant_id |
string | Yes | Target tenant |
namespace |
string | Yes | Namespace to add |
Response — 200 OK¶
Update tier¶
Change a tenant's billing tier and quota.
Request body¶
| Field | Type | Required | Description |
|---|---|---|---|
tenant_id |
string | Yes | Target tenant |
plan |
string | Yes | New tier: starter, builder, pro, enterprise |
Response — 200 OK¶
{
"tenant_id": "acme-corp",
"plan": "pro",
"monthly_quota": 500000,
"rate_limit": {"requests": 1000, "window_s": 60}
}
Deactivate tenant¶
Soft-delete a tenant. API key is immediately invalidated. Data is retained for the compaction retention period.
Request body¶
| Field | Type | Required | Description |
|---|---|---|---|
tenant_id |
string | Yes | Target tenant |
Response — 200 OK¶
List tenants¶
Return all registered tenants with their current plans and namespace ACLs.
Response — 200 OK¶
{
"tenants": [
{
"tenant_id": "acme-corp",
"plan": "pro",
"namespaces": ["default", "staging", "production"],
"active": true
}
]
}
Get usage — all tenants¶
Response — 200 OK¶
{
"period": "2026-01",
"tenants": [
{
"tenant_id": "acme-corp",
"cus_used": 12450.5,
"monthly_quota": 500000,
"utilization": 0.0249
}
]
}
Get usage — single tenant¶
Response — 200 OK¶
{
"tenant_id": "acme-corp",
"period": "2026-01",
"cus_used": 12450.5,
"monthly_quota": 500000,
"utilization": 0.0249,
"breakdown": {
"put": 5000.0,
"get": 250.0,
"query_topk": 3200.0,
"serve": 2000.0,
"search": 1500.0,
"delete": 500.5
}
}
Reload tenant registry¶
Hot-reload the tenant registry from disk without restarting the gate process.
Response — 200 OK¶
Health check¶
Response — 200 OK¶
No authentication required.