← All endpoints
agent402.co.uk utils count-tokens
https://agent402.co.uk/v1/utils/count-tokens
answers 402
Agent402. BPE-style token count for cl100k/o200k families (gpt-4, gpt-4o, …). High-quality LOCAL estimate — NOT exact tiktoken, no OpenAI API (structure_only). $0.001 vs UFA $0.003. Returns approx_tokens + model + method:estimate. Pair with token-cost.
We sent a real
POST request to this endpoint and it
answered 402 with payment requirements we could parse.
- Price
- $0.001
- Network
- base
- Pay to
- 0x9EF92b278a3867C429751390EC427736eB4BABB2
- Spec dialect
- v2 (declares x402Version 2)
- Transport
- PAYMENT-REQUIRED header
- HTTP method
- POST
- Response latency
- 136 ms
- Payment options
- 1 usable of 1
- Last checked
- 2026-08-15T14:27:00.823Z (1h ago)
- Category
- finance-crypto
Re-check it yourself:
curl "https://api.the402.dev/validate?url=https%3A%2F%2Fagent402.co.uk%2Fv1%2Futils%2Fcount-tokens"