Z-Image Turbo API guide
The short answer · Z-Image Turbo is available in MaxAPI's image API under prunaai/z-image-turbo, for generation and reference-image editing. This catalogue entry allows up to 0 references. Published routes are official; file acceptance, permissions and output options must be checked for the route you actually use.
Integration review ·
Checked against MaxAPI's public catalogue, gateway implementation and local regression cases. Shared gateway checks are not separate end-to-end tests of every listed model. This is an integration reference, not a live upstream availability or performance report.
Before you integrate
Parameters describe MaxAPI's published configuration. A selected route may impose additional input or access requirements.
- Request model ID
prunaai/z-image-turbo- Output type
- Image
- Base URL
https://api.maxapi.dev- Generation workflow
- Synchronous or asynchronous
- Resolution & dimensions
- 64–2048 px per edge · default 1024x1024 · num_outputs default 1
Text-to-image only. Supply a prompt and size, or width plus height. Each dimension accepts integers between 64 and 2048. References and masks are not accepted.
Model strengths & selection
Text-to-image with explicit dimensions
Z-Image Turbo is served through Replicate's prunaai/z-image-turbo endpoint. MaxAPI exposes text-to-image with one output, configurable dimensions and PNG, JPEG or WebP delivery. The Official route settles from Replicate's returned billing metrics.
Source review ·
Model-specific sources: Replicate · Z-Image Turbo API schema
When to compare this model
Evaluate it for prompt-driven visual drafts and composition variants. Keep the seed, dimensions and steps fixed when comparing prompts, and inspect the actual downloaded file before using it.
Know the limits
This entry has no reference-image editing or masks. Each requested edge must be 64–2048 pixels. Upstream may round dimensions (64→128, 720→768). Billing megapixels are provider-reported units, not width × height: observed 512×512 uses 1.25 units at the 0.5 tier. A temporary base hold of 0.025 credits per requested output is replaced by the actual charge; account multipliers apply.
Provider capabilities describe the model, not the complete MaxAPI feature set. Use the parameters, input types and routes documented for this MaxAPI entry. Vendor speed or quality descriptions are not service-level guarantees.
How MaxAPI handles this request
Which route wins?
Routing priority is: the API key's configured route_modes list → an explicitly requested route → the model's default route. A non-empty key list takes precedence over route_mode in the request. To test a specific route, check the key configuration first; changing the request alone may not change the route used.
RPM is shared at account level
An account's positive RPM limit covers its API keys together. A key can impose a stricter limit, but a higher key limit does not override the user limit. For example, a user limit of 200 RPM is not 200 RPM for each key. Service-level RPM and concurrency controls also apply; adding keys is not a way to bypass them.
Routes & pricing
Published routes: official. Specify route_mode in an image/video JSON request; Gemini-native requests use X-MaxAPI-Route-Mode. A route is an access and billing choice, not a different public model ID.
| Route | Published base price | Billing unit |
|---|---|---|
official | $0.0025 | 0.5 · per returned billing megapixel |
official | $0.005 | 1 · per returned billing megapixel |
official | $0.01 | 2 · per returned billing megapixel |
official | $0.015 | 3 · per returned billing megapixel |
official | $0.02 | 4 · per returned billing megapixel |
1 credit = US$1. These are catalogue base rates, not a live account quote. Account multipliers and the active billing configuration determine the final charge. Token rates are not a fixed price per image.
Check current pricingYour first request
Create a MaxAPI API key and set MAXAPI_KEY in your server environment; never put it in browser code. A configured key route list takes priority, even if the request specifies a route. Only when that list is empty does the request route apply; otherwise the model default is used. API calls may incur charges.
POST /v1/images/generationsGET /v1/images/generations/{task_id}
Synchronous calls wait for the result. For asynchronous image generation, add async: true to the JSON body; on Gemini-native requests use X-MaxAPI-Async: true. Save the returned task ID and poll the matching GET endpoint listed above.
curl -X POST "https://api.maxapi.dev/v1/images/generations" \
-H "Authorization: Bearer $MAXAPI_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "prunaai/z-image-turbo",
"prompt": "a clean product photo of a glass cube",
"route_mode": "official",
"size": "1024x1024",
"n": 1
}'An accepted image task is not a finished image
On the OpenAI-compatible image endpoints, async=true returns task fields such as id, status and poll_url. Follow that poll_url with authentication from the same account. queued/running are not successful image outputs; inspect the final state before consuming data. A polling HTTP 200 means the lookup succeeded, not that the generation succeeded.
{
"id": "example-task-id",
"object": "image.generation.task",
"status": "queued",
"model": "prunaai/z-image-turbo",
"poll_url": "/v1/images/generations/example-task-id"
}Check your first result
Request-contract review ·
Checked against the public catalogue and gateway code. Examples are structural illustrations, not paid model tests, latency measurements or a guarantee that every route is currently available.
Send the right fields
model- Use prunaai/z-image-turbo for this MaxAPI entry. The model ID alone does not select a billing route.
size / n- Use size=1024x1024 and n=1. Each edge must be 64–2048 pixels, a multiple of 16. Use width and height together only when size is absent.
Text-to-image only- Do not send reference images, masks or an edit request. Settlement uses returned resolution_target and image_output_megapixel_count, not inferred pixel area.
Read the actual result
data[]- For a synchronous result, inspect data entries and the returned url or b64_json. Download or decode the image, then check its actual dimensions and visual details.
async=true- For asynchronous calls, save id and poll_url. HTTP 200 from polling means the lookup worked; wait for status=succeeded and inspect data. Do not re-submit a POST just to check progress.
{
"data": [
{
"url": "https://example.com/generated-image.png"
}
]
}Troubleshoot by symptom, not just HTTP status
400Missing or invalid request fields
- What it tells you
- Check the response's error code, not only 400. For image edits, an empty prompt produces prompt_required. A parameter validation error is different from an upstream generation failure.
- What to do next
- Check model, prompt, field types and documented size/quality values. Correct the request before retrying. For Gemini-native responses, inspect the numeric error.code and error.status fields.
Invalid image fileA reference cannot be decoded or accepted
- What it tells you
- A filename ending in .png does not prove that the bytes are a valid PNG. The URL may return an error page, an incomplete download or a format the selected channel cannot use. An upstream 400 may be reported as a generic generation failure, so status alone does not identify the bad file.
- What to do next
- Download and decode every reference locally. Check MIME type and pixel dimensions, then export a fresh supported image if needed. Submit one reference first and add the others in order to locate the problematic input; do not repeatedly resend an unchanged invalid file.
429rate_limit_exceeded / capacity_exhausted
- What it tells you
- 429 can represent account/key RPM, service-wide capacity or generation capacity. Use Retry-After and available X-RateLimit-* / X-Global-* headers to distinguish them; one status code does not identify one unique cause.
- What to do next
- Respect Retry-After when present, reduce request rate or active concurrency as appropriate, and use bounded backoff. Do not treat the site's total capacity as your account's personal quota.
451content_policy_violation
- What it tells you
- On the image generation failure path, a recognized upstream content refusal is mapped to 451. This is not the same as a network outage. MaxAPI's local moderation and an upstream refusal are different stages, even when both prevent a result.
- What to do next
- Review the stated policy issue and use compliant inputs, or contact support if you believe the classification is mistaken. Do not retry unchanged blocked content or rotate routes to evade moderation.
502 / 503 / 504Generation failure, unavailable service or timeout
- What it tells you
- These responses do not all mean the same thing. MaxAPI distinguishes generation_failed, generation_unavailable and generation_timeout on compatible image endpoints. A client-side timeout can also happen before the server has finished a task.
- What to do next
- If you have a task ID, poll before creating another task. Without an ID, keep the request ID and timestamp and investigate before blindly resubmitting. Retry transient failures with a limit, not an unbounded loop.
What you can build
The use cases and prompts below are our suggested evaluation briefs, not provider benchmarks or tested output samples.

