API网关 APIG-x-apigateway-backend.httpVpcEndpoints

时间:2023-11-01 16:25:08

x-apigateway-backend.httpVpcEndpoints

含义:API网关定义的HTTP VPC类型API后端服务定义。

作用域x-apigateway-backend

示例

paths:  '/users/{userId}':    get:      produces:        - "application/json"      parameters:        - name: "X-Auth-Token"          description: "认证token"          type: "string"          in: "header"          required: true      responses:        default:          description: "default response"      x-apigateway-request-type: "public"      x-apigateway-backend:        type: "HTTP-VPC"        httpVpcEndpoints:          name: "vpc-test-1"          scheme: "http"          method: "GET"          path: "/users"          timeout: 30000
表1 参数说明

参数

是否必选

类型

说明

name

Array

VPC通道名称

scheme

String

后端请求协议定义,支持http、https

method

String

后端请求方法,支持GET、POST、PUT、DELETE、HEAD、OPTIONS、PATCH、ANY

path

String

后端请求路径,支持路径变量

timeout

Number

后端请求超时时间,单位毫秒,缺省值为5000,取值范围为1 ~ 60000

support.huaweicloud.com/devg-apig/apig_04_0009.html