Anda di halaman 1dari 35

Cointex API Specification

FIX 4.4 Message Reference ................................................................................................................. 4


Standard Header and Trailer ................................................................................................................ 4
Standard Header ........................................................................................................................... 4
Standard Trailer ............................................................................................................................ 5
Session Level Messages ....................................................................................................................... 6
Heartbeat....................................................................................................................................... 6
Test Request .................................................................................................................................. 6
Reset Request ............................................................................................................................... 7
Reject (Session) ............................................................................................................................ 7
Sequence Reset ............................................................................................................................. 8
Logout........................................................................................................................................... 9
Logon .......................................................................................................................................... 10
Application Messages for Security Data ............................................................................................ 12
Security Definition Request ....................................................................................................... 12
Security Definition ..................................................................................................................... 13
Application Messages for Routes Data .............................................................................................. 15
Route Status Request .................................................................................................................. 15
Route Status ................................................................................................................................ 15
Application Messages for Market Data ............................................................................................. 17
Market Data Request .................................................................................................................. 17
Market Data Incremental Refresh .............................................................................................. 18
Market Data SNAPSHOT/FULL Refresh .................................................................................. 20
News Messages .................................................................................................................................. 21
Account Status Messages ................................................................................................................... 21
2

Application Messages for Trading ..................................................................................................... 23


New Order Single ....................................................................................................................... 23
Identifying the Traded Commodity ............................................................................................ 25
Open and Close Indicator ........................................................................................................... 25
Order Cancel / Replace .............................................................................................................. 25
Order Cancel .............................................................................................................................. 27
Execution Report........................................................................................................................ 28
Order Cancel Reject ................................................................................................................... 31
Order Status Request .................................................................................................................. 32
Request for Positions ................................................................................................................. 32
Trade Capture Report ......................................................................................................................... 33
Trade capture report request ....................................................................................................... 33
Trader capture report .................................................................................................................. 34

FIX 4.4 MESSAGE REFERENCE


This section lists the messages in detail and provides information on our use of these FIX 4.4
messages. Tags marked Not supported are not used by our server, but may be required to
conform to FIX protocol.
All field values must conform to FIX protocol definitions. For example, a date must not contain
alphabetical characters. Specifying invalid field values may cause unexpected behavior. The
documentation at www.fixprotocol.org provides information on field data types.

STANDARD HEADER AND TRAILER


The Cointex FIX Trading Server expects and sends standard headers and trailers on each
message. Our FIX engine will reject messages not containing correct headers and trailers.
Unsupported tags should not be specified but in general, if they are present, will be ignored.

STANDARD HEADER
Tag

Field Name

Required

Comments

BeginString

FIX.4.4

BodyLength

35

MsgType

49

SenderCompID

Client: id of your application


Should be used Cointex user login

56

TargetCompID

Server: id of your application


CTPRICE for price connection and CTORDER for trade
connection.

115

OnBehalfOfCompID

Not supported

128

DeliverToCompID

Not supported

90

SecureDataLen

Not supported

91

SecureData

Not supported

34

MsgSeqNum

50

SenderSubID

Not supported

142

SenderLocationID

Not supported

57

TargetSubID

Not supported

143

TargetLocationID

Not supported

116

OnBehalfOfSubID

Not supported

144

OnBehalfOfLocationID

Not supported

129

DeliverToSubID

Not supported

145

DeliverToLocationID

Not supported

97

PossResend

Send when message may be duplicate of another message


sent under a different sequence number. (As example for
Execution report .)

52

SendingTime

122

OrigSendingTime

Required if message was resent as


ResendRequest. Can set to SendingTime.

212

XmlDataLen

Only for xml messages

213

XmlData

Only for xml messages

347

MessageEncoding

Not supported

369

LastMsgSeqNumProcess
ed

Not supported

370

OnBehalfOfSendingTime

Not supported

result

of

STANDARD TRAILER
Tag
93

Field Name
SignatureLength

