Freedom Street

API

The API provides HTTP endpoints for querying blockchain data across Bitcoin (BTC), Bitcoin Cash (BCH), Litecoin (LTC), Dogecoin (DOGE), Dash (DASH), and eCash (XEC).

Base URL: https://api.freedom.st

All endpoints return JSON. Transaction and block responses use the { type, crypto, data } envelope format, consistent with Socket API events.

Network Prefix

Most endpoints accept an optional network prefix. Without it, the API searches all networks.

/tx/{hash}             Search all networks
/btc/tx/{hash}         Search BTC only

/block/943587          Search all networks for height 943587
/btc/block/943587      Get BTC block at height 943587

/info                  Info for all networks
/btc/info              Info for BTC only

Supported networks: btc, bch, ltc, doge, dash, xec

Transactions

Get Transaction

GET https://api.freedom.st/tx/{hash}

Returns full transaction data including inputs, outputs, fees, and confirmation status. Checks the database first, falls back to querying nodes directly.

{
  "type": "tx",
  "crypto": "btc",
  "data": {
    "hash": "7bf9e6990a92d1a9e65d97040e29ea0d0492ee7f756524474b4754250221e752",
    "seen": 1775196460,
    "version": 2,
    "locktime": 0,
    "mined": 1775196460,
    "block": "00000000000000000000193bc4e2031f73d252f27d3b63e2b0b25da6059c6eda",
    "size": 296,
    "fee": 0.000043,
    "fee_usd": 2.9,
    "from": [
      {
        "hash": "a3d76c33dacc244fc2c678e7757842c97b984ecd88765a6449604ba52b0de78a",
        "index": 2,
        "sequence": 4294967293,
        "address": "bc1qryhgpmfv03qjhhp2dj8nw8g4ewg08jzmgy3cyx",
        "script_type": "witness_v0_keyhash",
        "amount": 4.72206009,
        "amount_usd": 318202.39
      }
    ],
    "to": [
      {
        "index": 0,
        "address": "bc1qm7gggnv0etatlsguu8tjhraf06uwp0awu37pnq",
        "script_type": "witness_v0_keyhash",
        "script": "0014df90844d8fcafabfc11ce1d72b8fa97eb8e0bfae",
        "amount": 0.00276766,
        "amount_usd": 186.5
      },
      {
        "index": 1,
        "address": "bc1qryhgpmfv03qjhhp2dj8nw8g4ewg08jzmgy3cyx",
        "script_type": "witness_v0_keyhash",
        "script": "0014192e80ed2c7c412bdc2a6c8f371d15cb90f3c85b",
        "amount": 4.69391307,
        "amount_usd": 316305.67,
        "spent": "7bf9e6990a92d1a9e65d97040e29ea0d0492ee7f756524474b4754250221e752"
      },
      {
        "index": 2,
        "address": "bc1q7nnmc5kwzy2m44hw0vsexg46yw2k28089s5z6vfex8lktgxtz7wseert2f",
        "script_type": "witness_v0_scripthash",
        "script": "0020f4e7bc52ce1115bad6ee7b219322ba2395651de72c282d313931ff65a0cb179d",
        "amount": 0.02019476,
        "amount_usd": 1360.85,
        "spent": "7bf9e6990a92d1a9e65d97040e29ea0d0492ee7f756524474b4754250221e752"
      },
      {
        "index": 3,
        "address": "bc1q9g0fv4hemwjykz4cq8suuynzkxzt599a284l9v",
        "script_type": "witness_v0_keyhash",
        "script": "00142a1e9656f9dba44b0ab801e1ce1262b184ba14bd",
        "amount": 0.0051416,
        "amount_usd": 346.47,
        "spent": "7bf9e6990a92d1a9e65d97040e29ea0d0492ee7f756524474b4754250221e752"
      }
    ],
    "block_index": 27,
    "vsize": 215,
    "weight": 857
  }
}

Outputs include a spent field with the spending transaction hash when the output has been spent.

RBF Status

GET https://api.freedom.st/tx/{hash}/rbf

Checks if a transaction has been replaced via Replace-By-Fee.

When replaced:

