Videos from your code

The same engine the app runs on, behind an HTTP call. Send the script, collect the MP4.

The API is included in the Creator and Pro plans.

Get started

One call creates the video and returns its id. Rendering takes a few minutes, so the response arrives before the video does: poll the status with that id.

bash
curl https://autoshort.io/api/v1/videos \
  -H "Authorization: Bearer sk_live_..." \
  -H "Content-Type: application/json" \
  -d '{
    "type": "faceless",
    "script": "Tres cosas que nadie te cuenta sobre dormir bien.",
    "duration": 30
  }'

Authentication

Every request carries your key in the Authorization header. Keys are created in the dashboard and shown once.

http
Authorization: Bearer sk_live_8f2c...

We store only a hash of the key, so we cannot show it to you again. Lose it and you revoke it and make another.

POST/api/v1/videos

Creates a video. Returns 202 with the id: the render is still running when you get the response.

FieldTypeNotes
typestringfaceless, brainrot or reddit. Defaults to faceless.
scriptstringThe full script. Required unless you send a topic.
topicstringA topic, and the AI writes the script.
durationnumberSeconds, between 15 and 180. Defaults to 30.
aspectRatiostring9:16, 1:1 or 16:9. Defaults to 9:16.
stylestringVisual style for the scenes.
voicestringVoice id. Omit it for the default.
backgroundVideostringGameplay background URL, for brainrot and reddit.

Response

json
{
  "id": "9f1c2a6e-...",
  "status": "pending",
  "type": "faceless",
  "title": "Tres cosas que nadie te cuenta...",
  "credits_used": 40,
  "url": null
}
GET/api/v1/videos/{id}

Fetch one of your videos. While it renders status is pending or processing; when it finishes the MP4 url arrives.

json
{
  "id": "9f1c2a6e-...",
  "status": "completed",
  "url": "https://cdn.autoshort.io/renders/9f1c2a6e.mp4",
  "error": null,
  "created_at": "2026-08-05T18:20:11.000Z"
}

Someone else's video answers 404, not 403: a 403 would confirm the id exists.

GET/api/v1/videos?limit=20

The account's latest videos, newest first. limit accepts up to 50.

json
{ "data": [ { "id": "...", "status": "completed", "url": "..." } ] }
GET/api/v1/me

Your plan, your credits, your limits and what you have spent. Worth calling before a batch: it tells you how many renders you already have running.

json
{
  "email": "[email protected]",
  "plan": "creator",
  "credits": 820,
  "limits": {
    "requests_per_minute": 60,
    "concurrent_renders": 3,
    "credits_per_video": 40,
    "credits_per_extra_minute": 15
  },
  "usage": {
    "requests_last_minute": 2,
    "requests_today": 34,
    "requests_30d": 512,
    "credits_today": 120,
    "credits_30d": 1840,
    "errors_30d": 3,
    "renders_running": 1
  }
}

Errors

Every error has the same body: an error object with code and message.

401missing_key / invalid_keyThe key is missing or not valid.
403plan_requiredThe account is not on Creator or Pro.
402insufficient_creditsNot enough credits for this call.
400missing_script / bad_durationThe script is missing or the duration is out of range.
404not_foundNo such video, or it belongs to another account.
429rate_limited / too_many_runningToo fast, or you already have the maximum number of videos rendering.

Credits and limits

An API call costs exactly what making the video in the app costs, out of the same balance.

  • 40 credits for a video up to 60 seconds, plus 15 for every extra minute.
  • Up to five active keys per account, revocable at any time.
  • Videos made through the API show up in your dashboard like any other.
  • A per-minute request limit and a cap on videos rendering at once, by plan.
  • Every response carries your credits and your remaining quota in the headers.
PlanRequests / minuteConcurrent videos
Creator603
Pro18010

Headers on every response

http
X-Plan: creator
X-Credits-Remaining: 780
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 58
X-RateLimit-Reset: 60

MCP server

If you work with an assistant that speaks MCP (Claude Desktop, Claude Code, Cursor), the AutoShort server hands it these tools directly. It is the same API: same key, same plan, same credits, same limits.

json
{
  "mcpServers": {
    "autoshort": {
      "command": "node",
      "args": ["/ruta/a/mcp/autoshort-mcp.mjs"],
      "env": { "AUTOSHORT_API_KEY": "sk_live_..." }
    }
  }
}

Tools

  • create_videocreates a video and returns its id.
  • get_videochecks where a video got to.
  • list_videoslists the account's latest videos.
  • get_accountplan, credits, limits and usage.

The server lives in the repository at mcp/autoshort-mcp.mjs. No dependencies: just Node.

Your key lives in the dashboard

One click in API settings. It is shown once, so copy it there and then.

Create my key
API Documentation | AutoShort