Required
N

Comments
Not supported.

89

Signature

10

CheckSum

Not supported.

Checksum Calculation
Please refer to the FIX documentation available at www.fixprotocol.org for checksum calculation
algorithm specifications.

SESSION LEVEL MESSAGES


The following messages are session level messages and are processed by our server using the
FIX engine. Some of these messages can be generated as well as accepted by our server, and
some messages are expected to be received only.

HEARTBEAT
Heartbeat messages can be initiated by either the client or the server.
Tag

112

Field Name

Required

Comments

Standard Header

MsgType = 0

TestReqID

Set by the server when responding to a Test Request


message.

Standard Trailer

Data type: string

TEST REQUEST
Test Request messages may be initiated by the client or the server. The server may initiate this
message under the control of the FIX engine if it believes there is a problem with the socket.
Upon receipt of this message, the server will respond with a Heartbeat message.
6

Tag

112

Field Name

Required

Comments

Standard Header

MsgType = 1

TestReqID

Will be returned in tag 112 of Heartbeat

Standard Trailer

Data type: string

RESET REQUEST
Either the client or the server, in response to a detected gap in the message sequences, can
initiate a Reset Request message. It requests a resend of the messages from BeginSeqNo through
to and including EndSeqNo.
Tag

Field Name

Required

Standard Header

BeginSeqNo

16

EndSeqNo

Standard Trailer

Comments

MsgType = 2

A Reset Request will be responded to by retransmitting the requested messages, or by


transmitting a Sequence Reset (Gap Fill) to skip some of those messages.

REJECT (SESSION)
A message reject is issued when an incoming message fails session level validation. Either the
client or the server can produce this message, although the client is very unlikely to do so, as all
FIX messages produced by the server are supposed to be FIX compliant.
When this type of message is produced by the server, the error will have been detected by the FIX
engine and suitable text will be found in tag 58. The field in error is found in tag 371 and the
sequence number of the message in error is found in tag 45.

Tag

Field Name

Required

Comments

Standard Header

MsgType = 3

45

RefSeqNum

MsgSeqNum of rejected message

371

RefTagID

The tag failing validation

372

RefMsgType

MsgType of the message in error

373

SessionRejectReason

Refer to FIX documentation

58

Text

Message to explain the error

Standard Trailer

SEQUENCE RESET
The client may generate a Sequence Reset message when responding to a Reset Request in
order to skip messages. Please read the information on the importance of proper sequence
number reset co-ordination and sequence number processing in section This is a recommended
mechanism to ensure that stale orders are not re-transmitted in the event that the connection has
been down for an extended period.
This message is not produced by the server, when the server responds to Reset Requests all
requested messages are re-sent.
Tag

Field Name

Required

Comments

Standard Header

MsgType = 4

123

GapFillFlag

Normally present and set to Y

36

NewSeqNo

Must only increase expected SeqNo

Standard Trailer

The GapResetFlag (tag 123) should normally be present and set to Y in order to skip the
messages. This is called a Sequence Reset (Gap Fill) and the server will set the next expected
sequence number to the value of NewSeqNo (tag 36), thus skipping intervening messages. It is
important to note that the sequence number of this message should be the sequence number of
the first message to be skipped.

LOGOUT
This message is created by the client application when it wishes to disconnect a session.
Field Name

Requir
ed

Comments

Standard Header

MsgType = 5

58

Text

Not supported

20005

NoClusterNodes

20009

Id of the cluster node

Load of t the cluster node

1 Quote stream
2 Trade stream

Tag

NodeID
20007
NodeLoad
20008
ConnectionMode
20001

N
NoServerURLs
Y
20002

NodeHost

20003

NodePort

20004

NodeProtoc
ol

Standard Trailer

LOGON
FIX logon authentication requires a valid Cointex user SenderID name and a password. The user
must have rights for logon as FIX client.

Logon can be rejected for a number of reasons:

the login name or password are invalid


