aws-sdk-cognitosync 1.0.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing for info on making contributions:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
@@ -0,0 +1,23 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing for info on making contributions:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module CognitoSync
10
+ module Errors
11
+
12
+ extend Aws::Errors::DynamicErrors
13
+
14
+ # Raised when calling #load or #data on a resource class that can not be
15
+ # loaded. This can happen when:
16
+ #
17
+ # * A resource class has identifiers, but no data attributes.
18
+ # * Resource data is only available when making an API call that
19
+ # enumerates all resources of that type.
20
+ class ResourceNotLoadable < RuntimeError; end
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,25 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing for info on making contributions:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module CognitoSync
10
+ class Resource
11
+
12
+ # @param options ({})
13
+ # @option options [Client] :client
14
+ def initialize(options = {})
15
+ @client = options[:client] || Client.new(options)
16
+ end
17
+
18
+ # @return [Client]
19
+ def client
20
+ @client
21
+ end
22
+
23
+ end
24
+ end
25
+ end
@@ -0,0 +1,1036 @@
1
+ # WARNING ABOUT GENERATED CODE
2
+ #
3
+ # This file is generated. See the contributing for info on making contributions:
4
+ # https://github.com/aws/aws-sdk-ruby/blob/master/CONTRIBUTING.md
5
+ #
6
+ # WARNING ABOUT GENERATED CODE
7
+
8
+ module Aws
9
+ module CognitoSync
10
+ module Types
11
+
12
+ # The input for the BulkPublish operation.
13
+ # @note When making an API call, pass BulkPublishRequest
14
+ # data as a hash:
15
+ #
16
+ # {
17
+ # identity_pool_id: "IdentityPoolId", # required
18
+ # }
19
+ # @!attribute [rw] identity_pool_id
20
+ # A name-spaced GUID (for example,
21
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
22
+ # Cognito. GUID generation is unique within a region.
23
+ # @return [String]
24
+ class BulkPublishRequest < Struct.new(
25
+ :identity_pool_id)
26
+ include Aws::Structure
27
+ end
28
+
29
+ # The output for the BulkPublish operation.
30
+ # @!attribute [rw] identity_pool_id
31
+ # A name-spaced GUID (for example,
32
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
33
+ # Cognito. GUID generation is unique within a region.
34
+ # @return [String]
35
+ class BulkPublishResponse < Struct.new(
36
+ :identity_pool_id)
37
+ include Aws::Structure
38
+ end
39
+
40
+ # Configuration options for configure Cognito streams.
41
+ # @note When making an API call, pass CognitoStreams
42
+ # data as a hash:
43
+ #
44
+ # {
45
+ # stream_name: "StreamName",
46
+ # role_arn: "AssumeRoleArn",
47
+ # streaming_status: "ENABLED", # accepts ENABLED, DISABLED
48
+ # }
49
+ # @!attribute [rw] stream_name
50
+ # The name of the Cognito stream to receive updates. This stream must
51
+ # be in the developers account and in the same region as the identity
52
+ # pool.
53
+ # @return [String]
54
+ #
55
+ # @!attribute [rw] role_arn
56
+ # The ARN of the role Amazon Cognito can assume in order to publish to
57
+ # the stream. This role must grant access to Amazon Cognito
58
+ # (cognito-sync) to invoke PutRecord on your Cognito stream.
59
+ # @return [String]
60
+ #
61
+ # @!attribute [rw] streaming_status
62
+ # Status of the Cognito streams. Valid values are: ENABLED - Streaming of updates to identity pool is enabled.
63
+ #
64
+ # DISABLED - Streaming of updates to identity pool is disabled. Bulk
65
+ # publish will also fail if StreamingStatus is DISABLED.
66
+ # @return [String]
67
+ class CognitoStreams < Struct.new(
68
+ :stream_name,
69
+ :role_arn,
70
+ :streaming_status)
71
+ include Aws::Structure
72
+ end
73
+
74
+ # A collection of data for an identity pool. An identity pool can have
75
+ # multiple datasets. A dataset is per identity and can be general or
76
+ # associated with a particular entity in an application (like a saved
77
+ # game). Datasets are automatically created if they don't exist. Data
78
+ # is synced by dataset, and a dataset can hold up to 1MB of key-value
79
+ # pairs.
80
+ # @!attribute [rw] identity_id
81
+ # A name-spaced GUID (for example,
82
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
83
+ # Cognito. GUID generation is unique within a region.
84
+ # @return [String]
85
+ #
86
+ # @!attribute [rw] dataset_name
87
+ # A string of up to 128 characters. Allowed characters are a-z, A-Z,
88
+ # 0-9, '\_' (underscore), '-' (dash), and '.' (dot).
89
+ # @return [String]
90
+ #
91
+ # @!attribute [rw] creation_date
92
+ # Date on which the dataset was created.
93
+ # @return [Time]
94
+ #
95
+ # @!attribute [rw] last_modified_date
96
+ # Date when the dataset was last modified.
97
+ # @return [Time]
98
+ #
99
+ # @!attribute [rw] last_modified_by
100
+ # The device that made the last change to this dataset.
101
+ # @return [String]
102
+ #
103
+ # @!attribute [rw] data_storage
104
+ # Total size in bytes of the records in this dataset.
105
+ # @return [Integer]
106
+ #
107
+ # @!attribute [rw] num_records
108
+ # Number of records in this dataset.
109
+ # @return [Integer]
110
+ class Dataset < Struct.new(
111
+ :identity_id,
112
+ :dataset_name,
113
+ :creation_date,
114
+ :last_modified_date,
115
+ :last_modified_by,
116
+ :data_storage,
117
+ :num_records)
118
+ include Aws::Structure
119
+ end
120
+
121
+ # A request to delete the specific dataset.
122
+ # @note When making an API call, pass DeleteDatasetRequest
123
+ # data as a hash:
124
+ #
125
+ # {
126
+ # identity_pool_id: "IdentityPoolId", # required
127
+ # identity_id: "IdentityId", # required
128
+ # dataset_name: "DatasetName", # required
129
+ # }
130
+ # @!attribute [rw] identity_pool_id
131
+ # A name-spaced GUID (for example,
132
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
133
+ # Cognito. GUID generation is unique within a region.
134
+ # @return [String]
135
+ #
136
+ # @!attribute [rw] identity_id
137
+ # A name-spaced GUID (for example,
138
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
139
+ # Cognito. GUID generation is unique within a region.
140
+ # @return [String]
141
+ #
142
+ # @!attribute [rw] dataset_name
143
+ # A string of up to 128 characters. Allowed characters are a-z, A-Z,
144
+ # 0-9, '\_' (underscore), '-' (dash), and '.' (dot).
145
+ # @return [String]
146
+ class DeleteDatasetRequest < Struct.new(
147
+ :identity_pool_id,
148
+ :identity_id,
149
+ :dataset_name)
150
+ include Aws::Structure
151
+ end
152
+
153
+ # Response to a successful DeleteDataset request.
154
+ # @!attribute [rw] dataset
155
+ # A collection of data for an identity pool. An identity pool can have
156
+ # multiple datasets. A dataset is per identity and can be general or
157
+ # associated with a particular entity in an application (like a saved
158
+ # game). Datasets are automatically created if they don't exist. Data
159
+ # is synced by dataset, and a dataset can hold up to 1MB of key-value
160
+ # pairs.
161
+ # @return [Types::Dataset]
162
+ class DeleteDatasetResponse < Struct.new(
163
+ :dataset)
164
+ include Aws::Structure
165
+ end
166
+
167
+ # A request for meta data about a dataset (creation date, number of
168
+ # records, size) by owner and dataset name.
169
+ # @note When making an API call, pass DescribeDatasetRequest
170
+ # data as a hash:
171
+ #
172
+ # {
173
+ # identity_pool_id: "IdentityPoolId", # required
174
+ # identity_id: "IdentityId", # required
175
+ # dataset_name: "DatasetName", # required
176
+ # }
177
+ # @!attribute [rw] identity_pool_id
178
+ # A name-spaced GUID (for example,
179
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
180
+ # Cognito. GUID generation is unique within a region.
181
+ # @return [String]
182
+ #
183
+ # @!attribute [rw] identity_id
184
+ # A name-spaced GUID (for example,
185
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
186
+ # Cognito. GUID generation is unique within a region.
187
+ # @return [String]
188
+ #
189
+ # @!attribute [rw] dataset_name
190
+ # A string of up to 128 characters. Allowed characters are a-z, A-Z,
191
+ # 0-9, '\_' (underscore), '-' (dash), and '.' (dot).
192
+ # @return [String]
193
+ class DescribeDatasetRequest < Struct.new(
194
+ :identity_pool_id,
195
+ :identity_id,
196
+ :dataset_name)
197
+ include Aws::Structure
198
+ end
199
+
200
+ # Response to a successful DescribeDataset request.
201
+ # @!attribute [rw] dataset
202
+ # Meta data for a collection of data for an identity. An identity can
203
+ # have multiple datasets. A dataset can be general or associated with
204
+ # a particular entity in an application (like a saved game). Datasets
205
+ # are automatically created if they don't exist. Data is synced by
206
+ # dataset, and a dataset can hold up to 1MB of key-value pairs.
207
+ # @return [Types::Dataset]
208
+ class DescribeDatasetResponse < Struct.new(
209
+ :dataset)
210
+ include Aws::Structure
211
+ end
212
+
213
+ # A request for usage information about the identity pool.
214
+ # @note When making an API call, pass DescribeIdentityPoolUsageRequest
215
+ # data as a hash:
216
+ #
217
+ # {
218
+ # identity_pool_id: "IdentityPoolId", # required
219
+ # }
220
+ # @!attribute [rw] identity_pool_id
221
+ # A name-spaced GUID (for example,
222
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
223
+ # Cognito. GUID generation is unique within a region.
224
+ # @return [String]
225
+ class DescribeIdentityPoolUsageRequest < Struct.new(
226
+ :identity_pool_id)
227
+ include Aws::Structure
228
+ end
229
+
230
+ # Response to a successful DescribeIdentityPoolUsage request.
231
+ # @!attribute [rw] identity_pool_usage
232
+ # Information about the usage of the identity pool.
233
+ # @return [Types::IdentityPoolUsage]
234
+ class DescribeIdentityPoolUsageResponse < Struct.new(
235
+ :identity_pool_usage)
236
+ include Aws::Structure
237
+ end
238
+
239
+ # A request for information about the usage of an identity pool.
240
+ # @note When making an API call, pass DescribeIdentityUsageRequest
241
+ # data as a hash:
242
+ #
243
+ # {
244
+ # identity_pool_id: "IdentityPoolId", # required
245
+ # identity_id: "IdentityId", # required
246
+ # }
247
+ # @!attribute [rw] identity_pool_id
248
+ # A name-spaced GUID (for example,
249
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
250
+ # Cognito. GUID generation is unique within a region.
251
+ # @return [String]
252
+ #
253
+ # @!attribute [rw] identity_id
254
+ # A name-spaced GUID (for example,
255
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
256
+ # Cognito. GUID generation is unique within a region.
257
+ # @return [String]
258
+ class DescribeIdentityUsageRequest < Struct.new(
259
+ :identity_pool_id,
260
+ :identity_id)
261
+ include Aws::Structure
262
+ end
263
+
264
+ # The response to a successful DescribeIdentityUsage request.
265
+ # @!attribute [rw] identity_usage
266
+ # Usage information for the identity.
267
+ # @return [Types::IdentityUsage]
268
+ class DescribeIdentityUsageResponse < Struct.new(
269
+ :identity_usage)
270
+ include Aws::Structure
271
+ end
272
+
273
+ # The input for the GetBulkPublishDetails operation.
274
+ # @note When making an API call, pass GetBulkPublishDetailsRequest
275
+ # data as a hash:
276
+ #
277
+ # {
278
+ # identity_pool_id: "IdentityPoolId", # required
279
+ # }
280
+ # @!attribute [rw] identity_pool_id
281
+ # A name-spaced GUID (for example,
282
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
283
+ # Cognito. GUID generation is unique within a region.
284
+ # @return [String]
285
+ class GetBulkPublishDetailsRequest < Struct.new(
286
+ :identity_pool_id)
287
+ include Aws::Structure
288
+ end
289
+
290
+ # The output for the GetBulkPublishDetails operation.
291
+ # @!attribute [rw] identity_pool_id
292
+ # A name-spaced GUID (for example,
293
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
294
+ # Cognito. GUID generation is unique within a region.
295
+ # @return [String]
296
+ #
297
+ # @!attribute [rw] bulk_publish_start_time
298
+ # The date/time at which the last bulk publish was initiated.
299
+ # @return [Time]
300
+ #
301
+ # @!attribute [rw] bulk_publish_complete_time
302
+ # If BulkPublishStatus is SUCCEEDED, the time the last bulk publish
303
+ # operation completed.
304
+ # @return [Time]
305
+ #
306
+ # @!attribute [rw] bulk_publish_status
307
+ # Status of the last bulk publish operation, valid values are: NOT\_STARTED - No bulk publish has been requested for this identity
308
+ # pool
309
+ #
310
+ # IN\_PROGRESS - Data is being published to the configured stream
311
+ #
312
+ # SUCCEEDED - All data for the identity pool has been published to the
313
+ # configured stream
314
+ #
315
+ # FAILED - Some portion of the data has failed to publish, check
316
+ # FailureMessage for the cause.
317
+ # @return [String]
318
+ #
319
+ # @!attribute [rw] failure_message
320
+ # If BulkPublishStatus is FAILED this field will contain the error
321
+ # message that caused the bulk publish to fail.
322
+ # @return [String]
323
+ class GetBulkPublishDetailsResponse < Struct.new(
324
+ :identity_pool_id,
325
+ :bulk_publish_start_time,
326
+ :bulk_publish_complete_time,
327
+ :bulk_publish_status,
328
+ :failure_message)
329
+ include Aws::Structure
330
+ end
331
+
332
+ # A request for a list of the configured Cognito Events
333
+ # @note When making an API call, pass GetCognitoEventsRequest
334
+ # data as a hash:
335
+ #
336
+ # {
337
+ # identity_pool_id: "IdentityPoolId", # required
338
+ # }
339
+ # @!attribute [rw] identity_pool_id
340
+ # The Cognito Identity Pool ID for the request
341
+ # @return [String]
342
+ class GetCognitoEventsRequest < Struct.new(
343
+ :identity_pool_id)
344
+ include Aws::Structure
345
+ end
346
+
347
+ # The response from the GetCognitoEvents request
348
+ # @!attribute [rw] events
349
+ # The Cognito Events returned from the GetCognitoEvents request
350
+ # @return [Hash<String,String>]
351
+ class GetCognitoEventsResponse < Struct.new(
352
+ :events)
353
+ include Aws::Structure
354
+ end
355
+
356
+ # The input for the GetIdentityPoolConfiguration operation.
357
+ # @note When making an API call, pass GetIdentityPoolConfigurationRequest
358
+ # data as a hash:
359
+ #
360
+ # {
361
+ # identity_pool_id: "IdentityPoolId", # required
362
+ # }
363
+ # @!attribute [rw] identity_pool_id
364
+ # A name-spaced GUID (for example,
365
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
366
+ # Cognito. This is the ID of the pool for which to return a
367
+ # configuration.
368
+ # @return [String]
369
+ class GetIdentityPoolConfigurationRequest < Struct.new(
370
+ :identity_pool_id)
371
+ include Aws::Structure
372
+ end
373
+
374
+ # The output for the GetIdentityPoolConfiguration operation.
375
+ # @!attribute [rw] identity_pool_id
376
+ # A name-spaced GUID (for example,
377
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
378
+ # Cognito.
379
+ # @return [String]
380
+ #
381
+ # @!attribute [rw] push_sync
382
+ # Options to apply to this identity pool for push synchronization.
383
+ # @return [Types::PushSync]
384
+ #
385
+ # @!attribute [rw] cognito_streams
386
+ # Options to apply to this identity pool for Amazon Cognito streams.
387
+ # @return [Types::CognitoStreams]
388
+ class GetIdentityPoolConfigurationResponse < Struct.new(
389
+ :identity_pool_id,
390
+ :push_sync,
391
+ :cognito_streams)
392
+ include Aws::Structure
393
+ end
394
+
395
+ # Usage information for the identity pool.
396
+ # @!attribute [rw] identity_pool_id
397
+ # A name-spaced GUID (for example,
398
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
399
+ # Cognito. GUID generation is unique within a region.
400
+ # @return [String]
401
+ #
402
+ # @!attribute [rw] sync_sessions_count
403
+ # Number of sync sessions for the identity pool.
404
+ # @return [Integer]
405
+ #
406
+ # @!attribute [rw] data_storage
407
+ # Data storage information for the identity pool.
408
+ # @return [Integer]
409
+ #
410
+ # @!attribute [rw] last_modified_date
411
+ # Date on which the identity pool was last modified.
412
+ # @return [Time]
413
+ class IdentityPoolUsage < Struct.new(
414
+ :identity_pool_id,
415
+ :sync_sessions_count,
416
+ :data_storage,
417
+ :last_modified_date)
418
+ include Aws::Structure
419
+ end
420
+
421
+ # Usage information for the identity.
422
+ # @!attribute [rw] identity_id
423
+ # A name-spaced GUID (for example,
424
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
425
+ # Cognito. GUID generation is unique within a region.
426
+ # @return [String]
427
+ #
428
+ # @!attribute [rw] identity_pool_id
429
+ # A name-spaced GUID (for example,
430
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
431
+ # Cognito. GUID generation is unique within a region.
432
+ # @return [String]
433
+ #
434
+ # @!attribute [rw] last_modified_date
435
+ # Date on which the identity was last modified.
436
+ # @return [Time]
437
+ #
438
+ # @!attribute [rw] dataset_count
439
+ # Number of datasets for the identity.
440
+ # @return [Integer]
441
+ #
442
+ # @!attribute [rw] data_storage
443
+ # Total data storage for this identity.
444
+ # @return [Integer]
445
+ class IdentityUsage < Struct.new(
446
+ :identity_id,
447
+ :identity_pool_id,
448
+ :last_modified_date,
449
+ :dataset_count,
450
+ :data_storage)
451
+ include Aws::Structure
452
+ end
453
+
454
+ # Request for a list of datasets for an identity.
455
+ # @note When making an API call, pass ListDatasetsRequest
456
+ # data as a hash:
457
+ #
458
+ # {
459
+ # identity_pool_id: "IdentityPoolId", # required
460
+ # identity_id: "IdentityId", # required
461
+ # next_token: "String",
462
+ # max_results: 1,
463
+ # }
464
+ # @!attribute [rw] identity_pool_id
465
+ # A name-spaced GUID (for example,
466
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
467
+ # Cognito. GUID generation is unique within a region.
468
+ # @return [String]
469
+ #
470
+ # @!attribute [rw] identity_id
471
+ # A name-spaced GUID (for example,
472
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
473
+ # Cognito. GUID generation is unique within a region.
474
+ # @return [String]
475
+ #
476
+ # @!attribute [rw] next_token
477
+ # A pagination token for obtaining the next page of results.
478
+ # @return [String]
479
+ #
480
+ # @!attribute [rw] max_results
481
+ # The maximum number of results to be returned.
482
+ # @return [Integer]
483
+ class ListDatasetsRequest < Struct.new(
484
+ :identity_pool_id,
485
+ :identity_id,
486
+ :next_token,
487
+ :max_results)
488
+ include Aws::Structure
489
+ end
490
+
491
+ # Returned for a successful ListDatasets request.
492
+ # @!attribute [rw] datasets
493
+ # A set of datasets.
494
+ # @return [Array<Types::Dataset>]
495
+ #
496
+ # @!attribute [rw] count
497
+ # Number of datasets returned.
498
+ # @return [Integer]
499
+ #
500
+ # @!attribute [rw] next_token
501
+ # A pagination token for obtaining the next page of results.
502
+ # @return [String]
503
+ class ListDatasetsResponse < Struct.new(
504
+ :datasets,
505
+ :count,
506
+ :next_token)
507
+ include Aws::Structure
508
+ end
509
+
510
+ # A request for usage information on an identity pool.
511
+ # @note When making an API call, pass ListIdentityPoolUsageRequest
512
+ # data as a hash:
513
+ #
514
+ # {
515
+ # next_token: "String",
516
+ # max_results: 1,
517
+ # }
518
+ # @!attribute [rw] next_token
519
+ # A pagination token for obtaining the next page of results.
520
+ # @return [String]
521
+ #
522
+ # @!attribute [rw] max_results
523
+ # The maximum number of results to be returned.
524
+ # @return [Integer]
525
+ class ListIdentityPoolUsageRequest < Struct.new(
526
+ :next_token,
527
+ :max_results)
528
+ include Aws::Structure
529
+ end
530
+
531
+ # Returned for a successful ListIdentityPoolUsage request.
532
+ # @!attribute [rw] identity_pool_usages
533
+ # Usage information for the identity pools.
534
+ # @return [Array<Types::IdentityPoolUsage>]
535
+ #
536
+ # @!attribute [rw] max_results
537
+ # The maximum number of results to be returned.
538
+ # @return [Integer]
539
+ #
540
+ # @!attribute [rw] count
541
+ # Total number of identities for the identity pool.
542
+ # @return [Integer]
543
+ #
544
+ # @!attribute [rw] next_token
545
+ # A pagination token for obtaining the next page of results.
546
+ # @return [String]
547
+ class ListIdentityPoolUsageResponse < Struct.new(
548
+ :identity_pool_usages,
549
+ :max_results,
550
+ :count,
551
+ :next_token)
552
+ include Aws::Structure
553
+ end
554
+
555
+ # A request for a list of records.
556
+ # @note When making an API call, pass ListRecordsRequest
557
+ # data as a hash:
558
+ #
559
+ # {
560
+ # identity_pool_id: "IdentityPoolId", # required
561
+ # identity_id: "IdentityId", # required
562
+ # dataset_name: "DatasetName", # required
563
+ # last_sync_count: 1,
564
+ # next_token: "String",
565
+ # max_results: 1,
566
+ # sync_session_token: "SyncSessionToken",
567
+ # }
568
+ # @!attribute [rw] identity_pool_id
569
+ # A name-spaced GUID (for example,
570
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
571
+ # Cognito. GUID generation is unique within a region.
572
+ # @return [String]
573
+ #
574
+ # @!attribute [rw] identity_id
575
+ # A name-spaced GUID (for example,
576
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
577
+ # Cognito. GUID generation is unique within a region.
578
+ # @return [String]
579
+ #
580
+ # @!attribute [rw] dataset_name
581
+ # A string of up to 128 characters. Allowed characters are a-z, A-Z,
582
+ # 0-9, '\_' (underscore), '-' (dash), and '.' (dot).
583
+ # @return [String]
584
+ #
585
+ # @!attribute [rw] last_sync_count
586
+ # The last server sync count for this record.
587
+ # @return [Integer]
588
+ #
589
+ # @!attribute [rw] next_token
590
+ # A pagination token for obtaining the next page of results.
591
+ # @return [String]
592
+ #
593
+ # @!attribute [rw] max_results
594
+ # The maximum number of results to be returned.
595
+ # @return [Integer]
596
+ #
597
+ # @!attribute [rw] sync_session_token
598
+ # A token containing a session ID, identity ID, and expiration.
599
+ # @return [String]
600
+ class ListRecordsRequest < Struct.new(
601
+ :identity_pool_id,
602
+ :identity_id,
603
+ :dataset_name,
604
+ :last_sync_count,
605
+ :next_token,
606
+ :max_results,
607
+ :sync_session_token)
608
+ include Aws::Structure
609
+ end
610
+
611
+ # Returned for a successful ListRecordsRequest.
612
+ # @!attribute [rw] records
613
+ # A list of all records.
614
+ # @return [Array<Types::Record>]
615
+ #
616
+ # @!attribute [rw] next_token
617
+ # A pagination token for obtaining the next page of results.
618
+ # @return [String]
619
+ #
620
+ # @!attribute [rw] count
621
+ # Total number of records.
622
+ # @return [Integer]
623
+ #
624
+ # @!attribute [rw] dataset_sync_count
625
+ # Server sync count for this dataset.
626
+ # @return [Integer]
627
+ #
628
+ # @!attribute [rw] last_modified_by
629
+ # The user/device that made the last change to this record.
630
+ # @return [String]
631
+ #
632
+ # @!attribute [rw] merged_dataset_names
633
+ # Names of merged datasets.
634
+ # @return [Array<String>]
635
+ #
636
+ # @!attribute [rw] dataset_exists
637
+ # Indicates whether the dataset exists.
638
+ # @return [Boolean]
639
+ #
640
+ # @!attribute [rw] dataset_deleted_after_requested_sync_count
641
+ # A boolean value specifying whether to delete the dataset locally.
642
+ # @return [Boolean]
643
+ #
644
+ # @!attribute [rw] sync_session_token
645
+ # A token containing a session ID, identity ID, and expiration.
646
+ # @return [String]
647
+ class ListRecordsResponse < Struct.new(
648
+ :records,
649
+ :next_token,
650
+ :count,
651
+ :dataset_sync_count,
652
+ :last_modified_by,
653
+ :merged_dataset_names,
654
+ :dataset_exists,
655
+ :dataset_deleted_after_requested_sync_count,
656
+ :sync_session_token)
657
+ include Aws::Structure
658
+ end
659
+
660
+ # Configuration options to be applied to the identity pool.
661
+ # @note When making an API call, pass PushSync
662
+ # data as a hash:
663
+ #
664
+ # {
665
+ # application_arns: ["ApplicationArn"],
666
+ # role_arn: "AssumeRoleArn",
667
+ # }
668
+ # @!attribute [rw] application_arns
669
+ # List of SNS platform application ARNs that could be used by clients.
670
+ # @return [Array<String>]
671
+ #
672
+ # @!attribute [rw] role_arn
673
+ # A role configured to allow Cognito to call SNS on behalf of the
674
+ # developer.
675
+ # @return [String]
676
+ class PushSync < Struct.new(
677
+ :application_arns,
678
+ :role_arn)
679
+ include Aws::Structure
680
+ end
681
+
682
+ # The basic data structure of a dataset.
683
+ # @!attribute [rw] key
684
+ # The key for the record.
685
+ # @return [String]
686
+ #
687
+ # @!attribute [rw] value
688
+ # The value for the record.
689
+ # @return [String]
690
+ #
691
+ # @!attribute [rw] sync_count
692
+ # The server sync count for this record.
693
+ # @return [Integer]
694
+ #
695
+ # @!attribute [rw] last_modified_date
696
+ # The date on which the record was last modified.
697
+ # @return [Time]
698
+ #
699
+ # @!attribute [rw] last_modified_by
700
+ # The user/device that made the last change to this record.
701
+ # @return [String]
702
+ #
703
+ # @!attribute [rw] device_last_modified_date
704
+ # The last modified date of the client device.
705
+ # @return [Time]
706
+ class Record < Struct.new(
707
+ :key,
708
+ :value,
709
+ :sync_count,
710
+ :last_modified_date,
711
+ :last_modified_by,
712
+ :device_last_modified_date)
713
+ include Aws::Structure
714
+ end
715
+
716
+ # An update operation for a record.
717
+ # @note When making an API call, pass RecordPatch
718
+ # data as a hash:
719
+ #
720
+ # {
721
+ # op: "replace", # required, accepts replace, remove
722
+ # key: "RecordKey", # required
723
+ # value: "RecordValue",
724
+ # sync_count: 1, # required
725
+ # device_last_modified_date: Time.now,
726
+ # }
727
+ # @!attribute [rw] op
728
+ # An operation, either replace or remove.
729
+ # @return [String]
730
+ #
731
+ # @!attribute [rw] key
732
+ # The key associated with the record patch.
733
+ # @return [String]
734
+ #
735
+ # @!attribute [rw] value
736
+ # The value associated with the record patch.
737
+ # @return [String]
738
+ #
739
+ # @!attribute [rw] sync_count
740
+ # Last known server sync count for this record. Set to 0 if unknown.
741
+ # @return [Integer]
742
+ #
743
+ # @!attribute [rw] device_last_modified_date
744
+ # The last modified date of the client device.
745
+ # @return [Time]
746
+ class RecordPatch < Struct.new(
747
+ :op,
748
+ :key,
749
+ :value,
750
+ :sync_count,
751
+ :device_last_modified_date)
752
+ include Aws::Structure
753
+ end
754
+
755
+ # A request to RegisterDevice.
756
+ # @note When making an API call, pass RegisterDeviceRequest
757
+ # data as a hash:
758
+ #
759
+ # {
760
+ # identity_pool_id: "IdentityPoolId", # required
761
+ # identity_id: "IdentityId", # required
762
+ # platform: "APNS", # required, accepts APNS, APNS_SANDBOX, GCM, ADM
763
+ # token: "PushToken", # required
764
+ # }
765
+ # @!attribute [rw] identity_pool_id
766
+ # A name-spaced GUID (for example,
767
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
768
+ # Cognito. Here, the ID of the pool that the identity belongs to.
769
+ # @return [String]
770
+ #
771
+ # @!attribute [rw] identity_id
772
+ # The unique ID for this identity.
773
+ # @return [String]
774
+ #
775
+ # @!attribute [rw] platform
776
+ # The SNS platform type (e.g. GCM, SDM, APNS, APNS\_SANDBOX).
777
+ # @return [String]
778
+ #
779
+ # @!attribute [rw] token
780
+ # The push token.
781
+ # @return [String]
782
+ class RegisterDeviceRequest < Struct.new(
783
+ :identity_pool_id,
784
+ :identity_id,
785
+ :platform,
786
+ :token)
787
+ include Aws::Structure
788
+ end
789
+
790
+ # Response to a RegisterDevice request.
791
+ # @!attribute [rw] device_id
792
+ # The unique ID generated for this device by Cognito.
793
+ # @return [String]
794
+ class RegisterDeviceResponse < Struct.new(
795
+ :device_id)
796
+ include Aws::Structure
797
+ end
798
+
799
+ # A request to configure Cognito Events"
800
+ #
801
+ # "
802
+ # @note When making an API call, pass SetCognitoEventsRequest
803
+ # data as a hash:
804
+ #
805
+ # {
806
+ # identity_pool_id: "IdentityPoolId", # required
807
+ # events: { # required
808
+ # "CognitoEventType" => "LambdaFunctionArn",
809
+ # },
810
+ # }
811
+ # @!attribute [rw] identity_pool_id
812
+ # The Cognito Identity Pool to use when configuring Cognito Events
813
+ # @return [String]
814
+ #
815
+ # @!attribute [rw] events
816
+ # The events to configure
817
+ # @return [Hash<String,String>]
818
+ class SetCognitoEventsRequest < Struct.new(
819
+ :identity_pool_id,
820
+ :events)
821
+ include Aws::Structure
822
+ end
823
+
824
+ # The input for the SetIdentityPoolConfiguration operation.
825
+ # @note When making an API call, pass SetIdentityPoolConfigurationRequest
826
+ # data as a hash:
827
+ #
828
+ # {
829
+ # identity_pool_id: "IdentityPoolId", # required
830
+ # push_sync: {
831
+ # application_arns: ["ApplicationArn"],
832
+ # role_arn: "AssumeRoleArn",
833
+ # },
834
+ # cognito_streams: {
835
+ # stream_name: "StreamName",
836
+ # role_arn: "AssumeRoleArn",
837
+ # streaming_status: "ENABLED", # accepts ENABLED, DISABLED
838
+ # },
839
+ # }
840
+ # @!attribute [rw] identity_pool_id
841
+ # A name-spaced GUID (for example,
842
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
843
+ # Cognito. This is the ID of the pool to modify.
844
+ # @return [String]
845
+ #
846
+ # @!attribute [rw] push_sync
847
+ # Options to apply to this identity pool for push synchronization.
848
+ # @return [Types::PushSync]
849
+ #
850
+ # @!attribute [rw] cognito_streams
851
+ # Options to apply to this identity pool for Amazon Cognito streams.
852
+ # @return [Types::CognitoStreams]
853
+ class SetIdentityPoolConfigurationRequest < Struct.new(
854
+ :identity_pool_id,
855
+ :push_sync,
856
+ :cognito_streams)
857
+ include Aws::Structure
858
+ end
859
+
860
+ # The output for the SetIdentityPoolConfiguration operation
861
+ # @!attribute [rw] identity_pool_id
862
+ # A name-spaced GUID (for example,
863
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
864
+ # Cognito.
865
+ # @return [String]
866
+ #
867
+ # @!attribute [rw] push_sync
868
+ # Options to apply to this identity pool for push synchronization.
869
+ # @return [Types::PushSync]
870
+ #
871
+ # @!attribute [rw] cognito_streams
872
+ # Options to apply to this identity pool for Amazon Cognito streams.
873
+ # @return [Types::CognitoStreams]
874
+ class SetIdentityPoolConfigurationResponse < Struct.new(
875
+ :identity_pool_id,
876
+ :push_sync,
877
+ :cognito_streams)
878
+ include Aws::Structure
879
+ end
880
+
881
+ # A request to SubscribeToDatasetRequest.
882
+ # @note When making an API call, pass SubscribeToDatasetRequest
883
+ # data as a hash:
884
+ #
885
+ # {
886
+ # identity_pool_id: "IdentityPoolId", # required
887
+ # identity_id: "IdentityId", # required
888
+ # dataset_name: "DatasetName", # required
889
+ # device_id: "DeviceId", # required
890
+ # }
891
+ # @!attribute [rw] identity_pool_id
892
+ # A name-spaced GUID (for example,
893
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
894
+ # Cognito. The ID of the pool to which the identity belongs.
895
+ # @return [String]
896
+ #
897
+ # @!attribute [rw] identity_id
898
+ # Unique ID for this identity.
899
+ # @return [String]
900
+ #
901
+ # @!attribute [rw] dataset_name
902
+ # The name of the dataset to subcribe to.
903
+ # @return [String]
904
+ #
905
+ # @!attribute [rw] device_id
906
+ # The unique ID generated for this device by Cognito.
907
+ # @return [String]
908
+ class SubscribeToDatasetRequest < Struct.new(
909
+ :identity_pool_id,
910
+ :identity_id,
911
+ :dataset_name,
912
+ :device_id)
913
+ include Aws::Structure
914
+ end
915
+
916
+ # Response to a SubscribeToDataset request.
917
+ class SubscribeToDatasetResponse < Aws::EmptyStructure; end
918
+
919
+ # A request to UnsubscribeFromDataset.
920
+ # @note When making an API call, pass UnsubscribeFromDatasetRequest
921
+ # data as a hash:
922
+ #
923
+ # {
924
+ # identity_pool_id: "IdentityPoolId", # required
925
+ # identity_id: "IdentityId", # required
926
+ # dataset_name: "DatasetName", # required
927
+ # device_id: "DeviceId", # required
928
+ # }
929
+ # @!attribute [rw] identity_pool_id
930
+ # A name-spaced GUID (for example,
931
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
932
+ # Cognito. The ID of the pool to which this identity belongs.
933
+ # @return [String]
934
+ #
935
+ # @!attribute [rw] identity_id
936
+ # Unique ID for this identity.
937
+ # @return [String]
938
+ #
939
+ # @!attribute [rw] dataset_name
940
+ # The name of the dataset from which to unsubcribe.
941
+ # @return [String]
942
+ #
943
+ # @!attribute [rw] device_id
944
+ # The unique ID generated for this device by Cognito.
945
+ # @return [String]
946
+ class UnsubscribeFromDatasetRequest < Struct.new(
947
+ :identity_pool_id,
948
+ :identity_id,
949
+ :dataset_name,
950
+ :device_id)
951
+ include Aws::Structure
952
+ end
953
+
954
+ # Response to an UnsubscribeFromDataset request.
955
+ class UnsubscribeFromDatasetResponse < Aws::EmptyStructure; end
956
+
957
+ # A request to post updates to records or add and delete records for a
958
+ # dataset and user.
959
+ # @note When making an API call, pass UpdateRecordsRequest
960
+ # data as a hash:
961
+ #
962
+ # {
963
+ # identity_pool_id: "IdentityPoolId", # required
964
+ # identity_id: "IdentityId", # required
965
+ # dataset_name: "DatasetName", # required
966
+ # device_id: "DeviceId",
967
+ # record_patches: [
968
+ # {
969
+ # op: "replace", # required, accepts replace, remove
970
+ # key: "RecordKey", # required
971
+ # value: "RecordValue",
972
+ # sync_count: 1, # required
973
+ # device_last_modified_date: Time.now,
974
+ # },
975
+ # ],
976
+ # sync_session_token: "SyncSessionToken", # required
977
+ # client_context: "ClientContext",
978
+ # }
979
+ # @!attribute [rw] identity_pool_id
980
+ # A name-spaced GUID (for example,
981
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
982
+ # Cognito. GUID generation is unique within a region.
983
+ # @return [String]
984
+ #
985
+ # @!attribute [rw] identity_id
986
+ # A name-spaced GUID (for example,
987
+ # us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon
988
+ # Cognito. GUID generation is unique within a region.
989
+ # @return [String]
990
+ #
991
+ # @!attribute [rw] dataset_name
992
+ # A string of up to 128 characters. Allowed characters are a-z, A-Z,
993
+ # 0-9, '\_' (underscore), '-' (dash), and '.' (dot).
994
+ # @return [String]
995
+ #
996
+ # @!attribute [rw] device_id
997
+ # The unique ID generated for this device by Cognito.
998
+ # @return [String]
999
+ #
1000
+ # @!attribute [rw] record_patches
1001
+ # A list of patch operations.
1002
+ # @return [Array<Types::RecordPatch>]
1003
+ #
1004
+ # @!attribute [rw] sync_session_token
1005
+ # The SyncSessionToken returned by a previous call to ListRecords for
1006
+ # this dataset and identity.
1007
+ # @return [String]
1008
+ #
1009
+ # @!attribute [rw] client_context
1010
+ # Intended to supply a device ID that will populate the lastModifiedBy
1011
+ # field referenced in other methods. The ClientContext field is not
1012
+ # yet implemented.
1013
+ # @return [String]
1014
+ class UpdateRecordsRequest < Struct.new(
1015
+ :identity_pool_id,
1016
+ :identity_id,
1017
+ :dataset_name,
1018
+ :device_id,
1019
+ :record_patches,
1020
+ :sync_session_token,
1021
+ :client_context)
1022
+ include Aws::Structure
1023
+ end
1024
+
1025
+ # Returned for a successful UpdateRecordsRequest.
1026
+ # @!attribute [rw] records
1027
+ # A list of records that have been updated.
1028
+ # @return [Array<Types::Record>]
1029
+ class UpdateRecordsResponse < Struct.new(
1030
+ :records)
1031
+ include Aws::Structure
1032
+ end
1033
+
1034
+ end
1035
+ end
1036
+ end