@@ -10095,9 +10095,10 @@ public UserEvents userEvents() {
1009510095 public class UserEvents {
1009610096
1009710097 /**
10098- * Writes a single user event from the browser. This uses a GET request to due to browser
10099- * restriction of POST-ing to a 3rd party domain. This method is used only by the Retail API
10100- * JavaScript pixel and Google Tag Manager. Users should not call this method directly.
10098+ * Writes a single user event from the browser. For larger user event payload over 16 KB, the POST
10099+ * method should be used instead, otherwise a 400 Bad Request error is returned. This method is used
10100+ * only by the Retail API JavaScript pixel and Google Tag Manager. Users should not call this method
10101+ * directly.
1010110102 *
1010210103 * Create a request for the method "userEvents.collect".
1010310104 *
@@ -10106,10 +10107,11 @@ public class UserEvents {
1010610107 *
1010710108 * @param parent Required. The parent catalog name, such as
1010810109 * `projects/1234/locations/global/catalogs/default_catalog`.
10110+ * @param content the {@link com.google.api.services.retail.v2.model.GoogleCloudRetailV2CollectUserEventRequest}
1010910111 * @return the request
1011010112 */
10111- public Collect collect(java.lang.String parent) throws java.io.IOException {
10112- Collect result = new Collect(parent);
10113+ public Collect collect(java.lang.String parent, com.google.api.services.retail.v2.model.GoogleCloudRetailV2CollectUserEventRequest content ) throws java.io.IOException {
10114+ Collect result = new Collect(parent, content );
1011310115 initialize(result);
1011410116 return result;
1011510117 }
@@ -10122,9 +10124,10 @@ public class Collect extends CloudRetailRequest<com.google.api.services.retail.v
1012210124 java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/catalogs/[^/]+$");
1012310125
1012410126 /**
10125- * Writes a single user event from the browser. This uses a GET request to due to browser
10126- * restriction of POST-ing to a 3rd party domain. This method is used only by the Retail API
10127- * JavaScript pixel and Google Tag Manager. Users should not call this method directly.
10127+ * Writes a single user event from the browser. For larger user event payload over 16 KB, the POST
10128+ * method should be used instead, otherwise a 400 Bad Request error is returned. This method is
10129+ * used only by the Retail API JavaScript pixel and Google Tag Manager. Users should not call this
10130+ * method directly.
1012810131 *
1012910132 * Create a request for the method "userEvents.collect".
1013010133 *
@@ -10136,10 +10139,11 @@ public class Collect extends CloudRetailRequest<com.google.api.services.retail.v
1013610139 *
1013710140 * @param parent Required. The parent catalog name, such as
1013810141 * `projects/1234/locations/global/catalogs/default_catalog`.
10142+ * @param content the {@link com.google.api.services.retail.v2.model.GoogleCloudRetailV2CollectUserEventRequest}
1013910143 * @since 1.13
1014010144 */
10141- protected Collect(java.lang.String parent) {
10142- super(CloudRetail.this, "GET ", REST_PATH, null , com.google.api.services.retail.v2.model.GoogleApiHttpBody.class);
10145+ protected Collect(java.lang.String parent, com.google.api.services.retail.v2.model.GoogleCloudRetailV2CollectUserEventRequest content ) {
10146+ super(CloudRetail.this, "POST ", REST_PATH, content , com.google.api.services.retail.v2.model.GoogleApiHttpBody.class);
1014310147 this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified.");
1014410148 if (!getSuppressPatternChecks()) {
1014510149 com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(),
@@ -10148,16 +10152,6 @@ protected Collect(java.lang.String parent) {
1014810152 }
1014910153 }
1015010154
10151- @Override
10152- public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException {
10153- return super.executeUsingHead();
10154- }
10155-
10156- @Override
10157- public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException {
10158- return super.buildHttpRequestUsingHead();
10159- }
10160-
1016110155 @Override
1016210156 public Collect set$Xgafv(java.lang.String $Xgafv) {
1016310157 return (Collect) super.set$Xgafv($Xgafv);
@@ -10241,124 +10235,6 @@ public Collect setParent(java.lang.String parent) {
1024110235 return this;
1024210236 }
1024310237
10244- /**
10245- * The event timestamp in milliseconds. This prevents browser caching of otherwise
10246- * identical get requests. The name is abbreviated to reduce the payload bytes.
10247- */
10248- @com.google.api.client.util.Key
10249- private java.lang.Long ets;
10250-
10251- /** The event timestamp in milliseconds. This prevents browser caching of otherwise identical get
10252- requests. The name is abbreviated to reduce the payload bytes.
10253- */
10254- public java.lang.Long getEts() {
10255- return ets;
10256- }
10257-
10258- /**
10259- * The event timestamp in milliseconds. This prevents browser caching of otherwise
10260- * identical get requests. The name is abbreviated to reduce the payload bytes.
10261- */
10262- public Collect setEts(java.lang.Long ets) {
10263- this.ets = ets;
10264- return this;
10265- }
10266-
10267- /**
10268- * The prebuilt rule name that can convert a specific type of raw_json. For example:
10269- * "ga4_bq" rule for the GA4 user event schema.
10270- */
10271- @com.google.api.client.util.Key
10272- private java.lang.String prebuiltRule;
10273-
10274- /** The prebuilt rule name that can convert a specific type of raw_json. For example: "ga4_bq" rule for
10275- the GA4 user event schema.
10276- */
10277- public java.lang.String getPrebuiltRule() {
10278- return prebuiltRule;
10279- }
10280-
10281- /**
10282- * The prebuilt rule name that can convert a specific type of raw_json. For example:
10283- * "ga4_bq" rule for the GA4 user event schema.
10284- */
10285- public Collect setPrebuiltRule(java.lang.String prebuiltRule) {
10286- this.prebuiltRule = prebuiltRule;
10287- return this;
10288- }
10289-
10290- /**
10291- * An arbitrary serialized JSON string that contains necessary information that can
10292- * comprise a user event. When this field is specified, the user_event field will be
10293- * ignored. Note: line-delimited JSON is not supported, a single JSON only.
10294- */
10295- @com.google.api.client.util.Key
10296- private java.lang.String rawJson;
10297-
10298- /** An arbitrary serialized JSON string that contains necessary information that can comprise a user
10299- event. When this field is specified, the user_event field will be ignored. Note: line-delimited
10300- JSON is not supported, a single JSON only.
10301- */
10302- public java.lang.String getRawJson() {
10303- return rawJson;
10304- }
10305-
10306- /**
10307- * An arbitrary serialized JSON string that contains necessary information that can
10308- * comprise a user event. When this field is specified, the user_event field will be
10309- * ignored. Note: line-delimited JSON is not supported, a single JSON only.
10310- */
10311- public Collect setRawJson(java.lang.String rawJson) {
10312- this.rawJson = rawJson;
10313- return this;
10314- }
10315-
10316- /**
10317- * The URL including cgi-parameters but excluding the hash fragment with a length limit
10318- * of 5,000 characters. This is often more useful than the referer URL, because many
10319- * browsers only send the domain for 3rd party requests.
10320- */
10321- @com.google.api.client.util.Key
10322- private java.lang.String uri;
10323-
10324- /** The URL including cgi-parameters but excluding the hash fragment with a length limit of 5,000
10325- characters. This is often more useful than the referer URL, because many browsers only send the
10326- domain for 3rd party requests.
10327- */
10328- public java.lang.String getUri() {
10329- return uri;
10330- }
10331-
10332- /**
10333- * The URL including cgi-parameters but excluding the hash fragment with a length limit
10334- * of 5,000 characters. This is often more useful than the referer URL, because many
10335- * browsers only send the domain for 3rd party requests.
10336- */
10337- public Collect setUri(java.lang.String uri) {
10338- this.uri = uri;
10339- return this;
10340- }
10341-
10342- /**
10343- * Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.
10344- */
10345- @com.google.api.client.util.Key
10346- private java.lang.String userEvent;
10347-
10348- /** Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.
10349- */
10350- public java.lang.String getUserEvent() {
10351- return userEvent;
10352- }
10353-
10354- /**
10355- * Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.
10356- */
10357- public Collect setUserEvent(java.lang.String userEvent) {
10358- this.userEvent = userEvent;
10359- return this;
10360- }
10361-
1036210238 @Override
1036310239 public Collect set(String parameterName, Object value) {
1036410240 return (Collect) super.set(parameterName, value);
0 commit comments