the user is already logged in the system in a different FIX session or via other means
Logon request message sequence number is smaller than the last received FIX message
(MsgSeqNum too low) manual intervention on the client side is required to correct the
sequence numbers and/or reset them via ResetSeqNumFlag field.

A Logout message is sent in all these cases with the Text(58) field containing the error description.
Field Name

Requir
ed

Comments

Standard Header

MsgType = A

98

EncryptMethod

Ignored, use 0.

108

HeartBtInt

Heartbeat interval used by both sides. Default 30.

141

ResetSeqNumFlag

Indicates both sides of a FIX session should reset


sequence numbers

554

Password

Cointex trader login password.

98

EncryptMethod

Ignored, use 0.

108

HeartBtInt

Heartbeat interval used by both sides. Default 30.

141

ResetSeqNumFlag

Indicates both sides of a FIX session should reset


sequence numbers

NodeID

ID of the cluster node

NoClusterNodes

20009

Tag

20009
20005

Id of the cluster node

NodeID

10

20007

Load of t the cluster node

1 Quote stream
2 Trade stream

NodeLoad
20008
ConnectionMode
20001

N
NoServerURLs
Y
20002

NodeHost

20003

NodePort

20004

NodeProtoc
ol

Standard Trailer

11

APPLICATION MESSAGES FOR SECURITY


DATA
SECURITY DEFINITION REQUEST
The server will only process a security definition request with a SecurityRequestType of 3
(Request List of Securities). The server will respond with a Security Definition message. Other
types of Security Definition Request are rejected by the server by setting the Security Response
Type to 5 on the returned message.
Tag

Field Name

Required

Comments

Standard Header

MsgType = c (lowercase)

320

SecurityReqID

Unique identifier for this request

321

SecurityRequestType

Ignored, use 3

55

Symbol

Instrument name

48

SecurityID

Instrument Id

22

IDSource

Not supported.

167

SecurityType

Cointex instrument type name

Standard Trailer

Most of the fields are unsupported due to the fact that on the Cointex FIX Trading Server, use of
this message is limited to requesting a list of available securities. It is not possible to use this
message to request that a particular security be traded on the Cointex servers.
The fields listed in the next table are used to specify filters on the returning data. Presence of a
field will indicate to the server that data should be filtered by that value. Absence of the field
indicates that the data should be wild-carded for that item. For example, to request all instrument of
Spot instrument type, use 207=Spot but do not specify the Symbol tag.

12

SECURITY DEFINITION
The Security Definition is send by the server on client logon or in response to a Security Definition
Request to list the available securities on the gateway. This does not list all securities defined on
the Cointex servers only the securities that your logon has received permission to access. If a
Security Definition Request is being rejected (e.g. not type 3) then the returned message will
contain no securities.

Tag

Field Name

Required

Comments

Standard Header

MsgType = d (lowercase)

320

SecurityReqID

As supplied in Request.

322

SecurityResponseID

A time based unique identifier.

323

SecurityResponseType

55

Symbol

4 (returning a list)
5 (rejecting a request)
6 (could not match selection)
Instrument name

48

SecurityID

Cointex instruement ID.

167

SecurityType

Cointex instrument type (i.e. instrument group)

200

MaturityMonthYear

Not supported.

205

MaturityDay

Not supported.

201

PutOrCall

Not supported.

202

StrikePrice

Not supported.

15

Currency

Instrument primary currency

58

Text

Instrument description

454

NoUnderlyings

Number of repeating groups for available routes

13

7020

CrossInstrumentType

7021

CrossInstrumentId

Cross type for convert instrument primary currency into


system currency:
0- simple, i.e. without cross instrument; 1- cross type
price;2 cross type simple reverse; 3 cross type
reverse price
Cross instrument id for account

7022

CurrencyMinChange

Accuracy of instrument.

16470

LotSizeOption

Reserved for options.

16552

ExchTickSize

Tic size

16554

ExchPointValue

