describe_identity_usage

CognitoSync.Client.describe_identity_usage(**kwargs)

Gets usage information for an identity, including number of datasets and data usage.

This API can be called with temporary user credentials provided by Cognito Identity or with developer credentials.

See also: AWS API Documentation

Request Syntax

response = client.describe_identity_usage(
    IdentityPoolId='string',
    IdentityId='string'
)
Parameters
  • IdentityPoolId (string) -- [REQUIRED] A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito. GUID generation is unique within a region.
  • IdentityId (string) -- [REQUIRED] A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito. GUID generation is unique within a region.
Return type

dict

Returns

Response Syntax

{
    'IdentityUsage': {
        'IdentityId': 'string',
        'IdentityPoolId': 'string',
        'LastModifiedDate': datetime(2015, 1, 1),
        'DatasetCount': 123,
        'DataStorage': 123
    }
}

Response Structure

  • (dict) -- The response to a successful DescribeIdentityUsage request.
    • IdentityUsage (dict) -- Usage information for the identity.
      • IdentityId (string) -- A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito. GUID generation is unique within a region.
      • IdentityPoolId (string) -- A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito. GUID generation is unique within a region.
      • LastModifiedDate (datetime) -- Date on which the identity was last modified.
      • DatasetCount (integer) -- Number of datasets for the identity.
      • DataStorage (integer) -- Total data storage for this identity.

Exceptions

  • CognitoSync.Client.exceptions.NotAuthorizedException
  • CognitoSync.Client.exceptions.InvalidParameterException
  • CognitoSync.Client.exceptions.ResourceNotFoundException
  • CognitoSync.Client.exceptions.InternalErrorException
  • CognitoSync.Client.exceptions.TooManyRequestsException