{
  "replaced": true,
  "opt_in": true,
  "outputs_changed": true,
  "old_hash": "048b6041694f0ee1567a55d015661bfcbf3d6771d60cbc28040f2d59c1b0937d",
  "old_fee": 0.00000203,
  "old_fee_usd": 0.14,
  "new_hash": "5856d22c50e42be84cedee272031190a0954cabe91392348f7aad35f184de807",
  "new_fee": 0.00000468,
  "new_fee_usd": 0.31
}

When not replaced:

{
  "replaced": false
}

CPFP Analysis

GET https://api.freedom.st/{network}/tx/{hash}/cpfp

Returns Child-Pays-For-Parent fee analysis for a mempool transaction. Fee rates are in sat/vB. Requires network prefix.

{
  "hash": "67c4bf893127a395ed5d17af20bd976d1f690c07d535dbb09713bc5a54b3cff2",
  "in_mempool": true,
  "fee_rate": 5.2,
  "package_fee_rate": 8.1,
  "ancestors": [
    { "hash": "1930b72b...", "fee": 0.00000300, "vsize": 140, "fee_rate": 2.143 }
  ],
  "descendants": [
    { "hash": "a1b2c3d4...", "fee": 0.00002000, "vsize": 200, "fee_rate": 10.0 }
  ]
}

package_fee_rate is computed via ancestor-package scoring (BTC, LTC, DOGE, DASH). Omitted for BCH and XEC.

When not in mempool:

{
  "hash": "67c4bf893127a395ed5d17af20bd976d1f690c07d535dbb09713bc5a54b3cff2",
  "in_mempool": false
}

Raw Transaction

GET https://api.freedom.st/{network}/tx/{hash}/raw

Returns the serialized transaction as a hex string. Response content type is text/plain.

Blocks

Get Block

GET https://api.freedom.st/block/{hash or height}

Returns block data. Accepts a block hash or numeric height.

{
  "type": "block",
  "crypto": "btc",
  "data": {
    "hash": "000000000000000000010391f292467e02d166a172684750f23222f6d75c5e05",
    "seen": 1775278318,
    "height": 943587,
    "version": "2c2da000",
    "mined": 1775278318,
    "previous_block": "000000000000000000018abc2b20bc00fae79ba53770106122e47420c93ef23c",
    "merkle_root": "a853b0b15fbab2897b21cd78d97b2dc9748b67bb049079df2c1b65cd3a5d8aa3",
    "size": 1550516,
    "weight": 3993707,
    "mining": {
      "nonce": 868323383,
      "bits": "17020684",
      "difficulty": "138966872071213",
      "chainwork": "00000000000000000000000000000000000000011cc048b774f70b6bf763eb60",
      "miner": "Foundry USA",
      "miner_message": "/Foundry USA Pool #dropgold/..."
    },
    "vsize": 814397,
    "tx_count": 2682,
    "reward": {
      "hash": "b475a4ff15a75b8c077c627eed7f6dd70f4ccde24f5099ab9adcc662981caee6",
      "subsidy": 3.125,
      "subsidy_usd": 210647.56,
      "fees": 0.0273978,
      "fees_usd": 1846.81
    },
    "transactions": [
      { "hash": "b475a4ff15a75b8c077c627eed7f6dd70f4ccde24f5099ab9adcc662981caee6", "index": 0 },
      { "hash": "7bf9e6990a92d1a9e65d97040e29ea0d0492ee7f756524474b4754250221e752", "index": 1 }
    ]
  }
}

Browse Blocks

GET https://api.freedom.st/blocks

Returns a paginated list of recent blocks. Optional network prefix filters by network.

Parameters:

