云服务器内容精选

  • 响应示例 状态码: 400 { "error_code" : "EG.00014000", "error_msg" : "Bad request"} 状态码: 401 { "error_code" : "EG.00014010", "error_msg" : "Incorrect token or token resolution failed"} 状态码: 403 { "error_code" : "EG.00014030", "error_msg" : "No permissions to request this method"} 状态码: 404 { "error_code" : "EG.00014040", "error_msg" : "Not request resource found"} 状态码: 500 { "error_code" : "EG.00015000", "error_msg" : "Internal Server Error"}
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 total Integer 总数 最小值:0 最大值:100 size Integer 本页数量 最小值:0 最大值:100 items Array of SubscriptionInfo objects 对象列表 数组长度:0 - 100 表5 SubscriptionInfo 参数 参数类型 描述 id String 订阅ID name String 订阅名称 description String 订阅描述 type String 类型 枚举值: EVENT SCHEDULED status String 状态 枚举值: CREATED ENABLED DISABLED FROZEN ERROR channel_id String 通道ID channel_name String 通道名称 used Array of SubscriptionUsedInfo objects 标签信息 sources Array of SubscriptionSourceInfo objects 订阅源列表 targets Array of SubscriptionTargetInfo objects 订阅目标列表 created_time String 创建时间 updated_time String 更新时间 表6 SubscriptionUsedInfo 参数 参数类型 描述 resource_id String 关联资源ID owner String 管理租户账号 description String 描述 表7 SubscriptionSourceInfo 参数 参数类型 描述 id String 订阅源ID name String 订阅的事件源名称 provider_type String 订阅的事件源的提供方类型 detail Object 订阅的事件源参数列表 filter Object 订阅事件源的匹配过滤规则 created_time String 创建时间 updated_time String 更新时间 表8 SubscriptionTargetInfo 参数 参数类型 描述 id String 订阅目标ID name String 订阅的事件目标名称 provider_type String 订阅的事件目标的提供方类型 connection_id String 订阅的事件目标使用的目标链接ID 最大长度:64 detail Object 订阅的事件目标参数列表 transform TransForm object 订阅的事件目标转换规则 dead_letter_queue DeadLetterQueue object 订阅的死信参数列表 created_time String 创建时间 updated_time String 更新时间 表9 TransForm 参数 参数类型 描述 type String 转换规则类型 枚举值: ORIGINAL CONSTANT VARIABLE value String 常量类型规则时,字段为常量内容定义; 变量类型规则时,为变量定义,内容必须为JsonObject字符串。 变量最多支持100个,且不支持嵌套结构定义; 变量名由字母、数字、点、下划线和中划线组成,必须字母或数字开头不能以HC.开头,长度不超过64个字符; 变量值表达式支持常量或JsonPath表达式,字符串长度不超过1024个字符。 最大长度:1024 template String 变量类型规则时,规则内容的模板定义,支持对已定义变量的引用。 最大长度:2048 表10 DeadLetterQueue 参数 参数类型 描述 type String 队列类型 枚举值: KAFKA instance_id String 实例id 最小长度:1 最大长度:128 connection_id String 目标连接id 最小长度:1 最大长度:128 topic String 主题 最小长度:1 最大长度:128 状态码: 400 表11 响应Body参数 参数 参数类型 描述 error_code String 错误码 最小长度:1 最大长度:128 error_msg String 错误消息 最小长度:1 最大长度:512 error_details String 具体错误消息 最小长度:1 最大长度:1024 request_id String 请求处理ID 最小长度:1 最大长度:128 状态码: 401 表12 响应Body参数 参数 参数类型 描述 error_code String 错误码 最小长度:1 最大长度:128 error_msg String 错误消息 最小长度:1 最大长度:512 error_details String 具体错误消息 最小长度:1 最大长度:1024 request_id String 请求处理ID 最小长度:1 最大长度:128 状态码: 403 表13 响应Body参数 参数 参数类型 描述 error_code String 错误码 最小长度:1 最大长度:128 error_msg String 错误消息 最小长度:1 最大长度:512 error_details String 具体错误消息 最小长度:1 最大长度:1024 request_id String 请求处理ID 最小长度:1 最大长度:128 状态码: 404 表14 响应Body参数 参数 参数类型 描述 error_code String 错误码 最小长度:1 最大长度:128 error_msg String 错误消息 最小长度:1 最大长度:512 error_details String 具体错误消息 最小长度:1 最大长度:1024 request_id String 请求处理ID 最小长度:1 最大长度:128 状态码: 500 表15 响应Body参数 参数 参数类型 描述 error_code String 错误码 最小长度:1 最大长度:128 error_msg String 错误消息 最小长度:1 最大长度:512 error_details String 具体错误消息 最小长度:1 最大长度:1024 request_id String 请求处理ID 最小长度:1 最大长度:128
  • URI GET /v1/{project_id}/subscriptions 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 租户项目ID 表2 Query参数 参数 是否必选 参数类型 描述 channel_id 否 String 指定查询的事件通道ID offset 否 Integer 偏移量,表示从此偏移量开始查询,偏移量不能小于0 最小值:0 最大值:100 缺省值:0 limit 否 Integer 每页显示的条目数量,不能小于1或大于1000 最小值:1 最大值:1000 缺省值:15 sort 否 String 指定查询排序 缺省值:created_time:DESC name 否 String 指定查询的事件订阅名称,精准匹配 fuzzy_name 否 String 指定查询的事件订阅名称,模糊匹配 connection_id 否 String 目标连接 id 最小长度:32 最大长度:64