A2Ax402no LLM · deterministic

ip402 GeoIP Agent

A paid IP-intelligence agent speaking the A2A protocol: send an IPv4/IPv6 address in a message, pay $0.01 per lookup in USDC (Base or Solana mainnet) via the in-message a2a-x402 extension, get normalized geolocation + ASN data back as a JSON artifact. No accounts, no API keys.

Looking for the plain HTTP API (GET /v1/geo, OpenAPI, MPP)? That lives at ip402.xyz — this host is the agent-to-agent surface.

Endpoints

JSON-RPC 2.0 (message/send) POST https://agent.ip402.xyz/a2a

How a lookup works

  1. Ask. message/send with a text part ("Where is 8.8.8.8?") or a data part ({"ip":"8.8.8.8","lang":"en"}).
  2. Payment required. The agent answers with a task in state input-required; its message metadata carries x402.payment.status = "payment-required" and x402.payment.required — the exact x402 accepts (USDC on Base eip155:8453 and Solana mainnet).
  3. Pay & receive. Sign an x402 PaymentPayload (e.g. with the x402 SDK) and re-send it with the same taskId in metadata["x402.payment.payload"]. The agent verifies and settles on-chain, then completes the task with the geo JSON artifact and a settlement receipt in x402.payment.receipts.

Try turn 1 now (free)

This calls the live endpoint from your browser — an unpaid request only ever returns the payment challenge; nothing is charged.



  

Turn 1 — curl

curl -s https://agent.ip402.xyz/a2a \
  -H 'Content-Type: application/json' \
  -d '{
    "jsonrpc": "2.0", "id": 1, "method": "message/send",
    "params": {"message": {
      "kind": "message", "messageId": "m1", "role": "user",
      "parts": [{"kind": "text", "text": "Where is 8.8.8.8?"}]
    }}
  }'

Turn 2 — pay

{
  "jsonrpc": "2.0", "id": 2, "method": "message/send",
  "params": {"message": {
    "kind": "message", "messageId": "m2", "role": "user",
    "taskId": "<task id from turn 1>",
    "parts": [{"kind": "text", "text": "payment attached"}],
    "metadata": {"x402.payment.payload": { /* signed x402 PaymentPayload */ }}
  }}
}

Reference client: consumer/a2a_consumer.py drives the full flow end to end.