All endpoints are served over HTTPS from your Clusterbot host and versioned under /v1. Request and response bodies are JSON with camelCase field names.
Prefer to explore interactively? The interactive API reference is generated from the running service and lets you send test requests. The machine-readable OpenAPI document works with code generators and API clients such as Postman.
| Endpoint | Description | Auth | Cost |
|---|---|---|---|
POST /v1/moderations |
Classify text | API key | 1 credit per 2,000 characters (paid) or 1,000 (Free), rounded up |
GET /v1/moderations/{reviewId} |
Get a manual review decision | API key | Free |
GET /v1/usage |
Get credit balances | API key | Free |
GET /v1/health |
Check that the service is running | None | Free |
Conventions
- Authentication: send
X-Api-Key: <key>. See Authentication. - Errors: Problem Details with a stable
code. See Errors. - Caching: authenticated responses carry
Cache-Control: no-store. - Compatibility: new optional fields and new enum values can be added to
/v1at any time. Ignore what you don't recognize. Removing or renaming fields requires a new version. - Timestamps: ISO 8601 with offset, such as
2026-12-01T00:00:00+00:00.
Moderate content
POST /v1/moderations
Request body
| Field | Type | Description |
|---|---|---|
content |
string, required | Text to classify, 1–16,000 characters, no NUL characters |
language |
string or null | Optional language hint, such as ro or pt-BR |
Response 200
| Field | Type | Description |
|---|---|---|
outcome |
Pass | FlaggedForReview | Rejected |
The decision under your thresholds |
categories |
string[] | Categories that didn't pass |
flagged |
boolean | true unless outcome is Pass |
evaluatedBy |
Model | Prefilter | Cache |
How the result was produced |
latencyMs |
number | Pipeline latency in milliseconds |
reviewId |
string (UUID) | Only when outcome is FlaggedForReview |
curl "$CLUSTERBOT_BASE_URL/v1/moderations" \
-H "X-Api-Key: $CLUSTERBOT_API_KEY" \
-H "Content-Type: application/json" \
-d '{"content":"Meet me after school, you will regret it.","language":"en"}'
{
"flagged": true,
"categories": ["harassment/threatening", "violence"],
"latencyMs": 91.4,
"outcome": "Rejected",
"evaluatedBy": "Model"
}
Errors
400 invalid_content, 400 invalid_language, 401, 403 customer_unavailable, 413, 429 quota_exceeded, 429, 503 provider_unavailable, 503 review_unavailable, 503.
Get a review decision
GET /v1/moderations/{reviewId}
| Parameter | In | Description |
|---|---|---|
reviewId |
path | The UUID returned with a FlaggedForReview result |
Response 200
| Field | Type | Description |
|---|---|---|
reviewId |
string (UUID) | The review ID |
status |
Pending | Approved | Rejected |
Review state |
outcome |
FlaggedForReview | Pass | Rejected |
The outcome to apply |
reviewedAt |
string or null | When the decision was made |
curl "$CLUSTERBOT_BASE_URL/v1/moderations/ab43b6e9-d212-4350-8ca7-c01bd21ad6b3" \
-H "X-Api-Key: $CLUSTERBOT_API_KEY"
{
"reviewId": "ab43b6e9-d212-4350-8ca7-c01bd21ad6b3",
"status": "Approved",
"outcome": "Pass",
"reviewedAt": "2026-10-18T10:30:00+00:00"
}
Errors
401, 403 customer_unavailable, 404 review_not_found, 429.
Get usage
GET /v1/usage
Response 200
| Field | Type | Description |
|---|---|---|
creditsUsed |
integer | Credits reserved in the current period |
creditLimit |
integer | Monthly allowance |
creditsRemaining |
integer | Unused monthly allowance |
topUpBalance |
integer | Carry-over credits |
resetsAt |
string | Next monthly reset |
unit |
string | Always credits |
used |
integer | Alias of creditsUsed |
limit |
integer | Alias of creditLimit |
curl "$CLUSTERBOT_BASE_URL/v1/usage" -H "X-Api-Key: $CLUSTERBOT_API_KEY"
{
"used": 1240,
"limit": 10000,
"resetsAt": "2026-12-01T00:00:00+00:00",
"unit": "credits",
"creditsUsed": 1240,
"creditLimit": 10000,
"creditsRemaining": 8760,
"topUpBalance": 500
}
Errors
401, 403 customer_unavailable, 429.
Health
GET /v1/health
Reports that the service process is running. It doesn't check inference providers or your workspace, and needs no API key.
{ "status": "ok" }
Review callback event
Sent by Clusterbot to your HTTPS endpoint. See Review callbacks.
| Field | Type | Description |
|---|---|---|
id |
string (UUID) | Event ID, stable across retries. Matches Clusterbot-Event-Id. |
type |
string | moderation.review.completed |
occurredAt |
string | When the decision was made |
data.reviewId |
string (UUID) | The review ID |
data.status |
Approved | Rejected |
The decision |
data.outcome |
Pass | Rejected |
The outcome to apply |
data.reviewedAt |
string | When the decision was made |
Questions about this guide? Contact us or try requests in the playground.