2021-05-21 10:54:05 -04:00
module . exports = {
2023-04-05 16:56:40 -04:00
"version" : "2.0.0" ,
"baseUrl" : "/api" ,
2022-05-18 00:12:22 -04:00
2021-05-21 10:54:05 -04:00
"routes" : [
// blocks
{
"category" : "blocks" ,
2023-04-05 16:56:40 -04:00
"url" : "/block/$HASH" ,
2022-05-23 10:06:10 -04:00
"desc" : "Returns the details of the block with the given hash." ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/block/0000000000000000001c8018d9cb3b742ef25114f27563e3fc4a1902167f9893"
2021-05-21 10:54:05 -04:00
} ,
{
"category" : "blocks" ,
2023-04-05 16:56:40 -04:00
"url" : "/block/$HEIGHT" ,
2022-05-23 10:06:10 -04:00
"desc" : "Returns the details of the block at the given height." ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/block/123456"
2021-05-21 10:54:05 -04:00
} ,
2022-09-22 18:15:36 -04:00
{
"category" : "blocks" ,
2023-04-05 16:56:40 -04:00
"url" : "/block/header/$HASH" ,
2022-09-22 18:15:36 -04:00
"desc" : "Returns the details of the block header with the given hash." ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/block/header/0000000000000000001c8018d9cb3b742ef25114f27563e3fc4a1902167f9893"
2022-09-22 18:15:36 -04:00
} ,
{
"category" : "blocks" ,
2023-04-05 16:56:40 -04:00
"url" : "/block/header/$HEIGHT" ,
2022-09-22 18:15:36 -04:00
"desc" : "Returns the details of the block header at the given height." ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/block/header/123456"
2022-09-22 18:15:36 -04:00
} ,
2021-05-21 10:54:05 -04:00
{
"category" : "blocks" ,
2023-04-05 16:56:40 -04:00
"url" : "/blocks/tip" ,
"desc" : "Returns basic details about the chain tip."
2021-05-21 10:54:05 -04:00
} ,
// transactions
{
"category" : "transactions" ,
2023-04-05 16:56:40 -04:00
"url" : "/tx/$TXID" ,
2022-05-23 10:06:10 -04:00
"desc" : "Returns the details of the transaction with the given txid." ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/tx/f4184fc596403b9d638783cf57adfe4c75c605f6356fbc91338530e9831e9e16"
2021-05-21 10:54:05 -04:00
} ,
2022-05-19 16:46:41 -04:00
{
"category" : "transactions" ,
2023-04-05 16:56:40 -04:00
"url" : "/tx/volume/24h" ,
2022-05-19 16:46:41 -04:00
"desc" : "Returns total output of all transactions over the last 24hrs." ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/tx/volume/24h" ,
2022-05-23 10:06:10 -04:00
"hideInSlowMode" : true
2022-05-19 16:46:41 -04:00
} ,
2021-05-21 10:54:05 -04:00
// blockchain
{
"category" : "blockchain" ,
2023-04-05 16:56:40 -04:00
"url" : "/blockchain/coins" ,
"desc" : "Returns the current supply of Bitcoin. An estimate using a checkpoint can be returned in 2 cases: on 'slow' devices, and before the UTXO Set snapshot is loaded."
} ,
{
"category" : "blockchain" ,
"url" : "/blockchain/utxo-set" ,
"desc" : "Returns the latest UTXO Set snapshot. Warning: This call can be very slow, depending on node hardware and index configurations."
2021-05-21 10:54:05 -04:00
} ,
2021-11-02 16:30:38 -04:00
{
"category" : "blockchain" ,
2023-04-05 16:56:40 -04:00
"url" : "/blockchain/next-halving" ,
"desc" : "Returns details about the next, upcoming halving."
2021-11-02 16:30:38 -04:00
} ,
2021-05-21 10:54:05 -04:00
2021-12-02 14:44:46 -05:00
// addresses
{
2022-05-18 00:12:22 -04:00
"category" : "addresses" ,
2023-04-05 16:56:40 -04:00
"url" : "/address/$ADDRESS" ,
"desc" : "Returns a summary of data pertaining to the given address. The output of this call will depend heavily on the configured 'Address API' (see .env-sample file). If an Address API is configured, transactions related to the given address will be returned (the below optional parameters apply to those transactions)." ,
2022-05-18 00:12:22 -04:00
"optionalParams" : {
"limit" : "Number of transactions to return" ,
"offset" : "Offset into transactions" ,
"sort" : "Sorting direction for transactions ('desc'=new first, 'asc'=old first)"
} ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/address/34rng4QwB5pHUbGDJw1JxjLwgEU8TQuEqv"
2021-12-02 14:44:46 -05:00
} ,
2022-05-18 00:12:22 -04:00
// xyz-pubs
{
"category" : "xpubs" ,
2023-04-05 16:56:40 -04:00
"url" : "/xyzpub/$XPUB" ,
2022-05-18 00:12:22 -04:00
"desc" : "Returns details for the specified extended public key, including related keys and addresses." ,
"optionalParams" : {
"limit" : "The number of addresses to return" ,
"offset" : "Offset into the list of addresses"
} ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/util/xyzpub/xpub6EuV33a2DXxAhoJTRTnr8qnysu81AA4YHpLY6o8NiGkEJ8KADJ35T64eJsStWsmRf1xXkEANVjXFXnaUKbRtFwuSPCLfDdZwYNZToh4LBCd"
2022-05-18 00:12:22 -04:00
} ,
{
"category" : "xpubs" ,
2023-04-05 16:56:40 -04:00
"url" : "/xyzpub/addresses/$XPUB" ,
2022-05-18 00:12:22 -04:00
"desc" : "Returns a list of addresses derived from the given [xyz]pub." ,
"optionalParams" : {
"receiveOrChange" : "0 for 'receive' addresses (default); 1 for 'change' addresses" ,
"limit" : "Number of addresses to return" ,
"offset" : "Offset into addresses"
} ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/xyzpub/addresses/xpub6EuV33a2DXxAhoJTRTnr8qnysu81AA4YHpLY6o8NiGkEJ8KADJ35T64eJsStWsmRf1xXkEANVjXFXnaUKbRtFwuSPCLfDdZwYNZToh4LBCd"
2022-05-18 00:12:22 -04:00
} ,
{
"category" : "xpubs" ,
2023-04-05 16:56:40 -04:00
"url" : "/xyzpub/txids/$XPUB" ,
2022-05-18 00:12:22 -04:00
"desc" : "Returns a list of transaction IDs associated with the given [xyz]pub." ,
"optionalParams" : {
"gapLimit" : "Limit of empty addresses to end searching for transactions (default: 20)" ,
"addressLimit" : "Forced limit on the number of addresses to search through (both 'receive' and 'change' addresses up to this number will be searched)"
} ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/xyzpub/txids/xpub6EuV33a2DXxAhoJTRTnr8qnysu81AA4YHpLY6o8NiGkEJ8KADJ35T64eJsStWsmRf1xXkEANVjXFXnaUKbRtFwuSPCLfDdZwYNZToh4LBCd"
2022-05-18 00:12:22 -04:00
} ,
2021-05-21 10:54:05 -04:00
// mining
{
"category" : "mining" ,
2023-04-05 16:56:40 -04:00
"url" : "/mining/hashrate" ,
"desc" : "Returns the network hash rate, estimated over the last 1, 7, 30, 90, and 365 days."
2021-05-21 10:54:05 -04:00
} ,
{
"category" : "mining" ,
2023-04-05 16:56:40 -04:00
"url" : "/mining/diff-adj-estimate" ,
"desc" : "Returns the current estimate for the next difficulty adjustment as a percentage."
2021-05-21 10:54:05 -04:00
} ,
2021-09-30 14:37:00 -04:00
{
"category" : "mining" ,
2023-04-05 16:56:40 -04:00
"url" : "/mining/next-block" ,
"desc" : "Returns a summary for the estimated next block to be mined (produced via getblocktemplate)."
2021-09-30 14:37:00 -04:00
} ,
{
"category" : "mining" ,
2023-04-05 16:56:40 -04:00
"url" : "/mining/next-block/txids" ,
"desc" : "Returns a list of the transaction IDs included in the estimated next block to be mined (produced via getblocktemplate)."
2021-09-30 14:37:00 -04:00
} ,
{
"category" : "mining" ,
2023-04-05 16:56:40 -04:00
"url" : "/mining/next-block/includes/$TXID" ,
2021-09-30 14:37:00 -04:00
"desc" : "Returns whether the specified transaction ID is included in the estimated next block to be mined (produced via getblocktemplate)." ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/mining/next-block/includes/yourTxId"
2021-09-30 14:37:00 -04:00
} ,
2021-12-02 13:53:43 -05:00
{
"category" : "mining" ,
2023-04-05 16:56:40 -04:00
"url" : "/mining/miner-summary" ,
2021-12-02 13:53:43 -05:00
"desc" : "Returns whether the specified transaction ID is included in the estimated next block to be mined (produced via getblocktemplate)." ,
2022-05-18 00:12:22 -04:00
"optionalParams" : {
"since" : "Use the form 'Nd' to specify the number of day to look back (e.g. 'since=7d' will analyze the last 7 days)" ,
"startHeight+endHeight" : "Use these 2 parameters to specify a custom start/end height (e.g. 'startHeight=0&endHeight=24' to analyze the first 25 blocks)"
} ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/mining/miner-summary?since=1d"
2021-12-02 13:53:43 -05:00
} ,
2021-05-21 10:54:05 -04:00
// mempool
{
"category" : "mempool" ,
2023-04-05 16:56:40 -04:00
"url" : "/mempool/count" ,
"desc" : "Returns the number of transactions in Bitcoin Core's mempool."
2021-05-21 10:54:05 -04:00
} ,
2022-11-19 18:50:08 -04:00
{
"category" : "mempool" ,
2023-04-05 16:56:40 -04:00
"url" : "/mempool/summary" ,
2022-12-09 11:44:02 -05:00
"desc" : "Returns a summary of Bitcoin Core's mempool (full output from 'getmempoolinfo')" ,
2022-11-19 18:50:08 -04:00
"example" : { "loaded" : true , "size" : 225 , "bytes" : 76209 , "usage" : 410496 , "total_fee" : 0.01763495 , "maxmempool" : 15000000 , "mempoolminfee" : 0.00001 , "minrelaytxfee" : 0.00001 , "unbroadcastcount" : 0 }
} ,
2021-05-21 10:54:05 -04:00
{
"category" : "mempool" ,
2023-04-05 16:56:40 -04:00
"url" : "/mempool/fees" ,
2021-05-21 10:54:05 -04:00
"desc" : "Returns recommended fee rates in sats/vB for next block, ~30 min, 1 hr, and 1 day." ,
"example" : { "nextBlock" : 17 , "30min" : 9 , "60min" : 9 , "1day" : 9 }
} ,
// price
{
"category" : "price" ,
2023-04-05 16:56:40 -04:00
"url" : "/price" ,
2021-05-21 10:54:05 -04:00
"desc" : "Returns the price of 1 BTC, in USD, EUR, GBP, and XAU" ,
2022-12-05 10:36:50 -05:00
"optionalParams" : {
"format" : "Set to 'true' to include thousands-separator formatting in results"
}
2021-05-21 10:54:05 -04:00
} ,
{
"category" : "price" ,
2023-04-05 16:56:40 -04:00
"url" : "/price/marketcap" ,
"desc" : "Returns the market cap of Bitcoin, in USD, EUR, GBP, XAU" ,
2021-05-21 10:54:05 -04:00
} ,
{
"category" : "price" ,
2023-04-05 16:56:40 -04:00
"url" : "/price/sats" ,
"desc" : "Returns the price of 1 unit of [USD, EUR, GBP, XAU] (e.g. 1 \"usd\") in satoshis (aka \"Moscow Time\")" ,
2021-05-21 10:54:05 -04:00
} ,
2021-05-29 17:28:53 -04:00
// fun
{
"category" : "fun" ,
2023-04-05 16:56:40 -04:00
"url" : "/quotes/all" ,
2021-07-23 20:09:04 -04:00
"desc" : "Returns the full curated list of Bitcoin quotes." ,
2021-05-29 17:28:53 -04:00
} ,
{
"category" : "fun" ,
2023-04-05 16:56:40 -04:00
"url" : "/quotes/$INDEX" ,
2021-07-23 20:09:04 -04:00
"desc" : "Returns the Bitcoin quote with the given index from the curated list." ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/quotes/0"
2021-07-23 20:09:04 -04:00
} ,
{
"category" : "fun" ,
2023-04-05 16:56:40 -04:00
"url" : "/quotes/random" ,
"desc" : "Returns a random Bitcoin quote from the curated list."
2021-05-29 17:28:53 -04:00
} ,
2022-05-22 10:50:27 -04:00
{
"category" : "fun" ,
2023-04-05 16:56:40 -04:00
"url" : "/holidays/all" ,
"desc" : "Returns the full curated list of Bitcoin Holidays."
2022-05-22 10:50:27 -04:00
} ,
{
"category" : "fun" ,
2023-04-05 16:56:40 -04:00
"url" : "/holidays/today" ,
2022-05-22 10:50:27 -04:00
"desc" : "Returns the Bitcoin Holidays celebrated 'today' (i.e. at the time the API call is made)." ,
"optionalParams" : {
"tzOffset" : "The number of hours to offset from UTC for the caller's local timezone, e.g. \"-5\" for EST"
} ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/holidays/today?tzOffset=-5"
2022-05-22 10:50:27 -04:00
} ,
{
"category" : "fun" ,
2023-04-05 16:56:40 -04:00
"url" : "/holidays/$DAY" ,
2022-05-23 09:43:35 -04:00
"desc" : "Returns the Bitcoin Holidays celebrated on the specified day, using one of the following formats: yyyy-MM-DD, MM-DD." ,
2023-04-05 16:56:40 -04:00
"testUrl" : "/holidays/01-03"
2022-05-22 10:50:27 -04:00
} ,
2021-05-30 09:47:43 -04:00
// admin
{
"category" : "admin" ,
2023-04-05 16:56:40 -04:00
"url" : "/version" ,
"desc" : "Returns the semantic version of the public API, which is maintained separate from the app version."
2021-05-30 09:47:43 -04:00
} ,
2021-05-21 10:54:05 -04:00
]
}