Point (pips) size

460

InstrumentType

Standard Trailer

FOREX = 1;
EQUITIES = 2;
FUTURES = 3;
OPTIONS = 4;
EQUITIES_CFD = 5;
FORWARD = 6;
FUTURES_CFD = 7;
INDICIES= 8;
GENERAL = 0;

14

APPLICATION MESSAGES FOR ROUTES


DATA
ROUTE STATUS REQUEST
Request status information for Cointex routes.
Tag

Field Name

Required

Comments

Standard Header

MsgType = UAR (uppercase)

18200

GatewayStatusReqId

ID for this route status request.

263

SubscriptionRequestType

Not supported.

Standard Trailer

ROUTE STATUS
The Route Status message is sending on client logon or returned by the server in response to a
Route Status Request.

Field Name

Require
d

Comments

Standard Header

MsgType = UAT (lowercase)

20009

NodeID

ID of the node, where this route was started

18200

GatewayStatusReqId

ID for this route status request.

18201

NoGatewayStatus

Number of status messages contained in this repeating


group.

Tag

15

18202

GatewayStatu
s

207

SecurityExcha
nge

20015

QuoteSecurityE
xchange

18203

ExchangeGat
eway

18204

SubExchange
Gateway

58

Text

Standard Trailer

Current status of the route. Possible values include:

1: Halted

2: Open

3: Closed
Generally to user will be send only Route Status
message with GatewayStatus=2.
Cointex route name.

Info route (only for trade mode). If group with


SubExchangeGateway=1 isnt set, subscription should
be with using this securityExchange
Not supported.

Type of Cointex route. Valid values include:

1: Price

2: Order (i.e. trade)


Additional information about the route.

16

APPLICATION MESSAGES FOR MARKET


DATA
MARKET DATA REQUEST
The Market Data Request is submitted by the client application in order to request price data from
the server. Both snapshots and incremental refreshes are supported. Market depth is supported to
20 levels although for most exchanges only 10 levels will be provided. Some exchanges limit this
to 5 levels.
The server will respond to a Market Data Request with a Market Data Incremental Refresh
message as requested, or a Market Data Reject message.

Tag

Field Name

Required

Comments

Standard Header

MsgType = V

262

MDReqID

Unique ID, or the ID of the request to disable.

263

SubscriptionRequest
Type

1 subscribe
2 unsubscribe

264

MarketDepth

1 Level I
0 Full cup
*For full market depth server do not send
MDEntryPositionNo , only MDEntryID.

265

MDUpdateType

Not supported. Snapshot/Full and Market Data Incremental


Refresh.

266

AggregatedBook

Ignored.

267

NoMDEntryTypes

Number of MDEntryType fields requested.

269

If not set subscribe for bids, offers and trade.


Supported value:
BID = '0';
OFFER = '1';
TRADE = '2';
OPENING_PRICE = '4';
CLOSING_PRICE = 5;
HIGH_PRICE = '7';
LOW_PRICE = '8';

MDEntryTy
pe

17

146

NoRelatedSym

Number of securities requested.

55

Symbol

Cointex instrument name

167

SecurityTy
pe

Cointex instrument type. Not required.

200

MaturityM
onth
Year
MaturityDa
y

Format YYYYMM only for Derivatives.

Use for Options.

201

PutOrCall

Use for Options.

202

StrikePrice

Use for Options.

207

Security
Exchange

Cointex route name

205

Standard Trailer

MARKET DATA INCREMENTAL REFRESH


A Market Data Incremental Refresh is returned by the server when the Market Data Request has
requested an incremental refresh. Multiple market data entries can be notified in the same
message.

Tag

Field Name

Required

Comments

Standard Header

MsgType = X

262

MDReqID

Request this is responding to

268

NoMDEntries

Number of entries following.

279

0 (new)
1 (change)
2 (delete)

MDUpdate
Action

18

269

MDEntryTy
pe

Entry type for new entries.

278

