Documentation
The Questrade API allows developers to create their own fully featured trading and analytical applications through their brokerage account.
REST operations
POST accounts/:id/orders
Allows to (re)place an order against a certain account.
Request parameters
| Parameter | Type | Description |
|---|---|---|
| Parameterid | TypeString | DescriptionAccount number against which order is being submitted. Can occur in the 'Location' header only. |
| ParameterorderId | TypeInteger | DescriptionOptional – order id of the order to be replaced. |
| ParametersymbolId | TypeInteger | DescriptionInternal symbol identifier. |
| Parameterquantity | TypeInteger | DescriptionOrder quantity. |
| ParametericebergQuantity | TypeInteger | DescriptionIceberg instruction quantity. |
| ParameterlimitPrice | TypeDouble | DescriptionLimit price. |
| ParameterstopPrice | TypeDouble | DescriptionStop price. |
| ParameterisAllOrNone | TypeBoolean | DescriptionIdentifies whether the all-or-none instruction is enabled. |
| ParameterisAnonymous | TypeBoolean | DescriptionIdentifies whether the anonymous instruction is enabled. |
| ParameterorderType | TypeEnumeration | DescriptionOrder type (e.g., "Market"). See Order Type section for all allowed values. |
| Parameteraction | TypeEnumeration | DescriptionOrder side (e.g., "Buy"). See Order Action section for all allowed values. |
| ParameterprimaryRoute | TypeEnumeration | DescriptionPrimary order route (e.g., "AUTO"). |
| ParametersecondaryRoute | TypeEnumeration | DescriptionSecondary order route (e.g., "NYSE"). |
Response properties
| Property | Type | Description |
|---|---|---|
| PropertyorderId | TypeInteger | DescriptionInternal order identifier. |
| Propertyorders | TypeComplex | DescriptionList of order objects. |
| PropertyNested property, level 2. Order | TypeComplex | Description |
Sample request
POST https://api01.iq.questrade.com/v1/accounts/26598145/orders
{
"accountNumber" : XXXXXXXX ,
"symbolId": 8049,
"quantity": 10,
"icebergQuantity": 1,
"limitPrice": 537,
"isAllOrNone": true,
"isAnonymous": false,
"orderType": "Limit",
"timeInForce": "GoodTillCanceled",
"action": "Buy",
"primaryRoute":"AUTO",
"secondaryRoute": "AUTO"
}Sample JSON response
{
"orderId": 177106005 ,
"orders": [
{
"id": 177106005 ,
"symbol": "AAPL",
"symbolId": 8049,
"totalQuantity": 10,
"openQuantity": 10,
"filledQuantity": 0,
"canceledQuantity": 0,
"side": "Buy",
"orderType": "Limit",
"limitPrice": 537,
"stopPrice": null,
"isAllOrNone": true,
"isAnonymous": false,
"icebergQty": 1,
"minQuantity": null,
"avgExecPrice": null,
"lastExecPrice": null,
"source": "TradingAPI",
"timeInForce": "GoodTillCanceled",
"gtdDate": null,
"state": "Pending",
"clientReasonStr": "",
"chainId": 177106005,
"creationTime": "2014-10-24T17:48:20.546000-04:00",
"updateTime": "2014-10-24T17:48:20.876000-04:00",
"notes": "",
"primaryRoute": "LAMP",
"secondaryRoute": "AUTO",
"orderRoute": "LAMP",
"venueHoldingOrder": "",
"comissionCharged": 0,
"exchangeOrderId": "",
"isSignificantShareHolder": false,
"isInsider": false,
"isLimitOffsetInDollar": false,
"userId": 3000124,
"placementCommission": null,
"legs": [],
"strategyType": "SingleLeg",
"triggerStopPrice": null,
"orderGroupId": 0,
"orderClass": null,
"mainChainId": 0
},
...
]
}Already a Questrade client?
Create your first application using your Questrade account.
Integrate your application with Questrade API
Support
If you are using an api app developed by a third party, you are required to read, understand and accept the end-user license agreement for application program interface. If you are utilizing api access for an api-enabled app you built, you are required to read, understand and accept the Questrade personal application program interface ("api") license agreement ("license agreement"). This agreement can be found below. You may be bound by both agreements.


