aws-sdk-personalizeevents 1.11.0 → 1.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bdabd33d4876d4dc07e4ea82f8e9d4b0c1b8edb8eb4795180c3cb25f25ba8149
4
- data.tar.gz: 0b1495a68a5f8406a1c22814786250b688bf5930152250bb33a13e483fa2832b
3
+ metadata.gz: fd0b533a3d346ed3c67f830a2c38cabdfc0511d066300b02da789f943d67bf09
4
+ data.tar.gz: f02cc1929f8f100e052bcd6f276c1989bb82f38bc91983692c7c2768eeaa8fa3
5
5
  SHA512:
6
- metadata.gz: 75ce5ca7c7654eadf33328c3936000b929f44b68faf14f8282e5ad27342e3ba84016d4760fa7affc6fa96cd0536b870a66fd50c185ae544c2f33b3d0f966dec4
7
- data.tar.gz: 3959f6f2ac5d74e804932bbb5345c886f08d87363114b46a1c5eec10bed7541a983b480b8bd0095e586d162f36075bd58db3d17db050c7aca2bf52db65508616
6
+ metadata.gz: ac25c1b66a5c3581e5d6f000e632fe170b19916820159a731913a8775e0f7a79293873bbe8b94fc43cdba4e715fd04903be3b1a49d50972e8cfe0ecb1764ff1b
7
+ data.tar.gz: 0a6ee1743805f2e12e0407d7c737dc6803592e7f1e135b64dae43ca54a67821d5145ba90efc4c96bea78eef25d2095ffc96f09df899f62b1e30ad6a54179e648
@@ -7,6 +7,7 @@
7
7
  #
8
8
  # WARNING ABOUT GENERATED CODE
9
9
 
10
+
10
11
  require 'aws-sdk-core'
11
12
  require 'aws-sigv4'
12
13
 
@@ -47,6 +48,6 @@ require_relative 'aws-sdk-personalizeevents/customizations'
47
48
  # @!group service
48
49
  module Aws::PersonalizeEvents
49
50
 
50
- GEM_VERSION = '1.11.0'
51
+ GEM_VERSION = '1.16.0'
51
52
 
52
53
  end
@@ -328,7 +328,11 @@ module Aws::PersonalizeEvents
328
328
  # @!group API Operations
329
329
 
330
330
  # Records user interaction event data. For more information see
331
- # event-record-api.
331
+ # [Recording Events][1].
332
+ #
333
+ #
334
+ #
335
+ # [1]: https://docs.aws.amazon.com/personalize/latest/dg/recording-events.html
332
336
  #
333
337
  # @option params [required, String] :tracking_id
334
338
  # The tracking ID for the event. The ID is generated by a call to the
@@ -345,8 +349,12 @@ module Aws::PersonalizeEvents
345
349
  # The session ID associated with the user's visit. Your application
346
350
  # generates the sessionId when a user first visits your website or uses
347
351
  # your application. Amazon Personalize uses the sessionId to associate
348
- # events with the user before they log in. For more information see
349
- # event-record-api.
352
+ # events with the user before they log in. For more information, see
353
+ # [Recording Events][1].
354
+ #
355
+ #
356
+ #
357
+ # [1]: https://docs.aws.amazon.com/personalize/latest/dg/recording-events.html
350
358
  #
351
359
  # @option params [required, Array<Types::Event>] :event_list
352
360
  # A list of event data from the session.
@@ -382,6 +390,80 @@ module Aws::PersonalizeEvents
382
390
  req.send_request(options)
383
391
  end
384
392
 
