Queries members in a DataWorks workspace.

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

ParameterTypeRequiredExampleDescription
ActionStringYesListProjectMembers

The operation that you want to perform. Set the value to ListProjectMembers.

ProjectIdLongYes27

The ID of the DataWorks workspace.

PageNumberIntegerNo1

The number of the page to return.

PageSizeIntegerNo10

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

Response parameters

ParameterTypeExampleDescription
RequestIdString1AFAE64E-D1BE-432B-A9****

The ID of the request.

DataObject

The results that are returned.

PageNumberInteger1

The page number of the returned page.

PageSizeInteger10

The number of entries returned per page. Default value: 10. Maximum value: 100.

TotalCountInteger3

The total number of entries returned.

ProjectMemberListArray of ProjectMember

The information of members in the DataWorks workspace.

StatusString0

The status of the member. Valid values:

  • 0: NORMAL, which indicates that the member is in a normal state.
  • 1: FORBIDDEN, which indicates that the member is disabled.
  • 2: DELETED, which indicates that the member is deleted.
ProjectMemberIdString121

The ID of the member.

NickStringzhangsan

The nickname of the member.

ProjectMemberNameStringBob

The name of the member.

ProjectMemberTypeString1

The type of the member. Valid values:

  • 1: USER_ALIYUN, which indicates that the member is an Alibaba Cloud account.
  • 5: USER_UBACCOUNT, which indicates that the member is a RAM user.
  • 6: USER_STS_ROLE, which indicates that the member is a RAM role.
ProjectRoleListArray of Role

The roles that are assigned to the member.

ProjectRoleIdInteger1

The ID of the role.

ProjectRoleTypeString0

The type of the role. Valid values:

  • 0: SYSTEM, which indicates that the role is a built-in role.
  • 2: USER_CUSTOM, which indicates that the role is a custom role.
ProjectRoleNameStringVisitor

The name of the role.

DataWorks provides built-in roles and allows you to create custom roles based on your business requirements. For more information about roles, see Overview of users, roles, and permissions.

ProjectRoleCodeStringrole_project_guest

The code of the role.

DataWorks provides built-in roles and allows you to create custom roles based on your business requirements. For more information about roles, see Overview of users, roles, and permissions.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ListProjectMembers
&ProjectId=27
&PageNumber=1
&PageSize=10
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<ListProjectMembersResponse>
    <RequestId>1AFAE64E-D1BE-432B-A9****</RequestId>
    <Data>
        <PageNumber>1</PageNumber>
        <PageSize>10</PageSize>
        <TotalCount>3</TotalCount>
        <ProjectMemberList>
            <Status>0</Status>
            <ProjectMemberId>121</ProjectMemberId>
            <Nick>zhangsan</Nick>
            <ProjectMemberName>Tom</ProjectMemberName>
            <ProjectMemberType>1</ProjectMemberType>
            <ProjectRoleList>
                <ProjectRoleId>1</ProjectRoleId>
                <ProjectRoleType>0</ProjectRoleType>
                <ProjectRoleName>Visitor</ProjectRoleName>
                <ProjectRoleCode>role_project_guest</ProjectRoleCode>
            </ProjectRoleList>
        </ProjectMemberList>
    </Data>
</ListProjectMembersResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "1AFAE64E-D1BE-432B-A9****",
  "Data" : {
    "PageNumber" : 1,
    "PageSize" : 10,
    "TotalCount" : 3,
    "ProjectMemberList" : {
      "Status" : 0,
      "ProjectMemberId" : "121",
      "Nick" : "zhangsan",
      "ProjectMemberName" : "Tom",
      "ProjectMemberType" : "1",
      "ProjectRoleList" : {
        "ProjectRoleId" : 1,
        "ProjectRoleType" : "0",
        "ProjectRoleName" : "Visitor",
        "ProjectRoleCode" : "role_project_guest"
      }
    }
  }
}

Error codes

HTTP status codeError codeError messageDescription
400Invalid.Tenant.ConnectionNotExistsThe connection does not exist.The error message returned because the specified data source does not exist.
400Invalid.Tenant.ProjectNotExistsThe project does not exist.The error message returned because the specified workspace does not exist.
400Invalid.Tenant.UserNotInProjectThe user is not in the project.The error message returned because the user is not added to the workspace.
403Invalid.Tenant.UserIsNotProjectOwnerOrAdminThe user is not a project administrator or owner.The error message returned because the user is not the workspace owner or workspace administrator.
403Invalid.Tenant.UserNotInTenantThe user is not in tenant.The error message returned because the user does not belong to the tenant.

For a list of error codes, see Service error codes.