Session Messages
Session messages maintain any live FIX connection with the xPro FIX server, including market data sessions.
Standard Header
Section titled “Standard Header”All FIX messages must begin with a Standard Header.
| Tag | Name | Req’d | Datatype | Description |
|---|---|---|---|---|
| 8 | BeginString | Y | String | Marks the start of a message and indicates FIX version (FIX.4.4). Always the first field. |
| 9 | BodyLength | Y | int | Automatically computed message length in bytes. Always the second field. |
| 35 | MsgType | Y | String | The message type. See Supported Message Types. Always the third field. |
| 34 | MsgSeqNum | Y | int | Message sequence number, incremented by 1 for each consecutive message. |
| 49 | SenderCompID | Y | String | XPRO-supplied identifier of the client sending requests to the FIX server. |
| 52 | SendingTime | Y | Timestamp | Date/time the message was sent, UTC with milliseconds: YYYYMMDD-HH:MM:SS.sss. |
| 56 | TargetCompID | Y | String | XPRO-supplied identifier of the server receiving client messages. |
Standard Trailer
Section titled “Standard Trailer”| Tag | Name | Req’d | Datatype | Description |
|---|---|---|---|---|
| 10 | CheckSum | Y | int | Three-digit simple checksum indicating the end of a message. Always the last field. |
Supported Message Types
Section titled “Supported Message Types”| Type | Name | Direction | Category |
|---|---|---|---|
| A | Logon | Client → XPRO | Session |
| 0 | Heartbeat | Client ↔ XPRO | Session |
| 1 | Test Request | Client ↔ XPRO | Session |
| 3 | Reject | Client ← XPRO | Session |
| 4 | Sequence Reset | Client ↔ XPRO | Session |
| 5 | Logout | Client ↔ XPRO | Session |
| V | Market Data Request | Client → XPRO | MarketData |
| W | Market Data — Snapshot/Full Refresh | Client ← XPRO | MarketData |
| X | Market Data — Incremental Refresh | Client ← XPRO | MarketData |
| Y | Market Data Request Reject | Client ← XPRO | MarketData |
| j | Business Reject | Client ← XPRO | MarketData |
Sent by the client to initiate a FIX session. Must be the first message in each connection. Credentials are provided by XBTFX upon account setup.
| Tag | Name | Req’d | Datatype | Description |
|---|---|---|---|---|
| — | Standard Header | Y | MsgType = A | |
| 1 | Account | Y | String | XPRO-supplied account identifier, provided by XBTFX. |
| 98 | EncryptMethod | Y | int | Message encryption method. Must always be 0 (no encryption). |
| 108 | HeartBtInt | Y | int | Heartbeat interval in seconds. |
| 141 | ResetSeqNumFlag | N | Boolean | Indicates whether both parties should reset sequence numbers. |
| 553 | Username | Y | String | Client username, as provided by XBTFX. |
| 554 | Password | Y | String | Client password, as provided by XBTFX. |
| — | Standard Trailer | Y |
Example
Section titled “Example”Request (Client → XPRO):
8=FIX.4.4^9=117^35=A^1=68a4446ac84827ff5cd35c74^34=1^52=20231218-07:59:06.000^49=sender_xpro_trading^56=target_xpro_trading^554=password^553=username^98=0^108=30^10=117^Response (XPRO → Client):
8=FIX.4.4^9=93^35=A^1=68a4446ac84827ff5cd35c74^34=225^49=target_xpro_trading^52=20231218-07:59:06.655^56=sender_xpro_trading^98=0^108=30^10=054^Heartbeat
Section titled “Heartbeat”Sent back and forth between the FIX server and client to check connection status and in response to Test Request messages.
| Tag | Name | Req’d | Datatype | Description |
|---|---|---|---|---|
| — | Standard Header | Y | MsgType = 0 | |
| 112 | TestReqID | Y | String | Identifier of the Test Request this Heartbeat is responding to. |
| — | Standard Trailer | Y |
Example
Section titled “Example”8=FIX.4.4^9=79^35=0^34=2^52=20231218-07:59:36.000^49=sender_xpro_trading^56=target_xpro_trading^10=156^Test Request
Section titled “Test Request”Sent back and forth between the FIX server and client in response to Heartbeat messages as a connectivity check.
| Tag | Name | Req’d | Datatype | Description |
|---|---|---|---|---|
| — | Standard Header | Y | MsgType = 1 | |
| 112 | TestReqID | N | String | Identifier of a Heartbeat this Test Request is responding to. |
| — | Standard Trailer | Y |
Example
Section titled “Example”8=FIX.4.4^9=87^35=1^34=137^52=20231218-10:12:38.000^49=sender_xpro_trading^56=target_xpro_trading^112=2^10=250^Reject
Section titled “Reject”Sent by the FIX server upon receiving a malformed message. The reason is specified in the <373> SessionRejectReason field.
| Tag | Name | Req’d | Datatype | Description |
|---|---|---|---|---|
| — | Standard Header | Y | MsgType = 3 | |
| 45 | RefSeqNum | Y | int | Sequence number of the rejected message (<34> MsgSeqNum). |
| 371 | RefTagID | N | int | Tag number of the field that caused rejection. |
| 372 | RefMsgType | N | int | Type of the rejected message (<35> MsgType). |
| 373 | SessionRejectReason | N | int | Reason the message was rejected. See Reject reasons. |
| 58 | Text | N | String | Detailed information about the rejection reason. |
| — | Standard Trailer | Y |
Example
Section titled “Example”8=FIX.4.4^9=88^35=3^34=193^52=20231219-22:41:16.000^49=Q005^56=XCD197^45=18^371=12^372=12^373=1^58=135^10=126^Reject reasons
Section titled “Reject reasons”| Code | Meaning |
|---|---|
| 0 | Invalid tag number |
| 1 | Required tag missing |
| 2 | Tag not defined for this message type |
| 3 | Tag undefined |
| 4 | Tag has no value |
| 5 | Value out of range |
| 6 | Incorrect value data format |
| 7 | Decryption issue |
| 8 | Signature problem |
| 9 | CompID issue |
| 10 | SendingTime accuracy issue |
| 11 | Invalid MsgType |
| 12 | XML validation error |
| 13 | Duplicate tag |
| 14 | Tag not in required order |
| 15 | Wrong repeating group order |
| 16 | Incorrect NumInGroup count |
| 17 | SOH character in non-Data field |
| 99 | Other (unspecified) |
Sequence Reset
Section titled “Sequence Reset”Sent by the client or FIX server to indicate the sequence number of the next message. Used to recover from a disconnect where messages were lost or resending is undesirable.
| Tag | Name | Req’d | Datatype | Description |
|---|---|---|---|---|
| — | Standard Header | Y | MsgType = 4 | |
| 123 | GapFillFlag | N | Boolean | Y — Gap fill: MsgSeqNum marks start of gap fill range. N — Sequence reset: MsgSeqNum ignored. Disaster recovery only. |
| 36 | NewSeqNo | Y | int | The new sequence number. |
| — | Standard Trailer | Y |
Example
Section titled “Example”8=FIX.4.4^9=90^35=4^34=6^49=target_xpro_trading^52=20231219-21:11:38.578^56=sender_xpro_trading^123=Y^36=8^10=176^Logout
Section titled “Logout”Sent by the client or FIX server to terminate a session. The reason may be specified in the <58> Text field.
| Tag | Name | Req’d | Datatype | Description |
|---|---|---|---|---|
| — | Standard Header | Y | MsgType = 5 | |
| 58 | Text | N | String | Detailed information about the reason for logging out. |
| — | Standard Trailer | Y |
Example
Section titled “Example”Request (Client → XPRO):
8=FIX.4.4^9=89^35=5^34=5^52=20231218-13:40:48.000^49=sender_xpro_trading^56=target_xpro_trading^58=ST1234^10=183^Response (XPRO → Client):
8=FIX.4.4^9=81^35=5^34=748^49=target_xpro_trading^52=20231218-13:40:49.016^56=sender_xpro_trading^10=009^