{"openapi":"3.0.0","info":{"title":"RESI Subnet 46 API","version":"1.0.0","description":"\n# RESI Dashboard API\n\nAPI for the Real Estate Intelligence (RESI) Subnet 46 Dashboard.\n\n## Overview\n\nThis API provides access to:\n- **Models**: Miner AI models and their performance data\n- **Stats**: Network statistics and emissions data\n- **Authentication**: Validator authentication for validation set access\n\n## Authentication\n\nThe `/api/dashboard/auth/validation-set` endpoint requires Bittensor signature authentication.\n\n### How to Authenticate\n\n1. Generate a nonce (Unix timestamp)\n2. Construct the data to sign: `{METHOD}{URL}{SORTED_HEADERS_JSON}`\n3. Sign with your validator hotkey\n4. Include headers: `Hotkey`, `Nonce`, `Signature`\n\n### Example (Python)\n\n```python\nimport time\nimport json\nimport { env } from \"@/env\"\nfrom bittensor import Keypair\n\nkeypair = Keypair.create_from_mnemonic(\"your mnemonic\")\nurl = \"https://your-domain.com/api/dashboard/auth/validation-set\"\nnonce = str(time.time())\n\nheaders_to_sign = {\"Hotkey\": keypair.ss58_address, \"Nonce\": nonce}\ndata_to_sign = f\"POST{url}{json.dumps(headers_to_sign, sort_keys=True)}\"\nsignature = keypair.sign(data_to_sign.encode()).hex()\n\n# Make request with headers\n```\n\n## Rate Limiting\n\n- Authenticated validators: 10 requests/minute\n- Failed auth attempts: IP blocked after 5 failures in 5 minutes\n        ","contact":{"name":"RESI Subnet 46"}},"servers":[{"url":"http://localhost:3000","description":"Production"}],"tags":[{"name":"Models","description":"Miner AI models and performance data"},{"name":"Stats","description":"Network statistics and emissions"},{"name":"Authentication","description":"Validator authentication for validation set access"}],"components":{"securitySchemes":{"BittensorAuth":{"type":"apiKey","in":"header","name":"Hotkey","description":"Bittensor hotkey (SS58 address) with Nonce and Signature headers"}},"schemas":{"Model":{"type":"object","properties":{"uid":{"type":"integer","description":"Miner UID on subnet 46"},"hotkey":{"type":"string","description":"SS58 hotkey address"},"coldkey":{"type":"string","description":"SS58 coldkey address"},"modelHash":{"type":"string","description":"Current model hash"},"currentVersion":{"type":"integer","description":"Model version number"},"score":{"type":"number","description":"Latest R² score"},"rank":{"type":"integer","description":"Rank on leaderboard"},"status":{"type":"string","enum":["pending","completed","error"]},"lastEvaluatedAt":{"type":"string","format":"date-time"},"registeredAt":{"type":"string","format":"date-time"}}},"Error":{"type":"object","properties":{"error":{"type":"string","description":"Error message"},"code":{"type":"string","description":"Error code for programmatic handling"}}}}},"paths":{}}