Skip to content

Get Role Credentials

sso_get_role_credentials R Documentation

Returns the STS short-term credentials for a given role name that is assigned to the user

Description

Returns the STS short-term credentials for a given role name that is assigned to the user.

Usage

sso_get_role_credentials(roleName, accountId, accessToken)

Arguments

roleName

[required] The friendly name of the role that is assigned to the user.

accountId

[required] The identifier for the AWS account that is assigned to the user.

accessToken

[required] The token issued by the CreateToken API call. For more information, see CreateToken in the IAM Identity Center OIDC API Reference Guide.

Value

A list with the following syntax:

list(
  roleCredentials = list(
    accessKeyId = "string",
    secretAccessKey = "string",
    sessionToken = "string",
    expiration = 123
  )
)

Request syntax

svc$get_role_credentials(
  roleName = "string",
  accountId = "string",
  accessToken = "string"
)