The first call to Mantinea's video ad API should cost nothing, and the second should cost three cents. A price check with estimate_only is free. A script call is 3 credits, and it exercises the same key, auth header and idempotency handling as a render. Only once those work does it make sense to spend 150 credits on a 10-second talking-actor clip, then 450 on a 30-second ad. This walkthrough climbs that ladder in order.
API details come from Mantinea's public docs; prices from its list read on 24 November 2026, at one cent a credit.
A note on paths: this post doesn't hard-code operation paths, header names or body fields. Copy those from the OpenAPI 3.1 document and the API and MCP help page, not from a blog. Anything in <...> below is a value to take from the spec.
The cost ladder
| Rung | Call | Credits | Dollars | What it proves |
|---|---|---|---|---|
| 1 | Any paid call with estimate_only | 0 | $0 | Auth works; the price comes back |
| 2 | Script | 3 | $0.03 | Real job start, idempotency, job polling |
| 3 | 10-second narrated clip (3 per second) | 30 | $0.30 | A video asset comes back |
| 4 | 10-second talking actor (15 per second) | 150 | $1.50 | Actor rendering end to end |
| 5 | 30-second talking actor or Pro actor | 450 | $4.50 | A full ad |
| Ladder total | 633 | $6.33 |
The 14-day trial gives 1,000 credits with no card, and the API is on every plan, so the whole ladder fits with room for a retry. For reference, the lip-sync route is 40 credits per second (1,200 for 30 seconds, $12), and hooks are 2 credits.
Setup
You need a Mantinea account, curl, jq and about ten minutes.
Create a key with the generate scope. Keys come as read, generate or admin; an admin key in a script can do far more damage if it leaks.
export MANTINEA_KEY="paste-your-key-here"
export MANTINEA_API="https://app.mantinea.com/api/v1"
Keep the key in a secret manager, not the repo.
Load the OpenAPI 3.1 document into Postman, Insomnia or an SDK generator, and note three things: how the key is sent (<AUTH_HEADER>), the operation that starts a job (<START_JOB_PATH>) and the one that gets or waits on a job (<GET_JOB_PATH>).
Rung 1: the free estimate
curl -sS -X POST "$MANTINEA_API/<START_JOB_PATH>" \
-H "<AUTH_HEADER>: $MANTINEA_KEY" \
-H "Content-Type: application/json" \
-d '{ "estimate_only": true, "<job fields from the spec>": "..." }' | jq
Check the number against the ladder. One trap: the "Auto" talking-actor route reserves at 40 credits per second and charges whichever route actually ran, so a 30-second Auto estimate shows a 1,200-credit reserve even if it ends up at 450.
Rung 2: a script, with an idempotency key
Drop estimate_only, switch the job fields to a script, and add an idempotency key: one unique value per logical job. Retry with the same key after a network drop and the API won't start a second job.
JOB_KEY="first-script-$(date +%s)"
curl -sS -X POST "$MANTINEA_API/<START_JOB_PATH>" \
-H "<AUTH_HEADER>: $MANTINEA_KEY" \
-H "<IDEMPOTENCY_HEADER_OR_FIELD>: $JOB_KEY" \
-H "Content-Type: application/json" \
-d '{ "<script job fields from the spec>": "..." }' | tee job.json | jq
Save the job id. A started job reserves its quote; you pay for what ran, never more. Failed or canceled jobs refund automatically.
What a missing idempotency key costs: nothing much on a script, 450 credits on every accidental duplicate of a 30-second render. More on retries in idempotency keys in the Mantinea API.
Waiting for the result
Long-poll: the API holds a request for up to 50 seconds, and renders usually take a few minutes, so loop.
JOB_ID=$(jq -r '<path to the id in job.json>' job.json)
until curl -sS "$MANTINEA_API/<GET_JOB_PATH with $JOB_ID>" \
-H "<AUTH_HEADER>: $MANTINEA_KEY" | tee status.json \
| jq -e '<expression true when done>' >/dev/null; do
echo "still running..."
done
jq '<path to the result>' status.json
Webhooks: beyond testing, register one. Events are signed and cover a job or workflow run succeeding, failing or being canceled. Failed deliveries retry at 1 minute, 5 minutes, 30 minutes, 2 hours, 6 hours and 12 hours. Verify the X-Autonomous-Signature header before trusting the payload ("Autonomous" is an older product name that still shows up in developer surfaces).
Rungs 3 to 5
Same calls, different job fields: a 10-second narrated clip, then a 10-second talking actor, then the 30-second ad. Run an estimate before each new job type. It catches a wrong duration before it costs anything.
Limits, and what they mean for a catalog
| Limit | Value | For a 300-product catalog |
|---|---|---|
| Requests per minute per key | 600 | Plenty, if you long-poll instead of hammering |
| Paid starts per minute per key | 60 | At least 5 minutes of starts |
| Jobs per batch call | 50 | 6 batch calls |
| Long-poll wait | Up to 50 seconds | Fewer status requests |
Three hundred 15-second talking-actor ads at 225 credits each is 67,500 credits, $675. Price the batch with estimate_only before you send it; estimate_only explained covers batch pricing.
Mistakes that cost credits
- An admin key in scripts. Use generate.
- Skipping the estimate on a new job type.
- A new idempotency key per retry. The key names the job, not the attempt.
- Polling with no wait, which wastes your 600 requests a minute.
After the first ad
- Captions (2 credits) or Brand finish (captions, logo and end card, 2 credits per started minute) in a follow-up call.
- The automatic video quality check is on the API, as are reviews and approvals, so a finished asset can go to client review without leaving your pipeline.
- Prefer an assistant to curl? Point Claude or Cursor at the hosted MCP server at
https://app.mantinea.com/mcp, which supports?mode=estimate. - The AI video ad API page has the overview.