Turnstile tokens from one API call.
Send the page URL and its Turnstile site key. olakey solves the challenge and returns a token your client submits with the form. You pay only for solves that succeed.
Request
POST https://api.olakey.com/v1/solves
Authorization: Bearer ok_live_…
Content-Type: application/json
{
"kind": "turnstile",
"url": "https://example.com/login",
"site_key": "0x4AAAAAAA…"
}Response
200 OK{ "id": "sol_…", "status": "succeeded", "kind": "turnstile", "solution": { "token": "0.oERiLhS37W9T8mlVY310gUDmHPGV7pdt1tgm4FFckLDL5QNcAv4wgEANyAkeCZsXiqsZfXAyw7sB5KA8fTH2wfKN0FE9KZyTLQEwx6wteHNtjHiT-VjJarlzLs6JiN9mLP7ft7UUMIdnO_OuqBRwxaufU7B_HmTH" }, "identity": {}, "expires_at": "2026-10-09T18:24:05Z", "cost_usd": 0.00075, "solve_ms": 5670 }
Pay for tokens, not attempts.
$0.75
per 1,000 successful solves
- 100 free solves every month
- Each verified account gets 100 successful solves free every calendar month (UTC), used before paid credit.
- Failures cost nothing
- Timeouts, failed solves and unsupported sites are never charged. Every successful response states its cost.
- Free test keys
- Keys starting
ok_test_accept the same requests and return a fixed sandbox token, so you can build your integration without spending. - Spend caps per key
- Set a dollar limit on any live key in the dashboard.
How a solve works
- Create an API key in the dashboard. Live keys start with
ok_live_, test keys withok_test_. - Send
POST /v1/solveswith the page URL and site key. olakey holds the request open while it solves, up to thewaityou set. - Read the token from
solution.token. If the wait runs out first you get202and a solveid; fetchGET /v1/solves/{id}until it finishes. - Submit the token before
expires_at, 5 minutes after it was minted.
Before you integrate
- Coverage
GET /v1/capabilitieslists the sites olakey can solve right now. Check it first: an unsupported site returns422and costs nothing.- Retries
- Send an
Idempotency-Keyheader and a retried request returns the original solve for 24 hours instead of starting a new one. - Errors
- Errors are
application/problem+jsonwith a stablecodeand aretryableflag.402means the account has used its free solves and has no credit left. - Rate limits
- Each key allows 600 requests a minute.