Skip to main content
This guide takes you from credentials to a structured result in five steps: get your api_secret, exchange it for a bearer token, create a Task with a document, poll until the Task finishes, and read the verdict. The API is asynchronous. Creating a Task returns immediately with status: "pending" and no results — you retrieve the outcome by polling GET /task/get until the Task reaches a terminal status.
Base URLs
  • Production: https://app.synthpop.ai/public/v1
  • Staging: https://stage.synthpop.ai/public/v1
Every path below is relative to one of these. The examples use production.
1

Get your api_secret

Your api_secret identifies your organization to the API. An admin generates or resets it in the Synthpop UI; if you don’t have one, ask your Synthpop contact.It has the exact form provider:uid:secret — three colon-separated parts. Treat it like a password: keep it server-side and never commit it.
The api_secret is a long-lived credential. Exchange it for a bearer token (next step) and use that token for API calls — don’t send the api_secret on every request.
2

Exchange it for a bearer token

POST /auth/get_token takes your api_secret and returns a bearer token you attach to every other call. The token is long-lived (valid for 365 days), so cache it and refresh only when it expires.
A successful response returns the token plus your organization’s settings:
A malformed secret returns 400; an invalid or revoked one returns 403.
3

Create a Task with a document

POST /task/create is a multipart/form-data request. The only required field is task_type; attach your document(s) under uploads.
The response is a TaskDetails object. Note that it comes back right away with status: "pending" and empty verdicts — the work has only been queued:
Hold onto uuid — you’ll poll it in the next step.
task_type is required and provisioned for your organization; an unknown value returns 400 "Task type 'X' not in list of tasks for your organization: [...]." There is no endpoint that lists available types — your Synthpop contact tells you which are enabled during onboarding.task (used here) is an org-provisioned convenience type that auto-classifies the uploaded document and routes it to the right validation workflow. Other organizations use specific validation task types instead. The capability guides (e.g. Validate an order) use concrete, provisioned task types like hst_validation_bin rather than task.
Want to correlate the Task with a record in your own system? Add -F "external_id=order-4821" (cURL) or data={"task_type": ..., "external_id": "order-4821"} (Python). external_id is a correlation key you can later read by — it does not make creates idempotent. Deduplication is content-based: re-uploading identical bytes is a no-op.
4

Poll until the Task reaches a terminal status

GET /task/get returns the current TaskDetails for a uuid (or an external_id — supply exactly one). Poll it until the Task settles.Statuses are exactly: pending, processing, waiting, completed, failed, invalid.
  • Terminal: completed, failed, invalid — stop polling.
  • waiting: the Task needs more input from you before it can finish (see the note below).
  • pending / processing: keep polling; the Task is queued or in progress (under load it may be parked server-side but still reports as pending).
A Task that stops at waiting is asking for more input — for example, a required document that wasn’t in the original upload. Add the missing files with POST /task/{uuid}/upload and the Task resumes on its own. See Responding to waiting tasks.
Prefer not to poll? If your organization has callbacks enabled, pass a callback_template on create and Synthpop issues a GET to your URL when the Task finishes. Callbacks are opt-in and gated per organization — see Working with async results.
5

Read the verdict

Once the Task is completed, the result lives in three fields of TaskDetails:
  • verdict_summaries — a plain-English conclusion per code.
  • verdicts — the machine-readable decision per code: whether it was approved, and which issues (by index) affected it.
  • issues — everything Synthpop flagged: missing records, expired documents, inconsistent data, and so on, each with a human-readable message and a key.
When something is missing, the same shapes tell you what and where — an entry in issues describes the gap, and any affected verdict references it by index:
That’s the full loop: authenticate, create, poll, read. From here, wire the same pattern into your intake, coverage, or engagement workflow.

Next steps

Authentication

Token lifetime, the default-deny model, and rotating your api_secret.

Tasks & lifecycle

The Task resource and every status it moves through.

Results: verdicts & issues

The full shape of verdicts, summaries, and task issues.

Validate an order

An end-to-end intake walkthrough.