Get a text moderation batch

Read every item decision of a batch. Each item shows its current decision. The batch status is completed once every item is completed or failed; the body is then the same as the batch webhook body, without delivery_id.

GEThttps://api.omnifence.ai/api/v1/moderate/text/batch/{batch_id}

Requires the job:read scope. Requests without this scope receive a 403 FORBIDDEN response. See authentication.

The batch status stays processing until every item is completed or failed. Each item shows its own decision as soon as it has one. Match items by key, not by position: the response orders them by key.

A completed item can carry the optional scores and custom_scores risk scores, with the same meaning as on a single job. An item rejected by the blocked-keyword list has no scores.

A batch ID that does not exist, or that belongs to a different account, returns 404 BATCH_NOT_FOUND.

Request#

Headers#

Name Type Required Description
Authorization string Yes Your API key as a Bearer token: Bearer YOUR_API_KEY.

Path parameters#

Name Type Required Description
batch_id string (uuid) Yes

Responses#

200 OK#

Field Type Always present Description
type string Yes One of text_batch.
batch_id string (uuid) Yes
status string Yes completed once every item is completed or failed, in the same step that sends the batch webhook. One of processing, completed.
created_at string (date-time) Yes
completed_at null or string (date-time) Yes
items array of object Yes One decision for each item, ordered by key. Match items by key.
items[].key string Yes
items[].job_id string (uuid) Yes
items[].status string Yes One of queued, processing, completed, failed.
items[].is_prohibited null or boolean Yes true rejects the item, false passes it, null while pending or on failure.
items[].reason string No Why the item was rejected. Only on a rejection.
items[].scores object No Informational risk score per built-in policy category, from 0 (clearly does not match) to 1 (clearly matches), keyed by the category id (for example violence; the same category is default_violence in enabled_categories). The scores do not decide the job: is_prohibited is the decision, and a score can be high on content that passed. Child-safety categories are never scored. Returned for text and audio jobs; image and video jobs do not currently return scores. Present only on a completed job that produced scores; a category without a score is omitted.
items[].custom_scores object No The same informational risk scores for your custom categories, keyed by custom category slug. Present only when at least one custom category was scored.
items[].error_code string No Why the item failed. Only on a failed item, when a cause is known.
Example responseJSON
{
  "type": "text_batch",
  "batch_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "status": "processing",
  "created_at": "2026-05-19T12:00:00.000Z",
  "completed_at": "2026-05-19T12:00:00.000Z",
  "items": [
    {
      "key": "string",
      "job_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
      "status": "queued",
      "is_prohibited": false,
      "reason": "string",
      "scores": {},
      "custom_scores": {},
      "error_code": "string"
    }
  ]
}