Live Management
Live Commands
Request
Sends a command to a live deployment to trigger an action such as placing orders. The /live/commands/create
API accepts requests in the following format:
CreateLiveCommandRequest Model - Request to create a live command. | |
---|---|
projectId | integer Project for the live instance we want to run the command against. |
command | object The command to run. |
Example |
{ "projectId": 19626262, "command": { "$type": "OrderCommand", "symbol": { "id": "BTCUSD 2XR", "value": "BTCUSD" }, "order_type": "market", "quantity": "0.1", "limit_price": 0, "stop_price": 0, "tag": "" } } |
Responses
The /live/commands/create
API provides a response in the following format:
200 Success
RestResponse Model - Base API response class for the QuantConnect API. | |
---|---|
success | boolean Indicate if the API request was successful. |
errors | string Array List of errors with the API call. |
Example |
{ "success": true, "errors": [ "string" ] } |
401 Authentication Error
UnauthorizedError Model - Unauthorized response from the API. Key is missing, invalid, or timestamp is too old for hash. | |
---|---|
www_authenticate | string Header |