# CatsApi Gateway — instructions for AI agents Base URL: https://api.prjktspace.web.id/v1 Contract (BSC): 0x39666Ccf900f0213cEF6FaE28537532c9B0E75C9 Full machine-readable spec: GET https://api.prjktspace.web.id/agent-manifest.json You hold a CatsApi NFT in your wallet. Claim an API key by proving wallet ownership with a signature (no transaction, no gas). There are TWO claim paths — pick by what your wallet can sign: DECISION RULE - Your wallet supports personal_sign (EIP-191)? Use PATH A (POST /v1/keys). - Your wallet signs EIP-712 typed data ONLY — e.g. Binance Agentic Wallet (baw), where personal_sign fails with error 351817 or "We currently don't support signing this type of message"? Use PATH B (POST /v1/keys/eip712). - Fallback: POST /v1/keys with {address, timestamp, signature} and NO "message" field is automatically treated as an EIP-712 claim. PATH A — personal_sign Sign exactly this message (unix time in milliseconds, 10-minute window): CatsApi Gateway key request Address: Timestamp: POST /v1/keys {"address","message","signature"} PATH B — EIP-712 typed data domain: {"name":"CatsApi Gateway","version":"1","chainId":56, "verifyingContract":"0x39666Ccf900f0213cEF6FaE28537532c9B0E75C9"} types: {"KeyRequest":[{"name":"wallet","type":"address"}, {"name":"timestamp","type":"uint256"}]} primaryType: "KeyRequest" message: {"wallet": , "timestamp": } POST /v1/keys/eip712 {"address","timestamp","signature"} Notes: a 65-byte signature with v=27/28 is canonical. Also accepted: v=0/1, and baw-style split results — send the 64-byte signature plus "signatureRecovery":"00"|"01" as an extra field. A domain without verifyingContract is also accepted. For baw CLI: sign-message preview needs --message as the full JSON-RPC wrapper {"method":"eth_signTypedData_v4","params":[
, ]} with --signType EIP712; the result returns signature + signatureRecovery. AFTER CLAIMING - GET /v1/me (Authorization: Bearer ) — quota and usage. - POST /v1/chat/completions — OpenAI-compatible. Model: gpt-6.1-sol. - The key is shown once; requesting a new key revokes the old one. - Monthly quota by highest tier held (stacks across tokens): Common 500K, Rare 1M, Epic 5M, Legendary 20M, Mythic 50M tokens. - No CatsApi NFT yet? Agent ID holders mint their first cat free at https://gateway.prjktspace.web.id/