Create health check for dedicated gateway
Updated at:2025-10-16
Description
Set up a health check for the dedicated gateway.
Request structure
Plain Text
1POST /v{version}/etGateway/{etGatewayId}/healthCheck?clientToken={clientToken} HTTP/1.1
2Host: bcc.bj.baidubce.com
3Authorization: authorization string
4{
5 "healthCheckSourceIp": {healthCheckSourceIp},
6 "healthCheckType": {healthCheckSourceType},
7 "healthCheckPort": {healthCheckSourcePort},
8 "healthCheckInterval": {healthCheckInterval},
9 "healthThreshold": {healthThreshold},
10 "unhealthThreshold": {unhealthThreshold},
11 "autoGenerateRouteRule": {autoGenerateRouteRule}
12}
Request parameters
| Parameter name | Types | Whether required | Parameter location | Description |
|---|---|---|---|---|
| version | String | Yes | URL parameter | API version number, current value is 1. |
| etGatewayId | String | Yes | URL parameter | ID of the dedicated gateway |
| clientToken | String | No | Query | Idempotence Token, which is an ASCII string with a length not exceeding 64 bits, see details in [ClientToken Idempotence Support](VPC/API Reference/General Description.md#Idempotence). |
| healthCheckSourceIp | String | No | RequestBody | If this parameter is not provided, the system will automatically assign an IP |
| healthCheckType | String | No | RequestBody | The value of this parameter can be "ICMP", defaulted as "ICMP" |
| healthCheckPort | Integer | No | RequestBody | Health check port |
| healthCheckInterval | Integer | Yes | RequestBody | Health check interval, an integer between 1-60, in seconds |
| healthThreshold | Integer | Yes | RequestBody | Health check threshold, an integer between 2-5 |
| unhealthThreshold | Integer | Yes | RequestBody | Unhealthy check threshold, an integer between 2-5 |
| autoGenerateRouteRule | Boolean | No | RequestBody | Decide whether to automatically generate a probe route. It is enabled by default. To disable it, select "False." |
Response parameters
No special response parameters are available.
Request example
Plain Text
1POST /v1/etGateway/dcgw-4ds9x3kmds88/healthCheck?clientToken=8257tf9d-b98n-3r6n-a93m-297ng49io149 HTTP/1.1
2Host: bcc.bj.baidubce.com
3Authorization: authorization string
4{
5 "healthCheckInterval": 3,
6 "healthThreshold": 2,
7 "unhealthThreshold": 2
8}
Response example
Plain Text
1HTTP/1.1 200 OK
2x-bce-request-id: f7302165-756d-4c83-bb7a-1d4548fbba8c
3Date: Thu, 16 Mar 2017 06:29:48 GMT
4Content-Type: application/json;charset=UTF-8
5Server: BWS
