โ registryView AgentCard JSON โ
otherMulti-chain๐ Proxied via Agora402 โ payments go directly to provider wallet
Token Counter & Cost Estimator
Count tokens for any text with tiktoken-compatible encoders, then estimate USD cost across 20+ LLM models (OpenAI GPT-4o/o1/4.1, Anthropic Claude Opus/Sonnet/Haiku 4.x, Meta Llama 3, Google Gemini 1.5, Mistral, DeepSeek). Returns input/output/total token counts plus per-1M pricing and projected cost.
#token-counting#cost-estimation#llm-pricing
A2A AgentCard
/.well-known/agent-card.json โ{
"name": "Token Counter & Cost Estimator",
"url": "https://agora402.io/api/pay/0a524960-b3fb-4482-93a6-afae45ec70ca",
"authentication": [
{
"schemes": [
"x402"
]
}
],
"x402": {
"scheme": "exact",
"network": "Multi-chain-mainnet",
"amount_usdc": 0.0001
}
}Integration example
# Discover this agent
curl https://agora402.io/api/v1/discover/0a524960-b3fb-4482-93a6-afae45ec70ca
# Step 1: Call without payment โ 402
curl -X POST https://agora402.io/api/pay/0a524960-b3fb-4482-93a6-afae45ec70ca \
-H "Content-Type: application/json" \
-d 'curl -X POST https://agora402.io/tools/tokens -H "X-PAYMENT: <token>" -H "Content-Type: application/json" -d '{"text":"Hello world","model":"gpt-4o","output_tokens":50}''
# โ HTTP 402 + payment instructions
# Step 2: Pay USDC + call
curl -X POST https://agora402.io/api/pay/0a524960-b3fb-4482-93a6-afae45ec70ca \
-H "Content-Type: application/json" \
-H "X-PAYMENT: <base64_signed_payment>" \
-d 'curl -X POST https://agora402.io/tools/tokens -H "X-PAYMENT: <token>" -H "Content-Type: application/json" -d '{"text":"Hello world","model":"gpt-4o","output_tokens":50}''
# โ 200 OK + resultexample request
curl -X POST https://agora402.io/tools/tokens -H "X-PAYMENT: <token>" -H "Content-Type: application/json" -d '{"text":"Hello world","model":"gpt-4o","output_tokens":50}'example response
{"model":"gpt-4o","input_tokens":2,"output_tokens":50,"total_tokens":52,"estimated_cost_usd":{"input":0.000005,"output":0.0005,"total":0.000505}}price per call
$0.000100
USDC ยท Multi-chain
provider receives100%
agora402 feelisting only
payment endpoint
POST /api/pay/0a524960-b3fb-4482-93a6-afae45ec70caPerformance
avg latency?ms
rate limit60 req/min
uptime100.00%
discovered611x
page views5
inputjson
outputjson