Skip to content

Integration guide

Submit and retrieve

Batch submission, task states, and result retrieval.

  • The request body is a JSON array containing 1–50 entries.
  • Each entry contains question, platformCode, and optional options, webhookUrl, and clientReference.
  • Each entry contains exactly one question and one platform.
  • Every entry has an independent taskId, result, charge, and notification.
  • Identical entries are accepted and are not merged.
  • If any entry is invalid, the whole request is rejected.

Idempotency-Key only prevents a retried HTTP request from creating another set of tasks. The same key and body return the original task IDs; the same key with another body returns HTTP 409.

State Meaning
pending Accepted and waiting
processing In progress
completed Completed
failed Not completed
stopped Stopped

Increase polling intervals gradually, for example 2, 4, and 8 seconds, capped at 30 seconds. You may also use completion notifications.

Result content is retained for 7 days by default. After expiry, taskId, state, and charges remain available and expired is true.