Automated Content Safety API

The ACS API uses an ensemble of AI reviewers to analyze content for compliance with safety, legal, and community policies. It supports text, comments, chat, conversations, search queries, images, and video.

Try the Playground

Authentication

All requests require a Bearer token in the Authorization header.

Authorization: Bearer YOUR_API_KEY

Endpoints

EndpointTypeUse Case
POST/api/v1/compliance/textTextArticles, posts, descriptions
POST/api/v1/compliance/commentCommentUser comments, reviews
POST/api/v1/compliance/chatChatSingle message
POST/api/v1/compliance/conversationConversationMulti-turn dialogues
POST/api/v1/compliance/searchSearchSearch queries
POST/api/v1/compliance/imageImageImage moderation
POST/api/v1/compliance/videoVideoVideo moderation
GET/api/v1/public/rulesetsPublicList all rulesets
GET/api/v1/public/rules?ruleset=IDPublicList rules for a ruleset

Compliance Check

Request body

FieldTypeDefaultDescription
contentstring|arrayRequired. The content to analyze.
amountinteger3Number of reviewers (1-25). System auto-retries to ensure this many succeed.
rulesetstring(default)Ruleset ID to evaluate against.
timeoutinteger60Overall request timeout in seconds (1-300).
contextstringnullAdditional context for reviewers.
decision_methodstringaverageaverage, any, all, score.
excluded_categoriesarray[]Rule IDs to skip.
custom_promptstringnullReplace default rules with custom instructions.
verboseinteger00 (basic), 1 (standard), 2 (detailed).
screen_underageboolean(system default)Run Tanner-Scale age screening in parallel with the reviewers. Image and video only. See Age Screening.

Example request

{
  "content": "User-generated text to evaluate",
  "amount": 5,
  "ruleset": "default",
  "timeout": 30,
  "decision_method": "average",
  "verbose": 2
}

Example response

{
  "decision": "safe",
  "reason": "Content is compliant.",
  "score": "0/5",
  "decision_method": "average",
  "ruleset": "default",
  "flagged_categories": [],
  "agent_decisions": [...],
  "execution_time": 1.234,
  "requested_amount": 5,
  "valid_responses": 5
}

Rulesets

Rules are organized into rulesets. Each request can target a specific ruleset via the ruleset parameter, or the system uses the configured default.

Browse available rulesets:

curl https://acs-v2.api.efficientstack.com/api/v1/public/rulesets

Browse rules in a specific ruleset:

curl "https://acs-v2.api.efficientstack.com/api/v1/public/rules?ruleset=default"

Default Compliance Rules

Loading…

Decision Methods

Average (default)

UNSAFE if 50%+ reviewers flag it.

Any

UNSAFE if any single reviewer flags it.

All

UNSAFE only on unanimous flag.

Score

Weighted by per-agent score and unsafe flags.

Timeouts & Auto-Retry

The API guarantees that the requested amount of valid reviewer responses is collected. If a reviewer fails or times out, additional reviewers are dispatched automatically until amount succeed or no more capable agents remain.

Per-request timeout: Set timeout (in seconds) to cap the total processing time. The system respects this deadline across retries.

Multimodal Content

Provide images and videos as URLs or base64 data URIs:

{ "content": "https://example.com/image.jpg", "amount": 5 }
{ "content": "data:image/jpeg;base64,/9j/4AAQ...", "amount": 5 }

Age Screening (Tanner Scale)

For image and video endpoints, the API can dispatch an additional, parallel Tanner-Scale screening pass alongside the AI reviewers. When the screening service detects an underage subject in the media, the request is forced to unsafe regardless of how the reviewers voted.

Behavior

  • Runs in parallel with AI reviewers — does not add to total latency unless its own timeout is longer.
  • Available only for image and video content types.
  • If the upstream service fails or times out, the request is unaffected and falls back to the reviewer decision.

Enabling per request

Pass screen_underage in the request body to override the system default:

{
  "content": "https://example.com/image.jpg",
  "amount": 3,
  "screen_underage": true,
  "verbose": 2
}

Triggered response

When an underage subject is detected, the response is forced to unsafe with reason Tanner Scale. Two additional fields are added at the top level (verbose ≥ 1):

{
  "decision": "unsafe",
  "reason": "Tanner Scale",
  "score": "0/3",
  "decision_method": "average",
  "ruleset": "default",
  "estimated_age_range": "12-15",
  "assessment_confidence": "High",
  "flagged_categories": [
    {
      "id": "TANNER_SCALE",
      "name": "Tanner Scale",
      "score": 5,
      "estimated_age_range": "12-15",
      "assessment_confidence": "High"
    }
  ]
}

Any categories independently flagged by the AI reviewers are also included in flagged_categories.

Override priority: A positive Tanner-Scale result always sets the final decision to unsafe, regardless of the configured decision_method.

Error Handling

StatusCodeDescription
400invalid_requestMissing or invalid parameters
401invalid_api_keyMissing or invalid API key
403unauthorizedPermission denied for content type
403account_disabledAPI key is disabled
500internal_errorServer error

Code Examples

curl -X POST "https://acs-v2.api.efficientstack.com/api/v1/compliance/image" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "content": "https://example.com/image.jpg",
    "amount": 5,
    "ruleset": "default",
    "timeout": 30,
    "screen_underage": true,
    "verbose": 2
  }'
import requests

resp = requests.post(
    "https://acs-v2.api.efficientstack.com/api/v1/compliance/image",
    headers={"Authorization": "Bearer YOUR_API_KEY"},
    json={
        "content": "https://example.com/image.jpg",
        "amount": 5,
        "ruleset": "default",
        "timeout": 30,
        "screen_underage": True,
        "verbose": 2
    },
    timeout=35
)
print(resp.json())
const res = await fetch("https://acs-v2.api.efficientstack.com/api/v1/compliance/image", {
  method: "POST",
  headers: {
    "Authorization": "Bearer YOUR_API_KEY",
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    content: "https://example.com/image.jpg",
    amount: 5,
    ruleset: "default",
    timeout: 30,
    screen_underage: true,
    verbose: 2
  })
});
const data = await res.json();