2015/03/04 - Amazon Cognito Sync - 2 new 2 updated api methods
Get the status of the last BulkPublish operation for an identity pool.
Request Syntax
client.get_bulk_publish_details( IdentityPoolId='string' )
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.
dict
Response Syntax
{ 'IdentityPoolId': 'string', 'BulkPublishStartTime': datetime(2015, 1, 1), 'BulkPublishCompleteTime': datetime(2015, 1, 1), 'BulkPublishStatus': 'NOT_STARTED'|'IN_PROGRESS'|'FAILED'|'SUCCEEDED', 'FailureMessage': 'string' }
Response Structure
(dict) -- The output for the GetBulkPublishDetails operation.
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.
BulkPublishStartTime (datetime) -- The date/time at which the last bulk publish was initiated.
BulkPublishCompleteTime (datetime) -- If BulkPublishStatus is SUCCEEDED, the time the last bulk publish operation completed.
BulkPublishStatus (string) -- Status of the last bulk publish operation, valid values are:
NOT_STARTED - No bulk publish has been requested for this identity pool
IN_PROGRESS - Data is being published to the configured stream
SUCCEEDED - All data for the identity pool has been published to the configured stream
FAILED - Some portion of the data has failed to publish, check FailureMessage for the cause.
FailureMessage (string) -- If BulkPublishStatus is FAILED this field will contain the error message that caused the bulk publish to fail.
Initiates a bulk publish of all existing datasets for an Identity Pool to the configured stream. Customers are limited to one successful bulk publish per 24 hours. Bulk publish is an asynchronous request, customers can see the status of the request via the GetBulkPublishDetails operation.
Request Syntax
client.bulk_publish( IdentityPoolId='string' )
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.
dict
Response Syntax
{ 'IdentityPoolId': 'string' }
Response Structure
(dict) -- The output for the BulkPublish operation.
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.
{'CognitoStreams': {'RoleArn': 'string', 'StreamName': 'string', 'StreamingStatus': 'ENABLED | DISABLED'}}
Gets the configuration settings of an identity pool.
Request Syntax
client.get_identity_pool_configuration( IdentityPoolId='string' )
string
[REQUIRED]
A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito. This is the ID of the pool for which to return a configuration.
dict
Response Syntax
{ 'IdentityPoolId': 'string', 'PushSync': { 'ApplicationArns': [ 'string', ], 'RoleArn': 'string' }, 'CognitoStreams': { 'StreamName': 'string', 'RoleArn': 'string', 'StreamingStatus': 'ENABLED'|'DISABLED' } }
Response Structure
(dict) --
The output for the GetIdentityPoolConfiguration operation.
IdentityPoolId (string) --
A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito.
PushSync (dict) --
Options to apply to this identity pool for push synchronization.
ApplicationArns (list) --
List of SNS platform application ARNs that could be used by clients.
(string) --
RoleArn (string) --
A role configured to allow Cognito to call SNS on behalf of the developer.
CognitoStreams (dict) -- Options to apply to this identity pool for Amazon Cognito streams.
StreamName (string) -- The name of the Cognito stream to receive updates. This stream must be in the developers account and in the same region as the identity pool.
RoleArn (string) -- The ARN of the role Amazon Cognito can assume in order to publish to the stream. This role must grant access to Amazon Cognito (cognito-sync) to invoke PutRecord on your Cognito stream.
StreamingStatus (string) -- Status of the Cognito streams. Valid values are:
ENABLED - Streaming of updates to identity pool is enabled.
DISABLED Streaming of updates to identity pool is disabled. Bulk publish will also fail if StreamingStatus is DISABLED .
{'CognitoStreams': {'RoleArn': 'string', 'StreamName': 'string', 'StreamingStatus': 'ENABLED | DISABLED'}}
Sets the necessary configuration for push sync.
Request Syntax
client.set_identity_pool_configuration( IdentityPoolId='string', PushSync={ 'ApplicationArns': [ 'string', ], 'RoleArn': 'string' }, CognitoStreams={ 'StreamName': 'string', 'RoleArn': 'string', 'StreamingStatus': 'ENABLED'|'DISABLED' } )
string
[REQUIRED]
A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito. This is the ID of the pool to modify.
dict
Options to apply to this identity pool for push synchronization.
ApplicationArns (list) --
List of SNS platform application ARNs that could be used by clients.
(string) --
RoleArn (string) --
A role configured to allow Cognito to call SNS on behalf of the developer.
dict
Options to apply to this identity pool for Amazon Cognito streams.
StreamName (string) -- The name of the Cognito stream to receive updates. This stream must be in the developers account and in the same region as the identity pool.
RoleArn (string) -- The ARN of the role Amazon Cognito can assume in order to publish to the stream. This role must grant access to Amazon Cognito (cognito-sync) to invoke PutRecord on your Cognito stream.
StreamingStatus (string) -- Status of the Cognito streams. Valid values are:
ENABLED - Streaming of updates to identity pool is enabled.
DISABLED Streaming of updates to identity pool is disabled. Bulk publish will also fail if StreamingStatus is DISABLED .
dict
Response Syntax
{ 'IdentityPoolId': 'string', 'PushSync': { 'ApplicationArns': [ 'string', ], 'RoleArn': 'string' }, 'CognitoStreams': { 'StreamName': 'string', 'RoleArn': 'string', 'StreamingStatus': 'ENABLED'|'DISABLED' } }
Response Structure
(dict) --
The output for the SetIdentityPoolConfiguration operation
IdentityPoolId (string) --
A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito.
PushSync (dict) --
Options to apply to this identity pool for push synchronization.
ApplicationArns (list) --
List of SNS platform application ARNs that could be used by clients.
(string) --
RoleArn (string) --
A role configured to allow Cognito to call SNS on behalf of the developer.
CognitoStreams (dict) -- Options to apply to this identity pool for Amazon Cognito streams.
StreamName (string) -- The name of the Cognito stream to receive updates. This stream must be in the developers account and in the same region as the identity pool.
RoleArn (string) -- The ARN of the role Amazon Cognito can assume in order to publish to the stream. This role must grant access to Amazon Cognito (cognito-sync) to invoke PutRecord on your Cognito stream.
StreamingStatus (string) -- Status of the Cognito streams. Valid values are:
ENABLED - Streaming of updates to identity pool is enabled.
DISABLED Streaming of updates to identity pool is disabled. Bulk publish will also fail if StreamingStatus is DISABLED .