API Reference

Seven endpoints. Predictable JSON. Same shape forever.

Base URL

bash
https://youtubetranscriptapi.com/api/v2

OpenAPI 3.1 spec: /openapi.json

Authentication

Send your API key as a bearer token on every request:

bash
Authorization: Bearer YOUR_API_KEY

Endpoints

Click any endpoint to see its full reference: parameters, response shape, examples, and edge cases.

Account

GET/api/v2/account/whoamiFree

The plan and balance of the account that owns the key. Free, and it answers at a zero balance too, so it works as a pre-flight check before a batch job. credits.spendable is what the API can spend now; plan credits are left out of it while a renewal payment is failing.

bash
curl "https://youtubetranscriptapi.com/api/v2/account/whoami" \
  -H "Authorization: Bearer YOUR_API_KEY"
json
{
  "user_id": "…",
  "plan": "free",
  "plan_status": null,
  "credits": { "spendable": 87, "plan": 0, "topup": 87 }
}

You don't need to poll it: every successful call carries X-Credits-Charged and X-Credits-Remaining headers. See Rate Limits.