Connect.Client.
get_federation_token
(**kwargs)¶Retrieves a token for federation.
Note
This API doesn't support root users. If you try to invoke GetFederationToken with root credentials, an error message similar to the following one appears:
Provided identity: Principal: .... User: .... cannot be used for federation with Amazon Connect
See also: AWS API Documentation
Request Syntax
response = client.get_federation_token(
InstanceId='string'
)
[REQUIRED]
The identifier of the Amazon Connect instance. You can find the instance ID in the Amazon Resource Name (ARN) of the instance.
{
'Credentials': {
'AccessToken': 'string',
'AccessTokenExpiration': datetime(2015, 1, 1),
'RefreshToken': 'string',
'RefreshTokenExpiration': datetime(2015, 1, 1)
},
'SignInUrl': 'string',
'UserArn': 'string',
'UserId': 'string'
}
Response Structure
The credentials to use for federation.
An access token generated for a federated user to access Amazon Connect.
A token generated with an expiration time for the session a user is logged in to Amazon Connect.
Renews a token generated for a user to access the Amazon Connect instance.
Renews the expiration timer for a generated token.
The URL to sign into the user's instance.
The Amazon Resource Name (ARN) of the user.
The identifier for the user.
Exceptions
Connect.Client.exceptions.InvalidRequestException
Connect.Client.exceptions.InvalidParameterException
Connect.Client.exceptions.ResourceNotFoundException
Connect.Client.exceptions.UserNotFoundException
Connect.Client.exceptions.InternalServiceException
Connect.Client.exceptions.DuplicateResourceException