Submit an image generation task
Returns HTTP 202 with a persistent task_id. Poll GET /api/v1/images/generations/{task_id}. Flat input or nested input is supported; nested input takes precedence. Callback fields are ignored. Capabilities and input parameters depend on the configured model and channel.
- Type: stringX
- Request - Id Optional caller request ID echoed back for diagnostics.
- Type: stringX
- Felo - Channel Ordered comma-separated public channel codes. Omit this header to use default; default must be used alone. In wallet mode, default scans the model's effective public channel order in reverse, skips unpublished or unavailable channels, and selects the first available channel's provider. It includes available endpoints from that provider with the same upstream model ID and service tier. Explicit channels are validated in client-specified order; only the first channel's provider group is submitted. No automatic fallback to other providers. Legacy provider headers cannot override channel routing.
Model-specific input follows the configured public model protocol.
- Type: stringmodelrequired
- Type: array string[]image
_urls - Type: objectinput
Optional nested input; takes precedence over flat input.
- serviceType: string | null
_tier Currently only default (standard) is supported. Omitted, null, aliases and unsupported strings fallback to default; other types return HTTP 400. Configured channels and prices remain unchanged. Text APIs send the provider's standard value; Decisions and generation APIs omit the upstream field.
- propertyType: anything
Name
- Type: integern
Integer numbers.
- Type: stringprompt
- Type: string | nullservice
_tier Currently only default (standard) is supported. Omitted, null, aliases and unsupported strings fallback to default; other types return HTTP 400. Configured channels and prices remain unchanged. Text APIs send the provider's standard value; Decisions and generation APIs omit the upstream field.
- Type: stringsize
- Type: anythingproperty
Name
- Type: object · ImageGenerationAccepted202
Task accepted
- enumkindconst:imagerequiredvalues
- image
- Type: array string[]outputsrequired
Empty until the task succeeds.
- enumstatusconst:queuedrequiredvalues
- queued
- Type: stringtask
_id requiredTask id to use for polling.
application/json - Type: object · GenerationError400
Invalid request (unknown model, mixed input modes, invalid fields)
OpenAI-compatible error envelope.
- Type: objecterror
- messageType: stringrequired
- typeType: string enumrequiredvalues
- invalid
_request _error - server
_error
- codeType: string
- paramType: string nullable
application/json - Type: object · GenerationError401
Invalid or missing Felo API key
OpenAI-compatible error envelope.
- Type: objecterror
- messageType: stringrequired
- typeType: string enumrequiredvalues
- invalid
_request _error - server
_error
- codeType: string
- paramType: string nullable
application/json - Type: object · GenerationError402
Insufficient balance / billing requirement not met
OpenAI-compatible error envelope.
- Type: objecterror
- messageType: stringrequired
- typeType: string enumrequiredvalues
- invalid
_request _error - server
_error
- codeType: string
- paramType: string nullable
application/json - Type: object · GenerationError403
Account not permitted (subscription required or user banned). Disabled models are also rejected before upstream calls. Existing accepted requests and tasks continue.
OpenAI-compatible error envelope.
- Type: objecterror
- messageType: stringrequired
- typeType: string enumrequiredvalues
- invalid
_request _error - server
_error
- codeType: string
- paramType: string nullable
application/json - Type: object · GenerationError429
Request or spending limit reached
OpenAI-compatible error envelope.
- Type: objecterror
- messageType: stringrequired
- typeType: string enumrequiredvalues
- invalid
_request _error - server
_error
- codeType: string
- paramType: string nullable
application/json - Type: object · GenerationError502
Upstream provider failed
OpenAI-compatible error envelope.
- Type: objecterror
- messageType: stringrequired
- typeType: string enumrequiredvalues
- invalid
_request _error - server
_error
- codeType: string
- paramType: string nullable
application/json - Type: object · GenerationError503
Generation service or billing service temporarily unavailable
OpenAI-compatible error envelope.
- Type: objecterror
- messageType: stringrequired
- typeType: string enumrequiredvalues
- invalid
_request _error - server
_error
- codeType: string
- paramType: string nullable
application/json
curl https://openapi.felo.ai/api/v1/images/generations \
--request POST \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer YOUR_SECRET_TOKEN' \
--data '{
"model": "configured-image-model",
"prompt": "a cat"
}'
{
"task_id": "string",
"status": "queued",
"kind": "image",
"outputs": [
"string"
]
}