MDEntryID

Identifies the market depth entry (MMID) Unique id in


market depth cap.

280

MDEntryR
efID

Not supported.

55

Symbol

Cointex instrument name

48

SecurityID

Cointex instrument ID.

167

SecurityTy
pe

Cointex instrument type.

200

MaturityMo
nthYear

Format YYYYMM only for derivatives.

205

MaturityDa
y

Use for Options.

201

PutOrCall

Use for Options.

202

StrikePrice

Use for Options.

207

SecurityEx
change

Cointex route name

270

MDEntryPx

Price for this entry.

271

MDEntrySi
ze

Volume for this price.

272

MDEntryD
ate

Date price received.

273

MDEntryTi
me

Time price received.

290

MDEntryPo
sitionNo

Not supported. Position for this entry in depth

Standard Trailer

19

MARKET DATA SNAPSHOT/FULL REFRESH


A Market Data Snapshot/Full Refresh is returned by the server when the Market Data Request has
requested an Snapshot/Full refresh.
Tag

Field Name

Required

Comments

Standard Header

MsgType = W

262

MDReqID

Request this is responding to

201

PutOrCall

200

MaturityMonthYear

Indicates whether an Option is for put or call


Valid values:
0 Put
1 Call
Format YYYYMM only for derivatives

205

MaturityDay

Use only for derivatives


Values: 1-31

55

Symbol

Cointex instrument name

167

SecurityType

Cointex instrument type

48

SecurityID

Cointex instrument ID

207

SecurityExchange

Cointex route name

268

NoMDEntries

Number of entries following.

269

MDEntryType

Entry type for new entries.

278

MDEntryID

Identifies the market depth entry (MMID) Unique id in


market depth cap.

275

MDMkt

Source of quote

270

MDEntryPx

Price for this entry

271

MDEntrySize

Volume for this price

290

MDEntryPositi
onNo

Position for this entry in depth

Standard Trailer

20

NEWS MESSAGES
The News Messages using for send news to client.
Tag

Field Name

Required

Comments

Standard Header

42

OrigTime

61

Urgency

News priority. Values from 0 (high) to 9 (low)

148

Headline

Headline of news.

146

NoRelatedSym

55

Symbol

Related symbol (if specified).

22

IDSource

Cointex route name (if specified).

Count of lines in message text.

LinesOfText

58

Text

MsgType = B (uppercase)

149

URLLink

URL link.

6515

NewsID

The unique identifier of a news message.

6940

NewsSource

String containing the news source for the News


Message

6518

NewsType

Textual description of the news category.

Standard Trailer

ACCOUNT STATUS MESSAGES


21

The AccountStatus Messages using for send account info to client. It sent by server on client logon
and when account info are changed.
Tag

Field Name

Required

Comments

Standard Header

MsgType = UAA (uppercase)

Account

Account name

7001

AccountId

Cointex Account id

7002

UserID

Cointex user id

553

Username

Cointex user name

7004

ClientType

Client terminal type


2 - .net; 3 - pocketPC; 4 - html; 0 - undefined ; 8 - FIX
client

7006

UserGroupID

7008

UserStatus

0 offline, 1 online, 2 account removed

7010

Balance

Account balance.

7011

BlockedSum

The unique identifier of a news message.

7012

Leverage

User leverage, for example for leverage 1:100 will be


send 7012=100

7013

TradingLevel

7014

WarningLevel

7015

MarginLevel

7016

CommisionId

15

Currency

Account currency

7020

CrossInstrumentType

Cross type for convert account currency into system


currency:
0- simple, i.e. without cross instrument; 1- cross type
price;2 cross type simple reverse; 3 cross type
reverse price

22

7021

CrossInstrumentId

Cross instrument id for account

7022

CurrencyMinChange

Accuracy for account currency.

7023

Master

Boolean flag for master account

Standard Trailer

APPLICATION MESSAGES FOR TRADING


