- Development Integration
- /
- SDK
- /
- Python
- /
Management Module
- /
Resource and Permission Management
- /
- Get Authorized Principals for Resource
¶ Get the authorized subject of the resource
Update time: 2025-07-23 07:34:21
This document is automatically generated based on https://github.com/authing/authing-docs-factory based on https://api-explorer.genauth.ai V3 API, and is consistent with API parameters and return results. If the description of this document is incorrect, please refer to V3 API.
Get the authorized subject of the resource
¶ Method name
ManagementClient.get_resource_authorized_targets
¶ Request parameters
| Name | Type | Is it required | Default value | Description | Sample value |
|---|---|---|---|---|---|
| resource | string | yes | - | Resource | ecs:1 |
| namespace | string | no | default | Permission group | |
| targetType | string | no | - | Target object type: - USER: User- ROLE: Role- GROUP: Group- DEPARTMENT: Department | USER |
| page | number | No | 1 | Current page number, starting from 1 | 1 |
| limit | number | No | 10 | Number per page, maximum cannot exceed 50, default is 10 | 10 |
¶ Request Response
Type: GetResourceAuthorizedTargetRespDto
| Name | Type | Description |
|---|---|---|
| statusCode | number | Business status code, which can be used to determine whether the operation is successful, 200 means success. |
| message | string | Description |
| apiCode | number | Segmented error code, which can be used to get the specific error type (successful request is not returned). For a detailed list of error codes, please see: API Code List (opens new window) |
| requestId | string | Request ID. Returned when the request fails. |
| data | GetResourceAuthorizedTargetDataDto | Response data |
Example results:
{
"statusCode": 200,
"message": "Success",
"requestId": "934108e5-9fbf-4d24-8da1-c330328abd6c",
"data": {
"totalCount": 10,
"list": {
"targetType": "USER",
"targetIdentifier": "code",
"actions": "[\"ecs:Start\",\"ecs:Stop\"]"
}
}
}
¶ Data Structure
¶ GetResourceAuthorizedTargetDataDto
| Name | Type | Required | Description | Sample value |
|---|---|---|---|---|
| totalCount | number | yes | total | 10 |
| list | array | yes | list of elements Nested type: ResourceAuthorizedTargetDto. |
¶ ResourceAuthorizedTargetDto
| Name | Type | Required | Description | Sample value |
|---|---|---|---|---|
| targetType | string | Yes | Subject type | USER |
| targetIdentifier | string | Yes | Subject unique identifier | code |
| actions | array | Yes | Action list | ["ecs:Start","ecs:Stop"] |
