google-apis-recommendationengine_v1beta1 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 80ab1fa68850e120723d0d506930fbb0c79fb13d45ccfe3381780163190ad3d6
4
+ data.tar.gz: 6c1df3c74ae12894360ea40868fe6c6f4da98c437d56418148ea8158a2cf6a32
5
+ SHA512:
6
+ metadata.gz: e48599fb8c8d1e9fa20171f2db21a3b2ca8da4705a6936c9cc1a9f1279fb96be2c353217d23ff3de9dd0a7f1af5a79d1728a4e8dd69741bf9fc839e0e1b9c9f0
7
+ data.tar.gz: 5ce1a5fc89db3c63bbb5dc5267d88160a871b5355d47e920c69343ececabef6eec01d31f5b26a374049342f656a217db87c6237b565db6d1f251b532fed29a1e
@@ -0,0 +1,13 @@
1
+ --hide-void-return
2
+ --no-private
3
+ --verbose
4
+ --title=google-apis-recommendationengine_v1beta1
5
+ --markup-provider=redcarpet
6
+ --markup=markdown
7
+ --main OVERVIEW.md
8
+ lib/google/apis/recommendationengine_v1beta1/*.rb
9
+ lib/google/apis/recommendationengine_v1beta1.rb
10
+ -
11
+ OVERVIEW.md
12
+ CHANGELOG.md
13
+ LICENSE.md
@@ -0,0 +1,7 @@
1
+ # Release history for google-apis-recommendationengine_v1beta1
2
+
3
+ ### v0.1.0 (2021-01-07)
4
+
5
+ * Regenerated using generator version 0.1.1
6
+ * Regenerated from discovery document revision 20201212
7
+
@@ -0,0 +1,202 @@
1
+
2
+ Apache License
3
+ Version 2.0, January 2004
4
+ http://www.apache.org/licenses/
5
+
6
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
+
8
+ 1. Definitions.
9
+
10
+ "License" shall mean the terms and conditions for use, reproduction,
11
+ and distribution as defined by Sections 1 through 9 of this document.
12
+
13
+ "Licensor" shall mean the copyright owner or entity authorized by
14
+ the copyright owner that is granting the License.
15
+
16
+ "Legal Entity" shall mean the union of the acting entity and all
17
+ other entities that control, are controlled by, or are under common
18
+ control with that entity. For the purposes of this definition,
19
+ "control" means (i) the power, direct or indirect, to cause the
20
+ direction or management of such entity, whether by contract or
21
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
+ outstanding shares, or (iii) beneficial ownership of such entity.
23
+
24
+ "You" (or "Your") shall mean an individual or Legal Entity
25
+ exercising permissions granted by this License.
26
+
27
+ "Source" form shall mean the preferred form for making modifications,
28
+ including but not limited to software source code, documentation
29
+ source, and configuration files.
30
+
31
+ "Object" form shall mean any form resulting from mechanical
32
+ transformation or translation of a Source form, including but
33
+ not limited to compiled object code, generated documentation,
34
+ and conversions to other media types.
35
+
36
+ "Work" shall mean the work of authorship, whether in Source or
37
+ Object form, made available under the License, as indicated by a
38
+ copyright notice that is included in or attached to the work
39
+ (an example is provided in the Appendix below).
40
+
41
+ "Derivative Works" shall mean any work, whether in Source or Object
42
+ form, that is based on (or derived from) the Work and for which the
43
+ editorial revisions, annotations, elaborations, or other modifications
44
+ represent, as a whole, an original work of authorship. For the purposes
45
+ of this License, Derivative Works shall not include works that remain
46
+ separable from, or merely link (or bind by name) to the interfaces of,
47
+ the Work and Derivative Works thereof.
48
+
49
+ "Contribution" shall mean any work of authorship, including
50
+ the original version of the Work and any modifications or additions
51
+ to that Work or Derivative Works thereof, that is intentionally
52
+ submitted to Licensor for inclusion in the Work by the copyright owner
53
+ or by an individual or Legal Entity authorized to submit on behalf of
54
+ the copyright owner. For the purposes of this definition, "submitted"
55
+ means any form of electronic, verbal, or written communication sent
56
+ to the Licensor or its representatives, including but not limited to
57
+ communication on electronic mailing lists, source code control systems,
58
+ and issue tracking systems that are managed by, or on behalf of, the
59
+ Licensor for the purpose of discussing and improving the Work, but
60
+ excluding communication that is conspicuously marked or otherwise
61
+ designated in writing by the copyright owner as "Not a Contribution."
62
+
63
+ "Contributor" shall mean Licensor and any individual or Legal Entity
64
+ on behalf of whom a Contribution has been received by Licensor and
65
+ subsequently incorporated within the Work.
66
+
67
+ 2. Grant of Copyright License. Subject to the terms and conditions of
68
+ this License, each Contributor hereby grants to You a perpetual,
69
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
+ copyright license to reproduce, prepare Derivative Works of,
71
+ publicly display, publicly perform, sublicense, and distribute the
72
+ Work and such Derivative Works in Source or Object form.
73
+
74
+ 3. Grant of Patent License. Subject to the terms and conditions of
75
+ this License, each Contributor hereby grants to You a perpetual,
76
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
+ (except as stated in this section) patent license to make, have made,
78
+ use, offer to sell, sell, import, and otherwise transfer the Work,
79
+ where such license applies only to those patent claims licensable
80
+ by such Contributor that are necessarily infringed by their
81
+ Contribution(s) alone or by combination of their Contribution(s)
82
+ with the Work to which such Contribution(s) was submitted. If You
83
+ institute patent litigation against any entity (including a
84
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
85
+ or a Contribution incorporated within the Work constitutes direct
86
+ or contributory patent infringement, then any patent licenses
87
+ granted to You under this License for that Work shall terminate
88
+ as of the date such litigation is filed.
89
+
90
+ 4. Redistribution. You may reproduce and distribute copies of the
91
+ Work or Derivative Works thereof in any medium, with or without
92
+ modifications, and in Source or Object form, provided that You
93
+ meet the following conditions:
94
+
95
+ (a) You must give any other recipients of the Work or
96
+ Derivative Works a copy of this License; and
97
+
98
+ (b) You must cause any modified files to carry prominent notices
99
+ stating that You changed the files; and
100
+
101
+ (c) You must retain, in the Source form of any Derivative Works
102
+ that You distribute, all copyright, patent, trademark, and
103
+ attribution notices from the Source form of the Work,
104
+ excluding those notices that do not pertain to any part of
105
+ the Derivative Works; and
106
+
107
+ (d) If the Work includes a "NOTICE" text file as part of its
108
+ distribution, then any Derivative Works that You distribute must
109
+ include a readable copy of the attribution notices contained
110
+ within such NOTICE file, excluding those notices that do not
111
+ pertain to any part of the Derivative Works, in at least one
112
+ of the following places: within a NOTICE text file distributed
113
+ as part of the Derivative Works; within the Source form or
114
+ documentation, if provided along with the Derivative Works; or,
115
+ within a display generated by the Derivative Works, if and
116
+ wherever such third-party notices normally appear. The contents
117
+ of the NOTICE file are for informational purposes only and
118
+ do not modify the License. You may add Your own attribution
119
+ notices within Derivative Works that You distribute, alongside
120
+ or as an addendum to the NOTICE text from the Work, provided
121
+ that such additional attribution notices cannot be construed
122
+ as modifying the License.
123
+
124
+ You may add Your own copyright statement to Your modifications and
125
+ may provide additional or different license terms and conditions
126
+ for use, reproduction, or distribution of Your modifications, or
127
+ for any such Derivative Works as a whole, provided Your use,
128
+ reproduction, and distribution of the Work otherwise complies with
129
+ the conditions stated in this License.
130
+
131
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
132
+ any Contribution intentionally submitted for inclusion in the Work
133
+ by You to the Licensor shall be under the terms and conditions of
134
+ this License, without any additional terms or conditions.
135
+ Notwithstanding the above, nothing herein shall supersede or modify
136
+ the terms of any separate license agreement you may have executed
137
+ with Licensor regarding such Contributions.
138
+
139
+ 6. Trademarks. This License does not grant permission to use the trade
140
+ names, trademarks, service marks, or product names of the Licensor,
141
+ except as required for reasonable and customary use in describing the
142
+ origin of the Work and reproducing the content of the NOTICE file.
143
+
144
+ 7. Disclaimer of Warranty. Unless required by applicable law or
145
+ agreed to in writing, Licensor provides the Work (and each
146
+ Contributor provides its Contributions) on an "AS IS" BASIS,
147
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
+ implied, including, without limitation, any warranties or conditions
149
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
+ PARTICULAR PURPOSE. You are solely responsible for determining the
151
+ appropriateness of using or redistributing the Work and assume any
152
+ risks associated with Your exercise of permissions under this License.
153
+
154
+ 8. Limitation of Liability. In no event and under no legal theory,
155
+ whether in tort (including negligence), contract, or otherwise,
156
+ unless required by applicable law (such as deliberate and grossly
157
+ negligent acts) or agreed to in writing, shall any Contributor be
158
+ liable to You for damages, including any direct, indirect, special,
159
+ incidental, or consequential damages of any character arising as a
160
+ result of this License or out of the use or inability to use the
161
+ Work (including but not limited to damages for loss of goodwill,
162
+ work stoppage, computer failure or malfunction, or any and all
163
+ other commercial damages or losses), even if such Contributor
164
+ has been advised of the possibility of such damages.
165
+
166
+ 9. Accepting Warranty or Additional Liability. While redistributing
167
+ the Work or Derivative Works thereof, You may choose to offer,
168
+ and charge a fee for, acceptance of support, warranty, indemnity,
169
+ or other liability obligations and/or rights consistent with this
170
+ License. However, in accepting such obligations, You may act only
171
+ on Your own behalf and on Your sole responsibility, not on behalf
172
+ of any other Contributor, and only if You agree to indemnify,
173
+ defend, and hold each Contributor harmless for any liability
174
+ incurred by, or claims asserted against, such Contributor by reason
175
+ of your accepting any such warranty or additional liability.
176
+
177
+ END OF TERMS AND CONDITIONS
178
+
179
+ APPENDIX: How to apply the Apache License to your work.
180
+
181
+ To apply the Apache License to your work, attach the following
182
+ boilerplate notice, with the fields enclosed by brackets "[]"
183
+ replaced with your own identifying information. (Don't include
184
+ the brackets!) The text should be enclosed in the appropriate
185
+ comment syntax for the file format. We also recommend that a
186
+ file or class name and description of purpose be included on the
187
+ same "printed page" as the copyright notice for easier
188
+ identification within third-party archives.
189
+
190
+ Copyright [yyyy] [name of copyright owner]
191
+
192
+ Licensed under the Apache License, Version 2.0 (the "License");
193
+ you may not use this file except in compliance with the License.
194
+ You may obtain a copy of the License at
195
+
196
+ http://www.apache.org/licenses/LICENSE-2.0
197
+
198
+ Unless required by applicable law or agreed to in writing, software
199
+ distributed under the License is distributed on an "AS IS" BASIS,
200
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
201
+ See the License for the specific language governing permissions and
202
+ limitations under the License.
@@ -0,0 +1,96 @@
1
+ # Simple REST client for version V1beta1 of the Recommendations AI
2
+
3
+ This is a simple client library for version V1beta1 of the Recommendations AI. It provides:
4
+
5
+ * A client object that connects to the HTTP/JSON REST endpoint for the service.
6
+ * Ruby objects for data structures related to the service.
7
+ * Integration with the googleauth gem for authentication using OAuth, API keys, and service accounts.
8
+ * Control of retry, pagination, and timeouts.
9
+
10
+ Note that although this client library is supported and will continue to be updated to track changes to the service, it is otherwise considered complete and not under active development. Many Google services, especially Google Cloud Platform services, may provide a more modern client that is under more active development and improvement. See the section below titled *Which client should I use?* for more information.
11
+
12
+ ## Getting started
13
+
14
+ ### Before you begin
15
+
16
+ There are a few setup steps you need to complete before you can use this library:
17
+
18
+ 1. If you don't already have a Google account, [sign up](https://www.google.com/accounts).
19
+ 2. If you have never created a Google APIs Console project, read about [Managing Projects](https://cloud.google.com/resource-manager/docs/creating-managing-projects) and create a project in the [Google API Console](https://console.cloud.google.com/).
20
+ 3. Most APIs need to be enabled for your project. [Enable it](https://console.cloud.google.com/apis/library/recommendationengine.googleapis.com) in the console.
21
+
22
+ ### Installation
23
+
24
+ Add this line to your application's Gemfile:
25
+
26
+ ```ruby
27
+ gem 'google-apis-recommendationengine_v1beta1', '~> 0.1'
28
+ ```
29
+
30
+ And then execute:
31
+
32
+ ```
33
+ $ bundle
34
+ ```
35
+
36
+ Or install it yourself as:
37
+
38
+ ```
39
+ $ gem install google-apis-recommendationengine_v1beta1
40
+ ```
41
+
42
+ ### Creating a client object
43
+
44
+ Once the gem is installed, you can load the client code and instantiate a client.
45
+
46
+ ```ruby
47
+ # Load the client
48
+ require "google/apis/recommendationengine_v1beta1"
49
+
50
+ # Create a client object
51
+ client = Google::Apis::RecommendationengineV1beta1::RecommendationsAIService.new
52
+
53
+ # Authenticate calls
54
+ client.authentication = # ... use the googleauth gem to create credentials
55
+ ```
56
+
57
+ See the class reference docs for information on the methods you can call from a client.
58
+
59
+ ## Documentation
60
+
61
+ More detailed descriptions of the Google simple REST clients are available in two documents.
62
+
63
+ * The [Usage Guide](https://github.com/googleapis/google-api-ruby-client/blob/master/docs/usage-guide.md) discusses how to make API calls, how to use the provided data structures, and how to work the various features of the client library, including media upload and download, error handling, retries, pagination, and logging.
64
+ * The [Auth Guide](https://github.com/googleapis/google-api-ruby-client/blob/master/docs/auth-guide.md) discusses authentication in the client libraries, including API keys, OAuth 2.0, service accounts, and environment variables.
65
+
66
+ (Note: the above documents are written for the simple REST clients in general, and their examples may not reflect the Recommendationengine service in particular.)
67
+
68
+ For reference information on specific calls in the Recommendations AI, see the {Google::Apis::RecommendationengineV1beta1::RecommendationsAIService class reference docs}.
69
+
70
+ ## Which client should I use?
71
+
72
+ Google provides two types of Ruby API client libraries: **simple REST clients** and **modern clients**.
73
+
74
+ This library, `google-apis-recommendationengine_v1beta1`, is a simple REST client. You can identify these clients by their gem names, which are always in the form `google-apis-<servicename>_<serviceversion>`. The simple REST clients connect to HTTP/JSON REST endpoints and are automatically generated from service discovery documents. They support most API functionality, but their class interfaces are sometimes awkward.
75
+
76
+ Modern clients are produced by a modern code generator, sometimes combined with hand-crafted functionality. Most modern clients connect to high-performance gRPC endpoints, although a few are backed by REST services. Modern clients are available for many Google services, especially Google Cloud Platform services, but do not yet support all the services covered by the simple clients.
77
+
78
+ Gem names for modern clients are often of the form `google-cloud-<service_name>`. (For example, [google-cloud-pubsub](https://rubygems.org/gems/google-cloud-pubsub).) Note that most modern clients also have corresponding "versioned" gems with names like `google-cloud-<service_name>-<version>`. (For example, [google-cloud-pubsub-v1](https://rubygems.org/gems/google-cloud-pubsub-v1).) The "versioned" gems can be used directly, but often provide lower-level interfaces. In most cases, the main gem is recommended.
79
+
80
+ **For most users, we recommend the modern client, if one is available.** Compared with simple clients, modern clients are generally much easier to use and more Ruby-like, support more advanced features such as streaming and long-running operations, and often provide much better performance. You may consider using a simple client instead, if a modern client is not yet available for the service you want to use, or if you are not able to use gRPC on your infrastructure.
81
+
82
+ The [product documentation](https://cloud.google.com/recommendations-ai/docs) may provide guidance regarding the preferred client library to use.
83
+
84
+ ## Supported Ruby versions
85
+
86
+ This library is supported on Ruby 2.5+.
87
+
88
+ Google provides official support for Ruby versions that are actively supported by Ruby Core -- that is, Ruby versions that are either in normal maintenance or in security maintenance, and not end of life. Currently, this means Ruby 2.5 and later. Older versions of Ruby _may_ still work, but are unsupported and not recommended. See https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby support schedule.
89
+
90
+ ## License
91
+
92
+ This library is licensed under Apache 2.0. Full license text is available in the {file:LICENSE.md LICENSE}.
93
+
94
+ ## Support
95
+
96
+ Please [report bugs at the project on Github](https://github.com/google/google-api-ruby-client/issues). Don't hesitate to [ask questions](http://stackoverflow.com/questions/tagged/google-api-ruby-client) about the client or APIs on [StackOverflow](http://stackoverflow.com).
@@ -0,0 +1,15 @@
1
+ # Copyright 2020 Google LLC
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require "google/apis/recommendationengine_v1beta1"
@@ -0,0 +1,38 @@
1
+ # Copyright 2020 Google LLC
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'google/apis/recommendationengine_v1beta1/service.rb'
16
+ require 'google/apis/recommendationengine_v1beta1/classes.rb'
17
+ require 'google/apis/recommendationengine_v1beta1/representations.rb'
18
+ require 'google/apis/recommendationengine_v1beta1/gem_version.rb'
19
+
20
+ module Google
21
+ module Apis
22
+ # Recommendations AI
23
+ #
24
+ # Recommendations AI service enables customers to build end-to-end personalized
25
+ # recommendation systems without requiring a high level of expertise in machine
26
+ # learning, recommendation system, or Google Cloud.
27
+ #
28
+ # @see https://cloud.google.com/recommendations-ai/docs
29
+ module RecommendationengineV1beta1
30
+ # Version of the Recommendations AI this client connects to.
31
+ # This is NOT the gem version.
32
+ VERSION = 'V1beta1'
33
+
34
+ # View and manage your data across Google Cloud Platform services
35
+ AUTH_CLOUD_PLATFORM = 'https://www.googleapis.com/auth/cloud-platform'
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,1928 @@
1
+ # Copyright 2020 Google LLC
2
+ #
3
+ # Licensed under the Apache License, Version 2.0 (the "License");
4
+ # you may not use this file except in compliance with the License.
5
+ # You may obtain a copy of the License at
6
+ #
7
+ # http://www.apache.org/licenses/LICENSE-2.0
8
+ #
9
+ # Unless required by applicable law or agreed to in writing, software
10
+ # distributed under the License is distributed on an "AS IS" BASIS,
11
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
+ # See the License for the specific language governing permissions and
13
+ # limitations under the License.
14
+
15
+ require 'date'
16
+ require 'google/apis/core/base_service'
17
+ require 'google/apis/core/json_representation'
18
+ require 'google/apis/core/hashable'
19
+ require 'google/apis/errors'
20
+
21
+ module Google
22
+ module Apis
23
+ module RecommendationengineV1beta1
24
+
25
+ # Message that represents an arbitrary HTTP body. It should only be used for
26
+ # payload formats that can't be represented as JSON, such as raw binary or an
27
+ # HTML page. This message can be used both in streaming and non-streaming API
28
+ # methods in the request as well as the response. It can be used as a top-level
29
+ # request field, which is convenient if one wants to extract parameters from
30
+ # either the URL or HTTP template into the request fields and also want access
31
+ # to the raw HTTP body. Example: message GetResourceRequest ` // A unique
32
+ # request id. string request_id = 1; // The raw HTTP body is bound to this field.
33
+ # google.api.HttpBody http_body = 2; ` service ResourceService ` rpc
34
+ # GetResource(GetResourceRequest) returns (google.api.HttpBody); rpc
35
+ # UpdateResource(google.api.HttpBody) returns (google.protobuf.Empty); ` Example
36
+ # with streaming methods: service CaldavService ` rpc GetCalendar(stream google.
37
+ # api.HttpBody) returns (stream google.api.HttpBody); rpc UpdateCalendar(stream
38
+ # google.api.HttpBody) returns (stream google.api.HttpBody); ` Use of this type
39
+ # only changes how the request and response bodies are handled, all other
40
+ # features will continue to work unchanged.
41
+ class GoogleApiHttpBody
42
+ include Google::Apis::Core::Hashable
43
+
44
+ # The HTTP Content-Type header value specifying the content type of the body.
45
+ # Corresponds to the JSON property `contentType`
46
+ # @return [String]
47
+ attr_accessor :content_type
48
+
49
+ # The HTTP request/response body as raw binary.
50
+ # Corresponds to the JSON property `data`
51
+ # NOTE: Values are automatically base64 encoded/decoded in the client library.
52
+ # @return [String]
53
+ attr_accessor :data
54
+
55
+ # Application specific response metadata. Must be set in the first response for
56
+ # streaming APIs.
57
+ # Corresponds to the JSON property `extensions`
58
+ # @return [Array<Hash<String,Object>>]
59
+ attr_accessor :extensions
60
+
61
+ def initialize(**args)
62
+ update!(**args)
63
+ end
64
+
65
+ # Update properties of this object
66
+ def update!(**args)
67
+ @content_type = args[:content_type] if args.key?(:content_type)
68
+ @data = args[:data] if args.key?(:data)
69
+ @extensions = args[:extensions] if args.key?(:extensions)
70
+ end
71
+ end
72
+
73
+ # Metadata for TriggerCatalogRejoin method.
74
+ class GoogleCloudRecommendationengineV1alphaRejoinCatalogMetadata
75
+ include Google::Apis::Core::Hashable
76
+
77
+ def initialize(**args)
78
+ update!(**args)
79
+ end
80
+
81
+ # Update properties of this object
82
+ def update!(**args)
83
+ end
84
+ end
85
+
86
+ # Response message for TriggerCatalogRejoin method.
87
+ class GoogleCloudRecommendationengineV1alphaRejoinCatalogResponse
88
+ include Google::Apis::Core::Hashable
89
+
90
+ # Number of user events that were joined with latest catalog items.
91
+ # Corresponds to the JSON property `rejoinedUserEventsCount`
92
+ # @return [Fixnum]
93
+ attr_accessor :rejoined_user_events_count
94
+
95
+ def initialize(**args)
96
+ update!(**args)
97
+ end
98
+
99
+ # Update properties of this object
100
+ def update!(**args)
101
+ @rejoined_user_events_count = args[:rejoined_user_events_count] if args.key?(:rejoined_user_events_count)
102
+ end
103
+ end
104
+
105
+ # Metadata associated with a tune operation.
106
+ class GoogleCloudRecommendationengineV1alphaTuningMetadata
107
+ include Google::Apis::Core::Hashable
108
+
109
+ # The resource name of the recommendation model that this tune applies to.
110
+ # Format: projects/`project_number`/locations/`location_id`/catalogs/`catalog_id`
111
+ # /eventStores/`event_store_id`/recommendationModels/`recommendation_model_id`
112
+ # Corresponds to the JSON property `recommendationModel`
113
+ # @return [String]
114
+ attr_accessor :recommendation_model
115
+
116
+ def initialize(**args)
117
+ update!(**args)
118
+ end
119
+
120
+ # Update properties of this object
121
+ def update!(**args)
122
+ @recommendation_model = args[:recommendation_model] if args.key?(:recommendation_model)
123
+ end
124
+ end
125
+
126
+ # Response associated with a tune operation.
127
+ class GoogleCloudRecommendationengineV1alphaTuningResponse
128
+ include Google::Apis::Core::Hashable
129
+
130
+ def initialize(**args)
131
+ update!(**args)
132
+ end
133
+
134
+ # Update properties of this object
135
+ def update!(**args)
136
+ end
137
+ end
138
+
139
+ # BigQuery source import data from.
140
+ class GoogleCloudRecommendationengineV1beta1BigQuerySource
141
+ include Google::Apis::Core::Hashable
142
+
143
+ # Optional. The schema to use when parsing the data from the source. Supported
144
+ # values for catalog imports: 1: "catalog_recommendations_ai" using https://
145
+ # cloud.google.com/recommendations-ai/docs/upload-catalog#json (Default for
146
+ # catalogItems.import) 2: "catalog_merchant_center" using https://cloud.google.
147
+ # com/recommendations-ai/docs/upload-catalog#mc Supported values for user event
148
+ # imports: 1: "user_events_recommendations_ai" using https://cloud.google.com/
149
+ # recommendations-ai/docs/manage-user-events#import (Default for userEvents.
150
+ # import) 2. "user_events_ga360" using https://support.google.com/analytics/
151
+ # answer/3437719?hl=en
152
+ # Corresponds to the JSON property `dataSchema`
153
+ # @return [String]
154
+ attr_accessor :data_schema
155
+
156
+ # Required. The BigQuery data set to copy the data from.
157
+ # Corresponds to the JSON property `datasetId`
158
+ # @return [String]
159
+ attr_accessor :dataset_id
160
+
161
+ # Optional. Intermediate Cloud Storage directory used for the import. Can be
162
+ # specified if one wants to have the BigQuery export to a specific Cloud Storage
163
+ # directory.
164
+ # Corresponds to the JSON property `gcsStagingDir`
165
+ # @return [String]
166
+ attr_accessor :gcs_staging_dir
167
+
168
+ # Optional. The project id (can be project # or id) that the BigQuery source is
169
+ # in. If not specified, inherits the project id from the parent request.
170
+ # Corresponds to the JSON property `projectId`
171
+ # @return [String]
172
+ attr_accessor :project_id
173
+
174
+ # Required. The BigQuery table to copy the data from.
175
+ # Corresponds to the JSON property `tableId`
176
+ # @return [String]
177
+ attr_accessor :table_id
178
+
179
+ def initialize(**args)
180
+ update!(**args)
181
+ end
182
+
183
+ # Update properties of this object
184
+ def update!(**args)
185
+ @data_schema = args[:data_schema] if args.key?(:data_schema)
186
+ @dataset_id = args[:dataset_id] if args.key?(:dataset_id)
187
+ @gcs_staging_dir = args[:gcs_staging_dir] if args.key?(:gcs_staging_dir)
188
+ @project_id = args[:project_id] if args.key?(:project_id)
189
+ @table_id = args[:table_id] if args.key?(:table_id)
190
+ end
191
+ end
192
+
193
+ # The catalog configuration. Next ID: 5.
194
+ class GoogleCloudRecommendationengineV1beta1Catalog
195
+ include Google::Apis::Core::Hashable
196
+
197
+ # Configures the catalog level that users send events to, and the level at which
198
+ # predictions are made.
199
+ # Corresponds to the JSON property `catalogItemLevelConfig`
200
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1CatalogItemLevelConfig]
201
+ attr_accessor :catalog_item_level_config
202
+
203
+ # Required. The ID of the default event store.
204
+ # Corresponds to the JSON property `defaultEventStoreId`
205
+ # @return [String]
206
+ attr_accessor :default_event_store_id
207
+
208
+ # Required. The catalog display name.
209
+ # Corresponds to the JSON property `displayName`
210
+ # @return [String]
211
+ attr_accessor :display_name
212
+
213
+ # The fully qualified resource name of the catalog.
214
+ # Corresponds to the JSON property `name`
215
+ # @return [String]
216
+ attr_accessor :name
217
+
218
+ def initialize(**args)
219
+ update!(**args)
220
+ end
221
+
222
+ # Update properties of this object
223
+ def update!(**args)
224
+ @catalog_item_level_config = args[:catalog_item_level_config] if args.key?(:catalog_item_level_config)
225
+ @default_event_store_id = args[:default_event_store_id] if args.key?(:default_event_store_id)
226
+ @display_name = args[:display_name] if args.key?(:display_name)
227
+ @name = args[:name] if args.key?(:name)
228
+ end
229
+ end
230
+
231
+ # The inline source for the input config for ImportCatalogItems method.
232
+ class GoogleCloudRecommendationengineV1beta1CatalogInlineSource
233
+ include Google::Apis::Core::Hashable
234
+
235
+ # Optional. A list of catalog items to update/create. Recommended max of 10k
236
+ # items.
237
+ # Corresponds to the JSON property `catalogItems`
238
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1CatalogItem>]
239
+ attr_accessor :catalog_items
240
+
241
+ def initialize(**args)
242
+ update!(**args)
243
+ end
244
+
245
+ # Update properties of this object
246
+ def update!(**args)
247
+ @catalog_items = args[:catalog_items] if args.key?(:catalog_items)
248
+ end
249
+ end
250
+
251
+ # CatalogItem captures all metadata information of items to be recommended.
252
+ class GoogleCloudRecommendationengineV1beta1CatalogItem
253
+ include Google::Apis::Core::Hashable
254
+
255
+ # Required. Catalog item categories. This field is repeated for supporting one
256
+ # catalog item belonging to several parallel category hierarchies. For example,
257
+ # if a shoes product belongs to both ["Shoes & Accessories" -> "Shoes"] and ["
258
+ # Sports & Fitness" -> "Athletic Clothing" -> "Shoes"], it could be represented
259
+ # as: "categoryHierarchies": [ ` "categories": ["Shoes & Accessories", "Shoes"]`,
260
+ # ` "categories": ["Sports & Fitness", "Athletic Clothing", "Shoes"] ` ]
261
+ # Corresponds to the JSON property `categoryHierarchies`
262
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1CatalogItemCategoryHierarchy>]
263
+ attr_accessor :category_hierarchies
264
+
265
+ # Optional. Catalog item description. UTF-8 encoded string with a length limit
266
+ # of 5 KiB.
267
+ # Corresponds to the JSON property `description`
268
+ # @return [String]
269
+ attr_accessor :description
270
+
271
+ # Required. Catalog item identifier. UTF-8 encoded string with a length limit of
272
+ # 128 bytes. This id must be unique among all catalog items within the same
273
+ # catalog. It should also be used when logging user events in order for the user
274
+ # events to be joined with the Catalog.
275
+ # Corresponds to the JSON property `id`
276
+ # @return [String]
277
+ attr_accessor :id
278
+
279
+ # FeatureMap represents extra features that customers want to include in the
280
+ # recommendation model for catalogs/user events as categorical/numerical
281
+ # features.
282
+ # Corresponds to the JSON property `itemAttributes`
283
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1FeatureMap]
284
+ attr_accessor :item_attributes
285
+
286
+ # Optional. Variant group identifier for prediction results. UTF-8 encoded
287
+ # string with a length limit of 128 bytes. This field must be enabled before it
288
+ # can be used. [Learn more](/recommendations-ai/docs/catalog#item-group-id).
289
+ # Corresponds to the JSON property `itemGroupId`
290
+ # @return [String]
291
+ attr_accessor :item_group_id
292
+
293
+ # Optional. Deprecated. The model automatically detects the text language. Your
294
+ # catalog can include text in different languages, but duplicating catalog items
295
+ # to provide text in multiple languages can result in degraded model performance.
296
+ # Corresponds to the JSON property `languageCode`
297
+ # @return [String]
298
+ attr_accessor :language_code
299
+
300
+ # ProductCatalogItem captures item metadata specific to retail products.
301
+ # Corresponds to the JSON property `productMetadata`
302
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ProductCatalogItem]
303
+ attr_accessor :product_metadata
304
+
305
+ # Optional. Filtering tags associated with the catalog item. Each tag should be
306
+ # a UTF-8 encoded string with a length limit of 1 KiB. This tag can be used for
307
+ # filtering recommendation results by passing the tag as part of the predict
308
+ # request filter.
309
+ # Corresponds to the JSON property `tags`
310
+ # @return [Array<String>]
311
+ attr_accessor :tags
312
+
313
+ # Required. Catalog item title. UTF-8 encoded string with a length limit of 1
314
+ # KiB.
315
+ # Corresponds to the JSON property `title`
316
+ # @return [String]
317
+ attr_accessor :title
318
+
319
+ def initialize(**args)
320
+ update!(**args)
321
+ end
322
+
323
+ # Update properties of this object
324
+ def update!(**args)
325
+ @category_hierarchies = args[:category_hierarchies] if args.key?(:category_hierarchies)
326
+ @description = args[:description] if args.key?(:description)
327
+ @id = args[:id] if args.key?(:id)
328
+ @item_attributes = args[:item_attributes] if args.key?(:item_attributes)
329
+ @item_group_id = args[:item_group_id] if args.key?(:item_group_id)
330
+ @language_code = args[:language_code] if args.key?(:language_code)
331
+ @product_metadata = args[:product_metadata] if args.key?(:product_metadata)
332
+ @tags = args[:tags] if args.key?(:tags)
333
+ @title = args[:title] if args.key?(:title)
334
+ end
335
+ end
336
+
337
+ # Category represents catalog item category hierarchy.
338
+ class GoogleCloudRecommendationengineV1beta1CatalogItemCategoryHierarchy
339
+ include Google::Apis::Core::Hashable
340
+
341
+ # Required. Catalog item categories. Each category should be a UTF-8 encoded
342
+ # string with a length limit of 2 KiB. Note that the order in the list denotes
343
+ # the specificity (from least to most specific).
344
+ # Corresponds to the JSON property `categories`
345
+ # @return [Array<String>]
346
+ attr_accessor :categories
347
+
348
+ def initialize(**args)
349
+ update!(**args)
350
+ end
351
+
352
+ # Update properties of this object
353
+ def update!(**args)
354
+ @categories = args[:categories] if args.key?(:categories)
355
+ end
356
+ end
357
+
358
+ # Configures the catalog level that users send events to, and the level at which
359
+ # predictions are made.
360
+ class GoogleCloudRecommendationengineV1beta1CatalogItemLevelConfig
361
+ include Google::Apis::Core::Hashable
362
+
363
+ # Optional. Level of the catalog at which events are uploaded. See https://cloud.
364
+ # google.com/recommendations-ai/docs/catalog#catalog-levels for more details.
365
+ # Corresponds to the JSON property `eventItemLevel`
366
+ # @return [String]
367
+ attr_accessor :event_item_level
368
+
369
+ # Optional. Level of the catalog at which predictions are made. See https://
370
+ # cloud.google.com/recommendations-ai/docs/catalog#catalog-levels for more
371
+ # details.
372
+ # Corresponds to the JSON property `predictItemLevel`
373
+ # @return [String]
374
+ attr_accessor :predict_item_level
375
+
376
+ def initialize(**args)
377
+ update!(**args)
378
+ end
379
+
380
+ # Update properties of this object
381
+ def update!(**args)
382
+ @event_item_level = args[:event_item_level] if args.key?(:event_item_level)
383
+ @predict_item_level = args[:predict_item_level] if args.key?(:predict_item_level)
384
+ end
385
+ end
386
+
387
+ # Request message for the `CreatePredictionApiKeyRegistration` method.
388
+ class GoogleCloudRecommendationengineV1beta1CreatePredictionApiKeyRegistrationRequest
389
+ include Google::Apis::Core::Hashable
390
+
391
+ # Registered Api Key.
392
+ # Corresponds to the JSON property `predictionApiKeyRegistration`
393
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1PredictionApiKeyRegistration]
394
+ attr_accessor :prediction_api_key_registration
395
+
396
+ def initialize(**args)
397
+ update!(**args)
398
+ end
399
+
400
+ # Update properties of this object
401
+ def update!(**args)
402
+ @prediction_api_key_registration = args[:prediction_api_key_registration] if args.key?(:prediction_api_key_registration)
403
+ end
404
+ end
405
+
406
+ # User event details shared by all recommendation types.
407
+ class GoogleCloudRecommendationengineV1beta1EventDetail
408
+ include Google::Apis::Core::Hashable
409
+
410
+ # FeatureMap represents extra features that customers want to include in the
411
+ # recommendation model for catalogs/user events as categorical/numerical
412
+ # features.
413
+ # Corresponds to the JSON property `eventAttributes`
414
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1FeatureMap]
415
+ attr_accessor :event_attributes
416
+
417
+ # Optional. A list of identifiers for the independent experiment groups this
418
+ # user event belongs to. This is used to distinguish between user events
419
+ # associated with different experiment setups (e.g. using Recommendation Engine
420
+ # system, using different recommendation models).
421
+ # Corresponds to the JSON property `experimentIds`
422
+ # @return [Array<String>]
423
+ attr_accessor :experiment_ids
424
+
425
+ # Optional. A unique id of a web page view. This should be kept the same for all
426
+ # user events triggered from the same pageview. For example, an item detail page
427
+ # view could trigger multiple events as the user is browsing the page. The `
428
+ # pageViewId` property should be kept the same for all these events so that they
429
+ # can be grouped together properly. This `pageViewId` will be automatically
430
+ # generated if using the JavaScript pixel.
431
+ # Corresponds to the JSON property `pageViewId`
432
+ # @return [String]
433
+ attr_accessor :page_view_id
434
+
435
+ # Optional. Recommendation token included in the recommendation prediction
436
+ # response. This field enables accurate attribution of recommendation model
437
+ # performance. This token enables us to accurately attribute page view or
438
+ # purchase back to the event and the particular predict response containing this
439
+ # clicked/purchased item. If user clicks on product K in the recommendation
440
+ # results, pass the `PredictResponse.recommendationToken` property as a url
441
+ # parameter to product K's page. When recording events on product K's page, log
442
+ # the PredictResponse.recommendation_token to this field. Optional, but highly
443
+ # encouraged for user events that are the result of a recommendation prediction
444
+ # query.
445
+ # Corresponds to the JSON property `recommendationToken`
446
+ # @return [String]
447
+ attr_accessor :recommendation_token
448
+
449
+ # Optional. The referrer url of the current page. When using the JavaScript
450
+ # pixel, this value is filled in automatically.
451
+ # Corresponds to the JSON property `referrerUri`
452
+ # @return [String]
453
+ attr_accessor :referrer_uri
454
+
455
+ # Optional. Complete url (window.location.href) of the user's current page. When
456
+ # using the JavaScript pixel, this value is filled in automatically. Maximum
457
+ # length 5KB.
458
+ # Corresponds to the JSON property `uri`
459
+ # @return [String]
460
+ attr_accessor :uri
461
+
462
+ def initialize(**args)
463
+ update!(**args)
464
+ end
465
+
466
+ # Update properties of this object
467
+ def update!(**args)
468
+ @event_attributes = args[:event_attributes] if args.key?(:event_attributes)
469
+ @experiment_ids = args[:experiment_ids] if args.key?(:experiment_ids)
470
+ @page_view_id = args[:page_view_id] if args.key?(:page_view_id)
471
+ @recommendation_token = args[:recommendation_token] if args.key?(:recommendation_token)
472
+ @referrer_uri = args[:referrer_uri] if args.key?(:referrer_uri)
473
+ @uri = args[:uri] if args.key?(:uri)
474
+ end
475
+ end
476
+
477
+ # FeatureMap represents extra features that customers want to include in the
478
+ # recommendation model for catalogs/user events as categorical/numerical
479
+ # features.
480
+ class GoogleCloudRecommendationengineV1beta1FeatureMap
481
+ include Google::Apis::Core::Hashable
482
+
483
+ # Categorical features that can take on one of a limited number of possible
484
+ # values. Some examples would be the brand/maker of a product, or country of a
485
+ # customer. Feature names and values must be UTF-8 encoded strings. For example:
486
+ # `` "colors": `"value": ["yellow", "green"]`, "sizes": `"value":["S", "M"]``
487
+ # Corresponds to the JSON property `categoricalFeatures`
488
+ # @return [Hash<String,Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1FeatureMapStringList>]
489
+ attr_accessor :categorical_features
490
+
491
+ # Numerical features. Some examples would be the height/weight of a product, or
492
+ # age of a customer. Feature names must be UTF-8 encoded strings. For example: ``
493
+ # "lengths_cm": `"value":[2.3, 15.4]`, "heights_cm": `"value":[8.1, 6.4]` ``
494
+ # Corresponds to the JSON property `numericalFeatures`
495
+ # @return [Hash<String,Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1FeatureMapFloatList>]
496
+ attr_accessor :numerical_features
497
+
498
+ def initialize(**args)
499
+ update!(**args)
500
+ end
501
+
502
+ # Update properties of this object
503
+ def update!(**args)
504
+ @categorical_features = args[:categorical_features] if args.key?(:categorical_features)
505
+ @numerical_features = args[:numerical_features] if args.key?(:numerical_features)
506
+ end
507
+ end
508
+
509
+ # A list of float features.
510
+ class GoogleCloudRecommendationengineV1beta1FeatureMapFloatList
511
+ include Google::Apis::Core::Hashable
512
+
513
+ # Float feature value.
514
+ # Corresponds to the JSON property `value`
515
+ # @return [Array<Float>]
516
+ attr_accessor :value
517
+
518
+ def initialize(**args)
519
+ update!(**args)
520
+ end
521
+
522
+ # Update properties of this object
523
+ def update!(**args)
524
+ @value = args[:value] if args.key?(:value)
525
+ end
526
+ end
527
+
528
+ # A list of string features.
529
+ class GoogleCloudRecommendationengineV1beta1FeatureMapStringList
530
+ include Google::Apis::Core::Hashable
531
+
532
+ # String feature value with a length limit of 128 bytes.
533
+ # Corresponds to the JSON property `value`
534
+ # @return [Array<String>]
535
+ attr_accessor :value
536
+
537
+ def initialize(**args)
538
+ update!(**args)
539
+ end
540
+
541
+ # Update properties of this object
542
+ def update!(**args)
543
+ @value = args[:value] if args.key?(:value)
544
+ end
545
+ end
546
+
547
+ # Google Cloud Storage location for input content. format.
548
+ class GoogleCloudRecommendationengineV1beta1GcsSource
549
+ include Google::Apis::Core::Hashable
550
+
551
+ # Required. Google Cloud Storage URIs to input files. URI can be up to 2000
552
+ # characters long. URIs can match the full object path (for example, gs://bucket/
553
+ # directory/object.json) or a pattern matching one or more files, such as gs://
554
+ # bucket/directory/*.json. A request can contain at most 100 files, and each
555
+ # file can be up to 2 GB. See [Importing catalog information](/recommendations-
556
+ # ai/docs/upload-catalog) for the expected file format and setup instructions.
557
+ # Corresponds to the JSON property `inputUris`
558
+ # @return [Array<String>]
559
+ attr_accessor :input_uris
560
+
561
+ # Optional. The schema to use when parsing the data from the source. Supported
562
+ # values for catalog imports: 1: "catalog_recommendations_ai" using https://
563
+ # cloud.google.com/recommendations-ai/docs/upload-catalog#json (Default for
564
+ # catalogItems.import) 2: "catalog_merchant_center" using https://cloud.google.
565
+ # com/recommendations-ai/docs/upload-catalog#mc Supported values for user events
566
+ # imports: 1: "user_events_recommendations_ai" using https://cloud.google.com/
567
+ # recommendations-ai/docs/manage-user-events#import (Default for userEvents.
568
+ # import) 2. "user_events_ga360" using https://support.google.com/analytics/
569
+ # answer/3437719?hl=en
570
+ # Corresponds to the JSON property `jsonSchema`
571
+ # @return [String]
572
+ attr_accessor :json_schema
573
+
574
+ def initialize(**args)
575
+ update!(**args)
576
+ end
577
+
578
+ # Update properties of this object
579
+ def update!(**args)
580
+ @input_uris = args[:input_uris] if args.key?(:input_uris)
581
+ @json_schema = args[:json_schema] if args.key?(:json_schema)
582
+ end
583
+ end
584
+
585
+ # Catalog item thumbnail/detail image.
586
+ class GoogleCloudRecommendationengineV1beta1Image
587
+ include Google::Apis::Core::Hashable
588
+
589
+ # Optional. Height of the image in number of pixels.
590
+ # Corresponds to the JSON property `height`
591
+ # @return [Fixnum]
592
+ attr_accessor :height
593
+
594
+ # Required. URL of the image with a length limit of 5 KiB.
595
+ # Corresponds to the JSON property `uri`
596
+ # @return [String]
597
+ attr_accessor :uri
598
+
599
+ # Optional. Width of the image in number of pixels.
600
+ # Corresponds to the JSON property `width`
601
+ # @return [Fixnum]
602
+ attr_accessor :width
603
+
604
+ def initialize(**args)
605
+ update!(**args)
606
+ end
607
+
608
+ # Update properties of this object
609
+ def update!(**args)
610
+ @height = args[:height] if args.key?(:height)
611
+ @uri = args[:uri] if args.key?(:uri)
612
+ @width = args[:width] if args.key?(:width)
613
+ end
614
+ end
615
+
616
+ # Request message for Import methods.
617
+ class GoogleCloudRecommendationengineV1beta1ImportCatalogItemsRequest
618
+ include Google::Apis::Core::Hashable
619
+
620
+ # Configuration of destination for Import related errors.
621
+ # Corresponds to the JSON property `errorsConfig`
622
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ImportErrorsConfig]
623
+ attr_accessor :errors_config
624
+
625
+ # The input config source.
626
+ # Corresponds to the JSON property `inputConfig`
627
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1InputConfig]
628
+ attr_accessor :input_config
629
+
630
+ # Optional. Unique identifier provided by client, within the ancestor dataset
631
+ # scope. Ensures idempotency and used for request deduplication. Server-
632
+ # generated if unspecified. Up to 128 characters long. This is returned as
633
+ # google.longrunning.Operation.name in the response.
634
+ # Corresponds to the JSON property `requestId`
635
+ # @return [String]
636
+ attr_accessor :request_id
637
+
638
+ # Optional. Indicates which fields in the provided imported 'items' to update.
639
+ # If not set, will by default update all fields.
640
+ # Corresponds to the JSON property `updateMask`
641
+ # @return [String]
642
+ attr_accessor :update_mask
643
+
644
+ def initialize(**args)
645
+ update!(**args)
646
+ end
647
+
648
+ # Update properties of this object
649
+ def update!(**args)
650
+ @errors_config = args[:errors_config] if args.key?(:errors_config)
651
+ @input_config = args[:input_config] if args.key?(:input_config)
652
+ @request_id = args[:request_id] if args.key?(:request_id)
653
+ @update_mask = args[:update_mask] if args.key?(:update_mask)
654
+ end
655
+ end
656
+
657
+ # Response of the ImportCatalogItemsRequest. If the long running operation is
658
+ # done, then this message is returned by the google.longrunning.Operations.
659
+ # response field if the operation was successful.
660
+ class GoogleCloudRecommendationengineV1beta1ImportCatalogItemsResponse
661
+ include Google::Apis::Core::Hashable
662
+
663
+ # A sample of errors encountered while processing the request.
664
+ # Corresponds to the JSON property `errorSamples`
665
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleRpcStatus>]
666
+ attr_accessor :error_samples
667
+
668
+ # Configuration of destination for Import related errors.
669
+ # Corresponds to the JSON property `errorsConfig`
670
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ImportErrorsConfig]
671
+ attr_accessor :errors_config
672
+
673
+ def initialize(**args)
674
+ update!(**args)
675
+ end
676
+
677
+ # Update properties of this object
678
+ def update!(**args)
679
+ @error_samples = args[:error_samples] if args.key?(:error_samples)
680
+ @errors_config = args[:errors_config] if args.key?(:errors_config)
681
+ end
682
+ end
683
+
684
+ # Configuration of destination for Import related errors.
685
+ class GoogleCloudRecommendationengineV1beta1ImportErrorsConfig
686
+ include Google::Apis::Core::Hashable
687
+
688
+ # Google Cloud Storage path for import errors. This must be an empty, existing
689
+ # Cloud Storage bucket. Import errors will be written to a file in this bucket,
690
+ # one per line, as a JSON-encoded `google.rpc.Status` message.
691
+ # Corresponds to the JSON property `gcsPrefix`
692
+ # @return [String]
693
+ attr_accessor :gcs_prefix
694
+
695
+ def initialize(**args)
696
+ update!(**args)
697
+ end
698
+
699
+ # Update properties of this object
700
+ def update!(**args)
701
+ @gcs_prefix = args[:gcs_prefix] if args.key?(:gcs_prefix)
702
+ end
703
+ end
704
+
705
+ # Metadata related to the progress of the Import operation. This will be
706
+ # returned by the google.longrunning.Operation.metadata field.
707
+ class GoogleCloudRecommendationengineV1beta1ImportMetadata
708
+ include Google::Apis::Core::Hashable
709
+
710
+ # Operation create time.
711
+ # Corresponds to the JSON property `createTime`
712
+ # @return [String]
713
+ attr_accessor :create_time
714
+
715
+ # Count of entries that encountered errors while processing.
716
+ # Corresponds to the JSON property `failureCount`
717
+ # @return [Fixnum]
718
+ attr_accessor :failure_count
719
+
720
+ # Name of the operation.
721
+ # Corresponds to the JSON property `operationName`
722
+ # @return [String]
723
+ attr_accessor :operation_name
724
+
725
+ # Id of the request / operation. This is parroting back the requestId that was
726
+ # passed in the request.
727
+ # Corresponds to the JSON property `requestId`
728
+ # @return [String]
729
+ attr_accessor :request_id
730
+
731
+ # Count of entries that were processed successfully.
732
+ # Corresponds to the JSON property `successCount`
733
+ # @return [Fixnum]
734
+ attr_accessor :success_count
735
+
736
+ # Operation last update time. If the operation is done, this is also the finish
737
+ # time.
738
+ # Corresponds to the JSON property `updateTime`
739
+ # @return [String]
740
+ attr_accessor :update_time
741
+
742
+ def initialize(**args)
743
+ update!(**args)
744
+ end
745
+
746
+ # Update properties of this object
747
+ def update!(**args)
748
+ @create_time = args[:create_time] if args.key?(:create_time)
749
+ @failure_count = args[:failure_count] if args.key?(:failure_count)
750
+ @operation_name = args[:operation_name] if args.key?(:operation_name)
751
+ @request_id = args[:request_id] if args.key?(:request_id)
752
+ @success_count = args[:success_count] if args.key?(:success_count)
753
+ @update_time = args[:update_time] if args.key?(:update_time)
754
+ end
755
+ end
756
+
757
+ # Request message for the ImportUserEvents request.
758
+ class GoogleCloudRecommendationengineV1beta1ImportUserEventsRequest
759
+ include Google::Apis::Core::Hashable
760
+
761
+ # Configuration of destination for Import related errors.
762
+ # Corresponds to the JSON property `errorsConfig`
763
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ImportErrorsConfig]
764
+ attr_accessor :errors_config
765
+
766
+ # The input config source.
767
+ # Corresponds to the JSON property `inputConfig`
768
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1InputConfig]
769
+ attr_accessor :input_config
770
+
771
+ # Optional. Unique identifier provided by client, within the ancestor dataset
772
+ # scope. Ensures idempotency for expensive long running operations. Server-
773
+ # generated if unspecified. Up to 128 characters long. This is returned as
774
+ # google.longrunning.Operation.name in the response. Note that this field must
775
+ # not be set if the desired input config is catalog_inline_source.
776
+ # Corresponds to the JSON property `requestId`
777
+ # @return [String]
778
+ attr_accessor :request_id
779
+
780
+ def initialize(**args)
781
+ update!(**args)
782
+ end
783
+
784
+ # Update properties of this object
785
+ def update!(**args)
786
+ @errors_config = args[:errors_config] if args.key?(:errors_config)
787
+ @input_config = args[:input_config] if args.key?(:input_config)
788
+ @request_id = args[:request_id] if args.key?(:request_id)
789
+ end
790
+ end
791
+
792
+ # Response of the ImportUserEventsRequest. If the long running operation was
793
+ # successful, then this message is returned by the google.longrunning.Operations.
794
+ # response field if the operation was successful.
795
+ class GoogleCloudRecommendationengineV1beta1ImportUserEventsResponse
796
+ include Google::Apis::Core::Hashable
797
+
798
+ # A sample of errors encountered while processing the request.
799
+ # Corresponds to the JSON property `errorSamples`
800
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleRpcStatus>]
801
+ attr_accessor :error_samples
802
+
803
+ # Configuration of destination for Import related errors.
804
+ # Corresponds to the JSON property `errorsConfig`
805
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ImportErrorsConfig]
806
+ attr_accessor :errors_config
807
+
808
+ # A summary of import result. The UserEventImportSummary summarizes the import
809
+ # status for user events.
810
+ # Corresponds to the JSON property `importSummary`
811
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1UserEventImportSummary]
812
+ attr_accessor :import_summary
813
+
814
+ def initialize(**args)
815
+ update!(**args)
816
+ end
817
+
818
+ # Update properties of this object
819
+ def update!(**args)
820
+ @error_samples = args[:error_samples] if args.key?(:error_samples)
821
+ @errors_config = args[:errors_config] if args.key?(:errors_config)
822
+ @import_summary = args[:import_summary] if args.key?(:import_summary)
823
+ end
824
+ end
825
+
826
+ # The input config source.
827
+ class GoogleCloudRecommendationengineV1beta1InputConfig
828
+ include Google::Apis::Core::Hashable
829
+
830
+ # BigQuery source import data from.
831
+ # Corresponds to the JSON property `bigQuerySource`
832
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1BigQuerySource]
833
+ attr_accessor :big_query_source
834
+
835
+ # The inline source for the input config for ImportCatalogItems method.
836
+ # Corresponds to the JSON property `catalogInlineSource`
837
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1CatalogInlineSource]
838
+ attr_accessor :catalog_inline_source
839
+
840
+ # Google Cloud Storage location for input content. format.
841
+ # Corresponds to the JSON property `gcsSource`
842
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1GcsSource]
843
+ attr_accessor :gcs_source
844
+
845
+ # The inline source for the input config for ImportUserEvents method.
846
+ # Corresponds to the JSON property `userEventInlineSource`
847
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1UserEventInlineSource]
848
+ attr_accessor :user_event_inline_source
849
+
850
+ def initialize(**args)
851
+ update!(**args)
852
+ end
853
+
854
+ # Update properties of this object
855
+ def update!(**args)
856
+ @big_query_source = args[:big_query_source] if args.key?(:big_query_source)
857
+ @catalog_inline_source = args[:catalog_inline_source] if args.key?(:catalog_inline_source)
858
+ @gcs_source = args[:gcs_source] if args.key?(:gcs_source)
859
+ @user_event_inline_source = args[:user_event_inline_source] if args.key?(:user_event_inline_source)
860
+ end
861
+ end
862
+
863
+ # Response message for ListCatalogItems method.
864
+ class GoogleCloudRecommendationengineV1beta1ListCatalogItemsResponse
865
+ include Google::Apis::Core::Hashable
866
+
867
+ # The catalog items.
868
+ # Corresponds to the JSON property `catalogItems`
869
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1CatalogItem>]
870
+ attr_accessor :catalog_items
871
+
872
+ # If empty, the list is complete. If nonempty, the token to pass to the next
873
+ # request's ListCatalogItemRequest.page_token.
874
+ # Corresponds to the JSON property `nextPageToken`
875
+ # @return [String]
876
+ attr_accessor :next_page_token
877
+
878
+ def initialize(**args)
879
+ update!(**args)
880
+ end
881
+
882
+ # Update properties of this object
883
+ def update!(**args)
884
+ @catalog_items = args[:catalog_items] if args.key?(:catalog_items)
885
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
886
+ end
887
+ end
888
+
889
+ # Response for ListCatalogs method.
890
+ class GoogleCloudRecommendationengineV1beta1ListCatalogsResponse
891
+ include Google::Apis::Core::Hashable
892
+
893
+ # Output only. All the customer's catalogs.
894
+ # Corresponds to the JSON property `catalogs`
895
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1Catalog>]
896
+ attr_accessor :catalogs
897
+
898
+ # Pagination token, if not returned indicates the last page.
899
+ # Corresponds to the JSON property `nextPageToken`
900
+ # @return [String]
901
+ attr_accessor :next_page_token
902
+
903
+ def initialize(**args)
904
+ update!(**args)
905
+ end
906
+
907
+ # Update properties of this object
908
+ def update!(**args)
909
+ @catalogs = args[:catalogs] if args.key?(:catalogs)
910
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
911
+ end
912
+ end
913
+
914
+ # Response message for the `ListPredictionApiKeyRegistrations`.
915
+ class GoogleCloudRecommendationengineV1beta1ListPredictionApiKeyRegistrationsResponse
916
+ include Google::Apis::Core::Hashable
917
+
918
+ # If empty, the list is complete. If nonempty, pass the token to the next
919
+ # request's `ListPredictionApiKeysRegistrationsRequest.pageToken`.
920
+ # Corresponds to the JSON property `nextPageToken`
921
+ # @return [String]
922
+ attr_accessor :next_page_token
923
+
924
+ # The list of registered API keys.
925
+ # Corresponds to the JSON property `predictionApiKeyRegistrations`
926
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1PredictionApiKeyRegistration>]
927
+ attr_accessor :prediction_api_key_registrations
928
+
929
+ def initialize(**args)
930
+ update!(**args)
931
+ end
932
+
933
+ # Update properties of this object
934
+ def update!(**args)
935
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
936
+ @prediction_api_key_registrations = args[:prediction_api_key_registrations] if args.key?(:prediction_api_key_registrations)
937
+ end
938
+ end
939
+
940
+ # Response message for ListUserEvents method.
941
+ class GoogleCloudRecommendationengineV1beta1ListUserEventsResponse
942
+ include Google::Apis::Core::Hashable
943
+
944
+ # If empty, the list is complete. If nonempty, the token to pass to the next
945
+ # request's ListUserEvents.page_token.
946
+ # Corresponds to the JSON property `nextPageToken`
947
+ # @return [String]
948
+ attr_accessor :next_page_token
949
+
950
+ # The user events.
951
+ # Corresponds to the JSON property `userEvents`
952
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1UserEvent>]
953
+ attr_accessor :user_events
954
+
955
+ def initialize(**args)
956
+ update!(**args)
957
+ end
958
+
959
+ # Update properties of this object
960
+ def update!(**args)
961
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
962
+ @user_events = args[:user_events] if args.key?(:user_events)
963
+ end
964
+ end
965
+
966
+ # Request message for Predict method.
967
+ class GoogleCloudRecommendationengineV1beta1PredictRequest
968
+ include Google::Apis::Core::Hashable
969
+
970
+ # Optional. Use dryRun mode for this prediction query. If set to true, a dummy
971
+ # model will be used that returns arbitrary catalog items. Note that the dryRun
972
+ # mode should only be used for testing the API, or if the model is not ready.
973
+ # Corresponds to the JSON property `dryRun`
974
+ # @return [Boolean]
975
+ attr_accessor :dry_run
976
+ alias_method :dry_run?, :dry_run
977
+
978
+ # Optional. Filter for restricting prediction results. Accepts values for tags
979
+ # and the `filterOutOfStockItems` flag. * Tag expressions. Restricts predictions
980
+ # to items that match all of the specified tags. Boolean operators `OR` and `NOT`
981
+ # are supported if the expression is enclosed in parentheses, and must be
982
+ # separated from the tag values by a space. `-"tagA"` is also supported and is
983
+ # equivalent to `NOT "tagA"`. Tag values must be double quoted UTF-8 encoded
984
+ # strings with a size limit of 1 KiB. * filterOutOfStockItems. Restricts
985
+ # predictions to items that do not have a stockState value of OUT_OF_STOCK.
986
+ # Examples: * tag=("Red" OR "Blue") tag="New-Arrival" tag=(NOT "promotional") *
987
+ # filterOutOfStockItems tag=(-"promotional") * filterOutOfStockItems If your
988
+ # filter blocks all prediction results, nothing will be returned. If you want
989
+ # generic (unfiltered) popular items to be returned instead, set `
990
+ # strictFiltering` to false in `PredictRequest.params`.
991
+ # Corresponds to the JSON property `filter`
992
+ # @return [String]
993
+ attr_accessor :filter
994
+
995
+ # Optional. The labels for the predict request. * Label keys can contain
996
+ # lowercase letters, digits and hyphens, must start with a letter, and must end
997
+ # with a letter or digit. * Non-zero label values can contain lowercase letters,
998
+ # digits and hyphens, must start with a letter, and must end with a letter or
999
+ # digit. * No more than 64 labels can be associated with a given request. See
1000
+ # https://goo.gl/xmQnxf for more information on and examples of labels.
1001
+ # Corresponds to the JSON property `labels`
1002
+ # @return [Hash<String,String>]
1003
+ attr_accessor :labels
1004
+
1005
+ # Optional. Maximum number of results to return per page. Set this property to
1006
+ # the number of prediction results required. If zero, the service will choose a
1007
+ # reasonable default.
1008
+ # Corresponds to the JSON property `pageSize`
1009
+ # @return [Fixnum]
1010
+ attr_accessor :page_size
1011
+
1012
+ # Optional. The previous PredictResponse.next_page_token.
1013
+ # Corresponds to the JSON property `pageToken`
1014
+ # @return [String]
1015
+ attr_accessor :page_token
1016
+
1017
+ # Optional. Additional domain specific parameters for the predictions. Allowed
1018
+ # values: * `returnCatalogItem`: Boolean. If set to true, the associated
1019
+ # catalogItem object will be returned in the `PredictResponse.PredictionResult.
1020
+ # itemMetadata` object in the method response. * `returnItemScore`: Boolean. If
1021
+ # set to true, the prediction 'score' corresponding to each returned item will
1022
+ # be set in the `metadata` field in the prediction response. The given 'score'
1023
+ # indicates the probability of an item being clicked/purchased given the user's
1024
+ # context and history. * `strictFiltering`: Boolean. True by default. If set to
1025
+ # false, the service will return generic (unfiltered) popular items instead of
1026
+ # empty if your filter blocks all prediction results.
1027
+ # Corresponds to the JSON property `params`
1028
+ # @return [Hash<String,Object>]
1029
+ attr_accessor :params
1030
+
1031
+ # UserEvent captures all metadata information recommendation engine needs to
1032
+ # know about how end users interact with customers' website.
1033
+ # Corresponds to the JSON property `userEvent`
1034
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1UserEvent]
1035
+ attr_accessor :user_event
1036
+
1037
+ def initialize(**args)
1038
+ update!(**args)
1039
+ end
1040
+
1041
+ # Update properties of this object
1042
+ def update!(**args)
1043
+ @dry_run = args[:dry_run] if args.key?(:dry_run)
1044
+ @filter = args[:filter] if args.key?(:filter)
1045
+ @labels = args[:labels] if args.key?(:labels)
1046
+ @page_size = args[:page_size] if args.key?(:page_size)
1047
+ @page_token = args[:page_token] if args.key?(:page_token)
1048
+ @params = args[:params] if args.key?(:params)
1049
+ @user_event = args[:user_event] if args.key?(:user_event)
1050
+ end
1051
+ end
1052
+
1053
+ # Response message for predict method.
1054
+ class GoogleCloudRecommendationengineV1beta1PredictResponse
1055
+ include Google::Apis::Core::Hashable
1056
+
1057
+ # True if the dryRun property was set in the request.
1058
+ # Corresponds to the JSON property `dryRun`
1059
+ # @return [Boolean]
1060
+ attr_accessor :dry_run
1061
+ alias_method :dry_run?, :dry_run
1062
+
1063
+ # IDs of items in the request that were missing from the catalog.
1064
+ # Corresponds to the JSON property `itemsMissingInCatalog`
1065
+ # @return [Array<String>]
1066
+ attr_accessor :items_missing_in_catalog
1067
+
1068
+ # Additional domain specific prediction response metadata.
1069
+ # Corresponds to the JSON property `metadata`
1070
+ # @return [Hash<String,Object>]
1071
+ attr_accessor :metadata
1072
+
1073
+ # If empty, the list is complete. If nonempty, the token to pass to the next
1074
+ # request's PredictRequest.page_token.
1075
+ # Corresponds to the JSON property `nextPageToken`
1076
+ # @return [String]
1077
+ attr_accessor :next_page_token
1078
+
1079
+ # A unique recommendation token. This should be included in the user event logs
1080
+ # resulting from this recommendation, which enables accurate attribution of
1081
+ # recommendation model performance.
1082
+ # Corresponds to the JSON property `recommendationToken`
1083
+ # @return [String]
1084
+ attr_accessor :recommendation_token
1085
+
1086
+ # A list of recommended items. The order represents the ranking (from the most
1087
+ # relevant item to the least).
1088
+ # Corresponds to the JSON property `results`
1089
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1PredictResponsePredictionResult>]
1090
+ attr_accessor :results
1091
+
1092
+ def initialize(**args)
1093
+ update!(**args)
1094
+ end
1095
+
1096
+ # Update properties of this object
1097
+ def update!(**args)
1098
+ @dry_run = args[:dry_run] if args.key?(:dry_run)
1099
+ @items_missing_in_catalog = args[:items_missing_in_catalog] if args.key?(:items_missing_in_catalog)
1100
+ @metadata = args[:metadata] if args.key?(:metadata)
1101
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1102
+ @recommendation_token = args[:recommendation_token] if args.key?(:recommendation_token)
1103
+ @results = args[:results] if args.key?(:results)
1104
+ end
1105
+ end
1106
+
1107
+ # PredictionResult represents the recommendation prediction results.
1108
+ class GoogleCloudRecommendationengineV1beta1PredictResponsePredictionResult
1109
+ include Google::Apis::Core::Hashable
1110
+
1111
+ # ID of the recommended catalog item
1112
+ # Corresponds to the JSON property `id`
1113
+ # @return [String]
1114
+ attr_accessor :id
1115
+
1116
+ # Additional item metadata / annotations. Possible values: * `catalogItem`: JSON
1117
+ # representation of the catalogItem. Will be set if `returnCatalogItem` is set
1118
+ # to true in `PredictRequest.params`. * `score`: Prediction score in double
1119
+ # value. Will be set if `returnItemScore` is set to true in `PredictRequest.
1120
+ # params`.
1121
+ # Corresponds to the JSON property `itemMetadata`
1122
+ # @return [Hash<String,Object>]
1123
+ attr_accessor :item_metadata
1124
+
1125
+ def initialize(**args)
1126
+ update!(**args)
1127
+ end
1128
+
1129
+ # Update properties of this object
1130
+ def update!(**args)
1131
+ @id = args[:id] if args.key?(:id)
1132
+ @item_metadata = args[:item_metadata] if args.key?(:item_metadata)
1133
+ end
1134
+ end
1135
+
1136
+ # Registered Api Key.
1137
+ class GoogleCloudRecommendationengineV1beta1PredictionApiKeyRegistration
1138
+ include Google::Apis::Core::Hashable
1139
+
1140
+ # The API key.
1141
+ # Corresponds to the JSON property `apiKey`
1142
+ # @return [String]
1143
+ attr_accessor :api_key
1144
+
1145
+ def initialize(**args)
1146
+ update!(**args)
1147
+ end
1148
+
1149
+ # Update properties of this object
1150
+ def update!(**args)
1151
+ @api_key = args[:api_key] if args.key?(:api_key)
1152
+ end
1153
+ end
1154
+
1155
+ # ProductCatalogItem captures item metadata specific to retail products.
1156
+ class GoogleCloudRecommendationengineV1beta1ProductCatalogItem
1157
+ include Google::Apis::Core::Hashable
1158
+
1159
+ # Optional. The available quantity of the item.
1160
+ # Corresponds to the JSON property `availableQuantity`
1161
+ # @return [Fixnum]
1162
+ attr_accessor :available_quantity
1163
+
1164
+ # Optional. Canonical URL directly linking to the item detail page with a length
1165
+ # limit of 5 KiB..
1166
+ # Corresponds to the JSON property `canonicalProductUri`
1167
+ # @return [String]
1168
+ attr_accessor :canonical_product_uri
1169
+
1170
+ # Optional. A map to pass the costs associated with the product. For example: `"
1171
+ # manufacturing": 45.5` The profit of selling this item is computed like so: *
1172
+ # If 'exactPrice' is provided, profit = displayPrice - sum(costs) * If '
1173
+ # priceRange' is provided, profit = minPrice - sum(costs)
1174
+ # Corresponds to the JSON property `costs`
1175
+ # @return [Hash<String,Float>]
1176
+ attr_accessor :costs
1177
+
1178
+ # Optional. Only required if the price is set. Currency code for price/costs.
1179
+ # Use three-character ISO-4217 code.
1180
+ # Corresponds to the JSON property `currencyCode`
1181
+ # @return [String]
1182
+ attr_accessor :currency_code
1183
+
1184
+ # Exact product price.
1185
+ # Corresponds to the JSON property `exactPrice`
1186
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ProductCatalogItemExactPrice]
1187
+ attr_accessor :exact_price
1188
+
1189
+ # Optional. Product images for the catalog item.
1190
+ # Corresponds to the JSON property `images`
1191
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1Image>]
1192
+ attr_accessor :images
1193
+
1194
+ # Product price range when there are a range of prices for different variations
1195
+ # of the same product.
1196
+ # Corresponds to the JSON property `priceRange`
1197
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ProductCatalogItemPriceRange]
1198
+ attr_accessor :price_range
1199
+
1200
+ # Optional. Online stock state of the catalog item. Default is `IN_STOCK`.
1201
+ # Corresponds to the JSON property `stockState`
1202
+ # @return [String]
1203
+ attr_accessor :stock_state
1204
+
1205
+ def initialize(**args)
1206
+ update!(**args)
1207
+ end
1208
+
1209
+ # Update properties of this object
1210
+ def update!(**args)
1211
+ @available_quantity = args[:available_quantity] if args.key?(:available_quantity)
1212
+ @canonical_product_uri = args[:canonical_product_uri] if args.key?(:canonical_product_uri)
1213
+ @costs = args[:costs] if args.key?(:costs)
1214
+ @currency_code = args[:currency_code] if args.key?(:currency_code)
1215
+ @exact_price = args[:exact_price] if args.key?(:exact_price)
1216
+ @images = args[:images] if args.key?(:images)
1217
+ @price_range = args[:price_range] if args.key?(:price_range)
1218
+ @stock_state = args[:stock_state] if args.key?(:stock_state)
1219
+ end
1220
+ end
1221
+
1222
+ # Exact product price.
1223
+ class GoogleCloudRecommendationengineV1beta1ProductCatalogItemExactPrice
1224
+ include Google::Apis::Core::Hashable
1225
+
1226
+ # Optional. Display price of the product.
1227
+ # Corresponds to the JSON property `displayPrice`
1228
+ # @return [Float]
1229
+ attr_accessor :display_price
1230
+
1231
+ # Optional. Price of the product without any discount. If zero, by default set
1232
+ # to be the 'displayPrice'.
1233
+ # Corresponds to the JSON property `originalPrice`
1234
+ # @return [Float]
1235
+ attr_accessor :original_price
1236
+
1237
+ def initialize(**args)
1238
+ update!(**args)
1239
+ end
1240
+
1241
+ # Update properties of this object
1242
+ def update!(**args)
1243
+ @display_price = args[:display_price] if args.key?(:display_price)
1244
+ @original_price = args[:original_price] if args.key?(:original_price)
1245
+ end
1246
+ end
1247
+
1248
+ # Product price range when there are a range of prices for different variations
1249
+ # of the same product.
1250
+ class GoogleCloudRecommendationengineV1beta1ProductCatalogItemPriceRange
1251
+ include Google::Apis::Core::Hashable
1252
+
1253
+ # Required. The maximum product price.
1254
+ # Corresponds to the JSON property `max`
1255
+ # @return [Float]
1256
+ attr_accessor :max
1257
+
1258
+ # Required. The minimum product price.
1259
+ # Corresponds to the JSON property `min`
1260
+ # @return [Float]
1261
+ attr_accessor :min
1262
+
1263
+ def initialize(**args)
1264
+ update!(**args)
1265
+ end
1266
+
1267
+ # Update properties of this object
1268
+ def update!(**args)
1269
+ @max = args[:max] if args.key?(:max)
1270
+ @min = args[:min] if args.key?(:min)
1271
+ end
1272
+ end
1273
+
1274
+ # Detailed product information associated with a user event.
1275
+ class GoogleCloudRecommendationengineV1beta1ProductDetail
1276
+ include Google::Apis::Core::Hashable
1277
+
1278
+ # Optional. Quantity of the products in stock when a user event happens.
1279
+ # Optional. If provided, this overrides the available quantity in Catalog for
1280
+ # this event. and can only be set if `stock_status` is set to `IN_STOCK`. Note
1281
+ # that if an item is out of stock, you must set the `stock_state` field to be `
1282
+ # OUT_OF_STOCK`. Leaving this field unspecified / as zero is not sufficient to
1283
+ # mark the item out of stock.
1284
+ # Corresponds to the JSON property `availableQuantity`
1285
+ # @return [Fixnum]
1286
+ attr_accessor :available_quantity
1287
+
1288
+ # Optional. Currency code for price/costs. Use three-character ISO-4217 code.
1289
+ # Required only if originalPrice or displayPrice is set.
1290
+ # Corresponds to the JSON property `currencyCode`
1291
+ # @return [String]
1292
+ attr_accessor :currency_code
1293
+
1294
+ # Optional. Display price of the product (e.g. discounted price). If provided,
1295
+ # this will override the display price in Catalog for this product.
1296
+ # Corresponds to the JSON property `displayPrice`
1297
+ # @return [Float]
1298
+ attr_accessor :display_price
1299
+
1300
+ # Required. Catalog item ID. UTF-8 encoded string with a length limit of 128
1301
+ # characters.
1302
+ # Corresponds to the JSON property `id`
1303
+ # @return [String]
1304
+ attr_accessor :id
1305
+
1306
+ # FeatureMap represents extra features that customers want to include in the
1307
+ # recommendation model for catalogs/user events as categorical/numerical
1308
+ # features.
1309
+ # Corresponds to the JSON property `itemAttributes`
1310
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1FeatureMap]
1311
+ attr_accessor :item_attributes
1312
+
1313
+ # Optional. Original price of the product. If provided, this will override the
1314
+ # original price in Catalog for this product.
1315
+ # Corresponds to the JSON property `originalPrice`
1316
+ # @return [Float]
1317
+ attr_accessor :original_price
1318
+
1319
+ # Optional. Quantity of the product associated with the user event. For example,
1320
+ # this field will be 2 if two products are added to the shopping cart for `add-
1321
+ # to-cart` event. Required for `add-to-cart`, `add-to-list`, `remove-from-cart`,
1322
+ # `checkout-start`, `purchase-complete`, `refund` event types.
1323
+ # Corresponds to the JSON property `quantity`
1324
+ # @return [Fixnum]
1325
+ attr_accessor :quantity
1326
+
1327
+ # Optional. Item stock state. If provided, this overrides the stock state in
1328
+ # Catalog for items in this event.
1329
+ # Corresponds to the JSON property `stockState`
1330
+ # @return [String]
1331
+ attr_accessor :stock_state
1332
+
1333
+ def initialize(**args)
1334
+ update!(**args)
1335
+ end
1336
+
1337
+ # Update properties of this object
1338
+ def update!(**args)
1339
+ @available_quantity = args[:available_quantity] if args.key?(:available_quantity)
1340
+ @currency_code = args[:currency_code] if args.key?(:currency_code)
1341
+ @display_price = args[:display_price] if args.key?(:display_price)
1342
+ @id = args[:id] if args.key?(:id)
1343
+ @item_attributes = args[:item_attributes] if args.key?(:item_attributes)
1344
+ @original_price = args[:original_price] if args.key?(:original_price)
1345
+ @quantity = args[:quantity] if args.key?(:quantity)
1346
+ @stock_state = args[:stock_state] if args.key?(:stock_state)
1347
+ end
1348
+ end
1349
+
1350
+ # ProductEventDetail captures user event information specific to retail products.
1351
+ class GoogleCloudRecommendationengineV1beta1ProductEventDetail
1352
+ include Google::Apis::Core::Hashable
1353
+
1354
+ # Optional. The id or name of the associated shopping cart. This id is used to
1355
+ # associate multiple items added or present in the cart before purchase. This
1356
+ # can only be set for `add-to-cart`, `remove-from-cart`, `checkout-start`, `
1357
+ # purchase-complete`, or `shopping-cart-page-view` events.
1358
+ # Corresponds to the JSON property `cartId`
1359
+ # @return [String]
1360
+ attr_accessor :cart_id
1361
+
1362
+ # Required for `add-to-list` and `remove-from-list` events. The id or name of
1363
+ # the list that the item is being added to or removed from. Other event types
1364
+ # should not set this field.
1365
+ # Corresponds to the JSON property `listId`
1366
+ # @return [String]
1367
+ attr_accessor :list_id
1368
+
1369
+ # Required for `category-page-view` events. Other event types should not set
1370
+ # this field. The categories associated with a category page. Category pages
1371
+ # include special pages such as sales or promotions. For instance, a special
1372
+ # sale page may have the category hierarchy: categories : ["Sales", "2017 Black
1373
+ # Friday Deals"].
1374
+ # Corresponds to the JSON property `pageCategories`
1375
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1CatalogItemCategoryHierarchy>]
1376
+ attr_accessor :page_categories
1377
+
1378
+ # The main product details related to the event. This field is required for the
1379
+ # following event types: * `add-to-cart` * `add-to-list` * `checkout-start` * `
1380
+ # detail-page-view` * `purchase-complete` * `refund` * `remove-from-cart` * `
1381
+ # remove-from-list` This field is optional for the following event types: * `
1382
+ # page-visit` * `shopping-cart-page-view` - note that 'product_details' should
1383
+ # be set for this unless the shopping cart is empty. * `search` (highly
1384
+ # encouraged) In a `search` event, this field represents the products returned
1385
+ # to the end user on the current page (the end user may have not finished
1386
+ # broswing the whole page yet). When a new page is returned to the end user,
1387
+ # after pagination/filtering/ordering even for the same query, a new SEARCH
1388
+ # event with different product_details is desired. The end user may have not
1389
+ # finished broswing the whole page yet. This field is not allowed for the
1390
+ # following event types: * `category-page-view` * `home-page-view`
1391
+ # Corresponds to the JSON property `productDetails`
1392
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ProductDetail>]
1393
+ attr_accessor :product_details
1394
+
1395
+ # A transaction represents the entire purchase transaction.
1396
+ # Corresponds to the JSON property `purchaseTransaction`
1397
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1PurchaseTransaction]
1398
+ attr_accessor :purchase_transaction
1399
+
1400
+ # Required for `search` events. Other event types should not set this field. The
1401
+ # user's search query as UTF-8 encoded text with a length limit of 5 KiB.
1402
+ # Corresponds to the JSON property `searchQuery`
1403
+ # @return [String]
1404
+ attr_accessor :search_query
1405
+
1406
+ def initialize(**args)
1407
+ update!(**args)
1408
+ end
1409
+
1410
+ # Update properties of this object
1411
+ def update!(**args)
1412
+ @cart_id = args[:cart_id] if args.key?(:cart_id)
1413
+ @list_id = args[:list_id] if args.key?(:list_id)
1414
+ @page_categories = args[:page_categories] if args.key?(:page_categories)
1415
+ @product_details = args[:product_details] if args.key?(:product_details)
1416
+ @purchase_transaction = args[:purchase_transaction] if args.key?(:purchase_transaction)
1417
+ @search_query = args[:search_query] if args.key?(:search_query)
1418
+ end
1419
+ end
1420
+
1421
+ # A transaction represents the entire purchase transaction.
1422
+ class GoogleCloudRecommendationengineV1beta1PurchaseTransaction
1423
+ include Google::Apis::Core::Hashable
1424
+
1425
+ # Optional. All the costs associated with the product. These can be
1426
+ # manufacturing costs, shipping expenses not borne by the end user, or any other
1427
+ # costs. Total product cost such that profit = revenue - (sum(taxes) + sum(costs)
1428
+ # ) If product_cost is not set, then profit = revenue - tax - shipping - sum(
1429
+ # CatalogItem.costs). If CatalogItem.cost is not specified for one of the items,
1430
+ # CatalogItem.cost based profit *cannot* be calculated for this Transaction.
1431
+ # Corresponds to the JSON property `costs`
1432
+ # @return [Hash<String,Float>]
1433
+ attr_accessor :costs
1434
+
1435
+ # Required. Currency code. Use three-character ISO-4217 code. This field is not
1436
+ # required if the event type is `refund`.
1437
+ # Corresponds to the JSON property `currencyCode`
1438
+ # @return [String]
1439
+ attr_accessor :currency_code
1440
+
1441
+ # Optional. The transaction ID with a length limit of 128 bytes.
1442
+ # Corresponds to the JSON property `id`
1443
+ # @return [String]
1444
+ attr_accessor :id
1445
+
1446
+ # Required. Total revenue or grand total associated with the transaction. This
1447
+ # value include shipping, tax, or other adjustments to total revenue that you
1448
+ # want to include as part of your revenue calculations. This field is not
1449
+ # required if the event type is `refund`.
1450
+ # Corresponds to the JSON property `revenue`
1451
+ # @return [Float]
1452
+ attr_accessor :revenue
1453
+
1454
+ # Optional. All the taxes associated with the transaction.
1455
+ # Corresponds to the JSON property `taxes`
1456
+ # @return [Hash<String,Float>]
1457
+ attr_accessor :taxes
1458
+
1459
+ def initialize(**args)
1460
+ update!(**args)
1461
+ end
1462
+
1463
+ # Update properties of this object
1464
+ def update!(**args)
1465
+ @costs = args[:costs] if args.key?(:costs)
1466
+ @currency_code = args[:currency_code] if args.key?(:currency_code)
1467
+ @id = args[:id] if args.key?(:id)
1468
+ @revenue = args[:revenue] if args.key?(:revenue)
1469
+ @taxes = args[:taxes] if args.key?(:taxes)
1470
+ end
1471
+ end
1472
+
1473
+ # Metadata related to the progress of the PurgeUserEvents operation. This will
1474
+ # be returned by the google.longrunning.Operation.metadata field.
1475
+ class GoogleCloudRecommendationengineV1beta1PurgeUserEventsMetadata
1476
+ include Google::Apis::Core::Hashable
1477
+
1478
+ # Operation create time.
1479
+ # Corresponds to the JSON property `createTime`
1480
+ # @return [String]
1481
+ attr_accessor :create_time
1482
+
1483
+ # The ID of the request / operation.
1484
+ # Corresponds to the JSON property `operationName`
1485
+ # @return [String]
1486
+ attr_accessor :operation_name
1487
+
1488
+ def initialize(**args)
1489
+ update!(**args)
1490
+ end
1491
+
1492
+ # Update properties of this object
1493
+ def update!(**args)
1494
+ @create_time = args[:create_time] if args.key?(:create_time)
1495
+ @operation_name = args[:operation_name] if args.key?(:operation_name)
1496
+ end
1497
+ end
1498
+
1499
+ # Request message for PurgeUserEvents method.
1500
+ class GoogleCloudRecommendationengineV1beta1PurgeUserEventsRequest
1501
+ include Google::Apis::Core::Hashable
1502
+
1503
+ # Required. The filter string to specify the events to be deleted. Empty string
1504
+ # filter is not allowed. The eligible fields for filtering are: * `eventType`:
1505
+ # UserEvent.eventType field of type string. * `eventTime`: in ISO 8601 "zulu"
1506
+ # format. * `visitorId`: field of type string. Specifying this will delete all
1507
+ # events associated with a visitor. * `userId`: field of type string. Specifying
1508
+ # this will delete all events associated with a user. Examples: * Deleting all
1509
+ # events in a time range: `eventTime > "2012-04-23T18:25:43.511Z" eventTime < "
1510
+ # 2012-04-23T18:30:43.511Z"` * Deleting specific eventType in time range: `
1511
+ # eventTime > "2012-04-23T18:25:43.511Z" eventType = "detail-page-view"` *
1512
+ # Deleting all events for a specific visitor: `visitorId = "visitor1024"` The
1513
+ # filtering fields are assumed to have an implicit AND.
1514
+ # Corresponds to the JSON property `filter`
1515
+ # @return [String]
1516
+ attr_accessor :filter
1517
+
1518
+ # Optional. The default value is false. Override this flag to true to actually
1519
+ # perform the purge. If the field is not set to true, a sampling of events to be
1520
+ # deleted will be returned.
1521
+ # Corresponds to the JSON property `force`
1522
+ # @return [Boolean]
1523
+ attr_accessor :force
1524
+ alias_method :force?, :force
1525
+
1526
+ def initialize(**args)
1527
+ update!(**args)
1528
+ end
1529
+
1530
+ # Update properties of this object
1531
+ def update!(**args)
1532
+ @filter = args[:filter] if args.key?(:filter)
1533
+ @force = args[:force] if args.key?(:force)
1534
+ end
1535
+ end
1536
+
1537
+ # Response of the PurgeUserEventsRequest. If the long running operation is
1538
+ # successfully done, then this message is returned by the google.longrunning.
1539
+ # Operations.response field.
1540
+ class GoogleCloudRecommendationengineV1beta1PurgeUserEventsResponse
1541
+ include Google::Apis::Core::Hashable
1542
+
1543
+ # The total count of events purged as a result of the operation.
1544
+ # Corresponds to the JSON property `purgedEventsCount`
1545
+ # @return [Fixnum]
1546
+ attr_accessor :purged_events_count
1547
+
1548
+ # A sampling of events deleted (or will be deleted) depending on the `force`
1549
+ # property in the request. Max of 500 items will be returned.
1550
+ # Corresponds to the JSON property `userEventsSample`
1551
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1UserEvent>]
1552
+ attr_accessor :user_events_sample
1553
+
1554
+ def initialize(**args)
1555
+ update!(**args)
1556
+ end
1557
+
1558
+ # Update properties of this object
1559
+ def update!(**args)
1560
+ @purged_events_count = args[:purged_events_count] if args.key?(:purged_events_count)
1561
+ @user_events_sample = args[:user_events_sample] if args.key?(:user_events_sample)
1562
+ end
1563
+ end
1564
+
1565
+ # Metadata for RejoinUserEvents method.
1566
+ class GoogleCloudRecommendationengineV1beta1RejoinUserEventsMetadata
1567
+ include Google::Apis::Core::Hashable
1568
+
1569
+ def initialize(**args)
1570
+ update!(**args)
1571
+ end
1572
+
1573
+ # Update properties of this object
1574
+ def update!(**args)
1575
+ end
1576
+ end
1577
+
1578
+ # Request message for CatalogRejoin method.
1579
+ class GoogleCloudRecommendationengineV1beta1RejoinUserEventsRequest
1580
+ include Google::Apis::Core::Hashable
1581
+
1582
+ # Required. The type of the catalog rejoin to define the scope and range of the
1583
+ # user events to be rejoined with catalog items.
1584
+ # Corresponds to the JSON property `userEventRejoinScope`
1585
+ # @return [String]
1586
+ attr_accessor :user_event_rejoin_scope
1587
+
1588
+ def initialize(**args)
1589
+ update!(**args)
1590
+ end
1591
+
1592
+ # Update properties of this object
1593
+ def update!(**args)
1594
+ @user_event_rejoin_scope = args[:user_event_rejoin_scope] if args.key?(:user_event_rejoin_scope)
1595
+ end
1596
+ end
1597
+
1598
+ # Response message for RejoinUserEvents method.
1599
+ class GoogleCloudRecommendationengineV1beta1RejoinUserEventsResponse
1600
+ include Google::Apis::Core::Hashable
1601
+
1602
+ # Number of user events that were joined with latest catalog items.
1603
+ # Corresponds to the JSON property `rejoinedUserEventsCount`
1604
+ # @return [Fixnum]
1605
+ attr_accessor :rejoined_user_events_count
1606
+
1607
+ def initialize(**args)
1608
+ update!(**args)
1609
+ end
1610
+
1611
+ # Update properties of this object
1612
+ def update!(**args)
1613
+ @rejoined_user_events_count = args[:rejoined_user_events_count] if args.key?(:rejoined_user_events_count)
1614
+ end
1615
+ end
1616
+
1617
+ # UserEvent captures all metadata information recommendation engine needs to
1618
+ # know about how end users interact with customers' website.
1619
+ class GoogleCloudRecommendationengineV1beta1UserEvent
1620
+ include Google::Apis::Core::Hashable
1621
+
1622
+ # User event details shared by all recommendation types.
1623
+ # Corresponds to the JSON property `eventDetail`
1624
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1EventDetail]
1625
+ attr_accessor :event_detail
1626
+
1627
+ # Optional. This field should *not* be set when using JavaScript pixel or the
1628
+ # Recommendations AI Tag. Defaults to `EVENT_SOURCE_UNSPECIFIED`.
1629
+ # Corresponds to the JSON property `eventSource`
1630
+ # @return [String]
1631
+ attr_accessor :event_source
1632
+
1633
+ # Optional. Only required for ImportUserEvents method. Timestamp of user event
1634
+ # created.
1635
+ # Corresponds to the JSON property `eventTime`
1636
+ # @return [String]
1637
+ attr_accessor :event_time
1638
+
1639
+ # Required. User event type. Allowed values are: * `add-to-cart` Products being
1640
+ # added to cart. * `add-to-list` Items being added to a list (shopping list,
1641
+ # favorites etc). * `category-page-view` Special pages such as sale or promotion
1642
+ # pages viewed. * `checkout-start` User starting a checkout process. * `detail-
1643
+ # page-view` Products detail page viewed. * `home-page-view` Homepage viewed. * `
1644
+ # page-visit` Generic page visits not included in the event types above. * `
1645
+ # purchase-complete` User finishing a purchase. * `refund` Purchased items being
1646
+ # refunded or returned. * `remove-from-cart` Products being removed from cart. *
1647
+ # `remove-from-list` Items being removed from a list. * `search` Product search.
1648
+ # * `shopping-cart-page-view` User viewing a shopping cart. * `impression` List
1649
+ # of items displayed. Used by Google Tag Manager.
1650
+ # Corresponds to the JSON property `eventType`
1651
+ # @return [String]
1652
+ attr_accessor :event_type
1653
+
1654
+ # ProductEventDetail captures user event information specific to retail products.
1655
+ # Corresponds to the JSON property `productEventDetail`
1656
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1ProductEventDetail]
1657
+ attr_accessor :product_event_detail
1658
+
1659
+ # Information of end users.
1660
+ # Corresponds to the JSON property `userInfo`
1661
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1UserInfo]
1662
+ attr_accessor :user_info
1663
+
1664
+ def initialize(**args)
1665
+ update!(**args)
1666
+ end
1667
+
1668
+ # Update properties of this object
1669
+ def update!(**args)
1670
+ @event_detail = args[:event_detail] if args.key?(:event_detail)
1671
+ @event_source = args[:event_source] if args.key?(:event_source)
1672
+ @event_time = args[:event_time] if args.key?(:event_time)
1673
+ @event_type = args[:event_type] if args.key?(:event_type)
1674
+ @product_event_detail = args[:product_event_detail] if args.key?(:product_event_detail)
1675
+ @user_info = args[:user_info] if args.key?(:user_info)
1676
+ end
1677
+ end
1678
+
1679
+ # A summary of import result. The UserEventImportSummary summarizes the import
1680
+ # status for user events.
1681
+ class GoogleCloudRecommendationengineV1beta1UserEventImportSummary
1682
+ include Google::Apis::Core::Hashable
1683
+
1684
+ # Count of user events imported with complete existing catalog information.
1685
+ # Corresponds to the JSON property `joinedEventsCount`
1686
+ # @return [Fixnum]
1687
+ attr_accessor :joined_events_count
1688
+
1689
+ # Count of user events imported, but with catalog information not found in the
1690
+ # imported catalog.
1691
+ # Corresponds to the JSON property `unjoinedEventsCount`
1692
+ # @return [Fixnum]
1693
+ attr_accessor :unjoined_events_count
1694
+
1695
+ def initialize(**args)
1696
+ update!(**args)
1697
+ end
1698
+
1699
+ # Update properties of this object
1700
+ def update!(**args)
1701
+ @joined_events_count = args[:joined_events_count] if args.key?(:joined_events_count)
1702
+ @unjoined_events_count = args[:unjoined_events_count] if args.key?(:unjoined_events_count)
1703
+ end
1704
+ end
1705
+
1706
+ # The inline source for the input config for ImportUserEvents method.
1707
+ class GoogleCloudRecommendationengineV1beta1UserEventInlineSource
1708
+ include Google::Apis::Core::Hashable
1709
+
1710
+ # Optional. A list of user events to import. Recommended max of 10k items.
1711
+ # Corresponds to the JSON property `userEvents`
1712
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleCloudRecommendationengineV1beta1UserEvent>]
1713
+ attr_accessor :user_events
1714
+
1715
+ def initialize(**args)
1716
+ update!(**args)
1717
+ end
1718
+
1719
+ # Update properties of this object
1720
+ def update!(**args)
1721
+ @user_events = args[:user_events] if args.key?(:user_events)
1722
+ end
1723
+ end
1724
+
1725
+ # Information of end users.
1726
+ class GoogleCloudRecommendationengineV1beta1UserInfo
1727
+ include Google::Apis::Core::Hashable
1728
+
1729
+ # Optional. Indicates if the request is made directly from the end user in which
1730
+ # case the user_agent and ip_address fields can be populated from the HTTP
1731
+ # request. This should *not* be set when using the javascript pixel. This flag
1732
+ # should be set only if the API request is made directly from the end user such
1733
+ # as a mobile app (and not if a gateway or a server is processing and pushing
1734
+ # the user events).
1735
+ # Corresponds to the JSON property `directUserRequest`
1736
+ # @return [Boolean]
1737
+ attr_accessor :direct_user_request
1738
+ alias_method :direct_user_request?, :direct_user_request
1739
+
1740
+ # Optional. IP address of the user. This could be either IPv4 (e.g. 104.133.9.80)
1741
+ # or IPv6 (e.g. 2001:0db8:85a3:0000:0000:8a2e:0370:7334). This should *not* be
1742
+ # set when using the javascript pixel or if `direct_user_request` is set. Used
1743
+ # to extract location information for personalization.
1744
+ # Corresponds to the JSON property `ipAddress`
1745
+ # @return [String]
1746
+ attr_accessor :ip_address
1747
+
1748
+ # Optional. User agent as included in the HTTP header. UTF-8 encoded string with
1749
+ # a length limit of 1 KiB. This should *not* be set when using the JavaScript
1750
+ # pixel or if `directUserRequest` is set.
1751
+ # Corresponds to the JSON property `userAgent`
1752
+ # @return [String]
1753
+ attr_accessor :user_agent
1754
+
1755
+ # Optional. Unique identifier for logged-in user with a length limit of 128
1756
+ # bytes. Required only for logged-in users.
1757
+ # Corresponds to the JSON property `userId`
1758
+ # @return [String]
1759
+ attr_accessor :user_id
1760
+
1761
+ # Required. A unique identifier for tracking visitors with a length limit of 128
1762
+ # bytes. For example, this could be implemented with a http cookie, which should
1763
+ # be able to uniquely identify a visitor on a single device. This unique
1764
+ # identifier should not change if the visitor log in/out of the website. Maximum
1765
+ # length 128 bytes. Cannot be empty.
1766
+ # Corresponds to the JSON property `visitorId`
1767
+ # @return [String]
1768
+ attr_accessor :visitor_id
1769
+
1770
+ def initialize(**args)
1771
+ update!(**args)
1772
+ end
1773
+
1774
+ # Update properties of this object
1775
+ def update!(**args)
1776
+ @direct_user_request = args[:direct_user_request] if args.key?(:direct_user_request)
1777
+ @ip_address = args[:ip_address] if args.key?(:ip_address)
1778
+ @user_agent = args[:user_agent] if args.key?(:user_agent)
1779
+ @user_id = args[:user_id] if args.key?(:user_id)
1780
+ @visitor_id = args[:visitor_id] if args.key?(:visitor_id)
1781
+ end
1782
+ end
1783
+
1784
+ # The response message for Operations.ListOperations.
1785
+ class GoogleLongrunningListOperationsResponse
1786
+ include Google::Apis::Core::Hashable
1787
+
1788
+ # The standard List next-page token.
1789
+ # Corresponds to the JSON property `nextPageToken`
1790
+ # @return [String]
1791
+ attr_accessor :next_page_token
1792
+
1793
+ # A list of operations that matches the specified filter in the request.
1794
+ # Corresponds to the JSON property `operations`
1795
+ # @return [Array<Google::Apis::RecommendationengineV1beta1::GoogleLongrunningOperation>]
1796
+ attr_accessor :operations
1797
+
1798
+ def initialize(**args)
1799
+ update!(**args)
1800
+ end
1801
+
1802
+ # Update properties of this object
1803
+ def update!(**args)
1804
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
1805
+ @operations = args[:operations] if args.key?(:operations)
1806
+ end
1807
+ end
1808
+
1809
+ # This resource represents a long-running operation that is the result of a
1810
+ # network API call.
1811
+ class GoogleLongrunningOperation
1812
+ include Google::Apis::Core::Hashable
1813
+
1814
+ # If the value is `false`, it means the operation is still in progress. If `true`
1815
+ # , the operation is completed, and either `error` or `response` is available.
1816
+ # Corresponds to the JSON property `done`
1817
+ # @return [Boolean]
1818
+ attr_accessor :done
1819
+ alias_method :done?, :done
1820
+
1821
+ # The `Status` type defines a logical error model that is suitable for different
1822
+ # programming environments, including REST APIs and RPC APIs. It is used by [
1823
+ # gRPC](https://github.com/grpc). Each `Status` message contains three pieces of
1824
+ # data: error code, error message, and error details. You can find out more
1825
+ # about this error model and how to work with it in the [API Design Guide](https:
1826
+ # //cloud.google.com/apis/design/errors).
1827
+ # Corresponds to the JSON property `error`
1828
+ # @return [Google::Apis::RecommendationengineV1beta1::GoogleRpcStatus]
1829
+ attr_accessor :error
1830
+
1831
+ # Service-specific metadata associated with the operation. It typically contains
1832
+ # progress information and common metadata such as create time. Some services
1833
+ # might not provide such metadata. Any method that returns a long-running
1834
+ # operation should document the metadata type, if any.
1835
+ # Corresponds to the JSON property `metadata`
1836
+ # @return [Hash<String,Object>]
1837
+ attr_accessor :metadata
1838
+
1839
+ # The server-assigned name, which is only unique within the same service that
1840
+ # originally returns it. If you use the default HTTP mapping, the `name` should
1841
+ # be a resource name ending with `operations/`unique_id``.
1842
+ # Corresponds to the JSON property `name`
1843
+ # @return [String]
1844
+ attr_accessor :name
1845
+
1846
+ # The normal response of the operation in case of success. If the original
1847
+ # method returns no data on success, such as `Delete`, the response is `google.
1848
+ # protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`,
1849
+ # the response should be the resource. For other methods, the response should
1850
+ # have the type `XxxResponse`, where `Xxx` is the original method name. For
1851
+ # example, if the original method name is `TakeSnapshot()`, the inferred
1852
+ # response type is `TakeSnapshotResponse`.
1853
+ # Corresponds to the JSON property `response`
1854
+ # @return [Hash<String,Object>]
1855
+ attr_accessor :response
1856
+
1857
+ def initialize(**args)
1858
+ update!(**args)
1859
+ end
1860
+
1861
+ # Update properties of this object
1862
+ def update!(**args)
1863
+ @done = args[:done] if args.key?(:done)
1864
+ @error = args[:error] if args.key?(:error)
1865
+ @metadata = args[:metadata] if args.key?(:metadata)
1866
+ @name = args[:name] if args.key?(:name)
1867
+ @response = args[:response] if args.key?(:response)
1868
+ end
1869
+ end
1870
+
1871
+ # A generic empty message that you can re-use to avoid defining duplicated empty
1872
+ # messages in your APIs. A typical example is to use it as the request or the
1873
+ # response type of an API method. For instance: service Foo ` rpc Bar(google.
1874
+ # protobuf.Empty) returns (google.protobuf.Empty); ` The JSON representation for
1875
+ # `Empty` is empty JSON object ````.
1876
+ class GoogleProtobufEmpty
1877
+ include Google::Apis::Core::Hashable
1878
+
1879
+ def initialize(**args)
1880
+ update!(**args)
1881
+ end
1882
+
1883
+ # Update properties of this object
1884
+ def update!(**args)
1885
+ end
1886
+ end
1887
+
1888
+ # The `Status` type defines a logical error model that is suitable for different
1889
+ # programming environments, including REST APIs and RPC APIs. It is used by [
1890
+ # gRPC](https://github.com/grpc). Each `Status` message contains three pieces of
1891
+ # data: error code, error message, and error details. You can find out more
1892
+ # about this error model and how to work with it in the [API Design Guide](https:
1893
+ # //cloud.google.com/apis/design/errors).
1894
+ class GoogleRpcStatus
1895
+ include Google::Apis::Core::Hashable
1896
+
1897
+ # The status code, which should be an enum value of google.rpc.Code.
1898
+ # Corresponds to the JSON property `code`
1899
+ # @return [Fixnum]
1900
+ attr_accessor :code
1901
+
1902
+ # A list of messages that carry the error details. There is a common set of
1903
+ # message types for APIs to use.
1904
+ # Corresponds to the JSON property `details`
1905
+ # @return [Array<Hash<String,Object>>]
1906
+ attr_accessor :details
1907
+
1908
+ # A developer-facing error message, which should be in English. Any user-facing
1909
+ # error message should be localized and sent in the google.rpc.Status.details
1910
+ # field, or localized by the client.
1911
+ # Corresponds to the JSON property `message`
1912
+ # @return [String]
1913
+ attr_accessor :message
1914
+
1915
+ def initialize(**args)
1916
+ update!(**args)
1917
+ end
1918
+
1919
+ # Update properties of this object
1920
+ def update!(**args)
1921
+ @code = args[:code] if args.key?(:code)
1922
+ @details = args[:details] if args.key?(:details)
1923
+ @message = args[:message] if args.key?(:message)
1924
+ end
1925
+ end
1926
+ end
1927
+ end
1928
+ end