RestartRobot
The RestartRobot method starts (restarts) a live trading bot of the platform account of the API KEY in the request; the bot is given by robotId. Starting a bot charges fees.
Returns
json
{
"code":0,
"data":{
"result":1,
"error":null
}
}
- result: Live trading status code, 1 indicates running.
Arguments
| Name | Type | Required | Description |
robotId | number | Yes | Live trading bot ID, see the |
settings | JSON object | No | Live trading configuration; for its fields see "Live trading configuration (settings)" in Extended API Interface Details. When given, the bot's configuration (name, parameters, exchanges, K-line period, docker, group) is updated with it before starting; the strategy cannot be changed. |
Remarks
A bot created on the website with exchange accounts referenced by pid can be started with robotId alone, using its current configuration. A bot whose exchanges were passed directly with eid (usually created through the extended API) has no stored keys, so settings must be passed on every restart.