393
+ # Adds one or more items to an Items dataset. For more information see
394
+ # [Importing Items Incrementally][1].
395
+ #
396
+ #
397
+ #
398
+ # [1]: https://docs.aws.amazon.com/personalize/latest/dg/importing-items.html
399
+ #
400
+ # @option params [required, String] :dataset_arn
401
+ # The Amazon Resource Name (ARN) of the Items dataset you are adding the
402
+ # item or items to.
403
+ #
404
+ # @option params [required, Array<Types::Item>] :items
405
+ # A list of item data.
406
+ #
407
+ # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
408
+ #
409
+ # @example Request syntax with placeholder values
410
+ #
411
+ # resp = client.put_items({
412
+ # dataset_arn: "Arn", # required
413
+ # items: [ # required
414
+ # {
415
+ # item_id: "StringType", # required
416
+ # properties: "ItemProperties",
417
+ # },
418
+ # ],
419
+ # })
420
+ #
421
+ # @see http://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutItems AWS API Documentation
422
+ #
423
+ # @overload put_items(params = {})
424
+ # @param [Hash] params ({})
425
+ def put_items(params = {}, options = {})
426
+ req = build_request(:put_items, params)
427
+ req.send_request(options)
428
+ end
429
+
430
+ # Adds one or more users to a Users dataset. For more information see
431
+ # [Importing Users Incrementally][1].
432
+ #
433
+ #
434
+ #
435
+ # [1]: https://docs.aws.amazon.com/personalize/latest/dg/importing-users.html
436
+ #
437
+ # @option params [required, String] :dataset_arn
438
+ # The Amazon Resource Name (ARN) of the Users dataset you are adding the
439
+ # user or users to.
440
+ #
441
+ # @option params [required, Array<Types::User>] :users
442
+ # A list of user data.
443
+ #
444
+ # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
445
+ #
446
+ # @example Request syntax with placeholder values
447
+ #
448
+ # resp = client.put_users({
449
+ # dataset_arn: "Arn", # required
450
+ # users: [ # required
451
+ # {
452
+ # user_id: "StringType", # required
453
+ # properties: "UserProperties",
454
+ # },
455
+ # ],
456
+ # })
457
+ #
458
+ # @see http://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutUsers AWS API Documentation
459
+ #
460
+ # @overload put_users(params = {})
461
+ # @param [Hash] params ({})
462
+ def put_users(params = {}, options = {})
463
+ req = build_request(:put_users, params)
464
+ req.send_request(options)
465
+ end
466
+
385
467
  # @!endgroup
386
468
 
387
469
  # @param params ({})
@@ -395,7 +477,7 @@ module Aws::PersonalizeEvents
395
477
  params: params,
396
478
  config: config)
397
479
  context[:gem_name] = 'aws-sdk-personalizeevents'
398
- context[:gem_version] = '1.11.0'
480
+ context[:gem_version] = '1.16.0'
399
481
  Seahorse::Client::Request.new(handlers, context)
400
482
  end
401
483
 
@@ -13,6 +13,7 @@ module Aws::PersonalizeEvents
13
13
 
14
14
  include Seahorse::Model
15
15
 
16
+ Arn = Shapes::StringShape.new(name: 'Arn')
16
17
  Date = Shapes::TimestampShape.new(name: 'Date')
17
18
  ErrorMessage = Shapes::StringShape.new(name: 'ErrorMessage')
18
19
  Event = Shapes::StructureShape.new(name: 'Event')
@@ -21,11 +22,21 @@ module Aws::PersonalizeEvents
21
22
  FloatType = Shapes::FloatShape.new(name: 'FloatType')
22
23
  Impression = Shapes::ListShape.new(name: 'Impression')
23
24
  InvalidInputException = Shapes::StructureShape.new(name: 'InvalidInputException')
25
+ Item = Shapes::StructureShape.new(name: 'Item')
24
26
  ItemId = Shapes::StringShape.new(name: 'ItemId')
27
+ ItemList = Shapes::ListShape.new(name: 'ItemList')
28
+ ItemProperties = Shapes::StringShape.new(name: 'ItemProperties')
25
29
  PutEventsRequest = Shapes::StructureShape.new(name: 'PutEventsRequest')
30
+ PutItemsRequest = Shapes::StructureShape.new(name: 'PutItemsRequest')
31
+ PutUsersRequest = Shapes::StructureShape.new(name: 'PutUsersRequest')
26
32
  RecommendationId = Shapes::StringShape.new(name: 'RecommendationId')
33
+ ResourceInUseException = Shapes::StructureShape.new(name: 'ResourceInUseException')
34
+ ResourceNotFoundException = Shapes::StructureShape.new(name: 'ResourceNotFoundException')
27
35
  StringType = Shapes::StringShape.new(name: 'StringType')
36
+ User = Shapes::StructureShape.new(name: 'User')
28
37
  UserId = Shapes::StringShape.new(name: 'UserId')
38
+ UserList = Shapes::ListShape.new(name: 'UserList')
39
+ UserProperties = Shapes::StringShape.new(name: 'UserProperties')
29
40
 
30
41
  Event.add_member(:event_id, Shapes::ShapeRef.new(shape: StringType, location_name: "eventId"))
31
42
  Event.add_member(:event_type, Shapes::ShapeRef.new(shape: StringType, required: true, location_name: "eventType"))
@@ -44,12 +55,38 @@ module Aws::PersonalizeEvents
44
55
  InvalidInputException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessage, location_name: "message"))
45
56
  InvalidInputException.struct_class = Types::InvalidInputException
46
57
 