NEW ORDER SINGLE
This message is used to submit a new order to the Cointex servers. Give-up and order routing can
be done on the Cointex servers by having the administrator set up users and accounts to do so.
The Cointex server will respond with either an Execution Report or a Reject (Session) message. A
Reject message is only issued if the message fails session level validation, such as invalid tag
values. If an order fails business validation, an Execution Report will be issued with an appropriate
status and error text.
Tag

Field Name

Required

Comments

Standard Header

MsgType = D

11

ClOrdID

Client identifier of the order.

73

NoOrders

Optional. Used for closing position or adding SL/TP. If


specified, must be the value of Cointex Order ID
supplied by the server in the execution report.
Cointex OrderID

37

OrderID

Account

The Cointex trader account

21

HandlInst

Set to 1, otherwise will cause reject

55

Symbol

Cointex instrument name

167

SecurityType

Cointex instrument type name

23

200

MaturityMonthYear

Reserved. Required for Options: format CCYYMM

205

MaturityDay

Reserved. Required for Options.

201

PutOrCall

Reserved. Required for Options

202

StrikePrice

Reserved. Required for Options

207

SecurityExchange

54

Side

Cointex route name


BlockEx
AuctionEx
Only 1 (buy) or 2 (sell) supported

60

TransactTime

Time of this order

38

OrderQty

Required: number of lots

40

OrdType

44

Price

Supported types:
1 market;
2 limit;
3 stop.
Order price for limit and market orders. For market
orders price is indicative and not required.

99

StopPx

Order price for stop orders.

15

Currency

Not supported. Always in primary currency.

117

QuoteID

Reserved.

59

TimeInForce

Varies by exchange

432

ExpireDate

Reserved GTD orders

58

Text

User comment for order.

583

ClOrdLinkID

Cointex OrderID. Cant be used together with 73 and 37


tag for close orders.

77

OpenClose

C for close orders (to add SL/TP or to close position)

18205

slPrice

Price for Stop loss order

18206

tpPrice

Price for Take profit order

24

Standard Trailer

Note, that if you have specifing SL/TP price, then system create independent Stop/Limit
order that is bound to main order. You can work with this orders (cancel, modify), like with
normal Stop/Limit Orders.

IDENTIFYING THE TRADED COMMODITY


To submit a trade to our servers you must identify the traded commodity using the following tags.
Tag

Field Name

Required

Comments

55

Symbol

The Cointex instrument name.

167

SecurityType

The Cointex instrument type name.

200

MaturityMonthYear

Reserved. Required for Options. Always in the format


CCYYMM

205

MaturityDay

Reserved. Required for Options.

207

SecurityExchange

Cointex route name.

201

PutOrCall

Only valid if options are configured for selected


instrument.

202

StrikePrice

Reserved. Required for Options. Should be entered in


the same format as tag 44 Price.

OPEN AND CLOSE INDICATOR


