CognitoIdentity / Client / set_principal_tag_attribute_map

set_principal_tag_attribute_map#

CognitoIdentity.Client.set_principal_tag_attribute_map(**kwargs)#

You can use this operation to use default (username and clientID) attribute or custom attribute mappings.

See also: AWS API Documentation

Request Syntax

response = client.set_principal_tag_attribute_map(
    IdentityPoolId='string',
    IdentityProviderName='string',
    UseDefaults=True|False,
    PrincipalTags={
        'string': 'string'
    }
)
Parameters:
  • IdentityPoolId (string) –

    [REQUIRED]

    The ID of the Identity Pool you want to set attribute mappings for.

  • IdentityProviderName (string) –

    [REQUIRED]

    The provider name you want to use for attribute mappings.

  • UseDefaults (boolean) – You can use this operation to use default (username and clientID) attribute mappings.

  • PrincipalTags (dict) –

    You can use this operation to add principal tags.

    • (string) –

      • (string) –

Return type:

dict

Returns:

Response Syntax

{
    'IdentityPoolId': 'string',
    'IdentityProviderName': 'string',
    'UseDefaults': True|False,
    'PrincipalTags': {
        'string': 'string'
    }
}

Response Structure

  • (dict) –

    • IdentityPoolId (string) –

      The ID of the Identity Pool you want to set attribute mappings for.

    • IdentityProviderName (string) –

      The provider name you want to use for attribute mappings.

    • UseDefaults (boolean) –

      You can use this operation to select default (username and clientID) attribute mappings.

    • PrincipalTags (dict) –

      You can use this operation to add principal tags. The ``PrincipalTags``operation enables you to reference user attributes in your IAM permissions policy.

      • (string) –

        • (string) –

Exceptions

  • CognitoIdentity.Client.exceptions.InvalidParameterException

  • CognitoIdentity.Client.exceptions.ResourceNotFoundException

  • CognitoIdentity.Client.exceptions.NotAuthorizedException

  • CognitoIdentity.Client.exceptions.TooManyRequestsException

  • CognitoIdentity.Client.exceptions.InternalErrorException