58
+ Item.add_member(:item_id, Shapes::ShapeRef.new(shape: StringType, required: true, location_name: "itemId"))
59
+ Item.add_member(:properties, Shapes::ShapeRef.new(shape: ItemProperties, location_name: "properties", metadata: {"jsonvalue"=>true}))
60
+ Item.struct_class = Types::Item
61
+
62
+ ItemList.member = Shapes::ShapeRef.new(shape: Item)
63
+
47
64
  PutEventsRequest.add_member(:tracking_id, Shapes::ShapeRef.new(shape: StringType, required: true, location_name: "trackingId"))
48
65
  PutEventsRequest.add_member(:user_id, Shapes::ShapeRef.new(shape: UserId, location_name: "userId"))
49
66
  PutEventsRequest.add_member(:session_id, Shapes::ShapeRef.new(shape: StringType, required: true, location_name: "sessionId"))
50
67
  PutEventsRequest.add_member(:event_list, Shapes::ShapeRef.new(shape: EventList, required: true, location_name: "eventList"))
51
68
  PutEventsRequest.struct_class = Types::PutEventsRequest
52
69
 
70
+ PutItemsRequest.add_member(:dataset_arn, Shapes::ShapeRef.new(shape: Arn, required: true, location_name: "datasetArn"))
71
+ PutItemsRequest.add_member(:items, Shapes::ShapeRef.new(shape: ItemList, required: true, location_name: "items"))
72
+ PutItemsRequest.struct_class = Types::PutItemsRequest
73
+
74
+ PutUsersRequest.add_member(:dataset_arn, Shapes::ShapeRef.new(shape: Arn, required: true, location_name: "datasetArn"))
75
+ PutUsersRequest.add_member(:users, Shapes::ShapeRef.new(shape: UserList, required: true, location_name: "users"))
76
+ PutUsersRequest.struct_class = Types::PutUsersRequest
77
+
78
+ ResourceInUseException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessage, location_name: "message"))
79
+ ResourceInUseException.struct_class = Types::ResourceInUseException
80
+
81
+ ResourceNotFoundException.add_member(:message, Shapes::ShapeRef.new(shape: ErrorMessage, location_name: "message"))
82
+ ResourceNotFoundException.struct_class = Types::ResourceNotFoundException
83
+
84
+ User.add_member(:user_id, Shapes::ShapeRef.new(shape: StringType, required: true, location_name: "userId"))
85
+ User.add_member(:properties, Shapes::ShapeRef.new(shape: UserProperties, location_name: "properties", metadata: {"jsonvalue"=>true}))
86
+ User.struct_class = Types::User
87
+
88
+ UserList.member = Shapes::ShapeRef.new(shape: User)
89
+
53
90
 
54
91
  # @api private
55
92
  API = Seahorse::Model::Api.new.tap do |api|
@@ -76,6 +113,28 @@ module Aws::PersonalizeEvents
76
113
  o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
77
114
  o.errors << Shapes::ShapeRef.new(shape: InvalidInputException)
78
115
  end)
116
+
117
+ api.add_operation(:put_items, Seahorse::Model::Operation.new.tap do |o|
118
+ o.name = "PutItems"
119
+ o.http_method = "POST"
120
+ o.http_request_uri = "/items"
121
+ o.input = Shapes::ShapeRef.new(shape: PutItemsRequest)
122
+ o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
123
+ o.errors << Shapes::ShapeRef.new(shape: InvalidInputException)
124
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
125
+ o.errors << Shapes::ShapeRef.new(shape: ResourceInUseException)
126
+ end)
127
+
128
+ api.add_operation(:put_users, Seahorse::Model::Operation.new.tap do |o|
129
+ o.name = "PutUsers"
130
+ o.http_method = "POST"
131
+ o.http_request_uri = "/users"
132
+ o.input = Shapes::ShapeRef.new(shape: PutUsersRequest)
133
+ o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
134
+ o.errors << Shapes::ShapeRef.new(shape: InvalidInputException)
135
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
136
+ o.errors << Shapes::ShapeRef.new(shape: ResourceInUseException)
137
+ end)
79
138
  end
80
139
 
81
140
  end
@@ -28,6 +28,8 @@ module Aws::PersonalizeEvents
28
28
  #
29
29
  # ## Error Classes
30
30
  # * {InvalidInputException}
31
+ # * {ResourceInUseException}
32
+ # * {ResourceNotFoundException}
31
33
  #
32
34
  # Additionally, error classes are dynamically generated for service errors based on the error code
33
35
  # if they are not defined above.
@@ -50,5 +52,35 @@ module Aws::PersonalizeEvents
50
52
  end
51
53
  end
52
54
 
