Copyright | (c) 2013-2015 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
- Service
- Errors
- InvalidParameterException
- NotAuthorizedException
- InternalErrorException
- InvalidConfigurationException
- DuplicateRequestException
- LambdaThrottledException
- AlreadyStreamedException
- InvalidLambdaFunctionOutputException
- ConcurrentModificationException
- TooManyRequestsException
- ResourceConflictException
- ResourceNotFoundException
- LimitExceededException
- Waiters
- Operations
- DescribeDataset
- DescribeIdentityPoolUsage
- SetCognitoEvents
- ListIdentityPoolUsage
- GetBulkPublishDetails
- SetIdentityPoolConfiguration
- DeleteDataset
- DescribeIdentityUsage
- GetCognitoEvents
- RegisterDevice
- SubscribeToDataset
- GetIdentityPoolConfiguration
- ListRecords
- UnsubscribeFromDataset
- UpdateRecords
- ListDatasets
- BulkPublish
- Types
Amazon Cognito Sync
Amazon Cognito Sync provides an AWS service and client library that enable cross-device syncing of application-related user data. High-level client libraries are available for both iOS and Android. You can use these libraries to persist data locally so that it's available even if the device is offline. Developer credentials don't need to be stored on the mobile device to access the service. You can use Amazon Cognito to obtain a normalized user ID and credentials. User data is persisted in a dataset that can store up to 1 MB of key-value pairs, and you can have up to 20 datasets per user identity.
With Amazon Cognito Sync, the data stored for each identity is accessible only to credentials assigned to that identity. In order to use the Cognito Sync service, you need to make API calls using credentials retrieved with Amazon Cognito Identity service.
If you want to use Cognito Sync in an Android or iOS application, you will probably want to make API calls via the AWS Mobile SDK. To learn more, see the Developer Guide for Android and the Developer Guide for iOS.
See: AWS API Reference
- data CognitoSync
- _InvalidParameterException :: AsError a => Getting (First ServiceError) a ServiceError
- _NotAuthorizedException :: AsError a => Getting (First ServiceError) a ServiceError
- _InternalErrorException :: AsError a => Getting (First ServiceError) a ServiceError
- _InvalidConfigurationException :: AsError a => Getting (First ServiceError) a ServiceError
- _DuplicateRequestException :: AsError a => Getting (First ServiceError) a ServiceError
- _LambdaThrottledException :: AsError a => Getting (First ServiceError) a ServiceError
- _AlreadyStreamedException :: AsError a => Getting (First ServiceError) a ServiceError
- _InvalidLambdaFunctionOutputException :: AsError a => Getting (First ServiceError) a ServiceError
- _ConcurrentModificationException :: AsError a => Getting (First ServiceError) a ServiceError
- _TooManyRequestsException :: AsError a => Getting (First ServiceError) a ServiceError
- _ResourceConflictException :: AsError a => Getting (First ServiceError) a ServiceError
- _ResourceNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError
- _LimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError
- module Network.AWS.CognitoSync.DescribeDataset
- module Network.AWS.CognitoSync.DescribeIdentityPoolUsage
- module Network.AWS.CognitoSync.SetCognitoEvents
- module Network.AWS.CognitoSync.ListIdentityPoolUsage
- module Network.AWS.CognitoSync.GetBulkPublishDetails
- module Network.AWS.CognitoSync.SetIdentityPoolConfiguration
- module Network.AWS.CognitoSync.DeleteDataset
- module Network.AWS.CognitoSync.DescribeIdentityUsage
- module Network.AWS.CognitoSync.GetCognitoEvents
- module Network.AWS.CognitoSync.RegisterDevice
- module Network.AWS.CognitoSync.SubscribeToDataset
- module Network.AWS.CognitoSync.GetIdentityPoolConfiguration
- module Network.AWS.CognitoSync.ListRecords
- module Network.AWS.CognitoSync.UnsubscribeFromDataset
- module Network.AWS.CognitoSync.UpdateRecords
- module Network.AWS.CognitoSync.ListDatasets
- module Network.AWS.CognitoSync.BulkPublish
- data BulkPublishStatus
- data Operation
- data Platform
- = ADM
- | APNS
- | APNSSandbox
- | GCM
- data StreamingStatus
- data CognitoStreams
- cognitoStreams :: CognitoStreams
- csStreamingStatus :: Lens' CognitoStreams (Maybe StreamingStatus)
- csStreamName :: Lens' CognitoStreams (Maybe Text)
- csRoleARN :: Lens' CognitoStreams (Maybe Text)
- data Dataset
- dataset :: Dataset
- dLastModifiedDate :: Lens' Dataset (Maybe UTCTime)
- dNumRecords :: Lens' Dataset (Maybe Integer)
- dDataStorage :: Lens' Dataset (Maybe Integer)
- dDatasetName :: Lens' Dataset (Maybe Text)
- dCreationDate :: Lens' Dataset (Maybe UTCTime)
- dLastModifiedBy :: Lens' Dataset (Maybe Text)
- dIdentityId :: Lens' Dataset (Maybe Text)
- data IdentityPoolUsage
- identityPoolUsage :: IdentityPoolUsage
- ipuLastModifiedDate :: Lens' IdentityPoolUsage (Maybe UTCTime)
- ipuIdentityPoolId :: Lens' IdentityPoolUsage (Maybe Text)
- ipuDataStorage :: Lens' IdentityPoolUsage (Maybe Integer)
- ipuSyncSessionsCount :: Lens' IdentityPoolUsage (Maybe Integer)
- data IdentityUsage
- identityUsage :: IdentityUsage
- iuLastModifiedDate :: Lens' IdentityUsage (Maybe UTCTime)
- iuIdentityPoolId :: Lens' IdentityUsage (Maybe Text)
- iuDatasetCount :: Lens' IdentityUsage (Maybe Int)
- iuDataStorage :: Lens' IdentityUsage (Maybe Integer)
- iuIdentityId :: Lens' IdentityUsage (Maybe Text)
- data PushSync
- pushSync :: PushSync
- psApplicationARNs :: Lens' PushSync [Text]
- psRoleARN :: Lens' PushSync (Maybe Text)
- data Record
- record :: Record
- rSyncCount :: Lens' Record (Maybe Integer)
- rLastModifiedDate :: Lens' Record (Maybe UTCTime)
- rDeviceLastModifiedDate :: Lens' Record (Maybe UTCTime)
- rValue :: Lens' Record (Maybe Text)
- rKey :: Lens' Record (Maybe Text)
- rLastModifiedBy :: Lens' Record (Maybe Text)
- data RecordPatch
- recordPatch :: Operation -> Text -> Integer -> RecordPatch
- rpDeviceLastModifiedDate :: Lens' RecordPatch (Maybe UTCTime)
- rpValue :: Lens' RecordPatch (Maybe Text)
- rpOp :: Lens' RecordPatch Operation
- rpKey :: Lens' RecordPatch Text
- rpSyncCount :: Lens' RecordPatch Integer
Service
data CognitoSync Source
Version 2014-06-30
of the Amazon Cognito Sync SDK.
AWSService CognitoSync | |
type Sg CognitoSync = V4 |
Errors
Error matchers are designed for use with the functions provided by
Control.Exception.Lens.
This allows catching (and rethrowing) service specific errors returned
by CognitoSync
.
InvalidParameterException
_InvalidParameterException :: AsError a => Getting (First ServiceError) a ServiceError Source
Thrown when a request parameter does not comply with the associated constraints.
NotAuthorizedException
_NotAuthorizedException :: AsError a => Getting (First ServiceError) a ServiceError Source
Thrown when a user is not authorized to access the requested resource.
InternalErrorException
_InternalErrorException :: AsError a => Getting (First ServiceError) a ServiceError Source
Indicates an internal service error.
InvalidConfigurationException
_InvalidConfigurationException :: AsError a => Getting (First ServiceError) a ServiceError Source
Prism for InvalidConfigurationException' errors.
DuplicateRequestException
_DuplicateRequestException :: AsError a => Getting (First ServiceError) a ServiceError Source
An exception thrown when there is an IN_PROGRESS bulk publish operation for the given identity pool.
LambdaThrottledException
_LambdaThrottledException :: AsError a => Getting (First ServiceError) a ServiceError Source
AWS Lambda throttled your account, please contact AWS Support
AlreadyStreamedException
_AlreadyStreamedException :: AsError a => Getting (First ServiceError) a ServiceError Source
An exception thrown when a bulk publish operation is requested less than 24 hours after a previous bulk publish operation completed successfully.
InvalidLambdaFunctionOutputException
_InvalidLambdaFunctionOutputException :: AsError a => Getting (First ServiceError) a ServiceError Source
The AWS Lambda function returned invalid output or an exception.
ConcurrentModificationException
_ConcurrentModificationException :: AsError a => Getting (First ServiceError) a ServiceError Source
Thrown if there are parallel requests to modify a resource.
TooManyRequestsException
_TooManyRequestsException :: AsError a => Getting (First ServiceError) a ServiceError Source
Thrown if the request is throttled.
ResourceConflictException
_ResourceConflictException :: AsError a => Getting (First ServiceError) a ServiceError Source
Thrown if an update can't be applied because the resource was changed by another call and this would result in a conflict.
ResourceNotFoundException
_ResourceNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError Source
Thrown if the resource doesn't exist.
LimitExceededException
_LimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError Source
Thrown when the limit on the number of objects or operations has been exceeded.
Waiters
Waiters poll by repeatedly sending a request until some remote success condition
configured by the Wait
specification is fulfilled. The Wait
specification
determines how many attempts should be made, in addition to delay and retry strategies.
Operations
Some AWS operations return results that are incomplete and require subsequent
requests in order to obtain the entire result set. The process of sending
subsequent requests to continue where a previous request left off is called
pagination. For example, the ListObjects
operation of Amazon S3 returns up to
1000 objects at a time, and you must send subsequent requests with the
appropriate Marker in order to retrieve the next page of results.
Operations that have an AWSPager
instance can transparently perform subsequent
requests, correctly setting Markers and other request facets to iterate through
the entire result set of a truncated API operation. Operations which support
this have an additional note in the documentation.
Many operations have the ability to filter results on the server side. See the individual operation parameters for details.
DescribeDataset
DescribeIdentityPoolUsage
SetCognitoEvents
ListIdentityPoolUsage
GetBulkPublishDetails
SetIdentityPoolConfiguration
DeleteDataset
DescribeIdentityUsage
GetCognitoEvents
RegisterDevice
SubscribeToDataset
GetIdentityPoolConfiguration
ListRecords
UnsubscribeFromDataset
UpdateRecords
ListDatasets
BulkPublish
Types
BulkPublishStatus
data BulkPublishStatus Source
Operation
Platform
StreamingStatus
data StreamingStatus Source
CognitoStreams
data CognitoStreams Source
Configuration options for configure Cognito streams.
See: cognitoStreams
smart constructor.
cognitoStreams :: CognitoStreams Source
Creates a value of CognitoStreams
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
csStreamingStatus :: Lens' CognitoStreams (Maybe StreamingStatus) Source
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.
csStreamName :: Lens' CognitoStreams (Maybe Text) Source
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.
csRoleARN :: Lens' CognitoStreams (Maybe Text) Source
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.
Dataset
A collection of data for an identity pool. An identity pool can have multiple datasets. A dataset is per identity and can be general or associated with a particular entity in an application (like a saved game). Datasets are automatically created if they don't exist. Data is synced by dataset, and a dataset can hold up to 1MB of key-value pairs.
See: dataset
smart constructor.
Creates a value of Dataset
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
dDataStorage :: Lens' Dataset (Maybe Integer) Source
Total size in bytes of the records in this dataset.
dDatasetName :: Lens' Dataset (Maybe Text) Source
A string of up to 128 characters. Allowed characters are a-z, A-Z, 0-9, '_' (underscore), '-' (dash), and '.' (dot).
dLastModifiedBy :: Lens' Dataset (Maybe Text) Source
The device that made the last change to this dataset.
dIdentityId :: Lens' Dataset (Maybe Text) Source
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.
IdentityPoolUsage
data IdentityPoolUsage Source
Usage information for the identity pool.
See: identityPoolUsage
smart constructor.
identityPoolUsage :: IdentityPoolUsage Source
Creates a value of IdentityPoolUsage
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
ipuLastModifiedDate :: Lens' IdentityPoolUsage (Maybe UTCTime) Source
Date on which the identity pool was last modified.
ipuIdentityPoolId :: Lens' IdentityPoolUsage (Maybe Text) Source
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.
ipuDataStorage :: Lens' IdentityPoolUsage (Maybe Integer) Source
Data storage information for the identity pool.
ipuSyncSessionsCount :: Lens' IdentityPoolUsage (Maybe Integer) Source
Number of sync sessions for the identity pool.
IdentityUsage
data IdentityUsage Source
Usage information for the identity.
See: identityUsage
smart constructor.
identityUsage :: IdentityUsage Source
Creates a value of IdentityUsage
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
iuLastModifiedDate :: Lens' IdentityUsage (Maybe UTCTime) Source
Date on which the identity was last modified.
iuIdentityPoolId :: Lens' IdentityUsage (Maybe Text) Source
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.
iuDatasetCount :: Lens' IdentityUsage (Maybe Int) Source
Number of datasets for the identity.
iuDataStorage :: Lens' IdentityUsage (Maybe Integer) Source
Total data storage for this identity.
iuIdentityId :: Lens' IdentityUsage (Maybe Text) Source
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.
PushSync
Configuration options to be applied to the identity pool.
See: pushSync
smart constructor.
Creates a value of PushSync
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
psApplicationARNs :: Lens' PushSync [Text] Source
List of SNS platform application ARNs that could be used by clients.
psRoleARN :: Lens' PushSync (Maybe Text) Source
A role configured to allow Cognito to call SNS on behalf of the developer.
Record
The basic data structure of a dataset.
See: record
smart constructor.
Creates a value of Record
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
rLastModifiedDate :: Lens' Record (Maybe UTCTime) Source
The date on which the record was last modified.
rDeviceLastModifiedDate :: Lens' Record (Maybe UTCTime) Source
The last modified date of the client device.
rLastModifiedBy :: Lens' Record (Maybe Text) Source
The user/device that made the last change to this record.
RecordPatch
data RecordPatch Source
An update operation for a record.
See: recordPatch
smart constructor.
Creates a value of RecordPatch
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
rpDeviceLastModifiedDate :: Lens' RecordPatch (Maybe UTCTime) Source
The last modified date of the client device.
rpOp :: Lens' RecordPatch Operation Source
An operation, either replace or remove.
rpKey :: Lens' RecordPatch Text Source
The key associated with the record patch.
rpSyncCount :: Lens' RecordPatch Integer Source
Last known server sync count for this record. Set to 0 if unknown.