Guides
Pagination & idempotency
List endpoints (/channel, /playlist, /search) return up to limit videos per page (1–50, default 5) plus a next_cursor. When next_cursor is non-null, pass it back as cursor to fetch the next page; null means the list is exhausted. Each page is one successful response and costs 1 credit.
Because requests are billed, retry safely by sending an Idempotency-Key header (any unique string, ≤255 chars). The first request runs and is charged; retries with the same key replay the stored response — same body, no extra charge — and carry an Idempotent-Replayed: true header. Replays are kept for 24 hours.
409 idempotency_conflict. Reusing a key with a different body, or while the first request with that key is still in flight, returns
409 idempotency_conflict.
