Queries the IDs of the workspaces on which a specific Alibaba Cloud account or RAM user has permissions in a specific region.
For example, an Alibaba Cloud account can assume the developer, O&M engineer, or workspace administrator role in a workspace. For more information, see Manage members and roles.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
Action | String | Yes | ListProjectIds | The operation that you want to perform. Set the value to ListProjectIds. |
UserId | String | Yes | 139699392458**** | The ID of the desired Alibaba Cloud account. You can log on to the DataWorks console and move the pointer over the profile picture in the upper-right corner to view the ID. |
Response parameters
Parameter | Type | Example | Description |
RequestId | String | 0b57ff7216278945532771749d**** | The request ID. |
ProjectIds | Array of Long | 466230 | The IDs of the DataWorks workspaces. The IDs of the workspaces on which the desired Alibaba Cloud account has permissions were returned. In this example, a single workspace ID is used. |
Examples
Sample requests
http(s)://[Endpoint]/?Action=ListProjectIds
&UserId=139699392458****
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<ListProjectIdsResponse>
<RequestId>0b57ff7216278945532771749d****</RequestId>
<ProjectIds>466230</ProjectIds>
</ListProjectIdsResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"RequestId" : "0b57ff7216278945532771749d****",
"ProjectIds" : [ 466230 ]
}
Error codes
HTTP status code | Error code | Error message | Description |
400 | Invalid.Tenant.ConnectionNotExists | The connection does not exist. | The specified data source does not exist. |
400 | Invalid.Tenant.ProjectNotExists | The project does not exist. | The specified workspace does not exist. |
400 | Invalid.Tenant.UserNotInProject | The user is not in the project. | The user is not added to the workspace. |
403 | Invalid.Tenant.UserIsNotProjectOwnerOrAdmin | The user is not a project administrator or owner. | The user is not the workspace owner or administrator. |
403 | Invalid.Tenant.UserNotInTenant | The user is not in tenant. | The user does not belong to the tenant. |
For a list of error codes, see Service error codes.