All Products
Search
Document Center

DataWorks:ListProjectRoles

Last Updated:Dec 10, 2024

Queries the information about roles in a DataWorks workspace by page.

Operation description

This API operation is available for all DataWorks editions.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
ProjectIdlongYes

The DataWorks workspace ID. You can log on to the DataWorks console and go to the Workspace page to query the ID.

You must configure this parameter to specify the DataWorks workspace to which the API operation is applied.

21229
CodesarrayNo

The codes of roles in the DataWorks workspace.

stringNo

The code of the role in the DataWorks workspace.

Valid values:

  • role_project_admin: workspace administrator
  • role_project_dev: developer
  • role_project_dg_admin: data governance administrator
  • role_project_guest: visitor
  • role_project_security: security administrator
  • role_project_deploy: deployer
  • role_project_owner: workspace owner
  • role_project_data_analyst: data analyst
  • role_project_pe: O&M engineer
  • role_project_erd: model designer
role_project_guest
NamesarrayNo

The names of roles in the DataWorks workspace.

stringNo

The name of the role in the DataWorks workspace.

TypestringNo

The type of the role in the DataWorks workspace.

Valid values:

  • UserCustom: user-defined role
  • System: system role
System
PageNumberintegerNo

The page number.

1
PageSizeintegerNo

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

10

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

RequestIdstring

The request ID.

61649187-0BCF-5E75-8D4B-64FDBEBBB447
PagingInfoobject

The pagination information.

PageSizestring

The number of entries per page.

10
PageNumberstring

The page number.

1
TotalCountstring

The total number of entries returned.

42
ProjectRolesarray<object>

The roles in the DataWorks workspace.

ProjectRoleobject

The role in the DataWorks workspace.

ProjectIdlong

The DataWorks workspace ID.

21229
Codestring

The code of the role in the DataWorks workspace.

role_project_guest
Namestring

The name of the role in the DataWorks workspace.

Typestring

The type of the role in the DataWorks workspace.

System

Examples

Sample success responses

JSONformat

{
  "RequestId": "61649187-0BCF-5E75-8D4B-64FDBEBBB447",
  "PagingInfo": {
    "PageSize": "10",
    "PageNumber": "1",
    "TotalCount": "42",
    "ProjectRoles": [
      {
        "ProjectId": 21229,
        "Code": "role_project_guest\n",
        "Name": "",
        "Type": "System"
      }
    ]
  }
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history