AddBackendServer
1. API Description
The API is used to register a backend server with a load balancer listener.
2. Input Parameters
The following request parameter list only provides API request parameters.
listenerId
Yes
String
Listener ID.
backendName
Yes
String
Backend server name. This parameter can contain up to 64 characters. Only letters, numbers, - and periods (.) are supported.
instanceId
Yes
String
Bare metal instance ID.
clientToken
Yes
String
This parameter is used to guarantee idempotence of the request.
portList
No
Array of Integer
The port used by the backend server. Valid values: 1 to 65535.
If the listener‘s working mode is DR, the value is empty.
weight
No
Integer
The weight of the backend server. Valid values: 1 to 100.
3. Output Parameters
requestId
String
The unique request ID, which is returned for each request. RequestId is required for locating a problem.
backendId
String
Backend server ID.
4. Code Example
Register a backend server with a load balancer listener.
POST / HTTP/1.1
Host: console.harmonynetworks.net/api/v2/bmc
Content-Type: application/json
X-ZC-Action: AddBackendServer
<Common Request Params>
Request:
{
"listenerId": "xxxx",
"backendName": "xxxx",
"portList": [80],
"clientToken": "xxxx",
"weight": 100,
"instanceId": "xxxx"
}
Response:
{
"requestId": "TEEFDCA5B-76FB-4E91-A18E-DF7F5D2CE41F",
"response": {
"requestId": "TEEFDCA5B-76FB-4E91-A18E-DF7F5D2CE41F",
"backendId": "xxxx"
}
}5. Error Codes
No error codes related to the API business logic. For other error codes, see Common Error Codes.
Last updated