Skip to main content
POST
Omni Moderation reviews text, at most one HTTPS image, or both using OpenAI omni-moderation-latest. Submit a review through the unified generation endpoint, then poll Get Task Status with the returned task_id or receive an optional callback. Submission immediately returns status: "not_started". The review runs asynchronously and moves through running to finished or failed.
Callbacks are supported through the optional outer callback_url field. Streaming is not supported; do not send stream.

Input

At least one of prompt or image_urls is required; both may be provided. Use non-whitespace text, one HTTPS image URL, or both. image_urls remains an array and accepts at most one image. Submit multiple images as separate tasks. Empty input is rejected.

Submit a Review

To review an image together with text:
For image-only review, omit prompt. To receive the completed task through a webhook, provide callback_url outside input:

Submit Response

Retrieve the Result

Poll until data.status becomes finished or failed. A completed review returns the full OpenAI response in data.output; data.files is empty and data.credits_amount is 0. status: "finished" means that the review completed. A result with flagged: true is a successful review that detected content, and does not make the task failed. Check data.error_message only when the task itself fails.

Callback Body

When callback_url is provided, PoYo sends a POST request when the task becomes finished or failed. The body is the status response’s data object, without the outer code and data wrapper. It includes task_id, status, credits_amount: 0, files: [], and the completed OpenAI response in output when available. Failed tasks expose error_message. See Webhook Callbacks for signature verification.

Completed Status Response Example

Authorizations

Authorization
string
header
required

All API endpoints require Bearer Token authentication.

Create an API key: sign in to PoYo, open Dashboard → API Key at poyo.ai/dashboard/api-key, and click to create a key.

Add it to the request header:

Body

application/json

Queue an asynchronous Omni Moderation review. Provide optional callback_url for completion notifications. Streaming is not supported.

model
enum<string>
required

Public model identifier.

Available options:
omni-moderation-latest
Example:

"omni-moderation-latest"

input
object
required

At least one of prompt or image_urls is required; both may be provided. Provide non-whitespace text or one HTTPS image URL. image_urls accepts at most one HTTPS image URL, and prompt may accompany the image.

callback_url
string<uri>

Optional webhook callback URL. On task completion or failure, the POST body is the status response data object without the outer code/data wrapper.

Example:

"https://your-domain.com/callback"

Response

Task queued with status not_started. Poll GET /api/generate/status/{task_id} or receive the optional callback after completion.

code
enum<integer>
required

Business status code. 200 means success; any other value means the request failed. Always check this field: some validation errors return HTTP 200 with code: 400 in the body.

  • 200: Success
  • 400: Invalid request parameters
  • 401: Missing or invalid API key
  • 402: Insufficient credits
  • 403: Permission denied
  • 404: Resource not found
  • 408: Request timeout
  • 429: Rate limit exceeded
  • 500: Internal server error
  • 502: Upstream service error
  • 503: Service unavailable

See Error Codes for details.

Available options:
200,
400,
401,
402,
403,
404,
408,
429,
500,
502,
503
Example:

200

data
object
required