Quickstart
Make an image with the Sume Open API in three calls.
This walk-through makes one low-quality image with gpt-image-2, which costs under a cent (GET /v1/open/catalog lists the exact price), and downloads it.
1. Get a key
Open API keys on open.sume.com and create a key. Copy it when it is shown: the full key is shown once. Then export it in your shell:
Authentication and keys explains the two kinds of key and where each one works.
2. Submit the job
Generate an image
POST /v1/image-router/generate
Required
The API answers 202 Accepted at once with the job id and the URLs to follow. next_poll_after_seconds tells you when to look again.
3. Poll until the job is done
Call status_url until terminal is true. Wait next_poll_after_seconds between calls.
4. Fetch the result
When next_action is fetch_result, read result_url. Each artifact has a URL you can download.
Get a job result
GET /v1/jobs/{id}/result
Required
Next
- Polling for intervals, timeouts and the wait modes.
- Webhooks to be called back instead of polling.
- Idempotency before you retry a submit.