2015/01/20 - Amazon Cognito Identity - 4 new 2 updated api methods
Returns metadata related to the given identity, including when the identity was created and any associated linked logins.
Request Syntax
client.describe_identity( IdentityId='string' )
string
[REQUIRED]
A unique identifier in the format REGION:GUID.
dict
Response Syntax
{ 'IdentityId': 'string', 'Logins': [ 'string', ], 'CreationDate': datetime(2015, 1, 1), 'LastModifiedDate': datetime(2015, 1, 1) }
Response Structure
(dict) -- A description of the identity.
IdentityId (string) -- A unique identifier in the format REGION:GUID.
Logins (list) -- A set of optional name-value pairs that map provider names to provider tokens.
(string) --
CreationDate (datetime) --
Date on which the identity was created.
LastModifiedDate (datetime) --
Date on which the identity was last modified.
Gets the roles for an identity pool.
Request Syntax
client.get_identity_pool_roles( IdentityPoolId='string' )
string
An identity pool ID in the format REGION:GUID.
dict
Response Syntax
{ 'IdentityPoolId': 'string', 'Roles': { 'string': 'string' } }
Response Structure
(dict) --
Returned in response to a successful GetIdentityPoolRoles operation.
IdentityPoolId (string) --
An identity pool ID in the format REGION:GUID.
Roles (dict) --
The map of roles associated with this pool. Currently only authenticated and unauthenticated roles are supported.
(string) --
(string) --
Sets the roles for an identity pool. These roles are used when making calls to GetCredentialsForIdentity action.
Request Syntax
client.set_identity_pool_roles( IdentityPoolId='string', Roles={ 'string': 'string' } )
string
[REQUIRED]
An identity pool ID in the format REGION:GUID.
dict
[REQUIRED]
The map of roles associated with this pool. Currently only authenticated and unauthenticated roles are supported.
(string) --
(string) --
None
Returns credentials for the the provided identity ID. Any provided logins will be validated against supported login providers. If the token is for cognito-identity.amazonaws.com, it will be passed through to AWS Security Token Service with the appropriate role for the token.
Request Syntax
client.get_credentials_for_identity( IdentityId='string', Logins={ 'string': 'string' } )
string
[REQUIRED]
A unique identifier in the format REGION:GUID.
dict
A set of optional name-value pairs that map provider names to provider tokens.
(string) --
(string) --
dict
Response Syntax
{ 'IdentityId': 'string', 'Credentials': { 'AccessKeyId': 'string', 'SecretKey': 'string', 'SessionToken': 'string', 'Expiration': datetime(2015, 1, 1) } }
Response Structure
(dict) --
Returned in response to a successful GetCredentialsForIdentity operation.
IdentityId (string) --
A unique identifier in the format REGION:GUID.
Credentials (dict) --
Credentials for the the provided identity ID.
AccessKeyId (string) --
The Access Key portion of the credentials.
SecretKey (string) --
The Secret Access Key portion of the credentials
SessionToken (string) --
The Session Token portion of the credentials
Expiration (datetime) --
The date at which these credentials will expire.
{'CreationDate': 'timestamp', 'LastModifiedDate': 'timestamp'}
Returns metadata related to the given identity, including when the identity was created and any associated linked logins.
Request Syntax
client.describe_identity( IdentityId='string' )
string
[REQUIRED]
A unique identifier in the format REGION:GUID.
dict
Response Syntax
{ 'IdentityId': 'string', 'Logins': [ 'string', ], 'CreationDate': datetime(2015, 1, 1), 'LastModifiedDate': datetime(2015, 1, 1) }
Response Structure
(dict) -- A description of the identity.
IdentityId (string) -- A unique identifier in the format REGION:GUID.
Logins (list) -- A set of optional name-value pairs that map provider names to provider tokens.
(string) --
CreationDate (datetime) --
Date on which the identity was created.
LastModifiedDate (datetime) --
Date on which the identity was last modified.
{'Identities': {'CreationDate': 'timestamp', 'LastModifiedDate': 'timestamp'}}
Lists the identities in a pool.
Request Syntax
client.list_identities( IdentityPoolId='string', MaxResults=123, NextToken='string' )
string
[REQUIRED] An identity pool ID in the format REGION:GUID.
integer
[REQUIRED] The maximum number of identities to return.
string
A pagination token.
dict
Response Syntax
{ 'IdentityPoolId': 'string', 'Identities': [ { 'IdentityId': 'string', 'Logins': [ 'string', ], 'CreationDate': datetime(2015, 1, 1), 'LastModifiedDate': datetime(2015, 1, 1) }, ], 'NextToken': 'string' }
Response Structure
(dict) -- The response to a ListIdentities request.
IdentityPoolId (string) -- An identity pool ID in the format REGION:GUID.
Identities (list) -- An object containing a set of identities and associated mappings.
(dict) -- A description of the identity.
IdentityId (string) -- A unique identifier in the format REGION:GUID.
Logins (list) -- A set of optional name-value pairs that map provider names to provider tokens.
(string) --
CreationDate (datetime) --
Date on which the identity was created.
LastModifiedDate (datetime) --
Date on which the identity was last modified.
NextToken (string) -- A pagination token.