ChangeAccessControlListServerGroup
API Request
URLs
POST zstack/v1/load-balancers/listener/acl/{aclUuid}/servergroup/actions
Headers
Authorization: OAuth the-session-uuid
Body
Note: In
the preceding sample, both systemTags and userTags are optional.
These two fields can be included in the body structure.
{
"changeAccessControlListServerGroup": {
"serverGroupUuids": [
"89bdb613cad93f5f881b9127986d4d1b"
],
"listenerUuid": "e58cd2cd6a633f999909c7e5ce448e07"
},
"systemTags": [],
"userTags": []
}

Curl
Sample
curl -H "Content-Type: application/json;charset=UTF-8" \
-H "Authorization: OAuth b86c9016b4f24953a9edefb53ca0678c" \
-X PUT -d '{"changeAccessControlListServerGroup":{"serverGroupUuids":["89bdb613cad93f5f881b9127986d4d1b"],"listenerUuid":"e58cd2cd6a633f999909c7e5ce448e07"}}' http://localhost:8080/zstack/v1/load-balancers/listener/acl/07f904e5fbc8312992dd85a99c8edc9b/servergroup/actions
Request Parameters
Name | Type | Location | Description | Optional Value | Starting Version |
---|---|---|---|---|---|
serverGroupUuids | List | body (contained in the changeAccessControlListServerGroup structure) | The UUID of the load balancer server group. | 4.1.0 | |
listenerUuid | String | body (contained in the changeAccessControlListServerGroup structure) | The UUID of the listener. | 4.1.0 | |
aclUuid | String | url | The UUID of the access control list. | 4.1.0 | |
systemTags | List | body | Optional. The system tags. | 4.1.0 | |
userTags | List | body | Optional. The user tags. | 4.1.0 |
API Response
When the API succeeded, an empty JSON structure {} is returned. When the API
failed, the returned JSON structure includes an error field. For
example,
{
"error": {
"code": "SYS.1001",
"description": "A message or a operation timeout",
"details": "Create VM on KVM timeout after 300s"
}
}
SDK Sample
Java
SDK
ChangeAccessControlListServerGroupAction action = new ChangeAccessControlListServerGroupAction();
action.serverGroupUuids = asList("89bdb613cad93f5f881b9127986d4d1b");
action.listenerUuid = "e58cd2cd6a633f999909c7e5ce448e07";
action.aclUuid = "07f904e5fbc8312992dd85a99c8edc9b";
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c";
ChangeAccessControlListServerGroupAction.Result res = action.call();
Python
SDK
ChangeAccessControlListServerGroupAction action = ChangeAccessControlListServerGroupAction()
action.serverGroupUuids = [89bdb613cad93f5f881b9127986d4d1b]
action.listenerUuid = "e58cd2cd6a633f999909c7e5ce448e07"
action.aclUuid = "07f904e5fbc8312992dd85a99c8edc9b"
action.sessionId = "b86c9016b4f24953a9edefb53ca0678c"
ChangeAccessControlListServerGroupAction.Result res = action.call()