Documentation
Arteza API reference
The Arteza API is a JSON REST API. You start a generation, then poll it or receive a webhook when it finishes. Every response has a request id you can quote to support.
Base URL https://arteza.ai/api/v1
OpenAPI 3.1 specification, for SDK generators and agents: /api/v1/openapi.json
Official SDKs for TypeScript and Python, a command line and agent skills: SDKs and CLI
Quickstart
- Create an API key in the console. Open the console
- Choose how the key pays: your plan credits, or a pay-as-you-go USD balance.
- Send your first request.
curl https://arteza.ai/api/v1/generations \
-H "Authorization: Bearer $ARTEZA_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "nano-banana-2",
"input": { "prompt": "A red fox in fresh snow, golden hour" }
}'The response is a generation. Images often finish within the request; video returns while still running, so poll it or use a webhook.
{
"id": "4f1c2b9e-8d6a-4c51-9a63-0f2b7d1e5a90",
"object": "generation",
"model": "nano-banana-2",
"status": "completed",
"created_at": "2026-11-28T10:00:00.000Z",
"completed_at": "2026-11-28T10:00:07.412Z",
"input": {
"prompt": "A red fox in fresh snow, golden hour",
"aspect_ratio": "1:1",
"num_images": 1
},
"output": {
"files": [
{
"url": "https://assets.arteza.ai/generations/4f1c2b9e.png",
"type": "image"
}
],
"thumbnail_url": null
},
"error": null,
"billing": {
"funding": "usd",
"usd": 0.08,
"usd_micros": 80000,
"refunded": false
}
}All sections
- AuthenticationSend your key in the Authorization header of every request. Keys start with ark_live_ and are shown once, when you create them.
- Pricing and fundingEach key is funded by plan credits or by a USD balance. The two are priced differently on purpose:
- GenerationsA generation runs one model on one input. These are the endpoints, relative to the base URL:
- ModelsEach model has an id and an input_schema in JSON Schema. Send only the fields it lists; an unknown field is rejected with unknown_parameter so a typo never silently changes your result. Omitted fields take the model's defaults.
- Automatic model choiceSend "model": "auto" with a "route" object and Arteza picks the model: it reads the media you sent to work out the task (an image plus "video" is image-to-video, audio plus a face is an avatar), keeps only models that can do it with those fields, and ranks them by route.priority -- quality (default), speed or cost -- optionally under route.max_credits. The response carries a "routing" object naming the model, the reason and the runners-up. POST /v1/estimate with "model": "auto" is a free dry run.
- AppsEvery app on arteza.ai/apps runs on the API too. An app is one model behind a prompt we engineered and a library of presets: send "app" instead of "model", choose a preset, and add your photo or your words where the app takes them. The prompt is put together on our side exactly as on the app's page, and the run is billed, refunded and delivered like any other generation. GET /apps lists every app; GET /apps/{id} gives its preset ids and inputs.
- StudiosFashion Studio and AI Influencer run on the API too, with the studio's own composition, model choice and second-chance re-render. A shoot photographs garments on a model: take a model, garments, shoes, a pose and a scene from GET /studios/fashion/catalog (presets, or your own added with POST /studios/fashion/items) and send up to 100 shots in one request. AI Influencer makes a persona with its portrait and identity sheet, then photographs it in any look, scene or product shot.
- Image toolsBesides generation models, the API runs the studio's image tools: upscaling, background removal, inpainting, expanding, vectorizing to SVG, face swap, style transfer and photo edits. They are listed by GET /v1/models with "kind": "tool" and a "family", take an image_url, and are created, billed, refunded and delivered exactly like any other generation.
- Estimating costPOST /estimate takes the same model and input as a generation and returns the price in credits and in USD, the funding your key uses, and whether your balance covers it. It never runs or charges anything.
- Uploading filesTo use a local file as an input, ask for an upload URL with its content type and size in bytes, PUT the file to it within ten minutes, then pass the returned url in your input. Images, video and audio are accepted.
- Client tokensNever ship your API key in a mobile or web app: anyone can pull it out and spend your balance. Keep the key on your server and have it mint a client token for each session with POST /tokens. The app sends the token exactly where it would send a key.
- UsageGET /usage returns what your account spent through the API between two dates (the last 30 days by default), grouped by day, model, key or end user (metadata.user_id). Generations and studio jobs are both counted, and a failed or canceled generation counts as zero because it was refunded.
- Live statusGET /generations/{id}/stream sends the generation as Server-Sent Events every time its status changes and closes once it completes, fails or is canceled. Use it in an app instead of polling: a phone cannot receive a webhook, and polling spends your read rate limit. The stream ends after five minutes; open it again, or read the generation, for a longer job.
- WebhooksPass webhook_url when you create a generation and we POST the final generation to it when it completes, fails or is canceled. The URL must be public HTTPS.
- IdempotencySend an Idempotency-Key header when you create a generation. Repeating the request with the same key returns the original generation instead of starting and charging a second one. Reusing a key with a different body returns idempotency_conflict.
- ErrorsErrors use standard HTTP status codes and one JSON shape. code is stable and safe to branch on; message is for people. Every error links to its row below.
- Rate limitsEach account can make 600 write requests and 1,200 read requests a minute. Every response carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset; a 429 also carries Retry-After. There is also a cap on generations running at once, returned as too_many_in_flight.
- ConcurrencyGenerations run in parallel. The table shows how many can be running at once for each account, per media kind. A request over the limit returns 429 too_many_in_flight with the current count and the cap, and costs nothing. Retry when a job finishes, or listen for its webhook.
- Advanced optionsEach model's input_schema lists its main controls, and many models also accept the provider's own settings, such as seed, negative_prompt, guidance_scale, num_inference_steps and output_format. These are marked "x-advanced": true. They change neither the price nor the content rules, and you can leave them out to use the model's defaults.
- Failures and refundsYou pay only for results. If the provider fails or refuses a request, the generation ends as failed and the full charge goes back to the balance it came from, credits or USD, automatically. You can cancel a queued generation with POST /v1/generations/{id}/cancel and get the same refund. The billing object of every generation shows whether it was refunded.
- Outputs and retentionResult files are stored on our CDN and their URLs stay valid until you delete the generation or your account, so you can link to them directly. Request logs are kept for 30 days.
- Usage policyThe API and the MCP server follow the same rules as the Arteza studio. Every request passes the provider's content checks, and these cannot be switched off. Do not use the API to create sexual content involving minors, content that impersonates or sexualises a real person without consent, or anything illegal. Keys belong to one account: do not share or resell them. Repeated violations suspend the key and the account.
- MCP serverArteza is also a remote MCP server, so AI assistants can use these models directly. It signs people in with OAuth and bills their plan credits at the studio price.
- ChangelogEvery change to the API, the SDKs and the MCP server, newest first, with the SDK version that brought it.