Receive real-time market data

Add MCP server to your AI tool

Allow AI tools and LLMs to interact with the API documentation portal through MCP.

MCP server URL

https://bump.sh/tie-tech/hub/b2b-api/doc/broker-asyncapi/mcp

Standard setup for AI tools providing an mcp.json file

mcp.json
{
  "broker-asyncapi MCP server": {
    "url": "https://bump.sh/tie-tech/hub/b2b-api/doc/broker-asyncapi/mcp"
  }
}

Close
/market-data

Real-time market data stream with dynamic topic subscription (order book snapshots/diffs, trades).

Subscription Model (no query parameters):

  • Connection starts with zero markets subscribed
  • Client sends a subscribe frame (MDClientSubscribe) listing market_id values
  • Server replies with exactly one MDBookSnapshot per NEW market, then streams MDBookDiff / MDTrade
  • Client may send unsubscribe (MDClientUnsubscribe) to stop updates for specific markets
  • Repeated subscription for already active market without force_snapshot is idempotent (no extra snapshot)

Ordering / Monotonicity:

  • md_seq is dense and strictly increasing per market_id ONLY on data frames (book_snapshot, book_diff, trade)
  • heartbeat does not advance md_seq
  • Gaps in md_seq per market indicate operational incident; client SHOULD resync (fresh snapshot + re-subscribe)

Initial Snapshots:

  • Snapshot sent only upon successful subscription (or re-subscription with force_snapshot=true)

Snapshots Cadence:

  • Periodic server-initiated book_snapshot frames limit diff chain length
  • Clients MUST apply snapshot then contiguous diffs/trades with md_seq = snapshot.md_seq+1 … without gaps

Operation WebSockets-specific information

  • headers object
    Hide headers attributes Show headers attributes object
    • PRE-ACCESS-KEY string Required

      Broker access key identifier

      Format should match the following pattern: ^[A-Za-z0-9._~-]{1,64}$.

    • PRE-ACCESS-TIMESTAMP string(date-time) Required

      RFC3339 timestamp with milliseconds

    • PRE-ACCESS-SIGNATURE string Required

      Keyed BLAKE2b-256 signature hex lowercase

      Format should match the following pattern: ^[0-9a-f]{64}$.

SUBSCRIBE /market-data

Order Book Snapshot

Full order book snapshot for a market

Payload

  • type string Required

    Value is book_snapshot.

  • market_id string Required
  • md_seq integer(int64) Required

    Minimum value is 0.

  • ts_ns integer(int64) Required
  • bids array[object] Required
    Hide bids attributes Show bids attributes object
    • price object Required
      Hide price attributes Show price attributes object
      • units integer(int64) Required
      • nanos integer(int32) Required

        Minimum value is -999999999, maximum value is 999999999.

    • qty object Required
      Hide qty attributes Show qty attributes object
      • units integer(int64) Required
      • nanos integer(int32) Required

        Minimum value is -999999999, maximum value is 999999999.

  • asks array[object] Required
    Hide asks attributes Show asks attributes object
    • price object Required
      Hide price attributes Show price attributes object
      • units integer(int64) Required
      • nanos integer(int32) Required

        Minimum value is -999999999, maximum value is 999999999.

    • qty object Required
      Hide qty attributes Show qty attributes object
      • units integer(int64) Required
      • nanos integer(int32) Required

        Minimum value is -999999999, maximum value is 999999999.

Payload examples
{
  "type": "book_snapshot",
  "market_id": "string",
  "md_seq": 42,
  "ts_ns": 42,
  "bids": [
    {
      "price": {
        "units": 42,
        "nanos": 42
      },
      "qty": {
        "units": 42,
        "nanos": 42
      }
    }
  ],
  "asks": [
    {
      "price": {
        "units": 42,
        "nanos": 42
      },
      "qty": {
        "units": 42,
        "nanos": 42
      }
    }
  ]
}

Order Book Diff

Incremental order book update (delta)

Payload

  • type string Required

    Value is book_diff.

  • market_id string Required
  • md_seq integer(int64) Required

    Minimum value is 0.

  • ts_ns integer(int64) Required
  • bids array[object] Required

    Price level deltas (upsert or delete if qty=0)

    Hide bids attributes Show bids attributes object
    • price object Required
      Hide price attributes Show price attributes object
      • units integer(int64) Required
      • nanos integer(int32) Required

        Minimum value is -999999999, maximum value is 999999999.

    • qty object Required
      Hide qty attributes Show qty attributes object
      • units integer(int64) Required
      • nanos integer(int32) Required

        Minimum value is -999999999, maximum value is 999999999.

  • asks array[object] Required

    Price level deltas (upsert or delete if qty=0)

    Hide asks attributes Show asks attributes object
    • price object Required
      Hide price attributes Show price attributes object
      • units integer(int64) Required
      • nanos integer(int32) Required

        Minimum value is -999999999, maximum value is 999999999.

    • qty object Required
      Hide qty attributes Show qty attributes object
      • units integer(int64) Required
      • nanos integer(int32) Required

        Minimum value is -999999999, maximum value is 999999999.

Payload examples
{
  "type": "book_diff",
  "market_id": "string",
  "md_seq": 42,
  "ts_ns": 42,
  "bids": [
    {
      "price": {
        "units": 42,
        "nanos": 42
      },
      "qty": {
        "units": 42,
        "nanos": 42
      }
    }
  ],
  "asks": [
    {
      "price": {
        "units": 42,
        "nanos": 42
      },
      "qty": {
        "units": 42,
        "nanos": 42
      }
    }
  ]
}

Trade Event

Trade execution notification

Payload

  • type string Required

    Value is trade.

  • market_id string Required
  • md_seq integer(int64) Required

    Minimum value is 0.

  • ts_ns integer(int64) Required
  • trade_id string Required
  • price object Required
    Hide price attributes Show price attributes object
    • units integer(int64) Required
    • nanos integer(int32) Required

      Minimum value is -999999999, maximum value is 999999999.

  • qty object Required
    Hide qty attributes Show qty attributes object
    • units integer(int64) Required
    • nanos integer(int32) Required

      Minimum value is -999999999, maximum value is 999999999.

  • taker_side string Required

    Values are BUY or SELL.

Payload examples
{
  "type": "trade",
  "market_id": "string",
  "md_seq": 42,
  "ts_ns": 42,
  "trade_id": "string",
  "price": {
    "units": 42,
    "nanos": 42
  },
  "qty": {
    "units": 42,
    "nanos": 42
  },
  "taker_side": "BUY"
}

Market Data Heartbeat

Keep-alive heartbeat (does not advance md_seq)

Payload

  • type string Required

    Value is heartbeat.

  • ts_ns integer(int64) Required
  • market_id string | null

    Optional; may be omitted for aggregated heartbeat across all subscribed markets

  • md_seq integer(int64) | null

    Repeats last data md_seq for the specific market if market_id present; absent for aggregated heartbeat

    Minimum value is 0.

Payload examples
{
  "type": "heartbeat",
  "ts_ns": 42,
  "market_id": "string",
  "md_seq": 42
}

Market Data Error

Market data stream error notification

Payload

  • type string Required

    Value is error.

  • ts_ns integer(int64) Required
  • payload object Required
    Hide payload attributes Show payload attributes object
    • code string Required
    • message string Required
    • details object

      Additional properties are allowed.

Payload examples
{
  "type": "error",
  "ts_ns": 42,
  "payload": {
    "code": "string",
    "message": "string",
    "details": {}
  }
}