---
title: "Instrument"
url: https://docs.truemarkets.co/api/websocket/institutional/instrument
description: "Message sent from server with instrument data."
---

Docs index: https://docs.truemarkets.co/llms.txt

# Instrument

True Markets CeFi WebSocket sends these messages to you.

Address: `/v1/cefi/market`

## Servers

- `wss://api.truemarkets.co` (Production, wss)
- `wss://api.uat.truemarkets.co` (Uat, wss)

## Messages

### instrument

Payload: `InstrumentPayload`

Example payload:

```json
{
  "seqnum": "string",
  "channel": "INSTRUMENT",
  "update": "SNAPSHOT",
  "data": {
    "id": "string",
    "status": "DISABLED",
    "info": {
      "symbol": "string",
      "reference_price": "string",
      "base_asset_id": "string",
      "quote_asset_id": "string",
      "price_limit_window_secs": "string",
      "price_limit_percent": "string",
      "price_bands_percent": "string"
    },
    "stats": {
      "last_24hr_notional": "string",
      "last_24hr_quantity": "string"
    }
  }
}
```

## Types

```ts
export type InstrumentMessage = InstrumentPayload;

export type InstrumentPayload =
  | {
  /** Current sequence number of the channel. */
  seqnum: string;
  channel: "INSTRUMENT";
  update: "SNAPSHOT" | "UPDATE";
  data: Instrument;
}
  | {
  /** Current sequence number of the channel. */
  seqnum: string;
  channel: "INSTRUMENT";
  update: "SNAPSHOT_COMPLETE";

  /** The subscribed item whose snapshot is complete. For single-instrument subscriptions this is the symbol (e.g. BTC-PYUSD). For all-instruments subscriptions this is ALL. */
  item: string;
};

export interface Instrument {
  /** Exchange assigned ID of the instrument. */
  id?: string;

  /** Current instrument state. */
  status?: "DISABLED" | "OPENING" | "ACTIVE" | "HALTED";
  info?: {
    /** Human readable representation of the instrument. */
    symbol?: string;

    /** Price used for initial price limit/band calcuations. */
    reference_price?: string;

    /** ID of the base asset. */
    base_asset_id?: string;

    /** ID of the quote asset. */
    quote_asset_id?: string;

    /** Number of seconds in the price limit's sliding window. */
    price_limit_window_secs?: string;

    /** Specifies the percentage threshold for price movement beyond a reference price (e.g., the midpoint or previous close) at which the exchange will take action. If the price of a trade or order breaches this threshold, the exchange may halt trading, trigger a circuit breaker, or initiate other predefined actions to ensure market stability. */
    price_limit_percent?: string;

    /** Defines the acceptable price range for order validation within the market. The price bands ensure that orders are priced within a range around the market's midpoint, adjusted for increments and thresholds. */
    price_bands_percent?: string;
  };
  stats?: InstrumentStat & Record<string, unknown>;
}

export interface InstrumentStat {
  /** The notional (quantity * price) amount of REFERENCE_ASSET traded over the last 24hr period. */
  last_24hr_notional?: string;

  /** The quantity traded over the last 24 hour period. */
  last_24hr_quantity?: string;
}
```