Updates a Server Load Balancer (SLB) instance for an application in a Container Service Kubernetes cluster.


OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request headers

This operation only uses the common request header. For more information, see Common request parameters.

Request syntax

PUT /pop/v5/k8s/acs/k8s_slb_binding HTTPS|HTTP

Request parameters

Parameter Type Position Required Example Description
AppId String Query Yes 5a166fbd-****-****-a286-781659d9f54c

The ID of the application.

ClusterId String Query Yes 712082c3-****-****-9217-a947b5cde6ee

The ID of the Kubernetes cluster.

Type String Query Yes Internete

The type of the SLB instance. This parameter can be set to internet for Internet-facing SLB instances and Intranet for internal-facing SLB instances.

SlbProtocol String Query No TCP

The SLB protocol. Set the value to TCP.

TargetPort String Query No 8082

The backend port, which is also the service port of the application. Valid values: 1 to 65535.

Port String Query No 80

The frontend port. Valid values: 1 to 65535.

ServicePortInfos String Query No [{"targetPort":8080,"port":82,"loadBalancerProtocol":"TCP"},{"port":81,"certId":"136246975637380916c185d6fa21914500329_-xxxxxxx","targetPort":8181,"lo adBalancerProtocol":"HTTPS"}]

This parameter is required if you want to configure multi-port mappings or use a protocol other than TCP.

You must specify the parameter value in the JSON array format. For example:


  • port: the frontend port. This parameter is required. Valid values: 1 to 65535. The value must be unique.
  • targetPort: the backend port. This parameter is required. Valid values: 1 to 65535.
  • loadBalancerProtocol: This parameter is required. Valid values: TCP and HTTPS. When HTTP is used, set the value to TCP.
  • certId: The ID of the certificate. This parameter is required when the HTTPS protocol is used. You can purchase an SLB instance in the SLB console.
  • Take note of the fact that the ServicePortInfos parameter is specified to support multi-port mappings. If you want this parameter to take effect, make sure that you specify the AppId, ClusterId, Type, and SlbId parameters.
Specification String Query No slb.s1.small

The specification of the SLB instance. If this parameter is not specified, Small I (slb.s1.small) is used.

For more information about the specifications and prices of SLB instances, see Pay-as-you-go.

Scheduler String Query No wrr

The scheduling algorithm for the SLB instance. If this parameter is not specified, the default value rr is used. SLB supports the following scheduling algorithms: round-robin and weighted round-robin. The value of rr represents round-robin scheduling, and the value of wrr represents weighted round-robin scheduling. Valid values:

  • wrr: weighted round-robin scheduling. Backend servers that have higher weights receive more requests than those that have lower weights.
  • rr: round-robin scheduling. Requests are sequentially distributed to backend servers.

Response parameters

Parameter Type Example Description
ChangeOrderId String 9a1dcdee-****-****-ad37-cbf9dc91fba9

The ID of the change process.

Code Integer 200

The returned code.

Message String success

The returned message.

RequestId String 4823-bhjf-23u4-eiufh


Sample requests

PUT /pop/v5/k8s/acs/k8s_slb_binding HTTP/1.1
Common request parameters
"AppId": "5a166fbd-****-****-a286-781659d9f54c",
"ClusterId": "712082c3-****-****-9217-a947b5cde6ee",
"Type": "Internete"

Sample success responses

XML format


JSON format

    "Message": "success",
    "RequestId": "",
    "ChangeOrderId": "9a1dcdee-****-****-ad37-cbf9dc91fba9",
    "Code": 200

Error codes

For a list of error codes, visit the API Error Center.