跳到正文
注册

自选与提醒

创建价格提醒

价格一到达你的目标,或在 24 小时内波动到你设定的幅度,即刻通知你。

POST/api/v1/alerts获取密钥
curl --request POST \
  --url "https://reirex.com/api/v1/alerts" \
  --header "GX-API-KEY: $GX_API_KEY" \
  --header "GX-API-TIMESTAMP: $TIMESTAMP" \
  --header "GX-API-SIGN: $SIGNATURE" \
  --header "Content-Type: application/json" \
  --data '{"symbol":"BTC","mode":"price","target":"80000","currency":"EUR","direction":"above","repeat":"once","channels":["push","email"]}'

201 Createdapplication/json

{
  "alertId": 12,
  "symbol": "BTC",
  "mode": "price",
  "target": "80000",
  "currency": "EUR",
  "direction": "above",
  "move": null,
  "repeat": "once",
  "channels": ["push", "email"],
  "createdAt": "2026-10-14T16:14:15.412Z"
}

price 提醒需要 target、currency 和 direction;move 提醒需要 move,单位为百分比。提醒通过推送、电子邮件或两者同时发送。

请求体application/json

  • symbolstring必填

    品种。

  • modestring必填

    price 表示目标价格,move 表示 24 小时内的涨跌幅。

    可选值pricemove

  • targetstring

    要关注的价格,以十进制字符串表示。

  • currencystring

    target 的货币,例如 EUR 或 USD。

  • directionstring

    above 表示涨到目标价,below 表示跌到目标价。

    可选值abovebelow

  • movestring

    涨跌幅百分比,不论方向,例如 5。

  • repeatstring必填

    once,或 always 表示每次都通知。

    可选值oncealways

  • channelsstring[]必填

    push、email 或两者。

    可选值pushemail

响应

  • alertIdinteger

    我们为提醒分配的 id。

  • symbolstring

    提醒关注的品种。

  • modestring

    price 或 move。

  • targetstring | null

    目标价格;涨跌幅提醒为 null。

  • currencystring | null

    目标价格的货币;涨跌幅提醒为 null。

  • directionstring | null

    above 或 below;涨跌幅提醒为 null。

  • movestring | null

    涨跌幅百分比;价格提醒为 null。

  • repeatstring

    once 或 always。

  • channelsstring[]

    通知方式:push、email 或两者。

  • createdAtstring

    设置时间。