AI-created concept illustrations · not outputs or benchmarks from this model. Prompts below are starting points, not recipes that reproduce these images.
Creative practice · shared production advice
Prompt composition trials
Describe one subject, one lighting direction and the desired empty space, then inspect the resulting composition.

Illustration drafts
Use a short visual brief to explore colors and shapes before adding final typography in an editor.
Format selection
Compare PNG, JPEG and WebP for your delivery workflow; compression quality does not change the model's inference tier.
Prompt examples worth adapting
A good prompt is a small creative brief. Replace the subject and constraints with your actual requirements; keep size, route and quality in the API parameters rather than relying on prose alone.
01 / A geometric ceramic still life
Create a square still life with a blue ceramic cup and a small orange sphere on a pale grey table. Use soft light from the upper left, a plain background, and generous empty space. Keep the two objects separate, show the entire cup handle, and add no lettering or logos.What to review · Check separation, shadows and the downloaded file's dimensions.

Plan the final format before generating
The destination determines the composition. A square catalogue image, a wide banner and a portrait cover need different focal points and safe areas. Choose the intended aspect ratio first; simply cropping a finished image may cut off the product or remove the space reserved for a headline.
Use the supported sizing controls listed above. A resolution label is not a promise of a particular square dimension, and a larger file is not automatically a better visual. Inspect the returned pixel dimensions, fine details and crop at the final display size. For precise grids, legal text or pixel-exact layouts, plan a finishing step in your design tool.
From a prompt to a useful image
Write a focused prompt
Describe the subject, composition and lighting. This model accepts text only; do not attach reference images or masks.
Fix the generation settings
Start with 1024x1024, one image and eight steps. Set a seed to compare prompt changes under the same configuration.
Inspect the delivered file
Download and decode the actual result. Inspect its dimensions, composition and format before using it in an application.
Reconcile the final charge
Save the request ID, prompt and returned billing units. The temporary hold is replaced by the actual charge when generation succeeds.