55
+ class ResourceInUseException < ServiceError
56
+
57
+ # @param [Seahorse::Client::RequestContext] context
58
+ # @param [String] message
59
+ # @param [Aws::PersonalizeEvents::Types::ResourceInUseException] data
60
+ def initialize(context, message, data = Aws::EmptyStructure.new)
61
+ super(context, message, data)
62
+ end
63
+
64
+ # @return [String]
65
+ def message
66
+ @message || @data[:message]
67
+ end
68
+ end
69
+
70
+ class ResourceNotFoundException < ServiceError
71
+
72
+ # @param [Seahorse::Client::RequestContext] context
73
+ # @param [String] message
74
+ # @param [Aws::PersonalizeEvents::Types::ResourceNotFoundException] data
75
+ def initialize(context, message, data = Aws::EmptyStructure.new)
76
+ super(context, message, data)
77
+ end
78
+
79
+ # @return [String]
80
+ def message
81
+ @message || @data[:message]
82
+ end
83
+ end
84
+
53
85
  end
54
86
  end
@@ -36,8 +36,9 @@ module Aws::PersonalizeEvents
36
36
  # @return [String]
37
37
  #
38
38
  # @!attribute [rw] event_type
39
- # The type of event. This property corresponds to the `EVENT_TYPE`
40
- # field of the Interactions schema.
39
+ # The type of event, such as click or download. This property
40
+ # corresponds to the `EVENT_TYPE` field of your Interactions schema
41
+ # and depends on the types of events you are tracking.
41
42
  # @return [String]
42
43
  #
43
44
  # @!attribute [rw] event_value
@@ -108,6 +109,48 @@ module Aws::PersonalizeEvents
108
109
  include Aws::Structure
109
110
  end
110
111
 
112
+ # Represents item metadata added to an Items dataset using the
113
+ # `PutItems` API. For more information see [Importing Items
114
+ # Incrementally][1].
115
+ #
116
+ #
117
+ #
118
+ # [1]: https://docs.aws.amazon.com/personalize/latest/dg/importing-items.html
119
+ #
120
+ # @note When making an API call, you may pass Item
121
+ # data as a hash:
122
+ #
123
+ # {
124
+ # item_id: "StringType", # required
125
+ # properties: "ItemProperties",
126
+ # }
127
+ #
128
+ # @!attribute [rw] item_id
129
+ # The ID associated with the item.
130
+ # @return [String]
131
+ #
132
+ # @!attribute [rw] properties
133
+ # A string map of item-specific metadata. Each element in the map
134
+ # consists of a key-value pair. For example, `\{"numberOfRatings":
135
+ # "12"\}`.
136
+ #
137
+ # The keys use camel case names that match the fields in the schema
138
+ # for the Items dataset. In the previous example, the
139
+ # `numberOfRatings` matches the 'NUMBER\_OF\_RATINGS' field defined
140
+ # in the Items schema. For categorical string data, to include
141
+ # multiple categories for a single item, separate each category with a
142
+ # pipe separator (`|`). For example, `"Horror|Action"`.
143
+ # @return [String]
144
+ #
145
+ # @see http://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/Item AWS API Documentation
146
+ #
147
+ class Item < Struct.new(
148
+ :item_id,
149
+ :properties)
150
+ SENSITIVE = []
151
+ include Aws::Structure
152
+ end
153
+
111
154
  # @note When making an API call, you may pass PutEventsRequest
112
155
  # data as a hash:
113
156
  #
@@ -147,7 +190,11 @@ module Aws::PersonalizeEvents
147
190
  # generates the sessionId when a user first visits your website or
148
191
  # uses your application. Amazon Personalize uses the sessionId to
149
192
  # associate events with the user before they log in. For more
150
- # information see event-record-api.
193
+ # information, see [Recording Events][1].
194
+ #
195
+ #
196
+ #
197
+ # [1]: https://docs.aws.amazon.com/personalize/latest/dg/recording-events.html
151
198
  # @return [String]
152
199
  #
153
200
  # @!attribute [rw] event_list
@@ -165,5 +212,135 @@ module Aws::PersonalizeEvents
165
212
  include Aws::Structure
166
213
  end
167
214
 