The OpenClose field is used in for trades to indicate whether the trade is opening or closing (close
position, add SL/TP to position or Order.
For close order OrderID tag must be the value Cointex Order ID. For mutual close must be sent
NoOrders of OrderID of all orders for mutual close.

ORDER CANCEL / REPLACE


25

The Order Cancel/Replace is sent by the client application to amend an order that has a working
status. It may not be used to re-open an order by increasing the volume of a completed order.
Part-filled orders may be amended, but not fully filled orders. Attempts to do so will result in a
Cancel Reject with no such order.
If an Order Cancel/Replace is accepted by the business rules but rejected downstream (for
example, if the exchange connection is disabled) the system will deliver an Execution Report for
the pending state followed by a Cancel Reject.

Tag

Field Name

Required

Comments

Standard Header

MsgType = G

37

OrderID

Cointex Order ID

11

ClOrdID

Account

Unique identifier of replacement order (will be used in


the Cancel Reject message if the replacement request
is rejected).
Required: Cointex user account.

21

HandlInst

Set to 1, otherwise will cause reject

55

Symbol

Must match original order

167

SecurityType

Optional: match original order if supplied

200

MaturityMonthYear

Optional: match original order if supplied

205

MaturityDay

Optional: match original order if supplied

201

PutOrCall

Optional: match original order if supplied

202

StrikePrice

Optional: match original order if supplied

207

SecurityExchange

Optional: match original order if supplied

54

Side

Must match original order.

60

TransactTime

Time this order request was initiated/released by the


trader or trading system.

26

38

OrderQty

Number of lots.

152

CashOrderQty

Not supported.

40

OrdType

Must match original order.

44

Price

Optional: may specify new price

99

StopPx

Optional: may specify new stop price

59

TimeInForce

Optional: match original order if supplied

41

OrigClOrdID

Cointex Order ID, used in case of order modification

168

EffectiveTime

Not supported.

432

ExpireDate

Optional: match original order if supplied

77

OpenClose

Optional: Must match original order.

527

SecondaryExecID

ID of open position

Standard Trailer

ORDER CANCEL
The Order Cancel is sent by the client application to cancel all the remaining volume of a working
order. To reduce the volume of an order, you should use Order Cancel/Replace.
Tag

Field Name

Required

Comments

Standard Header

MsgType = F

41

OrigClOrdID

Not supported. ClOrdID of the order to cancel.

37

OrderID

ClOrdID of the order to cancel.

11

ClOrdID

Unique identifier of cancel request (will be used in the


Cancel Reject message if the replacement request is
rejected).

27

Account

Required: Cointex user account.

55

Symbol

Must match original order.

48

SecurityID

Optional.

167

SecurityType

Ignored.

200

MaturityMonthYear

Ignored.

205

MaturityDay

Ignored.

201

PutOrCall

Ignored.

202

StrikePrice

Ignored.

207

SecurityExchange

Ignored.

54

Side

Must match original order

60

TransactTime

Time this order request was initiated/released by the


trader or trading system.

38

OrderQty

Ignored.

Standard Trailer

EXECUTION REPORT
The execution report message is sent by the server to your application for the following reasons:

Confirm receipt of a new order


Confirm changes or cancels to an existing order
Supply unsolicited order state changes
Relay fill information
Actual positions and order state (on login) or as response for Order Status request.
Reject new orders

The OrdStatus and ExecType fields are important for determining the sequence of events that took
place. Some of these scenarios are discussed in further detail below.

28

Tag

Field Name

Required

Comments

Standard Header

MsgType = 8 PossResend=Y for

37

OrderID

Cointex order identifier

198

SecondaryOrderID

Not supported.

11

ClOrdID

41

OrigClOrdID

As set by your application.


Tag 11 you are receiving only with first message 150=A
(pending new).
For further work should be used server orderid (tag 37).
Previous ClOrderID when responding to Cancel or
Cancel/Replace messages.

17

ExecID

Optional: fill identifier

19

ExecRefID

Not supported.

150

ExecType

Not all states are supported.

39

OrdStatus

Not all states are supported.

103

OrdRejReason

Not supported.

378

ExecRestatementReas
on

Supplied for ExecType = D (Restated).

Account

Cointex user account

55

Symbol

Cointex instrument name

48

SecurityID

Cointex instrument ID

167

SecurityType

Cointex instrument type name.

200

MaturityMonthYear

For Options: format CCYYMM

205

MaturityDay

For Options.

201

PutOrCall

For Options.

202

StrikePrice

For Options.

29

207

SecurityExchange

Optional: Cointex route name

54

Side

1 (buy) or 2 (sell) only

38

OrderQty

Order volume

40

OrdType

As stated on the order

44

Price

As stated on the order

99

StopPx

As status on the order

59

TimeInForce

As stated on the order

432

ExpireDate

As stated on the order

32

LastQty

Volume of this fill, zero for reversal

60

TransactTime

Date of order execution

77

PositionEffect

Used to identify if this is an open order 77=O or close


order 77=C (SL/TP or close position).

64

SettlDate

Date of settlement

31

LastPx

Price of this fill, zero for reversal

151

LeavesQty

Volume still working

14

CumQty

Volume filled so far

AvgPx

Decimal average price (accuracy limited)

21

HandlInst

Not returned (is set to 1 on order)

77

OpenClose

Indicate open or close

58

Text

Contains rejection reason text

527

SecondaryExecID

ID of open position

30

Standard Trailer

ExecType I = Order Status used in execution report messages that were sent for update
position/order status or as response on Order Status request.

ORDER CANCEL REJECT


The Order Cancel Reject is delivered by the server when a Cancel or Cancel/Replace is not
accepted by the Cointex server. If the server accepted the Cancel or Cancel/Replace but the
trading system rejected it, then this message is preceded by an Execution Report for the pending
status.
Tag

Field Name

Required

Comments

Standard Header

MsgType = 9

37

OrderID

Cointex order id.

198

SecondaryOrderID

Not supported.

11

ClOrdID

As set in the Cancel or Cancel/Replace

41

OrigClOrdID

ClOrdID which could not be cancelled.

39

OrdStatus

Current order status.

Account

Cointex user account

60

TransactTime

Not supported.

434

CxlRejResponseTo

Either 1 (Cancel) or 2 (Cancel/Replace)

102

CxlRejReason

58

Text

0 too late to cancel


1 unknown order
2 rejected by trading system
3 already in pending state
Text description of rejection

354

EncodedTextLen

Not supported.

31

355

EncodedText

Standard Trailer

Not supported.

ORDER STATUS REQUEST

The order status request can be used teo get list of opened positions or active orders.
Note, that during startup (after Logon) the system sent the list of active orders
automatically.
Tag

Field Name

Required

Comments

790

OrdStatusReqID

55

Symbol

Cointex Instrument Name

54

Side

1- buy, 2 sell

37

OrderId

Cointex OrderID

790

OrdStatusReqID

20000

IntField

1 - state of opened orders, 2 - state of opened positions

Account

Cointex account name

Standard Trailer

REQUEST FOR POSITIONS

Tag

710

Field Name

Require
d

Comments

Standard Header

MsgType = AN

PosReqID

Unique identifier for the Request for Positions as


assigned by the submitter

32

724

PosReqType

0 = Positions only

55

Symbol

if not define - for all visible instruments

Account

Cointex account

715

ClearingBusinessDate

Standard Trailer

name

TRADE CAPTURE REPORT


TRADE CAPTURE REPORT REQUEST
Tag

Field Name

Required

Comments

Standard Header

MsgType = AD

568

TradeRequestID

Unique request id

569

TradeRequestType

Must be 0

37

OrderID

Cointex order id

55

Symbol

Instrument Name

207

SecurityExchange

Cointex route name

580

NoDate

Must be 2. Range of dates (between NoDate1 and


NoDate2)

75

TradeDate

60

TransactTi
me

Time the trade was created

33

TRADER CAPTURE REPORT


Tag

Field Name

Required

Comments

Standard Header

MsgType = AE

568

TradeReportID

Unique report id

569

TradeRequestID

If have requested?

912

LastRptRequested

55

Symbol

Indicates that this is the


last report which will be
returned as a result of
the request.
N not last
Y last
Instrument Name

207

SecurityExchange

Cointex route name

570

PreviouslyReported

Not supported.

32

LastQty

Trade Quantity

31

LastPx

Trade Price

75

TradeDate

Not supported

60

TransactTime

Time the trade was created

552

NoSides

Number of sides

64

SettlDate

date of trade settlement

54

Side

1 (buy) or 2 (sell)

37

OrderID

Unique order id

Account

Account name

34

119

SettlCurrA
mt

LastPx*LastQty

198

Secondary
OrderID

Counter Order ID

Note: Trade capture report will be sent only in real time connection

35

Anda mungkin juga menyukai