# Issue an API key for the AI credit allowance Goal: obtain an API key bound to the wallet and to the monke it holds. ## Status The gateway is not public yet. This file describes the intended flow only. Do not call endpoints that are not listed here. ## Steps (once public) 1. Read /llms.txt and confirm the gateway base URL is listed. 2. Sign the exact message returned by GET {base}/keys/challenge?address={wallet}. 3. POST the signature to {base}/keys/new. The gateway checks balanceOf on the monke contract and on the .ai registry. 4. Show the returned quota and reset date before storing the key. 5. Store the key locally. Never print the full key in chat. ## Quota - up to 10,000,000 tokens per month per monke - resets each month, does not accumulate - revoked automatically when the monke leaves the wallet - five monkes do not mean five separate metered keys unless the gateway says so ## Errors - NOT_HOLDER - wallet holds no monke - NOT_AGENT - wallet holds no .ai Agent ID - SIGNATURE_EXPIRED - challenge older than 10 minutes - QUOTA_EXHAUSTED - allowance used up for this month - RATE_LIMITED - more than 20 requests per minute on one key