Stage 4: Session Persistence

Successful Log On with sequence number 1

1)  Successfully open TCP socket connection.

2)  Send a Logon message with proper trader login, password and sequence number = 1

3)  Receive Logon confirmation message.

4)  Send a Logout message.

5)  Close the TCP socket connection.

Recover from invalid Log On with sequence fallback

The following test is optional in case when session persistence interval = 1

1)  Send a Logon message with proper trader login, password and sequence number = 1

2)  Receive Logon confirmation message.

3)  Wait for 101 heartbeat

4)  Send a Logout message.

5)  Close the TCP socket connection.

6)  Send a Logon message with proper trader login, password and sequence number = 10.

7)  Receive logout message.

Order Placement and Fill

1)  Place new DAY order BUY 1 <Futures 1> LMT with price below the market.

2)  Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

3)  Logout from FIX Connect.

4)  Email OrderID (tag 37) to APIHELP@cqg.com to have it filled externally.

5)  Logon into FIX Connect.

6)  Receive Execution Report: ExecTransType=New, OrdStatus=Filled, ExecType=Fill.

7)  Confirm values of ClOrdID (11), OrderID (37), ExecID (17), and TransactTime (60).

Place and Cancel

1)  Place new DAY order BUY 5 <Call option 1> STP <P1 = price above the market>.

2)  Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

3)  Logout from FIX Connect.

4)  Email OrderID (tag 37) to APIHELP@cqg.com to have it cancelled externally.

5)  Logon into FIX Connect.

6)  Receive Execution Report: ExecTransType=New, OrdStatus=Pending Cancel, ExecType=Pending Cancel.

7)  Receive Execution Report: ExecTransType=New, OrdStatus=Canceled, ExecType=Canceled.

8)  Confirm values of ClOrdID (11), OrigClOrdID (41), OrderID (37), ExecID (17), StopPx (99), TransactTime (60).

Order Rejection

1)  Account trade size limit 100 by default.

2)  Logout from FIX Connect.

3)  Email APIHELP@cqg.com to have a new order placed (DAY order SELL 101 <Futures 1> MKT).

4)  Logon into FIX Connect.

5)  Receive Execution Report: ExecTransType=New, OrdStatus=Rejected, ExecType=Rejected.

Order Modifications

1)  Place new GTC order SELL 100 <Futures 2> LMT <P1 = price above the market>.

2)  Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

3)  Logout from FIX Connect.

4)  Email OrderID (tag 37) to APIHELP@cqg.com to

5)  Modify the quantity to 50 externally.

6)  Modify the price to P2 > P1 externally.

7)  Cancel the order externally.

8)  Logon into FIX Connect.

9)  Receive Execution Report: ExecTransType=New, OrdStatus=Pending Replace, ExecType=Pending Replace.

10) Confirm OrderQty value.

11) Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

12) Confirm OrderQty value.

13) Receive Execution Report: ExecTransType=New, OrdStatus=Pending Replace, ExecType=Pending Replace.

14) Confirm Price value.

15) Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

16) Confirm Price value.

17) Receive Execution Report: ExecTransType=New, OrdStatus=Pending Cancel, ExecType=Pending Cancel.

18) Receive Execution Report: ExecTransType=New, OrdStatus=Canceled, ExecType=Canceled.

19) Confirm values of OrderID, ExecID, Price, OrderQty, TransactTime.

Order Modification: Price and Quantity

1)  Place new GTC order SELL 50 <Futures 2> LMT <P1 = price above the market>.

2)  Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

3)  Logout from FIX Connect.

4)  Email OrderID (tag 37) to APIHELP@cqg.com to

5)  Modify the price to P2 > P1 and the size to 100 externally

6)  Cancel the order externally.

7)  Logon into FIX Connect.

8)  Receive Execution Report: ExecTransType=New, OrdStatus=Pending Replace, ExecType=Pending Replace.

9)  Confirm Price and OrderQty values.

10) Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

11) Confirm Price and OrderQty values.

12) Receive Execution Report: ExecTransType=New, OrdStatus=Pending Cancel, ExecType=Pending Cancel.

13) Confirm Price and OrderQty values.

14) Receive Execution Report: ExecTransType=New, OrdStatus=Canceled, ExecType=Canceled.

15) Confirm values of ClOrdID, OrigClOrdID, OrderID, ExecID, Price, OrderQty, TransactTime.

