Skip to content

Reset stop outs#

About#

Resets a stop out. Please note that before resetting a stopout vis this API you need to adjust startTime setting of your stoupout or risk limit configuration of your subscription.

POST /users/current/accounts/:accountId/strategies-subscribed/:strategyId/stopouts/:reason/reset

For more information see Swagger documentation

Headers#

Name Type Required Description
auth-token string Yes authorization token. See Authentication & authorization

Path parameters#

Name Type Required Description
accountId string Yes account id
strategyId string Yes strategy id
reason string Yes reason of a stop out to reset. One of yearly-balance, monthly-balance, daily-balance, yearly-equity, monthly-equity, daily-equity, max-drawdown

Response#

Responses:

  • 204 - Stopouts were reset successfully
  • 401 - Authorization failed. Response schema: Error
  • 403 - User is not an account owner. Response schema: Error

Examples#

Example request:

First step is to adjust the startTime setting on the stopout or risk limit configuration or both. See Update account API for more details.

curl -X PUT --header 'Accept: application/json' --header 'auth-token: token' -d '{
  "name": "Demo account",
  "connectionId": "105646d8-8c97-4d4d-9b74-413bd66cd4ed",
  "subscriptions": [
    {
      "strategyId": "SMKn",
      "multiplier": 1,
      ... (other settings go here)
      "stopOutRisk": {
        "value": 0.2,
        "startFrom": "2021-03-22T00:00:00.000Z" (current time)
      },
      "riskLimits": [
        {
          ... (risk limit settings go here)
          "startFrom": "2021-03-22T00:00:00.000Z" (current time)
        }
      ]
    }
  ]
}' 'https://trading-api-v1.agiliumtrade.agiliumtrade.ai/users/current/configuration/accounts/2DLmSEibEc1UeNpTXGcoZ22FqhFiaiUpxykfTuX2VbLMDD0NCuBXUlH8Jye6wWSQ'

Finally, you can reset the stopout so that trading can continue.
```bash
curl -X POST --header 'Accept: application/json' --header 'auth-token: token' 'https://trading-api-v1.agiliumtrade.agiliumtrade.ai/users/current/accounts/2DLmSEibEc1UeNpTXGcoZ22FqhFiaiUpxykfTuX2VbLMDD0NCuBXUlH8Jye6wWSQ/strategies-subscribed/iERv/stopouts/max-drawdown/reset'