{"openapi":"3.1.0","info":{"title":"AstroWallet & AstroConnect v1 Open API","version":"3.1.0","description":"Open, permissionless Stellar (Classic G... + Soroban C...) & TON non-custodial wallet connection, SEP-53 authentication, Clear-Sign XDR execution, ClaimEscrow V3.1 Claim Links & Community Drops, and AstroID directory protocol for Telegram Mini Apps.","externalDocs":{"description":"AstroWallet Official Documentation Portal (Users, Projects, Developers & AI Agents)","url":"https://astro-wallet-docs.pages.dev"}},"servers":[{"url":"https://astro-wallet.pages.dev","description":"AstroWallet (mainnet)"}],"paths":{"/health":{"get":{"summary":"Health & active Stellar network check","parameters":[{"name":"X-Astro-Network","in":"header","required":false,"schema":{"type":"string","enum":["mainnet","testnet"]},"description":"Optional network selector (defaults to mainnet)"}],"responses":{"200":{"description":"Service operational status and configured network"}}}},"/v1/metrics/public":{"get":{"summary":"Privacy-preserving live ecosystem metrics (DAU/WAU/MAU, linked wallets, intents)","responses":{"200":{"description":"Aggregated non-PII ecosystem telemetry cached at Edge"}}}},"/v1/identity/resolve":{"get":{"summary":"Resolve public AstroID Stellar G.../C... addresses by Telegram user ID, @username, or address","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string"},"description":"Numeric telegramUserId, @username, or G.../C... address"}],"responses":{"200":{"description":"Public linked addresses (never returns encrypted vault ciphertext)"},"400":{"description":"Invalid query parameter"},"429":{"description":"Rate limit exceeded"}}}},"/v1/connect/requests":{"post":{"summary":"Create an ephemeral AstroConnect v1 request (auth, sign_message, sign_xdr, or sign_auth_entry)","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["action","app","payload"],"properties":{"action":{"type":"string","enum":["auth","sign_message","sign_xdr","sign_auth_entry"]},"ttlSeconds":{"type":"integer","minimum":60,"maximum":300},"app":{"type":"object","required":["name","botUsername"],"properties":{"name":{"type":"string"},"botUsername":{"type":"string"},"miniAppShortName":{"type":"string"},"returnStartAppParam":{"type":"string"},"iconUrl":{"type":"string","format":"uri"},"origin":{"type":"string","format":"uri"}}},"payload":{"type":"object"}}}}}},"responses":{"201":{"description":"Created request with requestId, sig, resultToken, and Telegram deepLink"},"400":{"description":"Invalid payload or xdrSha256 mismatch"},"429":{"description":"Rate limit exceeded"}}}},"/v1/connect/requests/{requestId}":{"get":{"summary":"Poll request status/result (with X-Connect-Token) or load request details (with ?sig=)","parameters":[{"name":"requestId","in":"path","required":true,"schema":{"type":"string"}},{"name":"sig","in":"query","required":false,"schema":{"type":"string"}},{"name":"X-Connect-Token","in":"header","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Request status/result or Clear-Sign request metadata"},"401":{"description":"Missing or invalid token/signature"},"404":{"description":"Request not found"},"410":{"description":"Request expired"}}}},"/v1/connect/requests/{requestId}/complete":{"post":{"summary":"Complete (approve or reject) an AstroConnect request from AstroWallet","parameters":[{"name":"requestId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Completed request and verified Telegram Boomerang returnUrl"},"400":{"description":"Invalid SEP-53 signature or completion payload"},"409":{"description":"Already completed, cross-network, or unconfirmed txHash"}}}},"/v1/intents/claim":{"post":{"summary":"Create a signed 1-to-1 Claim Link or 1-to-1000 Community Drop intent backed by ClaimEscrowContract V3.1 (Mini App Bearer session required)","responses":{"200":{"description":"Created claim/drop intent metadata and derived 32-byte claimId"},"401":{"description":"Missing or expired Mini App Bearer token"}}}}}}