华为云用户手册

  • 响应示例 状态码: 200 OK { "total" : 1, "size" : 1, "plugins" : [ { "plugin_attach_id" : "8aa097b00e9843efacb9c593d11b769e", "plugin_id" : "5b729aa252764739b3s237ef0d66dc63", "plugin_name" : "跨域插件", "plugin_type" : "cors", "plugin_scope" : "global", "plugin_content" : "{\"allow_origin\": \"*\",\"allow_methods\": \"GET,POST,PUT\",\"allow_headers\": \"Content-Type,Accept,Accept-Ranges,Cache-Control\",\"expose_headers\": \"X-Request-Id,X-Apig-Latency\",\"max_age\": 172800,\"allow_credentials\": true}", "remark" : "CORS跨域资源访问", "env_id" : "DEFAULT_ENVIRONMENT_RELEASE_ID", "env_name" : "RELEASE", "attached_time" : "2022-11-02T12:31:23.353Z", "create_time" : "2022-11-02T12:31:23.353Z", "update_time" : "2022-11-02T12:31:23.353Z" } ] } 状态码: 400 Bad Request { "error_code" : "APIG.2012", "error_msg" : "Invalid parameter value,parameterName:instance_id. Please refer to the support documentation" } 状态码: 401 Unauthorized { "error_code" : "APIG.1002", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIG.1005", "error_msg" : "No permissions to request this method" } 状态码: 404 Not Found { "error_code" : "APIG.3002", "error_msg" : "API 5f918d104dc84480a75166ba99efff21 does not exist" } 状态码: 500 Internal Server Error { "error_code" : "APIG.9999", "error_msg" : "System error" }
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 size Integer 本次返回的列表长度 total Long 满足条件的记录数 plugins Array of AttachedPluginInfo objects 绑定API的插件列表。 表5 AttachedPluginInfo 参数 参数类型 描述 plugin_attach_id String 插件绑定编码。 plugin_id String 插件编码。 plugin_name String 插件名称。支持汉字,英文,数字,中划线,下划线,且只能以英文和汉字开头,3-255字符 说明: 中文字符必须为UTF-8或者unicode编码。 plugin_type String 插件类型 cors:跨域资源共享 set_resp_headers:HTTP响应头管理 kafka_log:Kafka日志推送 breaker:断路器 rate_limit: 流量控制 third_auth: 第三方认证 枚举值: cors set_resp_headers kafka_log breaker rate_limit third_auth plugin_scope String 插件可见范围。global:全局可见。 枚举值: global env_id String 绑定API的环境编码。 env_name String api授权绑定的环境名称 attached_time String 绑定时间。 plugin_content String 插件定义内容,支持json。 最大长度:65535 remark String 插件描述,255字符。 说明: 中文字符必须为UTF-8或者unicode编码。 最大长度:255 create_time String 创建时间。 update_time String 更新时间。 状态码: 400 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 401 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 404 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • URI GET /v2/{project_id}/apigw/instances/{instance_id}/apis/{api_id}/attached-plugins 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 项目ID,获取方式请参见获取项目ID。 instance_id 是 String 实例ID,在API网关控制台的“实例信息”中获取。 api_id 是 String API编号 表2 Query参数 参数 是否必选 参数类型 描述 offset 否 Long 偏移量,表示从此偏移量开始查询,偏移量小于0时,自动转换为0 缺省值:0 limit 否 Integer 每页显示的条目数量,条目数量小于等于0时,自动转换为20,条目数量大于500时,自动转换为500 最小值:1 最大值:500 缺省值:20 env_id 否 String 发布的环境编号 plugin_name 否 String 插件名称 plugin_id 否 String 插件编号 env_name 否 String 环境名称 plugin_type 否 String 插件类型
  • 响应示例 状态码: 201 Created { "variable_value" : "192.168.1.5", "env_id" : "7a1ad0c350844ee69479b47df9a881cb", "group_id" : "c77f5e81d9cb4424bf704ef2b0ac7600", "id" : "25054838a624400bbf2267cf5b3a3f70", "variable_name" : "address" } 状态码: 400 Bad Request { "error_code" : "APIG.2012", "error_msg" : "Invalid parameter value,parameterName:instance_id. Please refer to the support documentation" } 状态码: 401 Unauthorized { "error_code" : "APIG.1002", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIG.1005", "error_msg" : "No permissions to request this method" } 状态码: 404 Not Found { "error_code" : "APIG.3003", "error_msg" : "The instance does not exist;id:f0fa1789-3b76-433b-a787-9892951c620ec" } 状态码: 500 Internal Server Error { "error_code" : "APIG.9999", "error_msg" : "System error" }
  • 响应参数 状态码: 201 表4 响应Body参数 参数 参数类型 描述 variable_value String 变量值支持英文字母、数字、英文格式的下划线、中划线,斜线(/)、点、冒号,1 ~ 255个字符。 env_id String 环境编号 最小长度:1 最大长度:65 group_id String API分组编号 最小长度:1 最大长度:65 variable_name String 变量名,支持英文字母、数字、英文格式的下划线、中划线,必须以英文字母开头,3~32个字符。在API定义中等于#Name的值#部分(区分大小写),发布到环境里的API被变量值换。 说明: 中文字符必须为UTF-8或者unicode编码。 id String 环境变量编号 状态码: 400 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 401 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 404 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • 功能介绍 将API发布到不同的环境后,对于不同的环境,可能会有不同的环境变量,比如,API的服务部署地址,请求的版本号等。 用户可以定义不同的环境变量,用户在定义API时,在API的定义中使用这些变量,当调用API时,API网关会将这些变量替换成真实的变量值,以达到不同环境的区分效果。 环境变量定义在API分组上,该分组下的所有API都可以使用这些变量。 环境变量的变量名称必须保持唯一,即一个分组在同一个环境上不能有两个同名的变量。 环境变量区分大小写,即变量ABC与变量abc是两个不同的变量。 设置了环境变量后,使用到该变量的API的调试功能将不可使用。 定义了环境变量后,使用到环境变量的地方应该以对称的#标识环境变量,当API发布到相应的环境后,会对环境变量的值进行替换,如:定义的API的URL为:https://#address#:8080,环境变量address在RELEASE环境上的值为:192.168.1.5,则API发布到RELEASE环境后的真实的URL为:https://192.168.1.5:8080。
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 是 String 用户Token。通过调用 IAM 服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 表3 请求Body参数 参数 是否必选 参数类型 描述 variable_value 是 String 变量值支持英文字母、数字、英文格式的下划线、中划线,斜线(/)、点、冒号,1 ~ 255个字符。 env_id 是 String 环境编号 最小长度:1 最大长度:65 group_id 是 String API分组编号 最小长度:1 最大长度:65 variable_name 是 String 变量名,支持英文字母、数字、英文格式的下划线、中划线,必须以英文字母开头,3~32个字符。在API定义中等于#Name的值#部分(区分大小写),发布到环境里的API被变量值换。 说明: 中文字符必须为UTF-8或者unicode编码。
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 restrict_cidrs Array of strings 受限的IP网段的CIDR列表。 resource_subnet_cidr String 资源租户的IP网段的CIDR。 状态码: 401 表4 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 404 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • 响应示例 状态码: 200 OK { "restrict_cidrs" : [ "127.0.0.1/32", "192.168.0.1/24" ], "resource_subnet_cidr" : "192.168.0.1/24" } 状态码: 401 Unauthorized { "error_code" : "APIC.7102", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIC.7106", "error_msg" : "No permissions to request for the method" } 状态码: 404 Not Found { "error_code" : "APIC.7302", "error_msg" : "Instance not found" } 状态码: 500 Internal Server Error { "error_code" : "APIC.9000", "error_msg" : "Failed to request internal service" }
  • 响应示例 状态码: 200 OK { "tags" : [ { "key" : "test-key", "value" : "test-vaue" } ] } 状态码: 401 Unauthorized { "error_code" : "APIG.1002", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIG.1005", "error_msg" : "No permissions to request this method" } 状态码: 500 Internal Server Error { "error_code" : "APIG.9999", "error_msg" : "System error" }
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 tags Array of TmsKeyValue objects 实例绑定的标签列表 表4 TmsKeyValue 参数 参数类型 描述 key String 键。 支持可用 UTF-8 格式表示的字母(包含中文)、数字和空格,以及以下字符: _ . : = + - @; _sys_开头属于系统标签,租户不能输入 最小长度:1 最大长度:128 value String 值。 支持可用 UTF-8 格式表示的字母(包含中文)、数字和空格,以及以下字符: _ . : / = + - @ 最小长度:0 最大长度:255 状态码: 401 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • 响应示例 状态码: 200 OK { "app_quota_id" : "c900c5612dbe451bb43cbcc49cfaf2f3", "call_limits" : 1000, "create_time" : "2020-09-19T07:27:47Z", "name" : "ClientQuota_demo", "reset_time" : "2020-09-20 00:00:00", "time_interval" : 1, "time_unit" : "DAY" } 状态码: 400 Bad Request { "error_code" : "APIG.3325", "error_msg" : "The API quota name already exists" } 状态码: 401 Unauthorized { "error_code" : "APIG.1002", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIG.1005", "error_msg" : "No permissions to request this method" } 状态码: 404 Not Found { "error_code" : "APIG.3093", "error_msg" : "App quota c900c5612dbe451bb43cbcc49cfaf2f3 does not exist" } 状态码: 500 Internal Server Error { "error_code" : "APIG.9999", "error_msg" : "System error" }
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 app_quota_id String 凭据配额编号 name String 配额名称。支持汉字,英文,数字,下划线,且只能以英文和汉字开头,3-255字符 call_limits Integer 凭据配额的访问次数限制 time_unit String 限定时间单位:SECOND:秒、MINUTE:分、HOUR:时、DAY:天 枚举值: SECOND MINUTE HOUR DAY time_interval Integer 配额的限定时间值 remark String 参数说明和描述 最大长度:255 reset_time String 首次配额重置时间点,不配置默认为首次调用时间计算 create_time String 创建时间 bound_app_num Integer 配额策略已绑定应用数量 状态码: 400 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 401 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 404 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • URI PUT /v2/{project_id}/apigw/instances/{instance_id}/app-quotas/{app_quota_id} 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 项目ID,获取方式请参见获取项目ID。 instance_id 是 String 实例ID,在API网关控制台的“实例信息”中获取。 app_quota_id 是 String 凭据配额编号
  • 响应示例 状态码: 200 OK { "total" : 2, "size" : 2, "apps" : [ { "bind_num" : 0, "creator" : "USER", "update_time" : "2020-08-03T13:09:13Z", "app_key" : "ee8f878c252747028f07eb116c2cd91b", "name" : "app_demo", "remark" : "Demo app", "id" : "356de8eb7a8742168586e5daf5339965", "app_secret" : "416************ab8", "register_time" : "2020-08-03T13:09:13Z", "status" : 1, "app_type" : "apig" }, { "bind_num" : 3, "creator" : "USER", "update_time" : "2020-05-27T10:38:03.133586Z", "app_key" : "840b8b5b1efc4ec686639759c2c584da", "name" : "app_001", "id" : "9ed8b7fe84224de681e7d7a5587e76dc", "app_secret" : "0a4************c6e", "register_time" : "2020-03-28T11:09:06Z", "status" : 1 } ] } 状态码: 400 Bad Request { "error_code" : "APIG.2011", "error_msg" : "Invalid parameter value,parameterName:name. Please refer to the support documentation" } 状态码: 401 Unauthorized { "error_code" : "APIG.1002", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIG.1005", "error_msg" : "No permissions to request this method" } 状态码: 500 Internal Server Error { "error_code" : "APIG.9999", "error_msg" : "System error" }
  • URI GET /v2/{project_id}/apigw/instances/{instance_id}/apps 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 项目ID,获取方式请参见获取项目ID。 instance_id 是 String 实例ID,在API网关控制台的“实例信息”中获取。 表2 Query参数 参数 是否必选 参数类型 描述 offset 否 Long 偏移量,表示从此偏移量开始查询,偏移量小于0时,自动转换为0 缺省值:0 limit 否 Integer 每页显示的条目数量,条目数量小于等于0时,自动转换为20,条目数量大于500时,自动转换为500 最小值:1 最大值:500 缺省值:20 id 否 String APP编号 name 否 String APP名称 status 否 Integer APP状态 app_key 否 String APP的KEY creator 否 String APP的创建者。 USER:用户自行创建 MARKET:云商店分配 precise_search 否 String 指定需要精确匹配查找的参数名称,目前仅支持name
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 size Integer 本次返回的列表长度 total Long 满足条件的记录数 apps Array of AppInfoWithBindNum objects APP列表 表5 AppInfoWithBindNum 参数 参数类型 描述 id String 编号 name String 名称 remark String 描述 creator String APP的创建者 USER:用户自行创建 MARKET:云商店分配 暂不支持MARKET 枚举值: USER MARKET update_time String 更新时间 app_key String APP的key app_secret String 密钥 register_time String 注册时间 status Integer 状态 1: 有效 枚举值: 1 app_type String APP的类型: apig:存量apig应用,不推荐使用 roma:roma集成应用 默认apig,暂不支持其他类型 枚举值: apig roma roma_app_type String ROMA_APP的类型: subscription:订阅应用 integration:集成应用 暂不支持 bind_num Integer 绑定的API数量 状态码: 400 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 401 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 plugin_id String 插件编码。 plugin_name String 插件名称。支持汉字,英文,数字,中划线,下划线,且只能以英文和汉字开头,3-255字符。 说明: 中文字符必须为UTF-8或者unicode编码。 plugin_type String 插件类型 cors:跨域资源共享 set_resp_headers:HTTP响应头管理 kafka_log:Kafka日志推送 breaker:断路器 rate_limit: 流量控制 third_auth: 第三方认证 枚举值: cors set_resp_headers kafka_log breaker rate_limit third_auth plugin_scope String 插件可见范围。global:全局可见; 枚举值: global plugin_content String 插件定义内容,支持json。参考提供的具体模型定义 CorsPluginContent:跨域资源共享 定义内容 SetRespHeadersContent:HTTP响应头管理 定义内容 KafkaLogContent:Kafka日志推送 定义内容 BreakerContent:断路器 定义内容 RateLimitContent 流量控制 定义内容 ThirdAuthContent: 第三方认证 定义内容 最大长度:65535 remark String 插件描述,255字符。 说明: 中文字符必须为UTF-8或者unicode编码。 最大长度:255 create_time String 创建时间。 update_time String 更新时间。 状态码: 400 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 401 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 404 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • 请求示例 更新跨域共享插件 { "plugin_name" : "跨域插件", "plugin_type" : "cors", "plugin_scope" : "global", "plugin_content" : "{\"allow_origin\": \"*\",\"allow_methods\": \"GET,POST,PUT\",\"allow_headers\": \"Content-Type,Accept,Accept-Ranges,Cache-Control\",\"expose_headers\": \"X-Request-Id,X-Apig-Latency\",\"max_age\": 172800,\"allow_credentials\": true}", "remark" : "CORS跨域资源访问" } 更新HTTP响应头插件 { "plugin_name" : "HTTP响应头插件", "plugin_type" : "set_resp_headers", "plugin_scope" : "global", "plugin_content" : "{\\\"response_headers\\\":[{\\\"name\\\":\\\"x-demo\\\",\\\"value\\\":\\\"sss\\\",\\\"action\\\":\\\"append\\\"}]}", "remark" : "HTTP响应头管理" } 更新流控插件 { "plugin_name" : "流控插件", "plugin_type" : "rate_limit", "plugin_scope" : "global", "plugin_content" : "{\\\"scope\\\":\\\"basic\\\",\\\"default_time_unit\\\":\\\"minute\\\",\\\"default_interval\\\":1,\\\"api_limit\\\":50,\\\"app_limit\\\":0,\\\"user_limit\\\":0,\\\"ip_limit\\\":0,\\\"algorithm\\\":\\\"counter\\\",\\\"specials\\\":[],\\\"parameters\\\":[],\\\"rules\\\":[]}", "remark" : "流量控制" } 更新kafka日志插件 { "plugin_name" : "KAFKA日志插件", "plugin_type" : "kafka_log", "plugin_scope" : "app", "plugin_content" : "{\\\"broker_list\\\":[\\\"0.0.0.0:11\\\"],\\\"topic\\\":\\\"topic\\\",\\\"key\\\":\\\"\\\",\\\"max_retry_count\\\":0,\\\"retry_backoff\\\":1,\\\"sasl_config\\\":{\\\"security_protocol\\\":\\\"PLAINTEXT\\\",\\\"sasl_mechanisms\\\":\\\"PLAIN\\\",\\\"sasl_username\\\":\\\"\\\",\\\"sasl_password\\\":\\\"\\\",\\\"ssl_ca_content\\\":\\\"\\\"},\\\"meta_config\\\":{\\\"system\\\":{\\\"start_time\\\":true,\\\"request_id\\\":true,\\\"client_ip\\\":true,\\\"api_id\\\":false,\\\"user_name\\\":false,\\\"app_id\\\":false,\\\"access_model1\\\":false,\\\"request_time\\\":true,\\\"http_status\\\":true,\\\"server_protocol\\\":false,\\\"scheme\\\":true,\\\"request_method\\\":true,\\\"host\\\":false,\\\"api_uri_mode\\\":false,\\\"uri\\\":false,\\\"request_size\\\":false,\\\"response_size\\\":false,\\\"upstream_uri\\\":false,\\\"upstream_addr\\\":true,\\\"upstream_status\\\":true,\\\"upstream_connect_time\\\":false,\\\"upstream_header_time\\\":false,\\\"upstream_response_time\\\":true,\\\"all_upstream_response_time\\\":false,\\\"region_id\\\":false,\\\"auth_type\\\":false,\\\"http_x_forwarded_for\\\":true,\\\"http_user_agent\\\":true,\\\"error_type\\\":true,\\\"access_model2\\\":false,\\\"inner_time\\\":false,\\\"proxy_protocol_vni\\\":false,\\\"proxy_protocol_vpce_id\\\":false,\\\"proxy_protocol_addr\\\":false,\\\"body_bytes_sent\\\":false,\\\"api_name\\\":false,\\\"app_name\\\":false,\\\"provider_app_id\\\":false,\\\"provider_app_name\\\":false,\\\"custom_data_log01\\\":false,\\\"custom_data_log02\\\":false,\\\"custom_data_log03\\\":false,\\\"custom_data_log04\\\":false,\\\"custom_data_log05\\\":false,\\\"custom_data_log06\\\":false,\\\"custom_data_log07\\\":false,\\\"custom_data_log08\\\":false,\\\"custom_data_log09\\\":false,\\\"custom_data_log10\\\":false,\\\"response_source\\\":false},\\\"call_data\\\":{\\\"log_request_header\\\":false,\\\"request_header_filter\\\":\\\"\\\",\\\"log_request_query_string\\\":false,\\\"request_query_string_filter\\\":\\\"\\\",\\\"log_request_body\\\":false,\\\"log_response_header\\\":false,\\\"response_header_filter\\\":\\\"\\\",\\\"log_response_body\\\":false,\\\"custom_authorizer\\\":{\\\"frontend\\\":[],\\\"backend\\\":[]}}}}", "remark" : "KAFKA日志推送" } 更新断路器插件 { "plugin_name" : "断路器插件", "plugin_type" : "breaker", "plugin_scope" : "app", "plugin_content" : "{\\\"breaker_condition\\\":{\\\"breaker_type\\\":\\\"timeout\\\",\\\"breaker_mode\\\":\\\"counter\\\",\\\"unhealthy_condition\\\":\\\"\\\",\\\"unhealthy_threshold\\\":30,\\\"min_call_threshold\\\":20,\\\"unhealthy_percentage\\\":51,\\\"time_window\\\":15,\\\"open_breaker_time\\\":15},\\\"downgrade_default\\\":null,\\\"downgrade_parameters\\\":null,\\\"downgrade_rules\\\":null,\\\"scope\\\":\\\"basic\\\"}", "remark" : "断路器" } 更新第三方认证插件 { "plugin_name" : "第三方认证插件", "remark" : "这是一个包含规则表达名单的第三方认证插件", "plugin_type" : "third_auth", "plugin_scope" : "global", "plugin_content" : "{\\\"auth_request\\\":{\\\"method\\\":\\\"POST\\\",\\\"protocol\\\":\\\"HTTP\\\",\\\"url_domain\\\":\\\"xxx.xxx.xxx.xxx:1234\\\",\\\"timeout\\\":10,\\\"path\\\":\\\"/check\\\",\\\"vpc_channel_enabled\\\":false,\\\"vpc_channel_info\\\":{\\\"vpc_proxy_host\\\":\\\"abc.com\\\",\\\"vpc_id\\\":\\\"3c113f40a54a40369ceb1eb1409a32ee\\\"}},\\\"identities\\\":{\\\"headers\\\":[{\\\"name\\\":\\\"token\\\"}],\\\"query\\\":[{\\\"name\\\":\\\"user\\\"}]},\\\"carry_body\\\":{\\\"enabled\\\":true,\\\"max_body_size\\\":10000},\\\"carry_path_enabled\\\":false,\\\"return_resp_body_enabled\\\":true,\\\"carry_resp_headers\\\":[\\\"x-message-result\\\"],\\\"simple_auth_mode_enabled\\\":false,\\\"match_auth\\\":{\\\"key\\\":\\\"x-message-result\\\",\\\"value\\\":\\\"success\\\"},\\\"rule_enabled\\\":true,\\\"rule_type\\\":\\\"deny\\\",\\\"parameters\\\":[{\\\"value\\\":\\\"reqPath\\\",\\\"type\\\":\\\"path\\\",\\\"name\\\":\\\"reqPath\\\"},{\\\"value\\\":\\\"method\\\",\\\"type\\\":\\\"method\\\",\\\"name\\\":\\\"method\\\"},{\\\"value\\\":\\\"Host\\\",\\\"type\\\":\\\"header\\\",\\\"name\\\":\\\"Host\\\"}],\\\"rules\\\":[{\\\"match_regex\\\": \\\"[\\\\\\\"OR\\\\\\\", [\\\\\\\"reqPath\\\\\\\", \\\\\\\"~~\\\\\\\", \\\\\\\"/xxl-job-admin/*\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/app/leave/infor/v1/addLeaveLnfor\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/v1/charge/home/modifyChargeSync\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/app/mweb/campaign/api/v1/getActivityConfig\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/mp/vehicle/owner/home\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/app/mweb/campaign/api/v1/getTime\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/c-showroom-service/v1/vehicleDetails/upload\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"~~\\\\\\\", \\\\\\\"/operation-charging-bff/carOwnerRights/certificate/*\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"~~\\\\\\\", \\\\\\\"/api/2c/v1/sales-bff/*\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/2c/v1/vehicleDetails/upload\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"~~\\\\\\\", \\\\\\\"/operation-admin/*\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/app/settings/api/v1/receiveClk\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/vehicle/relative/yTSendVehicleControl.json\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/appoint/getAppointmentByTestDrive\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/evd/callBackEvdPay\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/evd/callBackEvdOrder\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/evd/getUserToken\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/evd/callBackEvdCoupon\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/task/busTriggerTaskEvent.json\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/datacenter-log-center/api/trackApi/commonAdd.json\\\\\\\"]]\\\", \\\"rule_name\\\": \\\"allow2\\\"}],\\\"custom_forbid_limit\\\":100,\\\"auth_downgrade_enabled\\\":false}" }
  • 响应示例 状态码: 200 OK 示例 1 { "plugin_id" : "5b729aa252764739b3s237ef0d66dc63", "plugin_name" : "跨域插件", "plugin_type" : "cors", "plugin_scope" : "global", "plugin_content" : "{\"allow_origin\": \"*\",\"allow_methods\": \"GET,POST,PUT\",\"allow_headers\": \"Content-Type,Accept,Accept-Ranges,Cache-Control\",\"expose_headers\": \"X-Request-Id,X-Apig-Latency\",\"max_age\": 172800,\"allow_credentials\": true}", "remark" : "CORS跨域资源访问", "create_time" : "2020-11-02T12:31:23.353Z", "update_time" : "2020-11-02T12:31:23.353Z" } 示例 2 { "plugin_id" : "8a688dce7d0c45cf84edac3d7b071769", "plugin_name" : "HTTP响应头插件", "plugin_type" : "set_resp_headers", "plugin_scope" : "global", "plugin_content" : "{\\\"response_headers\\\":[{\\\"name\\\":\\\"x-demo\\\",\\\"value\\\":\\\"sss\\\",\\\"action\\\":\\\"append\\\"}]}", "remark" : "HTTP响应头管理", "create_time" : "2022-11-02T12:31:23.353Z", "update_time" : "2022-11-02T12:31:23.353Z" } 示例 3 { "plugin_id" : "9642ff2b9a86481689ca9d28babcfd7f", "plugin_name" : "流控插件", "plugin_type" : "rate_limit", "plugin_scope" : "global", "plugin_content" : "{\\\"scope\\\":\\\"basic\\\",\\\"default_time_unit\\\":\\\"minute\\\",\\\"default_interval\\\":1,\\\"api_limit\\\":50,\\\"app_limit\\\":0,\\\"user_limit\\\":0,\\\"ip_limit\\\":0,\\\"algorithm\\\":\\\"counter\\\",\\\"specials\\\":[],\\\"parameters\\\":[],\\\"rules\\\":[]}", "remark" : "流量控制", "create_time" : "2022-11-02T12:31:23.353Z", "update_time" : "2022-11-02T12:31:23.353Z" } 示例 4 { "plugin_id" : "92284ece6ec7466da2c2ac2416f46d5d", "plugin_name" : "KAFKA日志插件", "plugin_type" : "kafka_log", "plugin_scope" : "app", "plugin_content" : "{\\\"broker_list\\\":[\\\"0.0.0.0:11\\\"],\\\"topic\\\":\\\"topic\\\",\\\"key\\\":\\\"\\\",\\\"max_retry_count\\\":0,\\\"retry_backoff\\\":1,\\\"sasl_config\\\":{\\\"security_protocol\\\":\\\"PLAINTEXT\\\",\\\"sasl_mechanisms\\\":\\\"PLAIN\\\",\\\"sasl_username\\\":\\\"\\\",\\\"sasl_password\\\":\\\"\\\",\\\"ssl_ca_content\\\":\\\"\\\"},\\\"meta_config\\\":{\\\"system\\\":{\\\"start_time\\\":true,\\\"request_id\\\":true,\\\"client_ip\\\":true,\\\"api_id\\\":false,\\\"user_name\\\":false,\\\"app_id\\\":false,\\\"access_model1\\\":false,\\\"request_time\\\":true,\\\"http_status\\\":true,\\\"server_protocol\\\":false,\\\"scheme\\\":true,\\\"request_method\\\":true,\\\"host\\\":false,\\\"api_uri_mode\\\":false,\\\"uri\\\":false,\\\"request_size\\\":false,\\\"response_size\\\":false,\\\"upstream_uri\\\":false,\\\"upstream_addr\\\":true,\\\"upstream_status\\\":true,\\\"upstream_connect_time\\\":false,\\\"upstream_header_time\\\":false,\\\"upstream_response_time\\\":true,\\\"all_upstream_response_time\\\":false,\\\"region_id\\\":false,\\\"auth_type\\\":false,\\\"http_x_forwarded_for\\\":true,\\\"http_user_agent\\\":true,\\\"error_type\\\":true,\\\"access_model2\\\":false,\\\"inner_time\\\":false,\\\"proxy_protocol_vni\\\":false,\\\"proxy_protocol_vpce_id\\\":false,\\\"proxy_protocol_addr\\\":false,\\\"body_bytes_sent\\\":false,\\\"api_name\\\":false,\\\"app_name\\\":false,\\\"provider_app_id\\\":false,\\\"provider_app_name\\\":false,\\\"custom_data_log01\\\":false,\\\"custom_data_log02\\\":false,\\\"custom_data_log03\\\":false,\\\"custom_data_log04\\\":false,\\\"custom_data_log05\\\":false,\\\"custom_data_log06\\\":false,\\\"custom_data_log07\\\":false,\\\"custom_data_log08\\\":false,\\\"custom_data_log09\\\":false,\\\"custom_data_log10\\\":false,\\\"response_source\\\":false},\\\"call_data\\\":{\\\"log_request_header\\\":false,\\\"request_header_filter\\\":\\\"\\\",\\\"log_request_query_string\\\":false,\\\"request_query_string_filter\\\":\\\"\\\",\\\"log_request_body\\\":false,\\\"log_response_header\\\":false,\\\"response_header_filter\\\":\\\"\\\",\\\"log_response_body\\\":false,\\\"custom_authorizer\\\":{\\\"frontend\\\":[],\\\"backend\\\":[]}}}}", "remark" : "KAFKA日志推送", "create_time" : "2022-11-02T12:31:23.353Z", "update_time" : "2022-11-02T12:31:23.353Z" } 示例 5 { "plugin_id" : "8b5253ed723c4a878e7b8532c08763b4", "plugin_name" : "断路器插件", "plugin_type" : "breaker", "plugin_scope" : "app", "plugin_content" : "{\\\"breaker_condition\\\":{\\\"breaker_type\\\":\\\"timeout\\\",\\\"breaker_mode\\\":\\\"counter\\\",\\\"unhealthy_condition\\\":\\\"\\\",\\\"unhealthy_threshold\\\":30,\\\"min_call_threshold\\\":20,\\\"unhealthy_percentage\\\":51,\\\"time_window\\\":15,\\\"open_breaker_time\\\":15},\\\"downgrade_default\\\":null,\\\"downgrade_parameters\\\":null,\\\"downgrade_rules\\\":null,\\\"scope\\\":\\\"basic\\\"}", "remark" : "断路器", "create_time" : "2022-11-02T12:31:23.353Z", "update_time" : "2022-11-02T12:31:23.353Z" } 示例 6 { "plugin_id" : "235d97683439437585aff06020059720", "plugin_name" : "第三方认证插件", "plugin_type" : "third_auth", "plugin_scope" : "global", "plugin_content" : "{\\\"auth_request\\\":{\\\"method\\\":\\\"POST\\\",\\\"protocol\\\":\\\"HTTP\\\",\\\"url_domain\\\":\\\"xxx.xxx.xxx.xxx:1234\\\",\\\"path\\\":\\\"/check\\\",\\\"timeout\\\":10,\\\"vpc_channel_enabled\\\":false,\\\"vpc_channel_info\\\":null},\\\"identities\\\":{\\\"headers\\\":[{\\\"name\\\":\\\"token\\\"}],\\\"queries\\\":null},\\\"carry_body\\\":{\\\"enabled\\\":true,\\\"max_body_size\\\":10000},\\\"carry_path_enabled\\\":false,\\\"return_resp_body_enabled\\\":true,\\\"carry_resp_headers\\\":[\\\"x-message-result\\\"],\\\"simple_auth_mode_enabled\\\":false,\\\"match_auth\\\":{\\\"key\\\":\\\"x-message-result\\\",\\\"value\\\":\\\"success\\\"},\\\"parameters\\\":[{\\\"type\\\":\\\"path\\\",\\\"name\\\":\\\"reqPath\\\",\\\"value\\\":\\\"reqPath\\\"},{\\\"type\\\":\\\"method\\\",\\\"name\\\":\\\"method\\\",\\\"value\\\":\\\"method\\\"},{\\\"type\\\":\\\"header\\\",\\\"name\\\":\\\"Host\\\",\\\"value\\\":\\\"Host\\\"}],\\\"rules\\\":[{\\\"rule_name\\\":\\\"allow2\\\",\\\"match_regex\\\":\\\"[\\\\\\\"OR\\\\\\\", [\\\\\\\"reqPath\\\\\\\", \\\\\\\"~~\\\\\\\", \\\\\\\"/xxl-job-admin/*\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/app/leave/infor/v1/addLeaveLnfor\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/v1/charge/home/modifyChargeSync\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/app/mweb/campaign/api/v1/getActivityConfig\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/mp/vehicle/owner/home\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/app/mweb/campaign/api/v1/getTime\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/c-showroom-service/v1/vehicleDetails/upload\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"~~\\\\\\\", \\\\\\\"/operation-charging-bff/carOwnerRights/certificate/*\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"~~\\\\\\\", \\\\\\\"/api/2c/v1/sales-bff/*\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/2c/v1/vehicleDetails/upload\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"~~\\\\\\\", \\\\\\\"/operation-admin/*\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/app/settings/api/v1/receiveClk\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/vehicle/relative/yTSendVehicleControl.json\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/appoint/getAppointmentByTestDrive\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/evd/callBackEvdPay\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/evd/callBackEvdOrder\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/evd/getUserToken\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/evd/callBackEvdCoupon\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/api/task/busTriggerTaskEvent.json\\\\\\\"], [\\\\\\\"reqPath\\\\\\\", \\\\\\\"==\\\\\\\", \\\\\\\"/datacenter-log-center/api/trackApi/commonAdd.json\\\\\\\"]]\\\"}],\\\"rule_type\\\":\\\"allow\\\",\\\"rule_enabled\\\":true,\\\"custom_forbid_limit\\\":100,\\\"auth_downgrade_enable\\\":false}", "remark" : "这是一个包含规则表达式黑名单的第三方认证插件", "create_time" : "2023-05-06T06:54:59.296181801Z", "update_time" : "2023-05-06T07:07:18.369017889Z" } 状态码: 400 Bad Request { "error_code" : "APIG.3326", "error_msg" : "The plugin name already exists" } 状态码: 401 Unauthorized { "error_code" : "APIG.1002", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIG.1005", "error_msg" : "No permissions to request this method" } 状态码: 404 Not Found { "error_code" : "APIG.3068", "error_msg" : "Plugin b294018ee0554156a875b3513e02e5b9 does not exist" } 状态码: 500 Internal Server Error { "error_code" : "APIG.9999", "error_msg" : "System error" }
  • URI PUT /v2/{project_id}/apigw/instances/{instance_id}/plugins/{plugin_id} 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 项目ID,获取方式请参见获取项目ID。 instance_id 是 String 实例ID,在API网关控制台的“实例信息”中获取。 plugin_id 是 String 插件编号
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 是 String 用户Token。通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 表3 请求Body参数 参数 是否必选 参数类型 描述 plugin_name 是 String 插件名称。支持汉字,英文,数字,下划线,且只能以英文和汉字开头,3-255字符。 说明: 中文字符必须为UTF-8或者unicode编码。 plugin_type 是 String 插件类型 cors:跨域资源共享 set_resp_headers:HTTP响应头管理 kafka_log:Kafka日志推送 breaker:断路器 rate_limit: 流量控制 third_auth: 第三方认证 枚举值: cors set_resp_headers kafka_log breaker rate_limit third_auth plugin_scope 是 String 插件可见范围。global:全局可见; 枚举值: global plugin_content 是 String 插件定义内容,支持json。参考提供的具体模型定义 CorsPluginContent:跨域资源共享 定义内容 SetRespHeadersContent:HTTP响应头管理 定义内容 KafkaLogContent:Kafka日志推送 定义内容 BreakerContent:断路器 定义内容 RateLimitContent 流量控制 定义内容 ThirdAuthContent: 第三方认证 定义内容 最大长度:65535 remark 否 String 插件描述,255字符。 说明: 中文字符必须为UTF-8或者unicode编码。 最大长度:255
  • 响应示例 状态码: 401 Unauthorized { "error_code" : "APIG.1002", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIG.1005", "error_msg" : "No permissions to request this method" } 状态码: 404 Not Found { "error_code" : "APIG.3001", "error_msg" : "API group c77f5e81d9cb4424bf704ef2b0ac7600 does not exist" } 状态码: 412 PreconditionFailed { "error_code" : "APIG.3415", "error_msg" : "The API group cannot be deleted because it contains APIs,id:47eaed4659db4e99ba2e1b642d5d1323" } 状态码: 500 Internal Server Error { "error_code" : "APIG.9999", "error_msg" : "System error" }
  • 响应参数 状态码: 401 表3 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表4 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 404 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 412 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • URI DELETE /v2/{project_id}/apigw/instances/{instance_id}/api-groups/{group_id} 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 项目ID,获取方式请参见获取项目ID。 instance_id 是 String 实例ID,在API网关控制台的“实例信息”中获取。 group_id 是 String 分组的编号
  • 响应示例 状态码: 200 OK { "total" : 2, "size" : 2, "app_codes" : [ { "app_code" : "GjOD3g80AABuuFeEJpVQADBlAjBh3UzC7W+gr4VJBB5BtJ4fdVOQoSvoji3gFxUDb5pWBz9wUcw9+8/bFZ1B/4pq29wCMQC0pQWX6zTndljDEl99As1pw+WntAU9xcq+ffagoH6zDpKUvdxV6Ezj8LcCcPZN6BU=", "app_id" : "9ed8b7fe84224de681e7d7a5587e76dc", "id" : "32dc8ca22d1b4b9cb94022186880576b", "create_time" : "2020-07-24T02:37:24Z" }, { "app_code" : "fdc8d90a30174460a91ddacfa54d6f04c92e523a85cc4a1894f87cb13b6f572a", "app_id" : "9ed8b7fe84224de681e7d7a5587e76dc", "id" : "b3d34f746d0847fb95138670e10207ed", "create_time" : "2020-07-24T02:31:45Z" } ] } 状态码: 400 Bad Request { "error_code" : "APIG.2012", "error_msg" : "Invalid parameter value,parameterName:app_id. Please refer to the support documentation" } 状态码: 401 Unauthorized { "error_code" : "APIG.1002", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIG.1005", "error_msg" : "No permissions to request this method" } 状态码: 404 Not Found { "error_code" : "APIG.3004", "error_msg" : "App 9ed8b7fe84224de681e7d7a5587e76dc does not exist" } 状态码: 500 Internal Server Error { "error_code" : "APIG.9999", "error_msg" : "System error" }
  • URI GET /v2/{project_id}/apigw/instances/{instance_id}/apps/{app_id}/app-codes 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 项目ID,获取方式请参见获取项目ID。 instance_id 是 String 实例ID,在API网关控制台的“实例信息”中获取。 app_id 是 String 应用编号 表2 Query参数 参数 是否必选 参数类型 描述 offset 否 Long 偏移量,表示从此偏移量开始查询,偏移量小于0时,自动转换为0 缺省值:0 limit 否 Integer 每页显示的条目数量,条目数量小于等于0时,自动转换为20,条目数量大于500时,自动转换为500 最小值:1 最大值:500 缺省值:20
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 size Integer 本次返回的列表长度 total Long 满足条件的记录数 app_codes Array of AppCodeBaseInfo objects App Code列表 表5 AppCodeBaseInfo 参数 参数类型 描述 app_code String App Code值 支持英文、数字,+_!@#$%-/=,且只能以英文、数字和+、/开头,64-180个字符。 id String 编号 app_id String 应用编号 create_time String 创建时间 状态码: 400 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 401 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 404 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表10 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • 响应参数 状态码: 400 表3 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 401 表4 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 403 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 404 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述 状态码: 500 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误描述
  • 响应示例 状态码: 400 Bad Request { "error_code" : "APIG.2012", "error_msg" : "Invalid parameter value,parameterName:domain_id. Please refer to the support documentation" } 状态码: 401 Unauthorized { "error_code" : "APIG.1002", "error_msg" : "Incorrect token or token resolution failed" } 状态码: 403 Forbidden { "error_code" : "APIG.1005", "error_msg" : "No permissions to request this method" } 状态码: 404 Not Found { "error_code" : "APIG.3020", "error_msg" : "The URL domain does not exist" } 状态码: 500 Internal Server Error { "error_code" : "APIG.9999", "error_msg" : "System error" }
共100000条