Skip to content

Update strategy#

About#

Updates provider strategy

PUT /users/current/configuration/strategies/:strategyId

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
strategyId string Yes strategy id

Body#

Account payload schema: UpdatedStrategy

Response#

Responses:

  • 204 - Strategy saved successfully.
  • 400 - Strategy payload validation failed. Response schema: Error
  • 401 - Authorization failed. Response schema: Error

Examples#

Example request:

curl -X PUT --header 'Accept: application/json' --header 'auth-token: token' -d '{
"name": "string",
"description": "string",
"positionLifecycle": "netting",
"skipPendingOrders": true,
"connectionId": "string",
"commissionScheme": {
  "type": "flat-fee",
  "billingPeriod": "week",
  "commissionRate": 0
},
"maxTradeRisk": 0,
"reverse": true,
"reduceCorrelations": "by-strategy",
"stopOutRisk": {
  "value": 0,
  "startTime": "string"
},
"symbolFilter": {
  "included": [
    "string"
  ],
  "excluded": [
    "string"
  ]
},
"newsFilter": {
  "breakingNewsFilter": {
    "priorities": [
      "high"
    ],
    "closePositionTimeGapInMinutes": 0,
    "openPositionFollowingTimeGapInMinutes": 0
  },
  "calendarNewsFilter": {
    "priorities": [
      "election"
    ],
    "closePositionTimeGapInMinutes": 0,
    "openPositionPrecedingTimeGapInMinutes": 0,
    "openPositionFollowingTimeGapInMinutes": 0
  }
},
"riskLimits": [
  {
    "type": "daily",
    "applyTo": "balance",
    "maxRisk": 0,
    "closePositions": true,
    "startTime": "string"
  }
],
"maxStopLoss": {
  "value": 0,
  "units": "pips"
},
"maxLeverage": 0,
"symbolMapping": [
  {
    "to": "string",
    "from": "string"
  }
],
"tradeSizeScalingMode": "none",
"magicFilter": {
  "included": [
    "string"
  ],
  "excluded": [
    "string"
  ]
},
"timeSettings": {
  "lifetimeInHours": 0,
  "openingIntervalInMinutes": 0
}
}' 'https://trading-api-v1.agiliumtrade.agiliumtrade.ai/users/current/configuration/strategies/iAFv'