Skip to main content
POST
/
v1
/
images
/
generations
Media and embeddings
curl --request POST \
  --url https://api.compose.market/v1/images/generations \
  --header 'Content-Type: application/json' \
  --data '
{
  "model": "<string>",
  "prompt": "<string>",
  "input": {},
  "file": "<string>",
  "image": "<string>",
  "image_url": "<string>"
}
'

Documentation Index

Fetch the complete documentation index at: https://docs.compose.market/llms.txt

Use this file to discover all available pages before exploring further.

Media routes use the same native payment behavior as text inference. Status polling routes are not billable; the charge happens on generation submission.

Routes

MethodPathDescription
POST/v1/images/generationsGenerate images from a prompt.
POST/v1/images/editsEdit an image with a prompt.
POST/v1/audio/speechGenerate speech audio bytes.
POST/v1/audio/transcriptionsTranscribe base64 audio.
POST/v1/embeddingsGenerate embeddings.
POST/v1/videos/generationsSubmit video generation.
GET/v1/videos/{id}Poll video generation status.
GET/v1/videos/{id}/streamStream video status until terminal state.

Common headers

Authorization
string
Bearer compose-... for Compose Key billing.
PAYMENT-SIGNATURE
string
Raw x402 payment signature for x402-aware clients.

Common fields

model
string
required
Public catalog model ID.
prompt
string
Required for image and video generation.
input
string | array
Required for speech and embeddings.
file
string
Required for audio transcription. The route expects base64 content.
image
string
Required for image edits; also accepted as an initial image for some video models.
image_url
string
URL form of an input image.

Video status stream

pollIntervalMs
number
Poll interval for /v1/videos/{id}/stream. Default 2000, minimum 500, maximum 30000.
timeoutMs
number
Stream timeout. Default 600000, minimum 5000, maximum 3600000.
The stream emits compose.video.status, compose.error, and data: [DONE].