API reference

One JSON API for everything a member does with a film. Every answer that names a price, a wait or a count reads it live, so read it from the answer instead of storing it.

Rendrio for agents

Watch: the Claude connector, the MCP server and the API in 30 seconds.

Basics

Base address and keys

Every path below starts at https://api.rendrio.io/api/v1. Send your key as Authorization: Bearer rdr_.... Keys are made and revoked in your account and are shown once.

Idempotency

A call that starts or spends something takes an Idempotency-Key header. Send the same key again, after a timeout or a crash, and you get the first success back, never a second film or a second charge. A refusal is not kept, so the same key runs once the person has paid.

Errors

Errors are JSON with error, code and message, plus the fields a code needs, like payUrl on a 402. The codes are listed below.

Webhooks

Rendrio calls your address when a film moves, signed with your secret. The events and the check in Node and Python are on the overview.

Account

Who the key belongs to, what it can spend, and the prices it would pay, read live from the price list.

GET

/v1/account

The account behind the key: film credits, the free film rule, the prices and the film lengths on offer.

  • Every number in the answer is read at call time from the account and the price list. Read it instead of storing it.
  • The free film is the whole film, made free: lengths.freeFilmSeconds long. lengths.previewSeconds is how much of it the person watches free on the film page before paying (null when the page shows the watermarked film instead). Quote these, never a guess.
  • A value Rendrio cannot read is null, never 0.
Answer
{
  "id": "uuid",
  "email": "you@company.com",
  "credits": {
    "films": "<number>"
  },
  "freeTeaser": {
    "allowed": "<boolean>",
    "used": "<number>",
    "limit": "<number>",
    "code": null
  },
  "prices": {
    "film": "<price object or null>",
    "twoFormats": "<price object or null>"
  },
  "lengths": {
    "freeFilmSeconds": "<number>",
    "payToWatch": "<boolean>",
    "previewSeconds": "<number or null>",
    "filmSeconds": "<number>",
    "film": {
      "step": "<number>",
      "max": "<number>",
      "seconds": [
        "<number>"
      ]
    }
  },
  "buyUrl": "https://rendrio.io/pricing"
}
GET

/v1/films/allowance

Whether the account may make its free film for a site, and the film this site already has.

  • The site's free film rule only. The API's own checks run when the film starts.
url
The website the film would be made from.
Answer
{
  "allowed": "<boolean>",
  "code": null,
  "message": null,
  "used": "<number>",
  "limit": "<number>"
}

Films

Start a film, follow it, unlock it, ask for an edit and download it. Films take minutes, so no call waits for one: start it, then read it or wait for the webhook.

POST

/v1/films

Idempotency-Key

Make a film from a website (or a text, where the account has that path).

  • kind "teaser" is the account's free film, watermarked, under the same rule as the site, with one free film per site.
  • kind "film" is the paid full film. It uses film credits from the account, the same as on the site. seconds is one of the lengths GET /v1/account lists.
  • With no credit the answer is 402 with a payUrl. A person opens it and pays on rendrio.io; the API never takes a payment.
  • brief.platforms is required. Every other brief field is optional; the director picks what you leave out.
  • Send the same Idempotency-Key again and you get the first success back, never a second film. A refusal is not kept, so the same key works once the person has paid.
  • etaSeconds is null when no estimate can be read.
Body
{
  "source": {
    "url": "https://acme.com"
  },
  "kind": "teaser",
  "brief": {
    "platforms": [
      "LinkedIn",
      "YouTube"
    ],
    "goal": "Launch our new pricing page",
    "freeText": "Keep it calm, B2B buyers",
    "language": {
      "voice": "en",
      "inVideo": "en"
    },
    "voiceGender": "female",
    "ratio": "16:9"
  },
  "assetKeys": []
}
Answer
{
  "id": "<filmId>",
  "jobId": "uuid",
  "kind": "teaser",
  "status": "queued",
  "filmUrl": "https://rendrio.io/studio/<filmId>",
  "etaSeconds": {
    "typical": "<number>",
    "low": "<number>",
    "high": "<number>"
  }
}
GET

/v1/films/{id}

Where a film is: its status and phase, an open question from the director, edits used and the downloads once it is paid.

  • status is one of queued, running, ready, failed, cancelled.
  • A free film that is not paid has no file to download: watch.url is the film page, where the person watches it and pays.
  • A field Rendrio cannot read is null, never false or 0.
Answer
{
  "id": "<filmId>",
  "site": "acme.com",
  "kind": "teaser",
  "paid": false,
  "status": "running",
  "phase": {
    "name": "composing_scene",
    "stalled": false
  },
  "question": null,
  "failure": null,
  "edits": {
    "used": 0,
    "included": "<number>"
  },
  "watch": {
    "url": "https://rendrio.io/studio/<filmId>",
    "markedPreview": true
  },
  "downloads": [],
  "jobs": [
    {
      "id": "uuid",
      "kind": "teaser",
      "status": "running",
      "phase": "composing_scene",
      "createdAt": "<ISO time>",
      "publishedAt": null
    }
  ],
  "createdAt": "<ISO time>",
  "publishedAt": null
}
GET

