Start generating in three lines of code. Pick your language:
curl https://www.flixly.ai/api/v1/generate \
-H "Authorization: Bearer flx_live_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "flux-dev",
"prompt": "A cat wearing a top hat, oil painting",
"type": "TEXT_TO_IMAGE"
}'All endpoints are prefixed with https://flixly.ai. Click an endpoint to expand examples.
All API requests require a Bearer token in the Authorization header.
flx_live_) — it is shown only once# Include in every request header
Authorization: Bearer flx_live_YOUR_KEYKeep your API key secret. Do not expose it in client-side code or public repositories.
Limits scale with your plan. Upgrade anytime from the billing page.
| Plan | Requests / min | Parallel Tasks |
|---|---|---|
| Free | 10 | 1 |
| Lite | 30 | 2 |
| Pro | 60 – 200 | 3 – 25 |
When you exceed your rate limit you will receive a 429 response with a Retry-After header indicating how many seconds to wait.
All errors follow a consistent JSON shape:
{
"error": {
"code": "insufficient_credits",
"status": 402,
"message": "You need at least 10 credits for this model."
}
}| Code | Status | Description |
|---|---|---|
unauthorized | 401 | Invalid or missing API key. |
insufficient_credits | 402 | Not enough credits to complete the request. |
forbidden | 403 | API key does not have permission for this action. |
not_found | 404 | The requested resource does not exist. |
validation_error | 422 | Request body failed validation. Check required fields. |
rate_limit_exceeded | 429 | Too many requests. Retry after the period shown in headers. |
internal_error | 500 | Unexpected server error. Contact support if it persists. |