跳转到主要内容
平台运维/云平台监控相关接口/监控报警/通知服务/通知服务相关接口

添加短信接收者

添加短信接收者

POST/zstack/v1/sns/sms-endpoints/receivers

操作 ID

AddSNSSmsReceiver

起始版本

3.7.0

执行模式

同步

认证信息

需要认证

认证信息

调用该 API 时需要在请求头中携带以下认证信息。

Authorizationstring必填

Bearer 令牌

X-Tenant-IDstring

X-Tenant-ID

请求参数

application/json

请求体字段

  • params
    Object必填

    请求体参数结构

    • phoneNumber
      String

      单个接收号码;与phoneNumberList至少提供一项,同时提供时使用phoneNumberList

    • phoneNumberList
      List

      号码列表不能重复或包含已有号码;添加后接收者总数最多200个

    • endpointUuid
      String必填

      短信接收端Uuid

    • type
      String必填

      短信接收端类型;插件短信通知对象填写Plugin

    • description
      String

      短信接收者描述

    • resourceUuid
      String

      可选。

    • tagUuids
      List

      标签UUID列表

  • systemTags
    List

    系统标签

  • userTags
    List

    用户标签

响应状态

200 OK
200 OK

该 API 成功时返回以下响应结构。

  • error
    ErrorCode必填

    错误码,若不为null,则表示操作失败, 操作成功时该字段为null。 详情参考error

    • code
      String必填

      错误码号,错误的全局唯一标识,例如SYS.1000, HOST.1001

    • description
      String必填

      错误的概要描述

    • details
      String必填

      错误的详细信息

    • elaboration
      String必填

      保留字段,默认为null

    • opaque
      LinkedHashMap必填

      保留字段,默认为null

    • cause
      ErrorCode必填

      根错误,引发当前错误的源错误,若无原错误,该字段为null

  • inventories
    List必填

    详情参考inventories

    • uuid
      String必填

      资源的UUID,唯一标示该资源

    • phoneNumber
      String必填

      短信接收号码

    • endpointUuid
      String必填

      短信接收端Uuid

    • description
      String必填

      短信接收者描述

    • createDate
      Timestamp必填

      创建时间

    • lastOpDate
      Timestamp必填

      最后一次修改时间

    • type
      SmsReceiverType必填

      详情参考type

      • AliyunSms
        SmsReceiverType必填

        阿里云短信

  • 变更时间

    已删除响应字段 UniversalSms, success
    查看 API