/v1/films

The account's films, newest first.

url
Only the films of this site.
limit
How many to return.
Answer
{
  "films": [
    {
      "id": "<filmId>",
      "site": "acme.com",
      "state": "ready"
    }
  ]
}
POST

/v1/films/{id}/unlock

Idempotency-Key

Turn a free film into the paid full film. It uses film credits, the same as the pay button on the film page.

  • When a film is already finishing or delivered, nothing new starts: the answer says held.
Body
{
  "seconds": "<one of the lengths on offer>"
}
Answer
{
  "id": "<filmId>",
  "unlocked": true,
  "source": "credit",
  "jobId": "uuid"
}
POST

/v1/films/{id}/edits

Ask the director for a change. The edits a film includes are free; past them the answer is 402 with a payUrl to the film page.

Body
{
  "note": "Make the opening line about the free trial",
  "assetKeys": []
}
Answer
{
  "id": "<filmId>",
  "jobId": "uuid"
}
POST

/v1/films/{id}/questions/{questionId}/answer

Answer a question the director asked. Questions expire and the film goes on with the director's own choice, so a film never waits on you.

  • Send choice or text, not both.
Body
{
  "choice": "<one of question.choices>"
}
Answer
{
  "ok": true
}
POST

/v1/films/{id}/formats

Order a paid film in its other shapes. Each shape is made by the director for that shape, never cropped.

  • Leave ratios out to order every shape the film does not have yet.
  • It uses film credits, the same as on the film page. With no credit the answer is 402 with a payUrl to the film page.
  • Send an Idempotency-Key so a retry never orders twice.
Body
{
  "ratios": [
    "9:16",
    "1:1"
  ]
}
GET

/v1/films/{id}/formats

The film's shapes: which are made, which can be downloaded, and the price of the other shapes, read live.

Answer
{
  "enabled": true,
  "own": "16:9",
  "formats": [
    {
      "ratio": "9:16",
      "status": "<status>",
      "downloadable": false
    }
  ],
  "twoFormats": "<price object or null>"
}
GET

/v1/films/{id}/download

A redirect to a short-lived link to the MP4 of a paid film.

  • Send Accept: application/json, or json=1, to get the link as JSON instead of a redirect.
  • A film that is not paid answers 402; a film not made yet answers 404 NOT_READY.
ratio
16:9, 9:16 or 1:1.
json
1 for a JSON answer.
Answer
{
  "url": "<signed link>",
  "filename": "<file name>",
  "expiresIn": "<seconds>"
}
POST

/v1/films/{id}/retry

Start a run that stopped again, for free, under the same rules as the site.

Answer
{
  "id": "<filmId>",
  "jobId": "uuid"
}

Uploads

Your own pictures for the brief: product shots, screenshots, a logo.

POST

/v1/uploads

Store one image for a brief and get its key back. Pass the key in brief.assetKeys.

Body
{
  "data": "<base64>",
  "mimeType": "image/png"
}
Answer
{
  "key": "<asset key>"
}

Error codes

The same codes the site uses, so an answer means the same thing wherever the film was started.

StatusCodeWhat it means
400INVALID_BRIEFA brief field is missing or wrong. message says which.
400IDEMPOTENCY_KEY_REQUIREDThis call starts or spends something and needs an Idempotency-Key header.
400BAD_RATIOSA shape in ratios is not 16:9, 9:16 or 1:1.
422IDEMPOTENCY_KEY_REUSEDThis Idempotency-Key was already used on another route. Use a new one.
401API_KEY_MISSINGNo Authorization: Bearer rdr_... header.
401API_KEY_INVALIDThe key is unknown or was revoked.
401SIGNUP_REQUIREDThe key belongs to an account that is not signed up.
402NEEDS_PAYMENTThe film needs a film credit. reason says why, payUrl is the link a person opens to pay, and price is read live.
403API_FREE_TEASER_REFUSEDThe free film was refused by an anti-abuse rule; reason says which. A paid film is not affected.
403ACCOUNT_SUSPENDEDThe account is suspended.
404NOT_FOUNDNot a film of this account, or the API is not open for this account yet.
409TEASER_LIMIT_PROJECTThis site already has its free film on the account. versionId names it; unlock it instead.
409AGENT_JOB_IN_PROGRESSThis film is being made right now. Wait for it.
409IDEMPOTENCY_IN_PROGRESSThe first call with this Idempotency-Key is still running. Read the film, or call again shortly.
429API_RATE_LIMITEDToo many calls a minute. retryAfter is in seconds.
429API_DAILY_LIMITThe account started as many films today as its limit allows. retryAfter says when to try again.
429API_TOO_MANY_RUNNINGToo many films are being made at once on the account.
429API_UPLOAD_LIMITThe account uploaded as many pictures today as its limit allows.
503API_FREE_FILMS_PAUSEDFree films through the API are paused for today. siteUrl is where the person can still make one.
503API_PAID_STARTS_PAUSEDPaid starts are paused for a moment to protect the queue. retryAfter says when.
503API_PAUSEDThe API is paused by the Rendrio team. Try again later.