Order Modification Rejection

1)  Account trade size limit 100 by default.

2)  Place new GTD <date = now + 1 week> order SELL 100 <Put option 1> STP P1 = <price below the market> LMT P2 > P1.

3)  Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

4)  Logout from FIX Connect.

5)  Email OrderID (tag 37) to APIHELP@cqg.com to

6)  Modify the size to 101 to hit the order size limit externally

7)  Cancel the order externally.

8)  Logon into FIX Connect.

9)  Receive Execution Report: ExecTransType=New, OrdStatus=Rejected, ExecType=Rejected.

10) Confirm OrderQty value.

11) Confirm values of ClOrdID, OrigClOrdID, OrderID, ExecID, OrderQty, TransactTime and ExpireDate.

Canceling Partially Filled Order

1)  Place new GTD <date = now + 1 week> order BUY 500 <Futures 2> LMT P1 = <below the market>.

2)  Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

3)  Logout from FIX Connect.

4)  Email OrderID (tag 37) to APIHELP@cqg.com to

a)  Partially fill the order externally

b)  Cancel the order externally.

5)  Logon into FIX Connect.

6)  Receive Execution Report: ExecTransType=New, OrdStatus=Partially Filled, ExecType=Partial Fill.

7)  Confirm values of LastPx, LastShares, AvgPx, CumQty, and LeavesQty.

8)  Confirm values of ClOrdID, OrigClOrdID, OrderID, ExecID, TransactTime, and ExpireDate.

9)  Confirm values of LastPx, LastShares, AvgPx, CumQty, and LeavesQty.

Strategy Order: Zero Price

1)  Place DAY order SELL or BUY 1 <Futures Spread 1> LMT 0, use SELL if market price is below zero, BUY if above (to get order filled).

2)  Logout from FIX Connect.

3)  Email OrderID (tag 37) to APIHELP@cqg.com to fill the order externally

4)  Logon into FIX Connect.

5)  Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

6)  Receive Execution Report: ExecTransType=New, OrdStatus=Filled, ExecType=Fill.

7)  Confirm values of ClOrdID, OrigClOrdID, OrderID, ExecID, TransactTime, and ExpireDate.

8)  Confirm values of LastPx, LastShares, AvgPx, CumQty, and LeavesQty.

9)  Confirm leg field values: NoLegs, LegCurrency, LegSymbol, LegSide, LegLastPx, and LegQty.

Strategy Order: Negative Price

1)  Place DAY order SELL or BUY 1 <Futures Spread 1> LMT -2, use SELL if market price is below zero, BUY if above (to get order filled).

2)  Logout from FIX Connect.

3)  Email OrderID (tag 37) to APIHELP@cqg.com to fill the order externally

4)  Logon into FIX Connect.

5)  Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

6)  Receive Execution Report: ExecTransType=New, OrdStatus=Filled, ExecType=Fill.

7)  Confirm values of ClOrdID, OrigClOrdID, OrderID, ExecID, TransactTime, and ExpireDate.

8)  Confirm values of LastPx, LastShares, AvgPx, CumQty, and LeavesQty.

9)  Confirm leg field values: NoLegs, LegCurrency, LegSymbol, LegSide, LegLastPx, and LegQty.

Fill Corrections

1)  Place DAY order BUY 2 <Futures 3> LMT P1 = <above the market>.

2)  Logout from FIX Connect.

3)  Email OrderID (tag 37) to APIHELP@cqg.com to

a)  Correct the fill price externally.

b)  Correct the fill size externally.

c)  Bust the order externally.

4)  Logon into FIX Connect.

5)  Receive Execution Report: ExecTransType=New, OrdStatus=New, ExecType=New.

6)  Receive Execution Report: ExecTransType=New, OrdStatus=Filled, ExecType=Fill.

7)  Receive Execution Report: ExecTransType=Correct, OrdStatus=Filled, ExecType=Fill.

8)  Confirm the values of fields LastPx, AvgPx, LastShares, and OrderQty.

9)  Receive Execution Report: ExecTransType=Correct, OrdStatus=Partially Filled, ExecType=Partial Fill.

10) Confirm values of fields LastPx, AvgPx, LastShares, and OrderQty.

11) Receive Execution Report: ExecTransType=New, OrdStatus=Filled, ExecType=Fill.

12) Confirm values of LastPx, AvgPx, LastShares, and OrderQty.