Assigns users to multiple WUYING Workspaces in a batch.
Operation description
The WUYING Workspaces must be in the Running state.
This operation returns a result immediately. To check if the assignment is successful, call DescribeDesktops. Check the
ManagementFlagsparameter in the response. A value ofASSIGNINGindicates that the assignment is in progress. Other values indicate that the assignment is complete.You can check the assignment status every 2 to 5 seconds for up to 50 seconds. The assignment is typically completed within 1 to 5 seconds.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
ecd:BatchModifyEntitlement |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
Yes |
The ID of the region. To obtain a list of regions that support WUYING Workspace, call DescribeRegions. |
cn-hangzhou |
| MaxUserPerDesktop |
integer |
No |
The number of users to assign to each cloud computer. |
1 |
| MaxDesktopPerUser |
integer |
No |
The number of WUYING Workspaces to assign to each user. |
0 |
| Strategy |
string |
No |
The policy for handling allocation when the number of workspaces and users cannot be proportionally matched. AVERAGE: The system prioritizes assigning at least one workspace to each user. CENTRAL: The system prioritizes assigning the specified number of workspaces to each user. Valid values:
|
AVERAGE |
| DesktopId |
array |
Yes |
The IDs of the WUYING Workspaces for which to modify user assignments. |
|
|
string |
No |
The ID of the WUYING Workspace for which to modify user assignments. |
ecd-gx2x1dhsmucyy**** |
|
| EndUserId |
array |
No |
The list of user IDs. A user ID is the same as a username. |
|
|
string |
No |
The user ID. A user ID is the same as a username. |
Alice |
|
| Preview |
boolean |
Yes |
Specifies whether to preview the assignment. If this parameter is set to `true`, the system does not perform the assignment. |
true |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The request ID. |
51592A88-0F2C-55E6-AD2C-2AD9C10D**** |
| Entitlements |
object |
The list of entitlements. |
|
| Status |
string |
The overall assignment result. Valid values:
|
FINISHED |
| TaskId |
string |
The task ID. |
B2F4F018-0EDF-159C-B285-117B5F1C**** |
| AssignModels |
array<object> |
The assignment results. |
|
|
object |
|||
| DesktopId |
string |
The ID of the cloud desktop. |
ecd-e94kzikmpljjx99pl |
| InnerStatus |
string |
The assignment result for a single WUYING Workspace. Valid values:
|
FINISHED |
| EndUserIds |
array |
The list of user IDs authorized for the WUYING Workspace. A user ID is the same as a username. |
|
|
string |
The user ID authorized for the WUYING Workspace. A user ID is the same as a username. |
Alice |
Examples
Success response
JSON format
{
"RequestId": "51592A88-0F2C-55E6-AD2C-2AD9C10D****",
"Entitlements": {
"Status": "FINISHED",
"TaskId": "B2F4F018-0EDF-159C-B285-117B5F1C****",
"AssignModels": [
{
"DesktopId": "ecd-e94kzikmpljjx99pl",
"InnerStatus": "FINISHED",
"EndUserIds": [
"Alice"
]
}
]
}
}
Error codes
See for a complete list.
Release notes
See Release Notes for a complete list.