Choose for the job, not just the model name
This is a testing guide, not a measured ranking. Reference limits come from MaxAPI's current catalogue; a selected route can have additional restrictions. Compare the same inputs, output settings and acceptance criteria.
| Model | Configured references | What to compare in your test |
|---|---|---|
| Nanobanana Pro | 14 | Reference-driven work: evaluate subject details, composition and target output tier. |
| Gemini 3.1 Flash Image Preview | 14 | Multiple output tiers: evaluate format coverage and the cost of usable results. |
| Gemini 3.1 Flash Lite Image | 3 | 1K delivery: test whether the detail level is sufficient for your actual placement. |
| Gemini 2.5 Flash Image | 3 | Preset-size workflows: test composition without relying on a selectable 4K tier. |
| GPT Image 2 | 16 | Generation and edits: compare instruction following, file acceptance and output dimensions. |
From a test to production
Test the route you will actually use
Keep model, route and parameters fixed during your first comparison. Test your own typical inputs as well as large or unusual files. Published model capabilities do not guarantee that every upstream channel accepts every edge case.
Separate limits from generation errors
On 429, reduce request rate or concurrency and back off before retrying. On invalid-input errors, fix the input first. Preserve request and task IDs for troubleshooting; do not log API keys or sensitive reference files in public logs.
Track usable results and actual spend
Use your account's usage and billing records to verify the final result and charge. A successful HTTP response can be a task receipt rather than the final output. For published work, check generated text, visual details and rights to supplied reference material.
Verified integration cases
Checked against MaxAPI's public catalogue, gateway implementation and local regression cases. Shared gateway checks are not separate end-to-end tests of every listed model. This is an integration reference, not a live upstream availability or performance report.
Multiple keys share the user limit
Local regression · passed- Test setup
- Use two keys owned by the same account against an in-memory limiter with a small user quota.
- Observed result
- Requests across the keys consume the same user quota; subsequent requests are limited. A larger key quota does not override the user quota, and a smaller key quota remains effective.
Content refusal and capacity failure stay distinct
Local regression · passed- Test setup
- Feed mocked upstream content-refusal and 429/503/504 responses into the generation-error mapper.
- Observed result
- Content refusal maps to 451; capacity, unavailable service and timeout retain distinct public codes. The compatible 429/503 responses include Retry-After: 2 in these tests.
Image reservations settle or release on completion
Local regression · passed- Test setup
- Exercise successful and failed synchronous image reservations with a local test database.
- Observed result
- Success consumes the hold with a usage record. Failure releases the reservation without a generation charge. This verifies the tested code path, not a live account's current balance.
Frequently asked questions
When should I choose this model?
Evaluate it for prompt-driven visual drafts and composition variants. Keep the seed, dimensions and steps fixed when comparing prompts, and inspect the actual downloaded file before using it.
What limitations are specific to this entry?
This entry has no reference-image editing or masks. Each requested edge must be 64–2048 pixels. Upstream may round dimensions (64→128, 720→768). Billing megapixels are provider-reported units, not width × height: observed 512×512 uses 1.25 units at the 0.5 tier. A temporary base hold of 0.025 credits per requested output is replaced by the actual charge; account multipliers apply.
Why does changing route_mode not change my route?
Routing priority is: the API key's configured route_modes list → an explicitly requested route → the model's default route. A non-empty key list takes precedence over route_mode in the request. To test a specific route, check the key configuration first; changing the request alone may not change the route used.
Does each API key get the user's full RPM limit?
An account's positive RPM limit covers its API keys together. A key can impose a stricter limit, but a higher key limit does not override the user limit. For example, a user limit of 200 RPM is not 200 RPM for each key. Service-level RPM and concurrency controls also apply; adding keys is not a way to bypass them.
Do these local regression cases prove live model performance?
Local tests use simulated requests, responses and test storage; they do not call paid model channels. They verify request handling, not model image quality, live success rates, latency or end-to-end support for the maximum reference count. The concept illustrations elsewhere on this page are not these test outputs.
Which model ID should I send for Z-Image Turbo?
Use prunaai/z-image-turbo. Use the exact endpoint format in the example; the Gemini-native URL uses the short model name.
Does a listed price apply to every account and route?
1 credit = US$1. These are catalogue base rates, not a live account quote. Account multipliers and the active billing configuration determine the final charge. Token rates are not a fixed price per image.
Are failed requests charged?
MaxAPI's published rule is that failed requests are not charged. A request may temporarily reserve balance while it runs; check the final task outcome and billing records rather than treating a temporary balance change as the final charge.
Why is a route unavailable for my API key?
Route availability depends on the model, account permission and the API key's allowed routes. A published price is not an access grant. Check the account and key configuration before changing route_mode.
Why does a reference image fail validation?
Text-to-image only. Supply a prompt and size, or width plus height. Each dimension accepts integers between 64 and 2048. References and masks are not accepted.
Does 4K always mean a 4096×4096 image?
No. Resolution labels are not universal pixel dimensions. 64–2048 px per edge · default 1024x1024 · num_outputs default 1 Check the actual output dimensions when preparing your layout.
Should I immediately retry a failed or timed-out request?
First identify whether the response is a rate limit, invalid input or a still-running task. If you already have a task ID, query its status before submitting another generation. Apply bounded retries with backoff only to retryable errors.