Queries DataWorks workspaces of the tenant to which a user belongs by page.

Debugging

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 parameters

Parameter Type Required Example Description
Action String Yes ListProjects

The operation that you want to perform.

PageNumber Integer Yes 1

The number of the page to return.

RegionId String Yes cn-shanghai

The region ID of the DataWorks.

PageSize Integer No 10

The number of entries to return on each page. Default value: 10. Maximum value: 100.

Response parameters

Parameter Type Example Description
PageResult Struct

The query results.

PageNumber Integer 1

The current page number.

PageSize Integer 10

The number of entries to return on each page. Default value: 10. Maximum value: 100.

ProjectList Array of Project

DataWorks a list of workspace management results.

ProjectDescription String Test Space

The detailed information about the workspace.

ProjectId Long 1212

The ID of the DataWorks workspace.

ProjectIdentifier String test

The code of the workspace.

ProjectName String Test Space

The name of the workspace.

ProjectOwnerBaseId String 122222

User ID of the workspace owner.

ProjectStatus Integer 0

The status of the workspace.

ProjectStatusCode String AVAILABLE

The status code of the workspace.

TotalCount Integer 123

The total number of entries.

RequestId String 20658801***

The ID of the request.

Examples

Sample requests


     http(s)://[Endpoint]/? Action=ListProjects &PageNumber=1 &RegionId=cn-shanghai &<common request parameters> 
   

Sample success responses

XML format


     <RequestId> 20658801*** </RequestId> <PageResult> <TotalCount> 123 </TotalCount> <PageSize> 10 </PageSize> <PageNumber> 1 </PageNumber> <ProjectList> <ProjectIdentifier> test </ProjectIdentifier> <ProjectOwnerBaseId> 122222 </ProjectOwnerBaseId> <ProjectStatus> 0 </ProjectStatus> <ProjectStatusCode> AVAILABLE </ProjectStatusCode> <ProjectName> Test space </ProjectName> <ProjectId> 1212 </ProjectId> <ProjectDescription> test space </ProjectDescription> </ProjectList> </PageResult> 
   

JSON Hint


     {"RequestId":"20658801 ${*", "PageResult":{ "TotalCount":"123", "PageSize":"10", "PageNumber":"1", "ProjectList":[ { "ProjectIdentifier":"test", "ProjectOwnerBaseId":"122222", "ProjectStatus":"0", "ProjectStatusCode":"AVAILABLE", "ProjectName":"Test Space", "ProjectId":"1212", "ProjectDescription":"Test Space" } ] } } 
   

Error codes

HttpCode Error code Error message Description
400 Invalid.Tenant.ConnectionNotExists The connection does not exist. The data source does not exist.
400 Invalid.Tenant.ProjectNotExists The project does not exist. The error message returned because the specified project does not exist.
400 Invalid.Tenant.UserAlreadyInProject The user already exists in the project. The user to be added already exists in the workspace.
403 Invalid.Tenant.UserIsNotProjectOwnerOrAdmin The user is not a project administrator or owner. The user is not the project owner or project administrator.
400 Invalid.Tenant.UserNotInProject The user is not in the project. The user is not in the project.
403 Invalid.Tenant.UserNotInTenant The user is not in tenant. The user is not in the tenant.

Go to the Error CenterFor more information, see error codes.