Param Type Default Description
limit number 20 Results per page (max 100)
before number now Unix timestamp anchor for stable pagination
skip number 0 Offset within the anchored result set
GET /btc/blocks?limit=2
{
  "data": [
    {
      "type": "block",
      "crypto": "btc",
      "data": {
        "hash": "00000000000000000001d8e3f19e5e093fa3b0bf241788139695ecb54c371b66",
        "seen": 1775388286,
        "height": 943755,
        "version": "291b6000",
        "mined": 1775388260,
        "previous_block": "0000000000000000000025cb06539a3064c3e53bfd55061cef43da6ae3f6856d",
        "merkle_root": "384fa757e9572e78a2f8b8a1ff2f8cda0232b9e9f599b8dbe911936c5f1b8aad",
        "size": 1626685,
        "weight": 3993508,
        "mining": {
          "nonce": 3834847560,
          "bits": "17020684",
          "difficulty": "138966872071213",
          "chainwork": "00000000000000000000000000000000000000011d133a7fc65dda7d60aaf1a0",
          "miner": "Foundry USA"
        },
        "vsize": 788941,
        "tx_count": 6902,
        "reward": {
          "hash": "42194605ef30997cc594cebeed59d66b4f7f147b7dec1fefc402ee4214d35210",
          "subsidy": 3.125,
          "subsidy_usd": 209473.19,
          "fees": 0.00304558,
          "fees_usd": 204.15
        }
      }
    },
    {
      "type": "block",
      "crypto": "btc",
      "data": {
        "hash": "0000000000000000000025cb06539a3064c3e53bfd55061cef43da6ae3f6856d",
        "seen": 1775388134,
        "height": 943754,
        "version": "2482e000",
        "mined": 1775388120,
        "mining": {
          "miner": "AntPool"
        },
        "tx_count": 5245,
        "reward": {
          "subsidy": 3.125,
          "fees": 0.01384821
        }
      }
    }
  ],
  "has_more": true
}

The before parameter anchors the result set so that new blocks arriving between page loads don't shift the results. Set it once on the first page load and reuse it for subsequent pages.

Addresses

Get Address

GET https://api.freedom.st/address/{address}

Returns balance, UTXOs, and transaction history for an address.

{
  "address": "bc1qm7gggnv0etatlsguu8tjhraf06uwp0awu37pnq",
  "script": "0014df90844d8fcafabfc11ce1d72b8fa97eb8e0bfae",
  "crypto": "btc",
  "received": 0.00276766,
  "received_confirmed": 0.00276766,
  "sent": 0,
  "sent_confirmed": 0,
  "transactions": [
    {
      "hash": "7bf9e6990a92d1a9e65d97040e29ea0d0492ee7f756524474b4754250221e752",
      "amount": 0.00276766,
      "amount_usd": 185.51,
      "block": "00000000000000000000193bc4e2031f73d252f27d3b63e2b0b25da6059c6eda",
      "seen": 1775196460
    }
  ]
}

In transactions, positive amounts are received and negative amounts are sent. For UTXOs, use the dedicated /{network}/address/{address}/utxo endpoint.

UTXOs

GET https://api.freedom.st/{network}/address/{address}/utxo

Returns unspent transaction outputs for an address. Requires network prefix. Each UTXO includes everything needed to construct a spending transaction.

[
  {
    "hash": "7bf9e6990a92d1a9e65d97040e29ea0d0492ee7f756524474b4754250221e752",
    "index": 0,
    "address": "bc1qm7gggnv0etatlsguu8tjhraf06uwp0awu37pnq",
    "amount": 0.00276766,
    "script_type": "witness_v0_keyhash",
    "script": "0014df90844d8fcafabfc11ce1d72b8fa97eb8e0bfae"
  }
]

Mempool

Browse Mempool

GET https://api.freedom.st/mempool

Returns a paginated list of recent unconfirmed transactions. Same pagination parameters as /blocks. Optional network prefix.

Mempool list responses include transaction metadata (hash, fee, size, seen) but not full inputs/outputs. Use /tx/{hash} for complete transaction data.

Mempool Info

GET https://api.freedom.st/{network}/mempool/info

Returns mempool statistics for a network. Requires network prefix.

{
  "recommended_fee": 1,
  "transactions": 90,
  "size": 18539
}

recommended_fee is in sat/vB. size is total mempool size in bytes.

Network Info

All Networks

GET https://api.freedom.st/info

Returns node, mempool, blockchain, and mining information for all supported networks.

