Why does the Bilibili API return 412?
412 is Bilibili's risk-control response: the request was judged automated and refused. It shows up when requests come too fast, when the WBI signature (wts and w_rid) is missing or wrong on endpoints that need it, or when an endpoint suddenly gets stricter. Waiting helps for rate limits; a bad signature fails every time. XTikAPI reads Bilibili with 10 endpoints from $0.002 a call. A failed call is not charged, and a verified account gets $0.5 of trial balance.
Updated 2026-11-18
What the bilibili-API-collect community reports
Issue #1018 on bilibili-API-collect reports the user video search endpoint (x/space/wbi/arc/search) starting to return 412 after a risk-control change. In discussion #1010 a maintainer's first question is whether the request carried the WBI parameters. Issue #1007 covers bili_ticket getting more weight in risk control.
Other tools describe 412 as the response to too many requests in a short period, so not every 412 is a signing bug.
Without WBI signing
bilibili.videos.search searches by keyword; bilibili.videos.detail and bilibili.comments.list take a bv_id; bilibili.videos.list lists an uploader's videos by uid. You send your key; no cookie, WBI key or ticket of yours.
Why XTikAPI
- One API key for Bilibili and every other supported platform, with the same JSON shape: data holds the result, meta says what was billed.
- A failed call or a timeout is not charged; the response says charged: false.
- X-Max-Price caps what one call may cost, and the same Idempotency-Key within 24 hours is never billed twice.
- Prepaid balance, no subscription. Balance never expires, and unused top-up money can be refunded within 14 days.