Get Role Permissions
GET
/web/v1/workspaces/{workspaceId}/roles/{roleId}/permissions JWTRetrieves the list of permission codes assigned to a workspace role.
Required Headers
| Header | Example Value | Description |
|---|---|---|
| Content-Type | application/json | Request content type |
| Accept | application/json | Expected response type |
| X-Client-Hash | Client device fingerprint | |
| Accept-Language | en, zh, zh-Hant, ja, vi | Response language (default: en) |
| Authorization | Bearer | JWT access token |
| X-Workspace-Id | Target workspace ID |
Request Parameters
| Name | Type | Required | In | Description |
|---|---|---|---|---|
workspaceId | String | Required | path | Business ID of the workspace |
roleId | String | Required | path | Business ID of the role |
Success Response
Status: 200 OK
Returns an array of permission code strings.
With Permissions 200
{
"version": "1.3.0",
"timestamp": 1709337600000,
"success": true,
"code": "2000",
"message": "SUCCESS",
"data": [
"transfer:read",
"transfer:write"
]
}No Permissions 200
{
"version": "1.3.0",
"timestamp": 1709337600000,
"success": true,
"code": "2000",
"message": "SUCCESS",
"data": []
}Error Responses
Unauthorized 401
{
"success": false,
"code": "4010",
"message": "Invalid or expired token"
}Notes
- Returns an empty array
[]if no permissions are assigned. - OWNER roles implicitly have all permissions; the returned list may be empty even though access is unrestricted.
- Requires
workspace:role:readpermission.