Our WebSocket API allows developers to receive Real-Time notifications about new transactions and blocks. The Websocket echo test can be useful for debugging.

Connection URL:


Status Updates

Regardless of channel subscription you may receive status messages. This should be displayed to the user.

{"op":"status", "msg", "Connected, Subscribed, Welcome etc..."}

Once the socket is open you can subscribe to a channel by sending an "op" message.

Subscribing to Unconfirmed transactions

Subscribe to notifications for all new bitcoin transactions.


Subscribing to an Address

Receive new transactions for a specific bitcoin address:

{"op":"addr_sub", "addr":"$bitcoin_address"}

Message on new transaction:

    "op": "utx",
    "x": {
        "hash": "f6c51463ea867ce58588fec2a77e9056046657b984fd28b1482912cdadd16374",
        "ver": 1,
        "vin_sz": 4,
        "vout_sz": 2,
        "lock_time": "Unavailable",
        "size": 796,
        "relayed_by": "",
        "tx_index": 3187820,
        "time": 1331300839,
        "inputs": [
                "prev_out": {
                    "value": 10000000,
                    "type": 0,
                    "addr": "12JSirdrJnQ8QWUaGZGiBPBYD19LxSPXho"
        "out": [
                "value": 2800000000,
                "type": 0,
                "addr": "1FzzMfNt46cBeS41r6WHDH1iqxSyzmxChw"

Subscribing to new Blocks

Receive notifications when a new block is found. Note: if the chain splits you will receive more than one notification for a specific block height.


Message On New Block:

    "op": "block",
    "x": {
        "txIndexes": [
        "nTx": 0,
        "totalBTCSent": 0,
        "estimatedBTCSent": 0,
        "reward": 0,
        "size": 0,
        "blockIndex": 190460,
        "prevBlockIndex": 190457,
        "height": 170359,
        "hash": "00000000000006436073c07dfa188a8fa54fefadf571fd774863cda1b884b90f",
        "mrklRoot": "94e51495e0e8a0c3b78dac1220b2f35ceda8799b0a20cfa68601ed28126cfcc2",
        "version": 1,
        "time": 1331301261,
        "bits": 436942092,
        "nonce": 758889471

Debugging OPs:


Responds with the latest block


Responds with the latest transaction. If subscribed to any addresses it will respond with the latest transaction involving those addresses.