interface OrdersBatchAut

Brief

Executes multiple trading operations with orders at once.

Details

Used to execute multiple trading operations ("create", "change" or "delete") at once.

To execute multiple operations with orders:

  1. Get an instance of the class using the TradeDeskAut.CreateOrdersBatch method.
  2. Add requests to create, change or delete orders to the orders batch. Use the appropriate methods of OrdersBatchAut.
    There are the following restrictions for requests in a batch:
    - All requests in a batch must have the same operation type ("create order", "change order" or "delete order"). Note that there are requests which can either create or change an order. For example, ChangeTradeStopLimit. These requests can be included either in the "create" or "change" batch depending on the trade operation they perform.
    - All requests in a batch must be either for regular orders (stop, limit, open, close, entry) or for contingent orders (ELS orders).
    - All requests in a batch must be for different orders.
  3. To execute the requests, call the OrdersBatchAut.Execute method.
    The method also allows creating regular entry orders or ELS orders and linking them in an OCO order at a time. For this, the property OrdersBatchAut.JoinOCO must be set to True.

Public Properties

JoinOCO

Gets/Sets "link to an OCO order" mode for the OrdersBatchAut.Execute method.

Public Methods

ChangeEntryOrder

Adds a request to change a rate, amount and trailing for an entry order.

ChangeEntryOrderAmount

Adds a request to change the entry order amount to the orders batch.

ChangeEntryOrderStopLimit

Adds a request to change a stop/limit order for the entry order to the orders batch.

Does not work for United States based accounts. Please read NFA Compliance Rule 2-43(b). In case if this function is used Order2Go API will throw an Exception/Error.

ChangeNetStopLimit

Adds a request to create or change a net position stop or limit order to the orders batch.

ChangeOrderRate

Adds a request to change the order rate or order trailing mode to the orders batch.

ChangeTradeStopLimit

Adds a request to change a stop/limit order for the trade to the orders batch.

Does not work for United States based accounts. Please read NFA Compliance Rule 2-43(b). In case if this function is used Order2Go API will throw an Exception/Error.

CloseTrade

Adds a request to create a close order to the orders batch.

Don't use for United States based accounts. Please read NFA Compliance Rule 2-43(b).

Please read: How to close positions on United States based (FIFO) accounts.

CloseTradesByInstrument

Adds a request to create a "close all by instrument" order to the orders batch.

CreateEntryOrder

Deprecated. Please use the CreateEntryOrder2 method instead.

Unlike the CreateEntryOrder method, CreateEntryOrder2 allows making any of the orders (entry, stop, limit) trailing.

CreateEntryOrder2

Adds a request to create an entry order to the orders batch.

CreateEntryOrder3

Adds a request to create an entry order to the orders batch.

Unlike the CreateEntryOrder2 method, CreateEntryOrder3 allows you to choose the Time In Force for the entry order.

CreateEntryOrderELS

Adds into the orders creation batch up to 3 orders for create an ELS with an entry order as a primary order.

CreateFixOrder

Adds a request to create an order to the orders batch.

DeleteEntryOrderStopLimit

Adds a request to delete either a stop or limit order created for the entry order to the orders batch.

Does not work for United States based accounts. Please read NFA Compliance Rule 2-43(b). In case if this function is used Order2Go API will throw an Exception/Error.

DeleteNetStopLimit

Adds a request to delete a net position stop/limit order to the orders batch.

DeleteOrder

Adds a request to delete an order to the orders batch.

DeleteTradeStopLimit

Adds a request to delete either a stop or limit order created for the trade to the orders batch.

Does not work for United States based accounts. Please read NFA Compliance Rule 2-43(b). In case if this function is used Order2Go API will throw an Exception/Error.

Execute, ExecuteAsync

Executes a batch of requests to create, change or delete orders. Allows creating entry orders and linking them to an OCO order at a time.

OpenTrade

Adds a request to create an open order to the orders batch.

Partial functionality for United States based accounts. Specifying any values for Stop and Limit (besides 0) in this function will result throwing an Exception/Error. Please read NFA Compliance Rule 2-43(b).

OpenTradeELS

Adds into the orders creation batch up to 3 orders for create an ELS with a market order as a primary order.

back