215
+ # @note When making an API call, you may pass PutItemsRequest
216
+ # data as a hash:
217
+ #
218
+ # {
219
+ # dataset_arn: "Arn", # required
220
+ # items: [ # required
221
+ # {
222
+ # item_id: "StringType", # required
223
+ # properties: "ItemProperties",
224
+ # },
225
+ # ],
226
+ # }
227
+ #
228
+ # @!attribute [rw] dataset_arn
229
+ # The Amazon Resource Name (ARN) of the Items dataset you are adding
230
+ # the item or items to.
231
+ # @return [String]
232
+ #
233
+ # @!attribute [rw] items
234
+ # A list of item data.
235
+ # @return [Array<Types::Item>]
236
+ #
237
+ # @see http://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutItemsRequest AWS API Documentation
238
+ #
239
+ class PutItemsRequest < Struct.new(
240
+ :dataset_arn,
241
+ :items)
242
+ SENSITIVE = []
243
+ include Aws::Structure
244
+ end
245
+
246
+ # @note When making an API call, you may pass PutUsersRequest
247
+ # data as a hash:
248
+ #
249
+ # {
250
+ # dataset_arn: "Arn", # required
251
+ # users: [ # required
252
+ # {
253
+ # user_id: "StringType", # required
254
+ # properties: "UserProperties",
255
+ # },
256
+ # ],
257
+ # }
258
+ #
259
+ # @!attribute [rw] dataset_arn
260
+ # The Amazon Resource Name (ARN) of the Users dataset you are adding
261
+ # the user or users to.
262
+ # @return [String]
263
+ #
264
+ # @!attribute [rw] users
265
+ # A list of user data.
266
+ # @return [Array<Types::User>]
267
+ #
268
+ # @see http://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/PutUsersRequest AWS API Documentation
269
+ #
270
+ class PutUsersRequest < Struct.new(
271
+ :dataset_arn,
272
+ :users)
273
+ SENSITIVE = []
274
+ include Aws::Structure
275
+ end
276
+
277
+ # The specified resource is in use.
278
+ #
279
+ # @!attribute [rw] message
280
+ # @return [String]
281
+ #
282
+ # @see http://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/ResourceInUseException AWS API Documentation
283
+ #
284
+ class ResourceInUseException < Struct.new(
285
+ :message)
286
+ SENSITIVE = []
287
+ include Aws::Structure
288
+ end
289
+
290
+ # Could not find the specified resource.
291
+ #
292
+ # @!attribute [rw] message
293
+ # @return [String]
294
+ #
295
+ # @see http://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/ResourceNotFoundException AWS API Documentation
296
+ #
297
+ class ResourceNotFoundException < Struct.new(
298
+ :message)
299
+ SENSITIVE = []
300
+ include Aws::Structure
301
+ end
302
+
303
+ # Represents user metadata added to a Users dataset using the `PutUsers`
304
+ # API. For more information see [Importing Users Incrementally][1].
305
+ #
306
+ #
307
+ #
308
+ # [1]: https://docs.aws.amazon.com/personalize/latest/dg/importing-users.html
309
+ #
310
+ # @note When making an API call, you may pass User
311
+ # data as a hash:
312
+ #
313
+ # {
314
+ # user_id: "StringType", # required
315
+ # properties: "UserProperties",
316
+ # }
317
+ #
318
+ # @!attribute [rw] user_id
319
+ # The ID associated with the user.
320
+ # @return [String]
321
+ #
322
+ # @!attribute [rw] properties
323
+ # A string map of user-specific metadata. Each element in the map
324
+ # consists of a key-value pair. For example,
325
+ # `\{"numberOfVideosWatched": "45"\}`.
326
+ #
327
+ # The keys use camel case names that match the fields in the schema
328
+ # for the Users dataset. In the previous example, the
329
+ # `numberOfVideosWatched` matches the 'NUMBER\_OF\_VIDEOS\_WATCHED'
330
+ # field defined in the Users schema. For categorical string data, to
331
+ # include multiple categories for a single user, separate each
332
+ # category with a pipe separator (`|`). For example,
333
+ # `"Member|Frequent shopper"`.
334
+ # @return [String]
335
+ #
336
+ # @see http://docs.aws.amazon.com/goto/WebAPI/personalize-events-2018-03-22/User AWS API Documentation
337
+ #
338
+ class User < Struct.new(
339
+ :user_id,
340
+ :properties)
341
+ SENSITIVE = []
342
+ include Aws::Structure
343
+ end
344
+
168
345
  end
169
346
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-personalizeevents
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.11.0
4
+ version: 1.16.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-08-25 00:00:00.000000000 Z
11
+ date: 2021-02-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core
@@ -19,7 +19,7 @@ dependencies:
19
19
  version: '3'
20
20
  - - ">="
21
21
  - !ruby/object:Gem::Version
22
- version: 3.99.0
22
+ version: 3.112.0
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,7 +29,7 @@ dependencies:
29
29
  version: '3'
30
30
  - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: 3.99.0
32
+ version: 3.112.0
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: aws-sigv4
35
35
  requirement: !ruby/object:Gem::Requirement