Skip to main content

编辑定投计划 (TRADE)

接口描述#

编辑定投计划

HTTP请求#

POST /sapi/v1/lending/auto-invest/plan/edit

请求权重(IP)#

1

请求参数#

名称类型是否必需描述
planIdLONGYES计划编号
subscriptionAmountDECIMALYESFiat&Stablecoin: 2dp, BNB/ETH/BTC: 4dp
subscriptionCycleENUMYES"H1", "H4", "H8","H12", "WEEKLY","DAILY","MONTHLY","BI_WEEKLY"
subscriptionStartDayINTEGERNO“1”,...”31”; 如果 “subscriptionCycleNumberUnit” = “MONTHLY”则必填,数值必须为 UTC+0
subscriptionStartWeekdayENUMNO“MON”,”TUE”,”WED”,”THU”,”FRI”,”SAT”,”SUN”; 如果 “subscriptionCycleNumberUnit” = “MONTHLY”则必填,数值必须为 UTC+0
subscriptionStartTimeINTEGERYES“0,1,2,3,4,5,6,7,8,..23”;Must be sent in form of UTC+0
sourceAssetSTRINGYES如 “USDT”
flexibleAllowedToUseBOOLEANNOtrue/false;true:使用 flexible wallet
detailsArray\<PortfolioDetail>YESsum(all node's percentage) == 100,若作为请求参数发送, 像以下格式details[0].targetAsset=BTC
details[0].percentage=60 details[1].targetAsset=ETH details[1].percentage=40
recvWindowLONGNOno more than 60000
timestampLONGYES
  • 单个账户每秒最多请求3次

响应示例#

{  "planId": 12345, //成功创建后planId不变  "nextExecutionDateTime":1648378800000, //计划下次执行时间}