ApplyResourceAccessPermission
Commits an access permissions request for specific resources.
Operation description
Operation description
Reason: The reason for the request. This parameter is required.
ApplyContents: Contains multiple resource permission request entries. Each entry includes a resource description (Resource), a grantee description (Grantee), access types (AccessTypes), and a permission expiration time (ExpirationTime). A maximum of 400 entries can be submitted in a single request.
Resource: The resource description. You must specify the ResourceSchema.name and version on which the resource parsing depends, as well as the resource metadata (MetaData).
Grantee: The grantee description. You must specify the principal type (PrincipalType) and principal ID (PrincipalId).
AccessTypes: The list of access types. Multiple access type combinations are supported.
ExpirationTime: The permission expiration time, provided as a millisecond-level timestamp.
AuthMethod: Optional. Specifies the authorization method. The system uses the built-in default authorization method if this parameter is not specified.
ClientToken: The client token used to prevent duplicate requests. This parameter is optional.
Make sure that all required fields are correctly specified and meet the corresponding constraints. For example, the DefVersion and MetaData in Resource must match the selected DefSchema.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
dataworks:ApplyResourceAccessPermission |
create |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| Reason |
string |
Yes |
The reason for the request. |
Business development needs |
| ApplyContents |
array<object> |
Yes |
The list of resource permission request entries. |
|
|
array<object> |
No |
|||
| Resource |
object |
No |
The resource description. |
|
| DefSchema |
string |
Yes |
The resource type. Note: The resource types that can be requested are constrained by ResourceSchema.name. See also: ResourceSchema documentation (Chinese) Valid values:
|
MaxCompute |
| DefVersion |
string |
No |
The resource parsing version, constrained by ResourceSchema.version. |
v1.0.0 |
| MetaData |
object |
No |
The resource metadata declaration. Note: The metadata is constrained by ResourceSchema.resources. A valid resource declaration must include the full-path metadata declaration from level 0 to the validLeaf level. See also: ResourceSchema documentation (Chinese) |
|
|
any |
No |
Declares specific resources in Map<String,Object> format. The declaration must comply with the resource constraints for the specific resource type defined in ResourceSchema. Note:
|
{ "workspace": "449656", "project": "sync_destination", "table": "order_table", "threeTierModel": false } |
|
| Grantee |
object |
Yes |
The grantee description. Note: The supported principal types are constrained by ResourceSchema.authPrincipal. See also: ResourceSchema documentation (Chinese) |
|
| PrincipalType |
string |
Yes |
The principal type. Valid values:
Valid values:
|
RamRole |
| PrincipalId |
string |
Yes |
The principal ID. The ID has different meanings depending on the principal type:
|
ROLE_32237475848545 |
| AccessTypes |
array |
Yes |
The list of requested access types. Note: Different resource levels support different access types. All access types are constrained by ResourceSchema.isValidLeaf, accessTypeRestrictions, and authMethodAccessTypes. See also: ResourceSchema documentation (Chinese) |
|
|
string |
No |
The resource access type. |
select |
|
| ExpirationTime |
integer |
No |
The permission expiration time, in millisecond-level timestamp format. |
1785835708000 |
| AuthMethod |
string |
No |
The authorization method. Currently, only SEVERLESS_STARROCKS supports specifying an authorization method: ranger or starrocksManager. Note: Different resources support different authorization methods. All authorization methods are constrained by ResourceSchema.authMethods. See also: ResourceSchema documentation (Chinese) Valid values:
|
ranger |
| ClientToken |
string |
No |
The idempotency token. Used to prevent duplicate operations caused by multiple calls. |
ABFUOEUOTRTRJKE |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response parameters. |
||
| RequestId |
string |
The request ID. Used for log identification and troubleshooting. |
0bc5df3a17***903790e8e8a |
| Data |
array |
The list of request order IDs. |
|
|
string |
The request order or approval process ID. |
332066440109224007 |
Examples
Success response
JSON format
{
"RequestId": "0bc5df3a17***903790e8e8a",
"Data": [
"332066440109224007"
]
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.