{
  "btc": {
    "node": {
      "chain": "main",
      "sync_progress": "0.9999998753229447",
      "syncing": false,
      "disk_size": 833255932550,
      "pruned": false,
      "uptime": 274905
    },
    "mempool": {
      "recommended_fee": 1,
      "transactions": 90,
      "size": 18539
    },
    "blockchain": {
      "blocks": 943755,
      "best_block": "00000000000000000001d8e3f19e5e093fa3b0bf241788139695ecb54c371b66",
      "time": 1775388260,
      "median_time": 1775386302
    },
    "mining": {
      "difficulty": "138966872071213",
      "bits": "17020684",
      "target": "0000000000000000000206840000000000000000000000000000000000000000",
      "chainwork": "00000000000000000000000000000000000000011d133a7fc65dda7d60aaf1a0",
      "hashrate": "976816231921619400000",
      "max_block_size": 4000000
    },
    "warnings": []
  },
  "bch": { ... },
  "ltc": { ... },
  "doge": { ... },
  "dash": { ... },
  "xec": { ... }
}

Single Network

GET https://api.freedom.st/{network}/info

Returns the same structure for a single network.

Exchange Rates

GET https://api.freedom.st/rates

Returns current USD exchange rates.

{
  "btc": 67031.42,
  "dash": 30.01,
  "doge": 0.09033,
  "ltc": 52.87,
  "bch": 434.69
}

Broadcasting

Broadcast Transaction

GET https://api.freedom.st/{network}/broadcast/{rawtx}

Broadcasts a signed raw transaction. Requires network prefix.

{
  "hash": "67c4bf893127a395ed5d17af20bd976d1f690c07d535dbb09713bc5a54b3cff2"
}

Bulk Broadcast

POST https://api.freedom.st/{network}/broadcast

Broadcasts multiple transactions (max 256).

Body:

{
  "txs": ["0200000001...", "0200000001..."]
}

Response:

[
  { "hash": "67c4bf89..." },
  { "error": "Missing inputs" }
]

Utilities

QR Code

GET https://api.freedom.st/qr/{text}

Returns a QR code as a PNG image.

BCH Token Info

GET https://api.freedom.st/token/{categoryId}

Returns CashToken metadata for a BCH token category.

Error Responses

All endpoints return errors as JSON with an appropriate HTTP status code:

{
  "error": "Transaction not found"
}
Status Meaning
400 Bad request (invalid parameters)
404 Resource not found
500 Server error
503 Node unavailable

Advanced: Query Endpoint

For complex searches that aren't covered by the endpoints above, a generic query interface is available. It allows arbitrary filtering, sorting, and pagination against the blockchain database.

POST https://api.freedom.st/query
GET https://api.freedom.st/query?q={base64(JSON)}

Open Query Playground

Body:

{
  "find": { "type": "tx", "crypto": "btc", "data.fee": { "gt": 0.01 } },
  "sort": { "data.seen": -1 },
  "limit": 50
}
Field Type Description
find object Filter conditions using operators below
sort object Sort order. 1 ascending, -1 descending
limit number Max results (default 1000, max 5000)
skip number Offset for pagination
count boolean Include total count in response
project array Field paths to include

Operators

Op Meaning Example
(value) Equals { "crypto": "btc" }
(array) Any of { "crypto": ["btc", "ltc"] }
eq Equal { "data.fee": { "eq": 0.001 } }
ne Not equal { "crypto": { "ne": "btc" } }
gt Greater than { "data.fee": { "gt": 0.001 } }
lt Less than { "data.fee": { "lt": 0.01 } }
ge Greater/equal { "data.size": { "ge": 500 } }
le Less/equal { "data.to.amount": { "le": 0.01 } }
sw Starts with { "data.to.address": { "sw": "bc1q" } }
ew Ends with { "data.to.address": { "ew": "abc" } }
co Contains { "data.mining.miner_message": { "co": "pool" } }

Queryable Fields

Path Description
type "tx" or "block"
crypto Network identifier
data.seen Index timestamp (Unix seconds)
data.hash Transaction or block hash
data.block Block hash (null if unconfirmed)
data.fee / data.fee_usd Transaction fee
data.size / data.vsize / data.weight Size metrics
data.from.address / data.from.amount Input fields
data.to.address / data.to.amount / data.to.script_type Output fields
data.height Block height
data.mining.miner / data.mining.difficulty Block mining fields