REST API
JSON over HTTPS with an API key. Generate, follow and publish from any language, a backend job or a no-code tool.
QuickstartWe are also available on mobile
AITube API · REST, MCP and OpenAPI
Generate videos with Veo, Kling, Seedance and every other AITube model, make faceless Shorts, music, voiceovers and effects, and publish to your channel, from your own code. Billed in AITube credits at the same prices as the studio.
POST /v1/generations
curl -X POST https://api.aitube.app/v1/generations \ -H "Authorization: Bearer $AITUBE_KEY" \ -d '{"prompt":"A neon fox in Tokyo rain","duration_sec":5}'
{
"generation_id": "8c1e…",
"status": "queued",
"price_credits": 130,
"refund_when": "Automatically, if it fails"
}Three ways in
JSON over HTTPS with an API key. Generate, follow and publish from any language, a backend job or a no-code tool.
QuickstartAdd AITube to Claude or ChatGPT by signing in, or to Cursor and other MCP apps with a key. The same tools, picked by your assistant as you talk.
Connect an appBuilding a custom GPT? Import the OpenAPI spec as an Action and set the authentication to API key, Bearer.
openapi.jsonQuickstart
Create a key in Settings, Developer API, and keep it in an environment variable. Base URL: https://api.aitube.app/v1
curl https://api.aitube.app/v1/me \
-H "Authorization: Bearer $AITUBE_KEY"curl -X POST https://api.aitube.app/v1/generations \
-H "Authorization: Bearer $AITUBE_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: fox-001" \
-d '{"prompt":"A neon fox running through Tokyo rain, cinematic","duration_sec":5,"aspect_ratio":"9:16"}'curl https://api.aitube.app/v1/generations/$GENERATION_ID \
-H "Authorization: Bearer $AITUBE_KEY"
curl -X POST https://api.aitube.app/v1/videos/$VIDEO_ID/publish \
-H "Authorization: Bearer $AITUBE_KEY" \
-H "Content-Type: application/json" \
-d '{"title":"Neon fox","category":"Entertainment"}'Reference
Paid endpoints spend credits or post for you. Every field, type and limit is in the OpenAPI spec, and GET /v1 lists them all.
/v1/mePlan, credit balance, perks and your API limits.
/v1/me/statsYour channel's views, watch time, subscribers and engagement.
/v1/modelsEvery video model with durations, ratios and the credit price of each.
/v1/generations/quoteThe exact price for a prompt and settings.
/v1/generationsGenerate a clip: text-to-video or image-to-video, any model.
Paid/v1/generations/{generation_id}Status, then the video URL and the draft's video_id.
/v1/generationsYour recent generations.
/v1/generations/{generation_id}/cancelCancel and refund.
/v1/faceless/optionsFormats, looks, voices, captions, music, presenters.
/v1/faceless/scriptsWrite a script from an idea, free.
/v1/faceless/quoteThe exact price, line by line.
/v1/faceless/videosMake the video; charged when it's ready.
Paid/v1/faceless/videos/{video_id}Progress, then the download link.
/v1/faceless/videosYour faceless videos.
/v1/audio/optionsMusic models, voices and sound-effect categories, with prices.
/v1/audioMusic, a voiceover from a script, or a sound effect.
Paid/v1/audio/{audio_id}Status, then the file URL.
/v1/effectsThe Instant Effects, with prices.
/v1/effectsTurn a photo (an https link) into an effect video.
Paid/v1/effects/{effect_job_id}Status, then the video URL.
/v1/prompts/enhanceTurn a short idea into a detailed prompt, free.
/v1/videos/{video_id}/publishPublish a finished generation to your channel.
Paid/v1/videos/{video_id}/publishProcessing, live with its link and stats, or held back.
/v1/uploadsA presigned upload URL for your own video file.
Paid/v1/uploads/{video_id}/completeStart processing; it publishes by itself.
Paid/v1/community/postsA text post in the AITube community.
Paid/v1/searchSearch videos and creators.
/v1/videos/trendingTrending videos, by category.
/v1/videos/{video_id}A public video's details.
/v1/channels/{username}A channel and its latest videos.
/v1/battlesOpen AI video battles.
Pricing
No separate API bill. Every call costs the same credits as the same action in the studio, with failed generations refunded.
A credit is $0.02 on Pay As You Go, and plans include credits every month. AI apps over MCP: 60 requests a minute and 60 paid actions a day per connection. Need more for a real product? support@aitube.app. See plans and credit packs
Conventions
Send your key as Authorization: Bearer ait_… on every request. Keys live on servers only; anyone holding one can spend your credits.
Add an Idempotency-Key header to paid calls. Repeating a call with the same key returns the job already started.
Generations answer at once with an id. Poll its status every 15-30 seconds; the response has the file URL when it's ready.
Quote first, then pass expected_credits: if the price moved, nothing starts and you get the new price with a 409.
| Status | Code | Meaning |
|---|---|---|
| 400 | INVALID_ARGUMENTS | A field is missing or wrong; the message names it. |
| 401 | API_KEY_INVALID | No key, a wrong key, or a revoked one. |
| 402 | INSUFFICIENT_CREDITS | Not enough credits; required, available and shortfall are included. |
| 403 | PLAN_REQUIRED | The account isn't on Creator or Pro, or an option needs a higher plan. |
| 404 | NOT_FOUND | No such generation, video or channel on this account. |
| 409 | CONFLICT | The price changed since your quote (with expected_credits), or the draft has no file yet. |
| 429 | RATE_LIMITED / DAILY_LIMIT | Too many requests a minute, or the day's paid actions; Retry-After says when. |
| 502 | SERVER_ERROR | Something failed on our side. Nothing was charged; retrying is safe. |
Errors are { "error": { "code", "message" } }, with the fix in the message. MCP server for AI apps: https://api.aitube.app/api/v1/mcp
Questions
Yes. The AITube API is a REST API at https://api.aitube.app/v1 with 31 endpoints: generate AI videos with every model AITube offers, make faceless videos, music, voiceovers and effects, publish to your channel, and search AITube. It has an OpenAPI 3.1 description at https://api.aitube.app/v1/openapi.json.
The REST API comes with the Creator and Pro plans. AI apps over MCP (Claude, ChatGPT, Cursor and others) work on every plan: free accounts get the free tools, and making or posting needs Creator, Pro or Pay As You Go credits.
In AITube credits, at the same price as the same action in the studio. The plan's monthly credits are used first, then credits you bought. AI video generations are refunded automatically if they fail, and faceless videos are charged only once they're ready.
Every model on the AITube Generate page, including Google Veo, Kling, Seedance, Wan, Hailuo and more. GET /v1/models lists them with their durations, aspect ratios and the credit price of each.
Yes. A finished generation is saved as a draft; POST /v1/videos/{video_id}/publish puts it on your channel with the same checks as an upload in the app. You can also upload your own files with /v1/uploads.
Per key: 60 requests a minute and 200 paid actions a day on Creator, 300 and 1000 on Pro. Going over returns 429 with a Retry-After header and costs nothing.
Yes. Connect AITube as an MCP connector in Claude or ChatGPT by signing in to AITube (see aitube.app/mcp), or import the OpenAPI spec as an Action in a custom GPT.
