These tracking technologies are strictly necessary for the Site to function and provide you with essential features, such as to allow you to log in to secure areas of the Site. Because these technologies are essential for the Site and its features to work, you cannot decline using these technologies.
Read morePublic FIX Interface v2
For FIX Interface access, contact support.
- 1 Introduction
- 2 Supported Fix Messages
-
3 FIX Session Layer
- 3.1 FIX Sesion Management
- 3.2 FIX Session Level Messages
-
3.3 FIX Application Level
Messages
- 3.3.1 FIX Component Blocks
- 3.3.2 FIX General
- 3.3.3 Market Data
-
3.3.4 Trading
- 3.3.4.1 New Order – Single (MsgType = ‘D’)
- 3.3.4.2 Order Cancel Request (MsgType = ‘F’)
- 3.3.4.3 Order Mass Cancel Request (MsgType = ‘q’)
- 3.3.4.4 Execution Report (MsgType = ‘8’)
- 3.3.4.5 Order Status Request (MsgType = ‘H’)
- 3.3.4.6 Order Cancel Reject (MsgType = ‘9’)
- 3.3.4.7 Order Mass Cancel Report (MsgType = ‘r’)
- 3.3.4.8 Business Message Reject (MsgType = ‘j’)
- 4 Appendix
1 Introduction
This is a public FIX Interface. It describes FIX messaging interface (messages, component blocks, and fields) supported by Bitstamp FIX Gateway. This interface is based on standard FIX 4.4 (Financial Information eXchange protocol, http://www.fixtradingcommunity.org/) and is adopted to Bitstamp FIX Gateway specifics.
Bitstamp FIX Gateway supports only those messages, component blocks and fields, which are described in this document. Note that all fields, which are required or conditionally required by FIX 4.4 standard, but absent in Bitstamp Public FIX Interface specification are optional and will be ignored. Messages containing fields, which are absent in FIX 4.4 standard and in this document, will be considered as invalid and will be rejected.
Note: View the previous FIX documentation.
1.1 System Overview
Bitstamp FIX Gateway is FIX compliant gateway that provides a direct connectivity to the core Bitstamp trading infrastructure. The communication is done via appropriate FIX messages.
Bitstamp FIX Gateway operates in UTC time zone.
1.2 Reading Instructions
Each message or component block is presented in table. Each table row is a message field or component block having the following characteristics:
| Tag | unique field identifier | |
|---|---|---|
| Name | field name | |
| Req’d | ||
| shows whether the field is required or not in appropriate message or component block: | ||
| ‘Y’ | tag is required (mandatory) | |
| ‘N’ | tag is not required (optional) | |
| ‘C’ | tag is conditionally required. | |
| ‘Y*’ | tag is required by Bitstamp FIX Gateway, but not required by the standard FIX 4.4 protocol | |
| ‘N*’ | tag is not required by Bitstamp FIX Gateway, but required by the standard FIX 4.4 protocol | |
| Type | field type | |
| Comments | comments, list of valid values and additional information for the tag. | |
1.3 Changelog
|
2025-10-16
2025-09-25
2025-09-08
|
2 Supported FIX Messages
Session level messages
All FIX 4.4 session-level messages are supported. The structure and semantics of FIX messages are identical to the standard.
Application level messages
The following FIX application-level messages are supported:
| From FIX Client to Bitstamp FIX Gateway | |
|---|---|
| Market Data messages: | Market Data Request (MsgType = ‘V’) |
| Order Flow messages: | |
| New Order – Single (MsgType = ‘D‘) | |
| Order Cancel Request (MsgType = ‘F‘) | |
| Order Mass Cancel Request (MsgType = ‘q‘) | |
| Order Status Request (MsgType = ‘H‘) | |
| From Bitstamp FIX Gateway to FIX Client | |
|---|---|
| General messages: | News (MsgType = ‘B’) |
| Market Data messages: | |
| Market Data – Full Refresh (MsgType = ‘W’) | |
| Market Data – Incremental Refresh (MsgType = ‘X’) | |
| Market Data Request Reject (MsgType = ‘Y’) | |
| Order Flow messages: | |
| Execution Report (MsgType = ‘8’) | |
| Order Cancel Reject (MsgType = ‘9’) | |
| Order Mass Cancel Report (MsgType = ‘r’) | |
| Business Message Reject (MsgType = ‘j’) | |
Other application-level messages are not supported. All unsupported messages are rejected with Session Level Reject (MsgType = '3').
3 FIX Session Layer
3.1 FIX Session Management
3.1.2 FIX Session Termination
In order to close FIX session, FIX Client should submit Logout (MsgType = ‘5’) message, wait for confirming Logout and close TCP/IP socket connection to Bitstamp FIX Gateway host. FIX Client is allowed to start and stop FIX session at any time.
3.1.3 FIX Server Restart
Occasionally servers need to be restarted (e.g. due to software updates). When this happens, clients get a news message notifying them to reconnect. Clients have 10 seconds to reconnect, otherwise server logs them out automatically. To recover, users should send a Logon message.
Example:
- Server needs to be restarted. It sends the following FIX message: '8=FIX.4.4|9=109|35=B|34=44|49=BITSTAMP|52=20220401-12:01:11.145|56=<user_id>|148=Server is about to restart. Please reconnect|10=113|'
- Server waits for 10 seconds.
- If clients have not reconnected, the server logs them out, by sending the following message: '8=FIX.4.4|9=121|35=5|34=65|49=BITSTAMP|52=20220401-12:01:16.146|56=<user_id>|58=Disconnected due to server going under restart procedure.|10=109|'.
- Clients have to send a Logon message to reconnect.
3.1.4 Sequence Numbers Reset
Sequence numbers will be reset when a user reaches a predefined threshold. The threshold of sequence number is currently set to 1,000,000.
When the user reaches the sequence number threshold, the server sends a fix news event notifying the user of the upcoming sequence number reset. After that user has 5 seconds to reconnect and reset the sequence numbers. If the user does not respond, the server sends an OnLogout event with ResetSeqNumFlag set to ‘Y’.
Example:
- User exceeds a threshold.
- Server sends the following FIX message: '8=FIX.4.4|9=132|35=B|34=1000002|49=BITSTAMP|52=20220401-12:01:11.145|56=<user_id>|148=Sequence number threshold reached. Please reset sequence numbers.|10=234|'.
- Server waits for 5 seconds.
- If user has not reconnected, the server logs them out, by sending the following message: '8=FIX.4.4|9=130|35=5|34=1|49=BITSTAMP|52=20220401-12:01:16.146|56=<user_id>|58=Sequence number threshold reached. Resetting sequence number.|141=Y|10=231|'.
- User has to send a Logon message to reconnect.
3.1.5 Reject Handling
Bitstamp FIX Gateway will reject message deviating from expected ones as follows:
| FIX Message | Reject Reason |
|---|---|
| Session Level Reject (MsgType = ‘3’) |
Received FIX message violates FIX session level rules. Example:
|
3.2 FIX Session Level Messages
3.2.1 Logon (MsgType = ‘A’)
The Logon (A) message authenticates a user establishing a connection to a remote system. The Logon (A) message must be the first message sent by the application requesting to initiate a FIX session.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'A' | ||
| 58 | Text | N | String |
We support the following parameters:
Examples:
|
| 98 | EncryptMethod | Y | Int |
Method of encryption. Supported values:
|
| 108 | HeartBtInt | Y | Int | Heartbeat interval in seconds. |
| 141 | ResetSeqNumFlag | N | Boolean | Indicates that the both sides of the FIX session should reset sequence numbers. |
| 553 | Username | Y* | String | Must contain API key assigned to the customer. |
| 554 | Password | Y* | String | Must contain API secret assigned to the customer. |
| <Standard Message Trailer> | Y | |||
3.2.2 Heartbeat (MsgType = ‘0’)
The Heartbeat (0) monitors the status of the communication link and identifies when the last of a string of messages was not received.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = '0' | ||
| 112 | TestReqID | N | String | Identifier included in Test Request (1) message to be returned in resulting Heartbeat (0). |
| <Standard Message Trailer> | Y | |||
3.2.3 Test Request (MsgType = ‘1’)
The Test Request (1) message forces a heartbeat from the opposing application. The Test Request (1) message checks sequence numbers or verifies communication line status. The opposite application responds to the Test Request (1) with a Heartbeat (0) containing the TestReqID (112).
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = '1' | ||
| 112 | TestReqID | Y | String | Identifier included in Test Request (1) message to be returned in resulting Heartbeat (0). |
| <Standard Message Trailer> | Y | |||
3.2.4 Resend Request (MsgType = ‘2’)
The resend request is sent by the receiving application to initiate the retransmission of messages. This function is utilized if a sequence number gap is detected, if the receiving application lost a message, or as a function of the initialization process.
The resend request can be used to request a single message, a range of messages or all messages subsequent to a particular message.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = '2' | ||
| 7 | BeginSeqNo | Y | SeqNum | Message sequence number of first message in range to be resent. |
| 16 | EndSeqNo | Y | SeqNum | Message sequence number of last message in range to be resent. If request is for a single message BeginSeqNo (7) = EndSeqNo (16). If request is for all messages subsequent to a particular message, EndSeqNo (16) = '0' (representing infinity). |
| <Standard Message Trailer> | Y | |||
3.2.5 Session Level Reject (MsgType = ‘3’)
Session Level Reject message is be used issued to reject message, which cannot be properly processed due to a session-level rule violation.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = '3' | ||
| 45 | RefSeqNum | Y | SeqNum | MsgSeqNum (34) of rejected message. |
| 371 | RefTagID | N | Int | The tag number of the FIX field being referenced. |
| 372 | RefMsgType | N | String(10) | The MsgType (35) of the FIX message being referenced. |
| 373 | SessionRejectReason | N | Int |
Code to identify reason for reject. Supported values:
|
| 58 | Text | N | String | Message to explain reason for rejection. |
| <Standard Message Trailer> | Y | |||
3.2.6 Reset Sequence (MsgType = ‘4’)
The Sequence Reset (4) message has two modes: Gap Fill mode and Reset mode.
Gap Fill mode
Gap Fill mode is used in response to a Resend Request (2) when one or more messages must be skipped over for the following reasons:
- During normal resend processing, the sending application may choose not to send a message (e.g. an aged order).
- During normal resend processing, a number of administrative messages are skipped and not resent (such as Heart Beats, Test Requests).
Gap Fill mode is indicated by GapFillFlag (123) field = 'Y'.
Reset mode
Reset mode involves specifying an arbitrarily higher new sequence number to be expected by the receiver of the Sequence Reset (4) message, and is used to re-establish a FIX session after an unrecoverable application failure.
Reset mode is indicated by the GapFillFlag (123) field = 'N' or if the field is omitted.
For more details, please read the following information.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = '4' | ||
| 123 | GapFillFlag | N | Boolean |
Indicates that the Sequence Reset (4) message is replacing administrative or application messages which will not be resent. Supported values:
|
| 36 | NewSeqNo | Y | SeqNum | New sequence number. |
| <Standard Message Trailer> | Y | |||
3.2.7 Logout (MsgType = ‘5’)
The Logout (5) message initiates or confirms the termination of a FIX session. Disconnection without the exchange of Logout (5) messages should be interpreted as an abnormal condition. To recover from this a user should send a Logon message with a 'ResetSeqNumFlag' field set to 'Y'.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = '5' | ||
| 58 | Text | N | String | Logout reason. |
| <Standard Message Trailer> | Y | |||
3.3 FIX Application Level Messages
3.3.1 FIX Component Blocks
3.3.1.1 Standard Message Header
Each administrative or application message is preceded by a standard header. The header identifies the message type, length, destination, sequence number, origination point and time.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| 8 | BeginString | Y | String |
Identifies beginning of new message and protocol version. Always unencrypted, must be first field in message. |
| 9 | BodyLength | Y | Length |
Message length, in bytes, forward to the CheckSum field. Always unencrypted, must be second field in message. |
| 35 | MsgType | Y | String |
Defines message type. Always unencrypted, must be third field in message. |
| 49 | SenderCompID | Y | String |
Assigned value used to identify firm sending message. Always unencrypted. |
| 56 | TargetCompID | Y | String |
Assigned value used to identify receiving firm. Always unencrypted. |
| 34 | MsgSeqNum | Y | SeqNum | Integer message sequence number. |
| 43 | PossDupFlag | N | Boolean |
Indicates possible retransmission of message with this sequence number. Required for retransmitted messages. Supported values:
|
| 97 | PossResend | N | Boolean |
Indicates that message may contain information that has been sent under another sequence number. Supported values:
|
| 52 | SendingTime | Y | UTCTimestamp |
Time of message transmission (expressed in UTC). YYYYMMDD-HH:MM:SS.sss |
| 122 | OrigSendingTime | N | UTCTimestamp |
Original time of message transmission when transmitting messages as the result of resend request (expressed in UTC). Required for message resent as a result of a resend request. |
3.3.1.2 Standard Message Trailer
Each administrative or application message is terminated by a standard trailer. The trailer is used to segregate messages and contains the three-digit character representation of the Checksum value.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| 10 | CheckSum | Y | String |
Three bytes, simple checksum. Always unencrypted, always last field in message. |
3.3.2 General
3.3.2.1 News (MsgType = ‘B’)
FIX message “News (B)” is used to inform user about the incoming actions.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'B' | ||
| 148 | Headline | Y | String | Specifies the headline text |
| <Standard Message Trailer> | Y | |||
3.3.3 Market Data
3.3.3.1 Market Data Request (MsgType = ‘V’)
FIX message “Market Data Request (V)” is used to subscribe for Order Book (events/changes) or Live Trades. Note that sending subsequent market data request invalidates previous subscriptions. To subscribe to more than one trading pair send a request containing all the wanted pairs (a repeating group).
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'V' | ||
| 262 | MDReqID | Y | String | Unique identifier for Market Data Request (V). |
| 263 | SubscriptionRequestType | Y | Char |
Subscription Request Type. Supported values:
|
| 264 | MarketDepth | Y | Int |
Depth of market for Order Book Snapshot.
Supported values: from 0 to 20, where 0 means full Book (same as
20), but every
other value means that received events contain at most that
given amount of price
levels of Book.
|
| 267 | NoMDEntryTypes | Y | NumInGroup | Number of MDEntryType (269) fields requested |
| =>269 | MDEntryType | Y | Char |
Type Market Data Entry. Supported values:
|
| 146 | NoRelatedSym | Y | NumInGroup | Number of symbols (instruments) requested. |
| =>55 | Symbol | Y | String |
Trading pair. Supported values: |
| <Standard Message Trailer> | Y | |||
3.3.3.2 Market Data – Full Refresh (MsgType = ‘W’)
FIX message “Market Data – Snapshot/Full Refresh (W)” is used to deliver updates of Order Book.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'W' | ||
| 262 | MDReqID | Y* | String | Unique identifier for Market Data Request (V) this message is sent in reply to. |
| 55 | Symbol | Y | String |
Trading pair. Valid values: |
| 268 | NoMDEntries | Y | NumInGroup | Number of entries following. |
| =>269 | MDEntryType | Y | Char |
Type of Market Data Entry. Valid values:
|
| =>270 | MDEntryPx | Y* | Price | Price of the Market Data Entry. |
| =>271 | MDEntrySize | Y* | Qty | Quantity or volume represented by the Market Data Entry. |
| <Standard Message Trailer> | Y | |||
3.3.3.3 Market Data – Incremental Refresh (MsgType = ‘X’)
FIX message “Market Data – Incremental Refresh (X)” is used to deliver live ticker.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'X' | ||
| 262 | MDReqID | Y* | String | Unique identifier for Market Data Request (V) this message is sent in reply to. |
| 268 | NoMDEntries | Y | NumInGroup | Number of entries following. |
| =>279 | MDUpdateAction | Y | Char |
Type of Market Data update action. Valid values:
|
| =>269 | MDEntryType | Y* | Char |
Type of Market Data entry. Valid values:
|
| =>278 | MDEntryID | Y* | String | Trade unique ID. |
| =>55 | Symbol | Y* | String |
Trading pair. Valid values: |
| =>270 | MDEntryPx | Y* | Price | Price of the Market Data Entry. |
| =>271 | MDEntrySize | Y* | Qty | Quantity or volume represented by the Market Data Entry. |
| =>272 | MDEntryDate | Y* | UTCDateOnly | Date of Market Data Entry. |
| =>273 | MDEntryTime | Y* | UTCTimeOnly | Time of Market Data Entry. |
| 288 | MDEntryBuyer | Y* | Int | This value represents a BuyOrderID*. |
| 289 | MDEntrySeller | Y* | Int | This value represents a SellOrderID*. |
| <Standard Message Trailer> | Y | |||
* NOTE: The lower ID value between MDEntryBuyer and MDEntrySeller represents a maker side, and the higher ID value represents a taker side.
3.3.3.4 Market Data Request Reject (MsgType = ‘Y’)
FIX message “Market Data Request Reject (Y)” is used to reject the Market Data Request, due to business or technical reasons.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'Y' | ||
| 262 | MDReqID | Y | String | Must refer to the MDReqID (262) of the request. |
| 281 | MDReqRejReason | Y* | Char |
Reason for the rejection of a Market Data Request (V). Valid values:
|
| <Standard Message Trailer> | Y | |||
3.3.4 Trading
3.3.4.1 New Order – Single (MsgType = 'D')
FIX message "New Order – Single (D)" is used to submit orders to the Bitstamp Trading System. This message can be used for two purposes: placing new orders and closing existing positions.
Place Order
Use the following fields to place a new order:
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'D' | ||
| 11 | ClOrdID | Y | String | Unique identifier of the order as assigned by the client |
| 55 | Symbol | Y | String |
Trading pair. Valid values: |
| 54 | Side | Y | Char |
Side of order. Valid values:
|
| 58 | Text | N | String |
Optional JSON that extends FIX with MOC order type MOC SupportFIX protocol does not support TimeInForce MOC (Maker Or Cancel) by default. By setting text value of {"moc":true} and TimeInForce value '1' (Good Till Cancel), we consider the order to have Maker Or Cancel TimeInForce. |
| 60 | TransactTime | N* | UTCTimestamp | Timestamp provided by the client. |
| 38 | OrderQty | Y | Qty | Quantity ordered. |
| 40 | OrdType | Y | Char |
Order type. Valid values:
|
| 44 | Price | C | Price | Price of the limit order. Required for OrderType(40) = ‘2’ (Limit) |
| 59 | TimeInForce | Y* | Char |
Specifies how long the order remains in effect. Valid values:
|
| 99 | StopPx | N | Decimal | Stop price for stop or stop-limit orders. |
| 126 | ExpireTime | Y* | UTCTimestamp | Time/Date of order expiration (always expressed in UTC (Universal Time Coordinated, also known as "GMT") This is the expiration time of a 'Good Till Date' TimeInForce <59>. UTCTimestamp is string field representing Time/date combination represented in either YYYYMMDD-HH:MM:SS (whole seconds) or YYYYMMDD-HH:MM:SS.sss (milliseconds) format, colons, dash, and period required. |
| 30000 | Margin Mode | Y | String (Enum) |
Specifies the margin mode for derivatives markets. This field is required for orders placed in either CROSS or ISOLATED margin mode. Valid values:
Usage: Applicable for margin trading, defining how margin is applied to the order. |
| 30001 | Leverage | Y | String |
Leverage rate for margin trading. This field is required for CROSS/ISOLATED margin mode. Usage: Applicable for margin orders to define the leverage rate. |
| 30002 | Trigger | Y | String (Enum) |
Specifies the type of price that the stop order will trigger on. This defines whether the stop price is compared to the last traded price, the index price, or the mark price. Valid values:
Usage: Used with stop orders to define the market condition that triggers the order. |
| 30003 | Activation Price | Y | String (Decimal) |
Activation price for trailing stop order. When this price is reached, the order starts trailing the market price in a favorable direction. Usage: Used in trailing stop orders to define the price at which the trailing behavior is activated. |
| 30004 | Trailing Delta | Y | String (Integer) |
The trailing delta represents how much the price can move in the unfavorable direction, from the highest or lowest price, before the trailing stop order is triggered. The value is in basis points (bps), where 5% equals 500, and the range is between 1 and 2000. Usage: Used in trailing stop orders to define the amount by which the market price can move unfavorably before the order is executed. |
| 30005 | Reduce Only | N | Boolean |
If set to 1, this field ensures that the order only reduces the existing position without opening a new one. Valid values:
Usage: Used to ensure that an order only reduces the existing position, commonly applied in margin trading scenarios. This field applies to all order types including Limit, Market, Stop, and Stop Limit orders. |
| 30007 | MakerOrCancel | N | Boolean |
Defines if an order is MoC order. Valid values:
|
| 30006 | White Label Account | N | String |
Indicates on behalf of which account the order is placed. |
| 30010 | StopOrdType | Y | String (Enum) |
Specifies whether a stop order is a stop-loss or take-profit type. Valid values:
Usage: Used with stop orders to define the market condition that triggers the order. |
| <Standard Message Trailer> | Y | |||
Note: In apiVersion V2, V2.1 and V2.2, the Price and OrderQty fields
are subject to precision validation. A value is accepted if the number of non-zero
digits after the decimal point is less than or equal to the instrument's allowed
precision (derived from market tick size for Price and from quantity step size for
OrderQty). Trailing zeros after the decimal point do not count toward precision
(e.g., 10.1200 is treated as 2 decimals), while leading zeros do (e.g., 0.0001 has 4
decimals). Examples: if Price precision = 2 → allowed: 10, 10.1, 10.12, 10.1200;
rejected: 10.123, 10.1205. If OrderQty precision = 3 → allowed: 1, 0.5, 1.125;
rejected: 1.1257. You can find the precision values for each instrument in the
/api/v2/markets/ endpoint.
Close Position
Use the following fields to close an existing position.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'D' | ||
| 11 | ClOrdID | N | String | Unique identifier of the order as assigned by the client |
| 30008 | PositionID | Y | Uint64 | ID of the position to close |
| <Standard Message Trailer> | Y | |||
Note: For close position requests, other required fields (Symbol, Side, OrderQty, OrdType, etc.) can be set to default values as they are ignored by the system when PositionID is provided.
3.3.4.2 Order Cancel Request (MsgType = ‘F’)
FIX message “Order Cancel Request (F)” is used to cancel a specific order previously submitted to the Bitstamp Trading System.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'F' | ||
| 41 | OrigClOrdID | Y | String | ClOrdID (11) of the previous non-rejected order when canceling an order. This will be used for the cancel attempt if OrderID is not present. |
| 11 | ClOrdID | Y | String | Unique ID of cancel request as assigned by the client |
| 37 | OrderID | Y* | String | Unique identifier of the order in Bitstamp Trading System. This ID will be used to find the order to be cancelled. |
| 60 | TransactTime | N* | UTCTimestamp | Timestamp provided by the client. |
| <Standard Message Trailer> | Y | |||
3.3.4.3 Order Mass Cancel Request (MsgType = ‘q’)
FIX message "Order Mass Cancel Request (q)" is used to cancel all client orders in the Bitstamp Trading System.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'q' | ||
| 11 | ClOrdID | Y | String | Unique ID of Order Mass Cancel Request (q) as assigned by the client |
| 530 | MassCancelRequestType | Y | Char |
Specifies the type of cancellation requested. Valid values:
|
| 60 | TransactTime | N* | UTCTimestamp | Time of order creation. |
| <Standard Message Trailer> | Y | |||
3.3.4.4 Execution Report (MsgType = ‘8’)
FIX message "Execution Report (8)" is used to:
- confirm the receipt of an order;
- confirm changes to an existing order (i.e. accept cancel request, replace order request);
- relay order status information;
- relay fill information on working orders;
- reject orders.
In case of disabled self-trading, you will receive an execution report similar to
this:
'8=FIX.4.4|9=406|35=8|34=3|49=BITSTAMP|52=20251125-11:47:20.619|56=
Bitstamp sends execution reports originating from liquidation events. Collateral, Assignment and ADL liquidation is not done via Order book, consequently reports originate from transaction events.
In case of liquidation, you will receive an execution report similar to this:
'8=FIX.4.4|9=353|35=8|34=6|49=BITSTAMP|52=20250509-05:14:01.640|56=1|57=98765|6=0.00000000|11=|14=0.00000000|17=1875692203950080|31=94844.00000000|37=|38=0.00023000|39=2|40=1|54=1|55=BTC/USD-PERP|60=19700523-21:21:18.890|136=1|137=0.00000000|139=7|150=F|151=0.00000000|914=1547035|30001=0.00000000|30008=1234567890|30009=Y|30012=1547035|30013=|32=0.00023000|30000=C|10=146|'
- OrdType(40) is always set as Market ('1'), since there is no originating order
- OrdStatus(39) is always set as Filled ('2'), since there is no originating order
- IsLiquidation(30009) is set to 'Y' to indicate this is a liquidation event
- The only difference between collateral liquidation and Assignment/ADL liquidation is visible in the Market instrument - BTC/USD for collateral liquidation vs BTC/USD-PERP for Assignment/ADL
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = '8' | ||
| 11 | ClOrdID | Y* | String | Unique identifier of the order or cancel request this Execution Report relates to, as assigned by the client. |
| 37 | OrderID | Y | String | Unique identifier of the order assigned by Bitstamp Trading System. |
| 41 | OrigClOrdID | C | String | ClOrdID (11) of the cancelled order. Conditionally required in response to Cancel request (ExecType (150) = Canceled). |
| 17 | ExecID | Y | String | Unique identifier of Execution Report (8) message as assigned by Bitstamp. |
| 150 | ExecType | Y | Char |
Describes the specific Execution Report (8) type. Valid values:
|
| 39 | OrdStatus | Y | Char |
Identifies current status of order. Valid values:
|
| 55 | Symbol | Y | String |
Trading pair. Valid values: |
| 54 | Side | Y | Char |
Side of order. Valid values:
|
| 40 | OrdType | N | Char |
Order type. Valid values:
|
| 32 | LastQty | С | Qty |
Quantity bought/sold on this fill. Required if ExecType (150) = ‘F’ (Trade). |
| 31 | LastPx | С | Price |
Price of this fill. Required if ExecType (150) = ‘F’ (Trade). |
| 151 | LeavesQty | Y | Qty | Quantity open for further execution. Always 0 for ExecType=’8’ (Rejected). |
| 14 | CumQty | Y | Qty | Currently quantity for the order. Always 0 for ExecType=’8’ (Rejected). |
| 6 | AvgPx | Y | Price | Always 0. |
| 60 | TransactTime | N | UTCTimestamp | Time of execution. |
| 58 | Text | N | String |
The error message for ER_REJECT is a general-purpose text field that carries structured diagnostic data for rate limit violations. New format for rate limit errors:
|
| 103 | OrdRejReason | N | Int | Code to identify reason for cancel rejection. If present, value is always '99' - Other. |
| 137 | MiscFeeAmt | N | Amt | Fees applied on this trade. |
| 851 | LastLiquidityInd | N | Int |
Indicator to identify whether this fill was a result of a liquidity provider providing or liquidity taker taking the liquidity. It is present in ER_TRADE events. Valid values:
|
| 30006 | White Label Account | N | String |
Identifies the white label account associated with this execution report. |
| 30007 | MakerOrCancel | N | Boolean |
Identifies if the order is MoC. Valid values:
|
| 30009 | IsLiquidation | N | Boolean |
Identifies if trade is result of liquidation. Valid values:
|
| 30012 | RelTxID | N | Uint64 |
Unique identifier of the transaction related to the execution
report.
When |
| 30013 | UTI | N | String |
Unique identifier of the transaction used for regulatory reports. |
| 30014 | TradeType | N | String (Enum) |
Classifies the nature of the trade. Valid values:
|
| 30015 | EstimatedNextSettlementTime | N | FIXUTCField |
Standard FIX UTC timestamp format representing estimated time for the next settlement. Information is received in collateral liquidation events. |
| 30017 | isRejectedSelfTrade | N | Boolean |
Indicates whether self-trade order is discarded due to client configuration. Valid values:
|
| 30018 | FeeRate | N | Float |
Rate at which the net trade fee was calculated. Expressed as a decimal fraction (e.g., 0.001 = 0.1%). |
| <Standard Message Trailer> | Y | |||
3.3.4.5 Order Status Request (MsgType = ‘H’)
FIX message "Order Status Request (H)" is used to obtain the status of an order. Response to this message is an Execution Report.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'H' | ||
| 37 | OrderID | N | String | Unique identifier of the order in Bitstamp Trading System. If this field is included, ClOrdID is ignored. |
| 11 | ClOrdID | Y | String | Unique ID of cancel request as assigned by the client. If OrderID is included, this field is ignored. This field can be left empty. |
| 54 | Side | Y | Char |
Side of order. Valid values:
|
| 30016 | OrderStatusRequest | N | String |
If set to 'V2', the system will return all execution reports that have occurred for the specified order. If not set or set to 'V1', the system will return only the most recent (latest) execution report for the order. Valid values:
|
| <Standard Message Trailer> | Y | |||
3.3.4.6 Order Cancel Reject (MsgType = ‘9’)
FIX message "Order Cancel Reject (9)" is used to reply to a Cancel Request (F) message which cannot be honored.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = '9' | ||
| 37 | OrderID | Y | String | Unique identifier of the order in Bitstamp Trading System. |
| 11 | ClOrdID | Y | String | Unique ID of cancel request as assigned by the client. |
| 41 | OrigClOrdID | Y | String | ClOrdID (11) of the previous non-rejected order when canceling an order. |
| 39 | OrdStatus | Y | Char |
Identifies current status of order. Valid values:
|
| 434 | CxlRejResponseTo | Y | Char |
Identifies the type of request that an Order Cancel Reject (9) is in response to. Valid values:
|
| 60 | TransactTime | N | UTCTimestamp | Timestamp of the reject being sent. |
| 102 | CxlRejReason | N | Int |
Code to identify reason for cancel rejection. Valid values:
|
| 58 | Text | N | String | Free format text string – the reason for the reject. |
| <Standard Message Trailer> | Y | |||
3.3.4.7 Order Mass Cancel Report (MsgType = ‘r’)
FIX message "Order Mass Cancel Report (r)" is used to acknowledge an Order Mass Cancel Request (q).
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'D' | ||
| 11 | ClOrdID | Y* | String | ClOrdID provided on the Order Mass Cancel Request (q) |
| 37 | OrderID | Y | String |
Unique Identifier for the Order Mass Cancel Request (q) assigned by the recipient of the Order Mass Cancel Request (q). Valid values:
|
| 60 | TransactTime | N | UTCTimestamp | Time this report was initiated/released. |
| 530 | MassCancelRequestType | Y | Char | Order Mass Cancel Request Type accepted by the system. |
| 531 | MassCancelResponse | Y | Char |
Specifies the action taken by system as a result of the Order Mass Cancel Request (q). Valid values:
|
| 532 | MassCancelRejectReason | N | Int |
Reason Order Mass Cancel Request (q) was rejected. Valid values:
|
| 58 | Text | N | String | Free format text string – the reason for the reject. |
| <Standard Message Trailer> | Y | |||
3.3.4.8 Business Message Reject (MsgType = ‘j’)
FIX message " Business Message Reject (j)" is used to reject an application-level message which fulfills session-level rules and cannot be rejected via any other means.
| Tag | Field Name | Req'd | Type | Comments |
|---|---|---|---|---|
| <Standard Message Header> | Y | MsgType = 'j' | ||
| 45 | RefSeqNum | N | SeqNum | Reference message sequence number. |
| 372 | RefMsgType | Y | String | The MsgType (35) of the FIX message being referenced. |
| 379 | BusinessRejectRefID | N | String | The value of the business-level "ID" field on the message being referenced. |
| 380 | BusinessRejectReason | Y | Int |
Code to identify reason for a Business Message Reject (j) message. Valid values:
|
| 58 | Text | N | String | Free format text string – the reason for the reject. |
| <Standard Message Trailer> | Y | |||
4 Appendix
4.1 Currency Pairs
This is the complete list of supported currency pairs:
-
BTC/USD,
BTC/EUR,
BTC/GBP,
BTC/USDC,
BTC/USDT,
BTC/RLUSD,
BTC/EURC,
BTC/EURCV -
GBP/USD
-
EUR/USD
-
XRP/USD,
XRP/EUR,
XRP/BTC,
XRP/GBP,
XRP/USDT,
XRP/RLUSD,
XRP/USDC -
LTC/BTC,
LTC/USD,
LTC/EUR -
ETH/BTC,
ETH/USD,
ETH/EUR,
ETH/GBP,
ETH/USDC,
ETH/USDT,
ETH/RLUSD,
ETH/EURC,
ETH/EURCV -
BCH/USD,
BCH/EUR -
XLM/USD,
XLM/EUR,
XLM/GBP -
LINK/USD,
LINK/EUR,
LINK/GBP -
USDC/USD,
USDC/EUR,
USDC/USDT -
ETH2/ETH
-
AAVE/USD,
AAVE/EUR,
AAVE/BTC -
BAT/USD,
BAT/EUR -
UMA/USD,
UMA/EUR -
DAI/USD
-
KNC/USD,
KNC/EUR -
MKR/USD,
MKR/EUR -
ZRX/USD,
ZRX/EUR -
ALGO/USD,
ALGO/EUR -
AUDIO/USD,
AUDIO/EUR -
CRV/USD,
CRV/EUR -
SNX/USD,
SNX/EUR -
UNI/USD,
UNI/EUR -
YFI/USD,
YFI/EUR -
COMP/USD,
COMP/EUR -
GRT/USD,
GRT/EUR -
LRC/USD,
LRC/EUR -
USDT/USD,
USDT/EUR -
FLR/USD,
FLR/EUR -
MANA/USD,
MANA/EUR -
SUSHI/USD,
SUSHI/EUR -
CHZ/USD,
CHZ/EUR -
ENJ/USD,
ENJ/EUR -
HBAR/USD,
HBAR/EUR -
AXS/USD,
AXS/EUR -
SAND/USD,
SAND/EUR -
STORJ/USD,
STORJ/EUR -
ADA/USD,
ADA/EUR -
FET/USD,
FET/EUR -
SKL/USD,
SKL/EUR -
AVAX/USD,
AVAX/EUR -
FTM/USD,
FTM/EUR -
SHIB/USD,
SHIB/EUR -
AMP/USD,
AMP/EUR -
ENS/USD,
ENS/EUR -
GALA/USD,
GALA/EUR -
PERP/USD,
PERP/EUR -
WBTC/BTC
-
CTSI/USD,
CTSI/EUR -
IMX/USD,
IMX/EUR -
INJ/USD,
INJ/EUR -
RNDR/USD,
RNDR/EUR -
1INCH/USD,
1INCH/EUR -
SOL/USD,
SOL/EUR,
SOL/USDC -
APE/USD,
APE/EUR -
EURC/USDC,
EURC/EUR -
DOT/USD,
DOT/EUR -
NEAR/USD,
NEAR/EUR -
LDO/USD,
LDO/EUR -
DOGE/USD,
DOGE/EUR -
SUI/USD,
SUI/EUR -
EURCV/USDT,
EURCV/EUR,
EURCV/USDC -
PYUSD/USD,
PYUSD/EUR -
TRAC/USD,
TRAC/EUR -
WECAN/USD,
WECAN/EUR -
BLUR/USD,
BLUR/EUR -
LMWR/USD,
LMWR/EUR -
PEPE/USD,
PEPE/EUR -
CSPR/USD,
CSPR/EUR -
GYEN/USD
-
VCHF/USD,
VCHF/EUR -
VEUR/USD,
VEUR/EUR -
ZUSD/USD
-
BONK/USD,
BONK/EUR -
JUP/USD,
JUP/EUR -
PYTH/USD,
PYTH/EUR -
WIF/USD,
WIF/EUR -
ONDO/USD,
ONDO/EUR -
SMT/USD,
SMT/EUR -
TRUF/USD,
TRUF/EUR -
EGLD/USD,
EGLD/EUR -
ICP/USD,
ICP/EUR -
XDC/USD,
XDC/EUR -
COREUM/USD,
COREUM/EUR -
FLOKI/USD,
FLOKI/EUR -
STRK/USD,
STRK/EUR -
XCHNG/USD,
XCHNG/EUR -
CTX/USD,
CTX/EUR -
MOG/USD,
MOG/EUR -
WEN/USD,
WEN/EUR -
ARB/USD,
ARB/EUR -
XSGD/USD,
XSGD/USDT -
ZETA/USD,
ZETA/EUR -
MEW/USD,
MEW/EUR -
RLUSD/USD,
RLUSD/EUR,
RLUSD/USDT -
WOO/USD,
WOO/EUR -
SEI/USD,
SEI/EUR -
OP/USD,
OP/EUR -
BOME/USD,
BOME/EUR -
CXT/USD,
CXT/EUR -
POPCAT/USD,
POPCAT/EUR -
SYRUP/USD,
SYRUP/EUR -
MELANIA/USD,
MELANIA/EUR -
TRUMP/USD,
TRUMP/EUR -
POL/USD,
POL/EUR -
FARTCOIN/USD,
FARTCOIN/EUR -
PENGU/USD,
PENGU/EUR -
PNUT/USD,
PNUT/EUR -
ETC/USD,
ETC/EUR -
SGD/USD
-
VIRTUAL/EUR,
VIRTUAL/USD -
XCN/USD,
XCN/EUR -
MOODENG/USD,
MOODENG/EUR -
TAI/USD,
TAI/EUR -
TON/USD,
TON/EUR -
XPL/USD,
XPL/EUR -
BIO/USD,
BIO/EUR -
ENA/USD,
ENA/EUR -
SPK/USD,
SPK/EUR -
WLFI/USD,
WLFI/EUR -
HYPE/USD,
HYPE/EUR -
ASTER/USD,
ASTER/EUR -
AVNT/USD,
AVNT/EUR -
BNB/USD,
BNB/EUR -
MON/USD,
MON/EUR -
PENDLE/USD,
PENDLE/EUR -
ZORA/USD,
ZORA/EUR