CreateEntitlement
Creates an entitlement (assignment) in account access manager. An entitlement (assignment) grants a principal (IAM Identity Center user or group) permission to assume a specified IAM role in an AWS account. This operation is idempotent.
Request Syntax
POST /entitlements HTTP/1.1
Content-type: application/json
{
"applicationArn": "string",
"entitlement": { ... }
}
URI Request Parameters
The request does not use any URI parameters.
Request Body
The request accepts the following data in JSON format.
- applicationArn
-
Specifies the ARN of the application to create the entitlement for.
Type: String
Length Constraints: Minimum length of 49. Maximum length of 2048.
Pattern:
arn:[a-z0-9-]+:account-access:[a-z0-9]+(-[a-z0-9]+)*:[0-9]{12}:application/[a-zA-Z0-9-]+Required: Yes
- entitlement
-
Specifies the entitlement configuration, including the principal and the IAM role to grant access to.
Type: Entitlement object
Note: This object is a Union. Only one member of this object can be specified or returned.
Required: Yes
Response Syntax
HTTP/1.1 200
Content-type: application/json
{
"entitlementId": "string"
}
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
- entitlementId
-
The unique identifier of the created entitlement.
Type: String
Errors
For information about the errors that are common to all actions, see Common Error Types.
- AccessDeniedException
-
You do not have sufficient access to perform this operation.
HTTP Status Code: 403
- ConflictException
-
The request conflicts with the current state of the resource.
HTTP Status Code: 409
- InternalServerException
-
An internal service error occurred. Try your request again later.
HTTP Status Code: 500
- ResourceNotFoundException
-
The specified resource does not exist. Verify that the resource identifier is correct and that the resource exists in the current Region.
HTTP Status Code: 404
- ServiceQuotaExceededException
-
The request exceeds a service quota for your account.
HTTP Status Code: 402
- ThrottlingException
-
The request was denied due to request throttling. Try your request again later.
HTTP Status Code: 429
- ValidationException
-
The input does not satisfy the constraints specified by the service. Check your request parameters and retry the request.
HTTP Status Code: 400
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: