CognitoIdentityProvider / Client / create_user_pool_replica
create_user_pool_replica¶
- CognitoIdentityProvider.Client.create_user_pool_replica(**kwargs)¶
Creates a replica of an existing user pool in a specified Amazon Web Services Region. The replica enables multi-region replication for high availability and disaster recovery. To create a replica, you must have permissions to create user pools in the target Region.
Note
Amazon Cognito evaluates Identity and Access Management (IAM) policies in requests for this API operation. For this operation, you must use IAM credentials to authorize requests, and you must grant yourself the corresponding IAM permission in a policy.
Learn more
See also: AWS API Documentation
Request Syntax
response = client.create_user_pool_replica( UserPoolId='string', RegionName='string', UserPoolTags={ 'string': 'string' } )
- Parameters:
UserPoolId (string) –
[REQUIRED]
The ID of the user pool to replicate.
RegionName (string) –
[REQUIRED]
The Amazon Web Services Region where you want to create the replica user pool.
UserPoolTags (dict) –
A map of tags to assign to the replica user pool. Each tag consists of a key and an optional value, both of which you define. You can maintain tags independently on replica user pools.
(string) –
(string) –
- Return type:
dict
- Returns:
Response Syntax
{ 'UserPoolReplica': { 'RegionName': 'string', 'Status': 'CREATING'|'ACTIVE'|'INACTIVE'|'DELETING', 'Role': 'PRIMARY'|'SECONDARY', 'UserPoolArn': 'string' } }
Response Structure
(dict) –
UserPoolReplica (dict) –
Information about the created user pool replica, including its status and role.
RegionName (string) –
The Amazon Web Services Region where the replica is located.
Status (string) –
The current status of the replica.
CREATING
The replica is being created.
INACTIVE
The replica has been created, but is not accepting requests for end-users. Administrator configuration operations are supported.
ACTIVE
The replica is available for both end-user and administrator operations.
DELETING
The replica is being deleted.
Role (string) –
The role of the user pool replica that determines which API operations are enabled.
PRIMARY
The primary replica supports all end user and administrator operations.
SECONDARY
The secondary replica supports a limited set of end user and administrator operations. Generally, only administrator operations that set configurations specific to the replica, and only end-user operations that do not create or change attributes of a user are supported.
UserPoolArn (string) –
The Amazon Resource Name (ARN) of the replica user pool.
Exceptions
CognitoIdentityProvider.Client.exceptions.InvalidParameterExceptionCognitoIdentityProvider.Client.exceptions.TooManyRequestsExceptionCognitoIdentityProvider.Client.exceptions.LimitExceededExceptionCognitoIdentityProvider.Client.exceptions.NotAuthorizedExceptionCognitoIdentityProvider.Client.exceptions.UserPoolTaggingExceptionCognitoIdentityProvider.Client.exceptions.OperationNotEnabledExceptionCognitoIdentityProvider.Client.exceptions.InternalErrorExceptionCognitoIdentityProvider.Client.exceptions.ResourceNotFoundExceptionCognitoIdentityProvider.Client.exceptions.FeatureUnavailableInTierException