signin:CreateOAuth2Token

Read

signin:CreateOAuth2Token is a Read access-level action in the signin service. Grants permission to exchange an authorization code, refresh token, SigV4 credentials, or JWT for OAuth 2 access token that can be used to access AWS services from developer tools and applications

Resource types

ARNs that signin:CreateOAuth2Token can be scoped to in an IAM policy.

arn:${Partition}:signin:::console/${ConsoleName} required
console
arn:${Partition}:signin:${Region}:${Account}:oauth2/public-client/localhost required
oauth2-public-client-localhost
arn:${Partition}:signin:${Region}:${Account}:oauth2/public-client/remote required
oauth2-public-client-remote
arn:${Partition}:signin:${Region}:${Account}:service-principal/${ServicePrincipalName} required
oauth2-resource-service-principal

Condition keys

Keys you can use in the Condition block of a policy that grants signin:CreateOAuth2Token.

signin:OAuthClientAuthentication String

Filters access by the client authentication method used in the OAuth token request

signin:OAuthClientId String

Filters access by the OAuth client ID used in the authorization or token request

signin:OAuthGrantType String

Filters access by the OAuth grant type used in the token request

signin:OAuthRedirectUri String

Filters access by the redirect URI specified in the OAuth authorization request

Example IAM policy

A minimal policy that allows signin:CreateOAuth2Token. Replace "Resource": "*" with a specific ARN to follow least privilege.

{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Sid": "AllowSigninCreateOAuth2Token",
      "Effect": "Allow",
      "Action": "signin:CreateOAuth2Token",
      "Resource": "*"
    }
  ]
}

Related actions in signin

View all signin actions →