{"service":"Ycash chain data for agents, paid per request over x402","network":"ycash:testnet","testnetProfile":"fast","note":"the Ycash fast testnet: its coins have no value; get some from the faucet","asset":"YEC","decimals":8,"payTo":"smMkuu3Ro3nQuryApnABHABnZPSg7YpBkT8","payment":{"protocol":"x402 version 2 (HTTP 402 Payment Required)","kinds":[{"scheme":"exact","assetTransferMethod":"transparent","description":"the client signs a whole transparent transaction paying payTo the route's price; the facilitator checks it and relays it","settlement":"on mempool acceptance (about a second) for payments up to 100000 zatoshis; otherwise after one block"}],"flow":["request the route: the answer is 402 with the price in the PAYMENT-REQUIRED header (base64 JSON)","sign a payment for one of its `accepts` and repeat the request with it in the PAYMENT-SIGNATURE header","the answer is the data, with the settlement (txid) in the PAYMENT-RESPONSE header"],"rules":["one payment buys one request: a payment already used, or in use by another request, is refused with 409","once a request reaches the data, its payment is used even if the answer is an error (an error is not settled, so not charged; sign a new payment to retry)","a request answered with an error (4xx or 5xx) is not settled, so not charged","bad parameters are refused with 400 before any payment"],"clients":"x402-ycash (CLI, `x402-ycash pay <url> --lwd <host:port> --wif-file <key>`) or any x402 client with the Ycash `exact` scheme"},"routes":[{"method":"GET","path":"/v1/tx/:txid","priceZat":"10000","priceYec":"0.0001","description":"A transaction, decoded: inputs, outputs by type, Sapling and Sprout counts, confirmations and fee","params":{"txid":"64 hexadecimal characters"},"example":"/v1/tx/<txid>"},{"method":"GET","path":"/v1/address/:address","priceZat":"10000","priceYec":"0.0001","description":"A transparent address: balance, received, unspent outputs, recent history and mempool activity (the node's address index)","params":{"address":"a transparent address of this network (P2PKH, P2SH, post-quantum or Yellowback)"},"example":"/v1/address/<address>"},{"method":"GET","path":"/v1/block/:id","priceZat":"10000","priceYec":"0.0001","description":"A block by height or hash: header, transaction ids, chain value pools and transparent pools by type","params":{"id":"a height (decimal) or a block hash (64 hexadecimal characters)"},"example":"/v1/block/1"},{"method":"GET","path":"/v1/chain","priceZat":"10000","priceYec":"0.0001","description":"The chain now: tip, difficulty, network solution rate, upgrades, value pools, mempool size and fee rates","params":{},"example":"/v1/chain"},{"method":"GET","path":"/v1/yellowback","priceZat":"10000","priceYec":"0.0001","description":"Yellowback where the network has it: the vault upgrade's status, the vault primitive's state and the YED module's reads","params":{},"example":"/v1/yellowback"},{"method":"POST","path":"/v1/broadcast","priceZat":"10000","priceYec":"0.0001","description":"Relays a signed raw transaction to the network (paid relay); answers its txid, or 422 with the node's reason (not charged)","params":{"body":"JSON {\"hex\": \"<signed transaction>\"}, at most 100,000 bytes of transaction"},"example":"/v1/broadcast"}],"free":[{"method":"GET","path":"/","description":"this document"},{"method":"GET","path":"/pricing","description":"this document"},{"method":"GET","path":"/healthz","description":"whether the API reaches its node"}],"limits":{"unpaidRequestsPerMinute":30,"paidRequestsPerMinute":120,"paidRelayRequestsPerMinute":10,"paidRequestsInProgress":16,"freeRequestsPerMinute":120,"addressHistoryBlocks":10000,"listEntries":100},"links":{"faucet":"https://fastnet-x402.ycash.team/faucet/","explorer":"https://fastnet-explorer.ycash.team","lightwalletd":"fastnet-lightwallet.ycash.team:443"}}