{"openapi":"3.0.0","info":{"title":"LedgerBrain x402 Pay-per-use API","version":"1.0.0","description":"Blockchain compliance reports for AI agents — KYT, KYA, and KYE risk scores, pay per request with USDC on Base.","license":{"name":"Proprietary"},"contact":{"name":"LedgerLink Team","url":"https://ledgerlink.io","email":"info@ledgerlink.io"},"x-guidance":"Use POST /api/v1/x402/kyt/report for transaction risk scores, POST /api/v1/x402/kya/report for address risk scores, POST /api/v1/x402/kye/report for entity profiles. All three endpoints require x402 USDC payment on Base mainnet — send a request with no payment header to receive the 402 challenge containing the payTo address."},"servers":[{"url":"https://api.ledgercore.io","description":"Production"}],"components":{"securitySchemes":{"BearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"JWT Bearer token for API authentication. Include as: Authorization: Bearer <token>"}},"schemas":{"Error":{"type":"object","properties":{"error":{"type":"string","description":"Error message","example":"Something went wrong"},"success":{"type":"boolean","example":false}}},"PaginationInfo":{"type":"object","properties":{"total":{"type":"integer","description":"Total number of items","example":150},"limit":{"type":"integer","description":"Items per page","example":50},"offset":{"type":"integer","description":"Current offset","example":0},"hasMore":{"type":"boolean","description":"Whether more items exist","example":true}}}},"responses":{"UnauthorizedError":{"description":"Authentication required","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","example":false},"error":{"type":"string","example":"Authentication required"}}}}}},"ForbiddenError":{"description":"Admin privileges required","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","example":false},"error":{"type":"string","example":"Admin privileges required"},"code":{"type":"string","example":"INSUFFICIENT_PERMISSIONS"}}}}}}}},"security":[{"BearerAuth":[]}],"paths":{"/api/v1/x402/kyt/report":{"post":{"tags":["x402 Pay-per-use"],"summary":"KYT Transaction Risk Report","description":"Pay-per-use KYT risk analysis for a single transaction. Requires x402 USDC payment on Base mainnet.","x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"1.00"},"protocols":[{"x402":{}}]},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["txid","chain"],"properties":{"txid":{"type":"string","description":"Transaction ID (64 hex chars; 0x prefix optional for ETH)"},"chain":{"type":"string","enum":["bitcoin","ethereum","solana","binance-smart-chain","tron","ripple"],"description":"Blockchain network"},"asset":{"type":"string","description":"ERC-20 contract address (ethereum only)"}}}}}},"responses":{"200":{"description":"KYT report generated successfully","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"x402":{"type":"object"},"data":{"type":"object"}}}}}},"402":{"description":"Payment Required"}}}},"/api/v1/x402/kya/report":{"post":{"tags":["x402 Pay-per-use"],"summary":"KYA Address Risk Report","description":"Pay-per-use KYA risk analysis for a single blockchain address. Requires x402 USDC payment on Base mainnet.","x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"1.00"},"protocols":[{"x402":{}}]},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["address","chain"],"properties":{"address":{"type":"string","description":"Blockchain address to analyze"},"chain":{"type":"string","enum":["bitcoin","ethereum","solana","binance-smart-chain","tron","ripple"],"description":"Blockchain network"},"asset":{"type":"string","description":"ERC-20 contract address (ethereum only)"}}}}}},"responses":{"200":{"description":"KYA report generated successfully","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"x402":{"type":"object"},"data":{"type":"object"}}}}}},"402":{"description":"Payment Required"}}}},"/api/v1/x402/kye/report":{"post":{"tags":["x402 Pay-per-use"],"summary":"KYE Entity Profile Report","description":"Pay-per-use full profile for a VASP or blockchain entity. Requires x402 USDC payment on Base mainnet.","x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"1.00"},"protocols":[{"x402":{}}]},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","minLength":2,"description":"Entity name to look up (e.g. \"Binance\", \"Luno\"). Top match is returned."}}}}}},"responses":{"200":{"description":"KYE entity profile returned successfully","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"x402":{"type":"object"},"data":{"type":"object"}}}}}},"402":{"description":"Payment Required"},"404":{"description":"Entity not found"}}}}},"tags":[]}