diff --git a/apigee/v1/apigee-api.json b/apigee/v1/apigee-api.json index e7faac22cc7..9e6c8b051de 100644 --- a/apigee/v1/apigee-api.json +++ b/apigee/v1/apigee-api.json @@ -7588,7 +7588,7 @@ } } }, - "revision": "20220303", + "revision": "20220310", "rootUrl": "https://apigee.googleapis.com/", "schemas": { "EdgeConfigstoreBundleBadBundle": { @@ -9947,6 +9947,11 @@ "description": "Required. ID of the attached environment.", "type": "string" }, + "environmentGroupId": { + "description": "Output only. ID of the environment group.", + "readOnly": true, + "type": "string" + }, "name": { "description": "ID of the environment group attachment.", "type": "string" diff --git a/apigee/v1/apigee-gen.go b/apigee/v1/apigee-gen.go index 7cf41b26b26..92b03a7a71f 100644 --- a/apigee/v1/apigee-gen.go +++ b/apigee/v1/apigee-gen.go @@ -4335,6 +4335,9 @@ type GoogleCloudApigeeV1EnvironmentGroupAttachment struct { // Environment: Required. ID of the attached environment. Environment string `json:"environment,omitempty"` + // EnvironmentGroupId: Output only. ID of the environment group. + EnvironmentGroupId string `json:"environmentGroupId,omitempty"` + // Name: ID of the environment group attachment. Name string `json:"name,omitempty"` diff --git a/documentai/v1/documentai-api.json b/documentai/v1/documentai-api.json index 201c2adf1a6..0b6454992c8 100644 --- a/documentai/v1/documentai-api.json +++ b/documentai/v1/documentai-api.json @@ -1029,7 +1029,7 @@ } } }, - "revision": "20220307", + "revision": "20220311", "rootUrl": "https://documentai.googleapis.com/", "schemas": { "GoogleCloudDocumentaiUiv1beta3BatchDeleteDocumentsMetadata": { @@ -1071,6 +1071,22 @@ ], "type": "string" }, + "destSplitType": { + "description": "The destination dataset split type.", + "enum": [ + "DATASET_SPLIT_TYPE_UNSPECIFIED", + "DATASET_SPLIT_TRAIN", + "DATASET_SPLIT_TEST", + "DATASET_SPLIT_UNASSIGNED" + ], + "enumDescriptions": [ + "Default value if the enum is not set. go/protodosdonts#do-include-an-unspecified-value-in-an-enum", + "Identifies the train documents.", + "Identifies the test documents.", + "Identifies the unassigned documents." + ], + "type": "string" + }, "individualBatchMoveStatuses": { "description": "The list of response details of each document.", "items": { diff --git a/documentai/v1/documentai-gen.go b/documentai/v1/documentai-gen.go index dd7a54284d8..062b0f03ad5 100644 --- a/documentai/v1/documentai-gen.go +++ b/documentai/v1/documentai-gen.go @@ -325,6 +325,16 @@ type GoogleCloudDocumentaiUiv1beta3BatchMoveDocumentsMetadata struct { // "DATASET_SPLIT_UNASSIGNED" - Identifies the unassigned documents. DestDatasetType string `json:"destDatasetType,omitempty"` + // DestSplitType: The destination dataset split type. + // + // Possible values: + // "DATASET_SPLIT_TYPE_UNSPECIFIED" - Default value if the enum is not + // set. go/protodosdonts#do-include-an-unspecified-value-in-an-enum + // "DATASET_SPLIT_TRAIN" - Identifies the train documents. + // "DATASET_SPLIT_TEST" - Identifies the test documents. + // "DATASET_SPLIT_UNASSIGNED" - Identifies the unassigned documents. + DestSplitType string `json:"destSplitType,omitempty"` + // IndividualBatchMoveStatuses: The list of response details of each // document. IndividualBatchMoveStatuses []*GoogleCloudDocumentaiUiv1beta3BatchMoveDocumentsMetadataIndividualBatchMoveStatus `json:"individualBatchMoveStatuses,omitempty"` diff --git a/documentai/v1beta2/documentai-api.json b/documentai/v1beta2/documentai-api.json index a89c7f48272..852aef4b48a 100644 --- a/documentai/v1beta2/documentai-api.json +++ b/documentai/v1beta2/documentai-api.json @@ -292,7 +292,7 @@ } } }, - "revision": "20220307", + "revision": "20220311", "rootUrl": "https://documentai.googleapis.com/", "schemas": { "GoogleCloudDocumentaiUiv1beta3BatchDeleteDocumentsMetadata": { @@ -334,6 +334,22 @@ ], "type": "string" }, + "destSplitType": { + "description": "The destination dataset split type.", + "enum": [ + "DATASET_SPLIT_TYPE_UNSPECIFIED", + "DATASET_SPLIT_TRAIN", + "DATASET_SPLIT_TEST", + "DATASET_SPLIT_UNASSIGNED" + ], + "enumDescriptions": [ + "Default value if the enum is not set. go/protodosdonts#do-include-an-unspecified-value-in-an-enum", + "Identifies the train documents.", + "Identifies the test documents.", + "Identifies the unassigned documents." + ], + "type": "string" + }, "individualBatchMoveStatuses": { "description": "The list of response details of each document.", "items": { diff --git a/documentai/v1beta2/documentai-gen.go b/documentai/v1beta2/documentai-gen.go index 29db47d078b..55abe783fcf 100644 --- a/documentai/v1beta2/documentai-gen.go +++ b/documentai/v1beta2/documentai-gen.go @@ -253,6 +253,16 @@ type GoogleCloudDocumentaiUiv1beta3BatchMoveDocumentsMetadata struct { // "DATASET_SPLIT_UNASSIGNED" - Identifies the unassigned documents. DestDatasetType string `json:"destDatasetType,omitempty"` + // DestSplitType: The destination dataset split type. + // + // Possible values: + // "DATASET_SPLIT_TYPE_UNSPECIFIED" - Default value if the enum is not + // set. go/protodosdonts#do-include-an-unspecified-value-in-an-enum + // "DATASET_SPLIT_TRAIN" - Identifies the train documents. + // "DATASET_SPLIT_TEST" - Identifies the test documents. + // "DATASET_SPLIT_UNASSIGNED" - Identifies the unassigned documents. + DestSplitType string `json:"destSplitType,omitempty"` + // IndividualBatchMoveStatuses: The list of response details of each // document. IndividualBatchMoveStatuses []*GoogleCloudDocumentaiUiv1beta3BatchMoveDocumentsMetadataIndividualBatchMoveStatus `json:"individualBatchMoveStatuses,omitempty"` diff --git a/documentai/v1beta3/documentai-api.json b/documentai/v1beta3/documentai-api.json index b2b2c4a0228..bf3d7e15c1f 100644 --- a/documentai/v1beta3/documentai-api.json +++ b/documentai/v1beta3/documentai-api.json @@ -796,7 +796,7 @@ } } }, - "revision": "20220307", + "revision": "20220311", "rootUrl": "https://documentai.googleapis.com/", "schemas": { "GoogleCloudDocumentaiUiv1beta3BatchDeleteDocumentsMetadata": { @@ -838,6 +838,22 @@ ], "type": "string" }, + "destSplitType": { + "description": "The destination dataset split type.", + "enum": [ + "DATASET_SPLIT_TYPE_UNSPECIFIED", + "DATASET_SPLIT_TRAIN", + "DATASET_SPLIT_TEST", + "DATASET_SPLIT_UNASSIGNED" + ], + "enumDescriptions": [ + "Default value if the enum is not set. go/protodosdonts#do-include-an-unspecified-value-in-an-enum", + "Identifies the train documents.", + "Identifies the test documents.", + "Identifies the unassigned documents." + ], + "type": "string" + }, "individualBatchMoveStatuses": { "description": "The list of response details of each document.", "items": { diff --git a/documentai/v1beta3/documentai-gen.go b/documentai/v1beta3/documentai-gen.go index 12ecd687e99..77f816d6d15 100644 --- a/documentai/v1beta3/documentai-gen.go +++ b/documentai/v1beta3/documentai-gen.go @@ -253,6 +253,16 @@ type GoogleCloudDocumentaiUiv1beta3BatchMoveDocumentsMetadata struct { // "DATASET_SPLIT_UNASSIGNED" - Identifies the unassigned documents. DestDatasetType string `json:"destDatasetType,omitempty"` + // DestSplitType: The destination dataset split type. + // + // Possible values: + // "DATASET_SPLIT_TYPE_UNSPECIFIED" - Default value if the enum is not + // set. go/protodosdonts#do-include-an-unspecified-value-in-an-enum + // "DATASET_SPLIT_TRAIN" - Identifies the train documents. + // "DATASET_SPLIT_TEST" - Identifies the test documents. + // "DATASET_SPLIT_UNASSIGNED" - Identifies the unassigned documents. + DestSplitType string `json:"destSplitType,omitempty"` + // IndividualBatchMoveStatuses: The list of response details of each // document. IndividualBatchMoveStatuses []*GoogleCloudDocumentaiUiv1beta3BatchMoveDocumentsMetadataIndividualBatchMoveStatus `json:"individualBatchMoveStatuses,omitempty"` diff --git a/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-api.json b/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-api.json index ce402e3984d..6e42d1829a7 100644 --- a/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-api.json +++ b/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-api.json @@ -2484,7 +2484,7 @@ } } }, - "revision": "20220314", + "revision": "20220316", "rootUrl": "https://prod-tt-sasportal.googleapis.com/", "schemas": { "SasPortalAssignment": { @@ -3186,7 +3186,7 @@ "type": "object" }, "SasPortalNrqzValidation": { - "description": "Information about National Radio Quiet Zone validation.", + "description": "Information about National Radio Quiet Zone validation. The presence of the field indicates the device has been validated.", "id": "SasPortalNrqzValidation", "properties": { "caseId": { @@ -3206,20 +3206,6 @@ "description": "Device longitude associated with the validation.", "format": "double", "type": "number" - }, - "state": { - "description": "State of the NRQZ validation info.", - "enum": [ - "STATE_UNSPECIFIED", - "DRAFT", - "FINAL" - ], - "enumDescriptions": [ - "Unspecified state.", - "Draft state.", - "Final state." - ], - "type": "string" } }, "type": "object" diff --git a/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-gen.go b/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-gen.go index 892bfa04d72..fbfd2a2d1d0 100644 --- a/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-gen.go +++ b/prod_tt_sasportal/v1alpha1/prod_tt_sasportal-gen.go @@ -1501,7 +1501,8 @@ func (s *SasPortalNode) MarshalJSON() ([]byte, error) { } // SasPortalNrqzValidation: Information about National Radio Quiet Zone -// validation. +// validation. The presence of the field indicates the device has been +// validated. type SasPortalNrqzValidation struct { // CaseId: Validation case id. CaseId string `json:"caseId,omitempty"` @@ -1515,14 +1516,6 @@ type SasPortalNrqzValidation struct { // Longitude: Device longitude associated with the validation. Longitude float64 `json:"longitude,omitempty"` - // State: State of the NRQZ validation info. - // - // Possible values: - // "STATE_UNSPECIFIED" - Unspecified state. - // "DRAFT" - Draft state. - // "FINAL" - Final state. - State string `json:"state,omitempty"` - // ForceSendFields is a list of field names (e.g. "CaseId") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any diff --git a/retail/v2/retail-api.json b/retail/v2/retail-api.json index 7452ece617d..bd5ffcd0d81 100644 --- a/retail/v2/retail-api.json +++ b/retail/v2/retail-api.json @@ -155,7 +155,7 @@ "type": "string" }, "visitorId": { - "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "description": "Required field. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", "location": "query", "type": "string" } @@ -873,7 +873,7 @@ ] }, "rejoin": { - "description": "Triggers a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This API can be used to trigger a 'join' operation on specified events with latest version of product catalog. It can also be used to correct events joined with wrong product catalog.", + "description": "Starts a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This method can be used to start a join operation on specified events with latest version of product catalog. It can also be used to correct events joined with the wrong product catalog. A rejoin operation can take hours or days to complete.", "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/catalogs/{catalogsId}/userEvents:rejoin", "httpMethod": "POST", "id": "retail.projects.locations.catalogs.userEvents.rejoin", @@ -1077,7 +1077,7 @@ } } }, - "revision": "20220303", + "revision": "20220316", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -1533,7 +1533,7 @@ "type": "object" }, "GoogleCloudRetailV2Image": { - "description": "Product thumbnail/detail image.", + "description": "Product image. Recommendations AI and Retail Search do not use product images to improve prediction and search results. However, product images can be returned in results, and are shown in prediction or search previews in the console.", "id": "GoogleCloudRetailV2Image", "properties": { "height": { @@ -1793,7 +1793,7 @@ "id": "GoogleCloudRetailV2PredictRequest", "properties": { "filter": { - "description": "Filter for restricting prediction results with a length limit of 5,000 characters. Accepts values for tags and the `filterOutOfStockItems` flag. * Tag expressions. Restricts predictions to products that match all of the specified tags. Boolean operators `OR` and `NOT` are supported if the expression is enclosed in parentheses, and must be separated from the tag values by a space. `-\"tagA\"` is also supported and is equivalent to `NOT \"tagA\"`. Tag values must be double quoted UTF-8 encoded strings with a size limit of 1,000 characters. Note: \"Recently viewed\" models don't support tag filtering at the moment. * filterOutOfStockItems. Restricts predictions to products that do not have a stockState value of OUT_OF_STOCK. Examples: * tag=(\"Red\" OR \"Blue\") tag=\"New-Arrival\" tag=(NOT \"promotional\") * filterOutOfStockItems tag=(-\"promotional\") * filterOutOfStockItems If your filter blocks all prediction results, nothing will be returned. If you want generic (unfiltered) popular products to be returned instead, set `strictFiltering` to false in `PredictRequest.params`.", + "description": "Filter for restricting prediction results with a length limit of 5,000 characters. Accepts values for tags and the `filterOutOfStockItems` flag. * Tag expressions. Restricts predictions to products that match all of the specified tags. Boolean operators `OR` and `NOT` are supported if the expression is enclosed in parentheses, and must be separated from the tag values by a space. `-\"tagA\"` is also supported and is equivalent to `NOT \"tagA\"`. Tag values must be double quoted UTF-8 encoded strings with a size limit of 1,000 characters. Note: \"Recently viewed\" models don't support tag filtering at the moment. * filterOutOfStockItems. Restricts predictions to products that do not have a stockState value of OUT_OF_STOCK. Examples: * tag=(\"Red\" OR \"Blue\") tag=\"New-Arrival\" tag=(NOT \"promotional\") * filterOutOfStockItems tag=(-\"promotional\") * filterOutOfStockItems If your filter blocks all prediction results, the API will return generic (unfiltered) popular products. If you only want results strictly matching the filters, set `strictFiltering` to True in `PredictRequest.params` to receive empty results instead. Note that the API will never return items with storageStatus of \"EXPIRED\" or \"DELETED\" regardless of filter choices.", "type": "string" }, "labels": { @@ -2033,7 +2033,7 @@ "type": "string" }, "images": { - "description": "Product images for the product.Highly recommended to put the main image to the first. A maximum of 300 images are allowed. Corresponding properties: Google Merchant Center property [image_link](https://support.google.com/merchants/answer/6324350). Schema.org property [Product.image](https://schema.org/image).", + "description": "Product images for the product. We highly recommend putting the main image first. A maximum of 300 images are allowed. Corresponding properties: Google Merchant Center property [image_link](https://support.google.com/merchants/answer/6324350). Schema.org property [Product.image](https://schema.org/image).", "items": { "$ref": "GoogleCloudRetailV2Image" }, @@ -2398,7 +2398,7 @@ "type": "string" }, "canonicalFilter": { - "description": "The filter applied to every search request when quality improvement such as query expansion is needed. For example, if a query does not have enough results, an expanded query with SearchRequest.canonical_filter will be returned as a supplement of the original query. This field is strongly recommended to achieve high search quality. See SearchRequest.filter for more details about filter syntax.", + "description": "The default filter that is applied when a user performs a search without checking any filters on the search page. The filter applied to every search request when quality improvement such as query expansion is needed. For example, if a query does not have enough results, an expanded query with SearchRequest.canonical_filter will be returned as a supplement of the original query. This field is strongly recommended to achieve high search quality. See SearchRequest.filter for more details about filter syntax.", "type": "string" }, "dynamicFacetSpec": { @@ -2877,7 +2877,7 @@ "additionalProperties": { "$ref": "GoogleCloudRetailV2CustomAttribute" }, - "description": "Extra user event features to include in the recommendation model. This field needs to pass all below criteria, otherwise an INVALID_ARGUMENT error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendation, an example of extra user information is traffic_channel, i.e. how user arrives at the site. Users can arrive at the site by coming to the site directly, or coming through Google search, and etc.", + "description": "Extra user event features to include in the recommendation model. If you provide custom attributes for ingested user events, also include them in the user events that you associate with prediction requests. Custom attribute formatting must be consistent between imported events and events provided with prediction requests. This lets the Retail API use those custom attributes when training models and serving predictions, which helps improve recommendation quality. This field needs to pass all below criteria, otherwise an INVALID_ARGUMENT error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendations, an example of extra user information is traffic_channel, which is how a user arrives at the site. Users can arrive at the site by coming to the site directly, coming through Google search, or in other ways.", "type": "object" }, "attributionToken": { @@ -3237,6 +3237,52 @@ "properties": {}, "type": "object" }, + "GoogleCloudRetailV2alphaPurgeProductsMetadata": { + "description": "Metadata related to the progress of the PurgeProducts operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudRetailV2alphaPurgeProductsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of entries that were deleted successfully.", + "format": "int64", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudRetailV2alphaPurgeProductsResponse": { + "description": "Response of the PurgeProductsRequest. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudRetailV2alphaPurgeProductsResponse", + "properties": { + "purgeCount": { + "description": "The total count of products purged as a result of the operation.", + "format": "int64", + "type": "string" + }, + "purgeSample": { + "description": "A sample of the product names that will be deleted. Only populated if `force` is set to false. A max of 100 names will be returned and the names are chosen at random.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaPurgeUserEventsResponse": { "description": "Response of the PurgeUserEventsRequest. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", "id": "GoogleCloudRetailV2alphaPurgeUserEventsResponse", diff --git a/retail/v2/retail-gen.go b/retail/v2/retail-gen.go index f253e113926..cfdbcbb5155 100644 --- a/retail/v2/retail-gen.go +++ b/retail/v2/retail-gen.go @@ -1224,7 +1224,10 @@ func (s *GoogleCloudRetailV2GetDefaultBranchResponse) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRetailV2Image: Product thumbnail/detail image. +// GoogleCloudRetailV2Image: Product image. Recommendations AI and +// Retail Search do not use product images to improve prediction and +// search results. However, product images can be returned in results, +// and are shown in prediction or search previews in the console. type GoogleCloudRetailV2Image struct { // Height: Height of the image in number of pixels. This field must be // nonnegative. Otherwise, an INVALID_ARGUMENT error is returned. @@ -1751,9 +1754,11 @@ type GoogleCloudRetailV2PredictRequest struct { // OUT_OF_STOCK. Examples: * tag=("Red" OR "Blue") tag="New-Arrival" // tag=(NOT "promotional") * filterOutOfStockItems tag=(-"promotional") // * filterOutOfStockItems If your filter blocks all prediction results, - // nothing will be returned. If you want generic (unfiltered) popular - // products to be returned instead, set `strictFiltering` to false in - // `PredictRequest.params`. + // the API will return generic (unfiltered) popular products. If you + // only want results strictly matching the filters, set + // `strictFiltering` to True in `PredictRequest.params` to receive empty + // results instead. Note that the API will never return items with + // storageStatus of "EXPIRED" or "DELETED" regardless of filter choices. Filter string `json:"filter,omitempty"` // Labels: The labels applied to a resource must meet the following @@ -2197,8 +2202,8 @@ type GoogleCloudRetailV2Product struct { // Schema.org property Product.sku (https://schema.org/sku). Id string `json:"id,omitempty"` - // Images: Product images for the product.Highly recommended to put the - // main image to the first. A maximum of 300 images are allowed. + // Images: Product images for the product. We highly recommend putting + // the main image first. A maximum of 300 images are allowed. // Corresponding properties: Google Merchant Center property image_link // (https://support.google.com/merchants/answer/6324350). Schema.org // property Product.image (https://schema.org/image). @@ -2966,9 +2971,11 @@ type GoogleCloudRetailV2SearchRequest struct { // search products under the default branch. Branch string `json:"branch,omitempty"` - // CanonicalFilter: The filter applied to every search request when - // quality improvement such as query expansion is needed. For example, - // if a query does not have enough results, an expanded query with + // CanonicalFilter: The default filter that is applied when a user + // performs a search without checking any filters on the search page. + // The filter applied to every search request when quality improvement + // such as query expansion is needed. For example, if a query does not + // have enough results, an expanded query with // SearchRequest.canonical_filter will be returned as a supplement of // the original query. This field is strongly recommended to achieve // high search quality. See SearchRequest.filter for more details about @@ -3903,16 +3910,23 @@ type GoogleCloudRetailV2SetInventoryResponse struct { // with customers' website. type GoogleCloudRetailV2UserEvent struct { // Attributes: Extra user event features to include in the - // recommendation model. This field needs to pass all below criteria, - // otherwise an INVALID_ARGUMENT error is returned: * The key must be a - // UTF-8 encoded string with a length limit of 5,000 characters. * For - // text attributes, at most 400 values are allowed. Empty values are not - // allowed. Each value must be a UTF-8 encoded string with a length - // limit of 256 characters. * For number attributes, at most 400 values - // are allowed. For product recommendation, an example of extra user - // information is traffic_channel, i.e. how user arrives at the site. - // Users can arrive at the site by coming to the site directly, or - // coming through Google search, and etc. + // recommendation model. If you provide custom attributes for ingested + // user events, also include them in the user events that you associate + // with prediction requests. Custom attribute formatting must be + // consistent between imported events and events provided with + // prediction requests. This lets the Retail API use those custom + // attributes when training models and serving predictions, which helps + // improve recommendation quality. This field needs to pass all below + // criteria, otherwise an INVALID_ARGUMENT error is returned: * The key + // must be a UTF-8 encoded string with a length limit of 5,000 + // characters. * For text attributes, at most 400 values are allowed. + // Empty values are not allowed. Each value must be a UTF-8 encoded + // string with a length limit of 256 characters. * For number + // attributes, at most 400 values are allowed. For product + // recommendations, an example of extra user information is + // traffic_channel, which is how a user arrives at the site. Users can + // arrive at the site by coming to the site directly, coming through + // Google search, or in other ways. Attributes map[string]GoogleCloudRetailV2CustomAttribute `json:"attributes,omitempty"` // AttributionToken: Highly recommended for user events that are the @@ -4621,6 +4635,84 @@ func (s *GoogleCloudRetailV2alphaImportUserEventsResponse) MarshalJSON() ([]byte type GoogleCloudRetailV2alphaPurgeMetadata struct { } +// GoogleCloudRetailV2alphaPurgeProductsMetadata: Metadata related to +// the progress of the PurgeProducts operation. This will be returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudRetailV2alphaPurgeProductsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudRetailV2alphaPurgeProductsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaPurgeProductsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRetailV2alphaPurgeProductsResponse: Response of the +// PurgeProductsRequest. If the long running operation is successfully +// done, then this message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudRetailV2alphaPurgeProductsResponse struct { + // PurgeCount: The total count of products purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // PurgeSample: A sample of the product names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudRetailV2alphaPurgeProductsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaPurgeProductsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaPurgeUserEventsResponse: Response of the // PurgeUserEventsRequest. If the long running operation is successfully // done, then this message is returned by the @@ -5534,8 +5626,8 @@ func (c *ProjectsLocationsCatalogsCompleteQueryCall) Query(query string) *Projec return c } -// VisitorId sets the optional parameter "visitorId": A unique -// identifier for tracking visitors. For example, this could be +// VisitorId sets the optional parameter "visitorId": Required field. A +// unique identifier for tracking visitors. For example, this could be // implemented with an HTTP cookie, which should be able to uniquely // identify a visitor on a single device. This unique identifier should // not change if the visitor logs in or out of the website. The field @@ -5690,7 +5782,7 @@ func (c *ProjectsLocationsCatalogsCompleteQueryCall) Do(opts ...googleapi.CallOp // "type": "string" // }, // "visitorId": { - // "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + // "description": "Required field. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", // "location": "query", // "type": "string" // } @@ -9348,14 +9440,15 @@ type ProjectsLocationsCatalogsUserEventsRejoinCall struct { header_ http.Header } -// Rejoin: Triggers a user event rejoin operation with latest product +// Rejoin: Starts a user event rejoin operation with latest product // catalog. Events will not be annotated with detailed product // information if product is missing from the catalog at the time the // user event is ingested, and these events are stored as unjoined -// events with a limited usage on training and serving. This API can be -// used to trigger a 'join' operation on specified events with latest +// events with a limited usage on training and serving. This method can +// be used to start a join operation on specified events with latest // version of product catalog. It can also be used to correct events -// joined with wrong product catalog. +// joined with the wrong product catalog. A rejoin operation can take +// hours or days to complete. // // - parent: The parent catalog resource name, such as // `projects/1234/locations/global/catalogs/default_catalog`. @@ -9457,7 +9550,7 @@ func (c *ProjectsLocationsCatalogsUserEventsRejoinCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Triggers a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This API can be used to trigger a 'join' operation on specified events with latest version of product catalog. It can also be used to correct events joined with wrong product catalog.", + // "description": "Starts a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This method can be used to start a join operation on specified events with latest version of product catalog. It can also be used to correct events joined with the wrong product catalog. A rejoin operation can take hours or days to complete.", // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/catalogs/{catalogsId}/userEvents:rejoin", // "httpMethod": "POST", // "id": "retail.projects.locations.catalogs.userEvents.rejoin", diff --git a/retail/v2alpha/retail-api.json b/retail/v2alpha/retail-api.json index adc3f69be22..676bc0b9dc3 100644 --- a/retail/v2alpha/retail-api.json +++ b/retail/v2alpha/retail-api.json @@ -155,7 +155,7 @@ "type": "string" }, "visitorId": { - "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "description": "Required field. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", "location": "query", "type": "string" } @@ -731,6 +731,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "purge": { + "description": "Permanently deletes all selected Products under a branch. This process is asynchronous. If the request is valid, the removal will be enqueued and processed offline. Depending on the number of Products, this operation could take hours to complete. Before the operation completes, some Products may still be returned by GetProduct or ListProducts. Depending on the number of Products, this operation could take hours to complete. To get a sample of Products that would be deleted, set PurgeProductsRequest.force to false.", + "flatPath": "v2alpha/projects/{projectsId}/locations/{locationsId}/catalogs/{catalogsId}/branches/{branchesId}/products:purge", + "httpMethod": "POST", + "id": "retail.projects.locations.catalogs.branches.products.purge", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The resource name of the branch under which the products are created. The format is `projects/${projectId}/locations/global/catalogs/${catalogId}/branches/${branchId}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/branches/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2alpha/{+parent}/products:purge", + "request": { + "$ref": "GoogleCloudRetailV2alphaPurgeProductsRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "removeFulfillmentPlaces": { "description": "Incrementally removes place IDs from a Product.fulfillment_info.place_ids. This process is asynchronous and does not require the Product to exist before updating fulfillment information. If the request is valid, the update will be enqueued and processed downstream. As a consequence, when a response is returned, the removed place IDs are not immediately manifested in the Product queried by GetProduct or ListProducts. This feature is only available for users who have Retail Search enabled. Please submit a form [here](https://cloud.google.com/contact) to contact cloud sales if you are interested in using Retail Search.", "flatPath": "v2alpha/projects/{projectsId}/locations/{locationsId}/catalogs/{catalogsId}/branches/{branchesId}/products/{productsId}:removeFulfillmentPlaces", @@ -1456,7 +1484,7 @@ ] }, "rejoin": { - "description": "Triggers a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This API can be used to trigger a 'join' operation on specified events with latest version of product catalog. It can also be used to correct events joined with wrong product catalog.", + "description": "Starts a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This method can be used to start a join operation on specified events with latest version of product catalog. It can also be used to correct events joined with the wrong product catalog. A rejoin operation can take hours or days to complete.", "flatPath": "v2alpha/projects/{projectsId}/locations/{locationsId}/catalogs/{catalogsId}/userEvents:rejoin", "httpMethod": "POST", "id": "retail.projects.locations.catalogs.userEvents.rejoin", @@ -1660,7 +1688,7 @@ } } }, - "revision": "20220303", + "revision": "20220316", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -2116,7 +2144,7 @@ ], "enumDescriptions": [ "Value used when unset. Defaults to CATALOG_LEVEL_ATTRIBUTE_CONFIG.", - "At this level, we honor the attribute configurations set in Product.attribtues.", + "At this level, we honor the attribute configurations set in Product.attributes.", "At this level, we honor the attribute configurations set in CatalogConfig.attribute_configs." ], "readOnly": true, @@ -2471,6 +2499,23 @@ "$ref": "GoogleCloudRetailV2alphaRule", "description": "A rule control - a condition-action pair. Enacts a set action when the condition is triggered. For example: Boost \"gShoe\" when query full matches \"Running Shoes\"." }, + "searchSolutionUseCase": { + "description": "Required. Specifies the use case for the control. Affects what condition fields can be set. Only settable by search controls. Will default to SEARCH_SOLUTION_USE_CASE_SEARCH if not specified. Currently only allow one search_solution_use_case per control.", + "items": { + "enum": [ + "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED", + "SEARCH_SOLUTION_USE_CASE_SEARCH", + "SEARCH_SOLUTION_USE_CASE_BROWSE" + ], + "enumDescriptions": [ + "The value when it's unspecified. Defaults to SEARCH.", + "Search use case. Expects the traffic has a non-empty query.", + "Browse use case. Expects the traffic has an empty query." + ], + "type": "string" + }, + "type": "array" + }, "solutionTypes": { "description": "Required. Immutable. The solution types that the serving config is used for. Currently we support setting only one type of solution at creation time. Only `SOLUTION_TYPE_SEARCH` value is supported at the moment. If no solution type is provided at creation time, will default to SOLUTION_TYPE_SEARCH.", "items": { @@ -2642,7 +2687,7 @@ "type": "object" }, "GoogleCloudRetailV2alphaImage": { - "description": "Product thumbnail/detail image.", + "description": "Product image. Recommendations AI and Retail Search do not use product images to improve prediction and search results. However, product images can be returned in results, and are shown in prediction or search previews in the console.", "id": "GoogleCloudRetailV2alphaImage", "properties": { "height": { @@ -2946,7 +2991,7 @@ "additionalProperties": { "$ref": "GoogleCloudRetailV2alphaCustomAttribute" }, - "description": "Additional local inventory attributes, for example, store name, promotion tags, etc. This field needs to pass all below criteria, otherwise an INVALID_ARGUMENT error is returned: * At most 30 attributes are allowed. * The key must be a UTF-8 encoded string with a length limit of 32 characters. * The key must match the pattern: `a-zA-Z0-9*`. For example, key0LikeThis or KEY_1_LIKE_THIS. * The attribute values must be of the same type (text or number). * The max number of values per attribute is 10. * For text values, the length limit is 256 UTF-8 characters. * The attribute does not support search. The `searchable` field should be unset or set to false. * The max summed total bytes of custom attribute keys and values per product is 5MiB.", + "description": "Additional local inventory attributes, for example, store name, promotion tags, etc. This field needs to pass all below criteria, otherwise an INVALID_ARGUMENT error is returned: * At most 30 attributes are allowed. * The key must be a UTF-8 encoded string with a length limit of 32 characters. * The key must match the pattern: `a-zA-Z0-9*`. For example, key0LikeThis or KEY_1_LIKE_THIS. * The attribute values must be of the same type (text or number). * Only 1 value is allowed for each attribute. * For text values, the length limit is 256 UTF-8 characters. * The attribute does not support search. The `searchable` field should be unset or set to false. * The max summed total bytes of custom attribute keys and values per product is 5MiB.", "type": "object" }, "placeId": { @@ -3010,7 +3055,7 @@ "id": "GoogleCloudRetailV2alphaPredictRequest", "properties": { "filter": { - "description": "Filter for restricting prediction results with a length limit of 5,000 characters. Accepts values for tags and the `filterOutOfStockItems` flag. * Tag expressions. Restricts predictions to products that match all of the specified tags. Boolean operators `OR` and `NOT` are supported if the expression is enclosed in parentheses, and must be separated from the tag values by a space. `-\"tagA\"` is also supported and is equivalent to `NOT \"tagA\"`. Tag values must be double quoted UTF-8 encoded strings with a size limit of 1,000 characters. Note: \"Recently viewed\" models don't support tag filtering at the moment. * filterOutOfStockItems. Restricts predictions to products that do not have a stockState value of OUT_OF_STOCK. Examples: * tag=(\"Red\" OR \"Blue\") tag=\"New-Arrival\" tag=(NOT \"promotional\") * filterOutOfStockItems tag=(-\"promotional\") * filterOutOfStockItems If your filter blocks all prediction results, nothing will be returned. If you want generic (unfiltered) popular products to be returned instead, set `strictFiltering` to false in `PredictRequest.params`.", + "description": "Filter for restricting prediction results with a length limit of 5,000 characters. Accepts values for tags and the `filterOutOfStockItems` flag. * Tag expressions. Restricts predictions to products that match all of the specified tags. Boolean operators `OR` and `NOT` are supported if the expression is enclosed in parentheses, and must be separated from the tag values by a space. `-\"tagA\"` is also supported and is equivalent to `NOT \"tagA\"`. Tag values must be double quoted UTF-8 encoded strings with a size limit of 1,000 characters. Note: \"Recently viewed\" models don't support tag filtering at the moment. * filterOutOfStockItems. Restricts predictions to products that do not have a stockState value of OUT_OF_STOCK. Examples: * tag=(\"Red\" OR \"Blue\") tag=\"New-Arrival\" tag=(NOT \"promotional\") * filterOutOfStockItems tag=(-\"promotional\") * filterOutOfStockItems If your filter blocks all prediction results, the API will return generic (unfiltered) popular products. If you only want results strictly matching the filters, set `strictFiltering` to True in `PredictRequest.params` to receive empty results instead. Note that the API will never return items with storageStatus of \"EXPIRED\" or \"DELETED\" regardless of filter choices.", "type": "string" }, "labels": { @@ -3250,7 +3295,7 @@ "type": "string" }, "images": { - "description": "Product images for the product.Highly recommended to put the main image to the first. A maximum of 300 images are allowed. Corresponding properties: Google Merchant Center property [image_link](https://support.google.com/merchants/answer/6324350). Schema.org property [Product.image](https://schema.org/image).", + "description": "Product images for the product. We highly recommend putting the main image first. A maximum of 300 images are allowed. Corresponding properties: Google Merchant Center property [image_link](https://support.google.com/merchants/answer/6324350). Schema.org property [Product.image](https://schema.org/image).", "items": { "$ref": "GoogleCloudRetailV2alphaImage" }, @@ -3472,6 +3517,67 @@ "properties": {}, "type": "object" }, + "GoogleCloudRetailV2alphaPurgeProductsMetadata": { + "description": "Metadata related to the progress of the PurgeProducts operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudRetailV2alphaPurgeProductsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of entries that were deleted successfully.", + "format": "int64", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudRetailV2alphaPurgeProductsRequest": { + "description": "Request message for PurgeProducts method.", + "id": "GoogleCloudRetailV2alphaPurgeProductsRequest", + "properties": { + "filter": { + "description": "Required. The filter string to specify the products to be deleted with a length limit of 5,000 characters. Empty string filter is not allowed. \"*\" implies delete all items in a branch. The eligible fields for filtering are: * `availability`: Double quoted Product.availability string. * `create_time` : in ISO 8601 \"zulu\" format. Supported syntax: * Comparators (\"\u003e\", \"\u003c\", \"\u003e=\", \"\u003c=\", \"=\"). Examples: * create_time \u003c= \"2015-02-13T17:05:46Z\" * availability = \"IN_STOCK” * Conjunctions (\"AND\") Examples: * create_time \u003c= \"2015-02-13T17:05:46Z\" AND availability = \"PREORDER\" * Disjunctions (\"OR\") Examples: * create_time \u003c= \"2015-02-13T17:05:46Z\" OR availability = \"IN_STOCK\" * Can support nested queries. Examples: * (create_time \u003c= \"2015-02-13T17:05:46Z\" AND availability = \"PREORDER\") OR (create_time \u003e= \"2015-02-14T13:03:32Z\" AND availability = \"IN_STOCK\") * Filter Limits: * Filter should not contain more than 6 conditions. * Max nesting depth should not exceed 2 levels. Examples queries: * Delete back order products created before a timestamp. create_time \u003c= \"2015-02-13T17:05:46Z\" OR availability = \"BACKORDER”", + "type": "string" + }, + "force": { + "description": "Actually perform the purge. If `force` is set to false, the method will return the expected purge count without deleting any products.", + "type": "boolean" + } + }, + "type": "object" + }, + "GoogleCloudRetailV2alphaPurgeProductsResponse": { + "description": "Response of the PurgeProductsRequest. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudRetailV2alphaPurgeProductsResponse", + "properties": { + "purgeCount": { + "description": "The total count of products purged as a result of the operation.", + "format": "int64", + "type": "string" + }, + "purgeSample": { + "description": "A sample of the product names that will be deleted. Only populated if `force` is set to false. A max of 100 names will be returned and the names are chosen at random.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaPurgeUserEventsRequest": { "description": "Request message for PurgeUserEvents method.", "id": "GoogleCloudRetailV2alphaPurgeUserEventsRequest", @@ -3875,7 +3981,7 @@ "type": "string" }, "canonicalFilter": { - "description": "The filter applied to every search request when quality improvement such as query expansion is needed. For example, if a query does not have enough results, an expanded query with SearchRequest.canonical_filter will be returned as a supplement of the original query. This field is strongly recommended to achieve high search quality. See SearchRequest.filter for more details about filter syntax.", + "description": "The default filter that is applied when a user performs a search without checking any filters on the search page. The filter applied to every search request when quality improvement such as query expansion is needed. For example, if a query does not have enough results, an expanded query with SearchRequest.canonical_filter will be returned as a supplement of the original query. This field is strongly recommended to achieve high search quality. See SearchRequest.filter for more details about filter syntax.", "type": "string" }, "dynamicFacetSpec": { @@ -4487,7 +4593,7 @@ "additionalProperties": { "$ref": "GoogleCloudRetailV2alphaCustomAttribute" }, - "description": "Extra user event features to include in the recommendation model. This field needs to pass all below criteria, otherwise an INVALID_ARGUMENT error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendation, an example of extra user information is traffic_channel, i.e. how user arrives at the site. Users can arrive at the site by coming to the site directly, or coming through Google search, and etc.", + "description": "Extra user event features to include in the recommendation model. If you provide custom attributes for ingested user events, also include them in the user events that you associate with prediction requests. Custom attribute formatting must be consistent between imported events and events provided with prediction requests. This lets the Retail API use those custom attributes when training models and serving predictions, which helps improve recommendation quality. This field needs to pass all below criteria, otherwise an INVALID_ARGUMENT error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendations, an example of extra user information is traffic_channel, which is how a user arrives at the site. Users can arrive at the site by coming to the site directly, coming through Google search, or in other ways.", "type": "object" }, "attributionToken": { diff --git a/retail/v2alpha/retail-gen.go b/retail/v2alpha/retail-gen.go index bf87ec2f2a8..01954d7090a 100644 --- a/retail/v2alpha/retail-gen.go +++ b/retail/v2alpha/retail-gen.go @@ -1159,7 +1159,7 @@ type GoogleCloudRetailV2alphaAttributesConfig struct { // "ATTRIBUTE_CONFIG_LEVEL_UNSPECIFIED" - Value used when unset. // Defaults to CATALOG_LEVEL_ATTRIBUTE_CONFIG. // "PRODUCT_LEVEL_ATTRIBUTE_CONFIG" - At this level, we honor the - // attribute configurations set in Product.attribtues. + // attribute configurations set in Product.attributes. // "CATALOG_LEVEL_ATTRIBUTE_CONFIG" - At this level, we honor the // attribute configurations set in CatalogConfig.attribute_configs. AttributeConfigLevel string `json:"attributeConfigLevel,omitempty"` @@ -1842,6 +1842,21 @@ type GoogleCloudRetailV2alphaControl struct { // query full matches "Running Shoes". Rule *GoogleCloudRetailV2alphaRule `json:"rule,omitempty"` + // SearchSolutionUseCase: Required. Specifies the use case for the + // control. Affects what condition fields can be set. Only settable by + // search controls. Will default to SEARCH_SOLUTION_USE_CASE_SEARCH if + // not specified. Currently only allow one search_solution_use_case per + // control. + // + // Possible values: + // "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED" - The value when it's + // unspecified. Defaults to SEARCH. + // "SEARCH_SOLUTION_USE_CASE_SEARCH" - Search use case. Expects the + // traffic has a non-empty query. + // "SEARCH_SOLUTION_USE_CASE_BROWSE" - Browse use case. Expects the + // traffic has an empty query. + SearchSolutionUseCase []string `json:"searchSolutionUseCase,omitempty"` + // SolutionTypes: Required. Immutable. The solution types that the // serving config is used for. Currently we support setting only one // type of solution at creation time. Only `SOLUTION_TYPE_SEARCH` value @@ -2215,7 +2230,10 @@ func (s *GoogleCloudRetailV2alphaGetDefaultBranchResponse) MarshalJSON() ([]byte return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRetailV2alphaImage: Product thumbnail/detail image. +// GoogleCloudRetailV2alphaImage: Product image. Recommendations AI and +// Retail Search do not use product images to improve prediction and +// search results. However, product images can be returned in results, +// and are shown in prediction or search previews in the console. type GoogleCloudRetailV2alphaImage struct { // Height: Height of the image in number of pixels. This field must be // nonnegative. Otherwise, an INVALID_ARGUMENT error is returned. @@ -2816,7 +2834,7 @@ type GoogleCloudRetailV2alphaLocalInventory struct { // with a length limit of 32 characters. * The key must match the // pattern: `a-zA-Z0-9*`. For example, key0LikeThis or KEY_1_LIKE_THIS. // * The attribute values must be of the same type (text or number). * - // The max number of values per attribute is 10. * For text values, the + // Only 1 value is allowed for each attribute. * For text values, the // length limit is 256 UTF-8 characters. * The attribute does not // support search. The `searchable` field should be unset or set to // false. * The max summed total bytes of custom attribute keys and @@ -2964,9 +2982,11 @@ type GoogleCloudRetailV2alphaPredictRequest struct { // OUT_OF_STOCK. Examples: * tag=("Red" OR "Blue") tag="New-Arrival" // tag=(NOT "promotional") * filterOutOfStockItems tag=(-"promotional") // * filterOutOfStockItems If your filter blocks all prediction results, - // nothing will be returned. If you want generic (unfiltered) popular - // products to be returned instead, set `strictFiltering` to false in - // `PredictRequest.params`. + // the API will return generic (unfiltered) popular products. If you + // only want results strictly matching the filters, set + // `strictFiltering` to True in `PredictRequest.params` to receive empty + // results instead. Note that the API will never return items with + // storageStatus of "EXPIRED" or "DELETED" regardless of filter choices. Filter string `json:"filter,omitempty"` // Labels: The labels applied to a resource must meet the following @@ -3411,8 +3431,8 @@ type GoogleCloudRetailV2alphaProduct struct { // Schema.org property Product.sku (https://schema.org/sku). Id string `json:"id,omitempty"` - // Images: Product images for the product.Highly recommended to put the - // main image to the first. A maximum of 300 images are allowed. + // Images: Product images for the product. We highly recommend putting + // the main image first. A maximum of 300 images are allowed. // Corresponding properties: Google Merchant Center property image_link // (https://support.google.com/merchants/answer/6324350). Schema.org // property Product.image (https://schema.org/image). @@ -3876,6 +3896,134 @@ func (s *GoogleCloudRetailV2alphaPurchaseTransaction) UnmarshalJSON(data []byte) type GoogleCloudRetailV2alphaPurgeMetadata struct { } +// GoogleCloudRetailV2alphaPurgeProductsMetadata: Metadata related to +// the progress of the PurgeProducts operation. This will be returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudRetailV2alphaPurgeProductsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudRetailV2alphaPurgeProductsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaPurgeProductsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRetailV2alphaPurgeProductsRequest: Request message for +// PurgeProducts method. +type GoogleCloudRetailV2alphaPurgeProductsRequest struct { + // Filter: Required. The filter string to specify the products to be + // deleted with a length limit of 5,000 characters. Empty string filter + // is not allowed. "*" implies delete all items in a branch. The + // eligible fields for filtering are: * `availability`: Double quoted + // Product.availability string. * `create_time` : in ISO 8601 "zulu" + // format. Supported syntax: * Comparators (">", "<", ">=", "<=", "="). + // Examples: * create_time <= "2015-02-13T17:05:46Z" * availability = + // "IN_STOCK” * Conjunctions ("AND") Examples: * create_time <= + // "2015-02-13T17:05:46Z" AND availability = "PREORDER" * Disjunctions + // ("OR") Examples: * create_time <= "2015-02-13T17:05:46Z" OR + // availability = "IN_STOCK" * Can support nested queries. Examples: * + // (create_time <= "2015-02-13T17:05:46Z" AND availability = "PREORDER") + // OR (create_time >= "2015-02-14T13:03:32Z" AND availability = + // "IN_STOCK") * Filter Limits: * Filter should not contain more than 6 + // conditions. * Max nesting depth should not exceed 2 levels. Examples + // queries: * Delete back order products created before a timestamp. + // create_time <= "2015-02-13T17:05:46Z" OR availability = "BACKORDER” + Filter string `json:"filter,omitempty"` + + // Force: Actually perform the purge. If `force` is set to false, the + // method will return the expected purge count without deleting any + // products. + Force bool `json:"force,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Filter") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Filter") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudRetailV2alphaPurgeProductsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaPurgeProductsRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRetailV2alphaPurgeProductsResponse: Response of the +// PurgeProductsRequest. If the long running operation is successfully +// done, then this message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudRetailV2alphaPurgeProductsResponse struct { + // PurgeCount: The total count of products purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // PurgeSample: A sample of the product names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudRetailV2alphaPurgeProductsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaPurgeProductsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaPurgeUserEventsRequest: Request message for // PurgeUserEvents method. type GoogleCloudRetailV2alphaPurgeUserEventsRequest struct { @@ -4705,9 +4853,11 @@ type GoogleCloudRetailV2alphaSearchRequest struct { // search products under the default branch. Branch string `json:"branch,omitempty"` - // CanonicalFilter: The filter applied to every search request when - // quality improvement such as query expansion is needed. For example, - // if a query does not have enough results, an expanded query with + // CanonicalFilter: The default filter that is applied when a user + // performs a search without checking any filters on the search page. + // The filter applied to every search request when quality improvement + // such as query expansion is needed. For example, if a query does not + // have enough results, an expanded query with // SearchRequest.canonical_filter will be returned as a supplement of // the original query. This field is strongly recommended to achieve // high search quality. See SearchRequest.filter for more details about @@ -5824,16 +5974,23 @@ type GoogleCloudRetailV2alphaSetInventoryResponse struct { // with customers' website. type GoogleCloudRetailV2alphaUserEvent struct { // Attributes: Extra user event features to include in the - // recommendation model. This field needs to pass all below criteria, - // otherwise an INVALID_ARGUMENT error is returned: * The key must be a - // UTF-8 encoded string with a length limit of 5,000 characters. * For - // text attributes, at most 400 values are allowed. Empty values are not - // allowed. Each value must be a UTF-8 encoded string with a length - // limit of 256 characters. * For number attributes, at most 400 values - // are allowed. For product recommendation, an example of extra user - // information is traffic_channel, i.e. how user arrives at the site. - // Users can arrive at the site by coming to the site directly, or - // coming through Google search, and etc. + // recommendation model. If you provide custom attributes for ingested + // user events, also include them in the user events that you associate + // with prediction requests. Custom attribute formatting must be + // consistent between imported events and events provided with + // prediction requests. This lets the Retail API use those custom + // attributes when training models and serving predictions, which helps + // improve recommendation quality. This field needs to pass all below + // criteria, otherwise an INVALID_ARGUMENT error is returned: * The key + // must be a UTF-8 encoded string with a length limit of 5,000 + // characters. * For text attributes, at most 400 values are allowed. + // Empty values are not allowed. Each value must be a UTF-8 encoded + // string with a length limit of 256 characters. * For number + // attributes, at most 400 values are allowed. For product + // recommendations, an example of extra user information is + // traffic_channel, which is how a user arrives at the site. Users can + // arrive at the site by coming to the site directly, coming through + // Google search, or in other ways. Attributes map[string]GoogleCloudRetailV2alphaCustomAttribute `json:"attributes,omitempty"` // AttributionToken: Highly recommended for user events that are the @@ -6944,8 +7101,8 @@ func (c *ProjectsLocationsCatalogsCompleteQueryCall) Query(query string) *Projec return c } -// VisitorId sets the optional parameter "visitorId": A unique -// identifier for tracking visitors. For example, this could be +// VisitorId sets the optional parameter "visitorId": Required field. A +// unique identifier for tracking visitors. For example, this could be // implemented with an HTTP cookie, which should be able to uniquely // identify a visitor on a single device. This unique identifier should // not change if the visitor logs in or out of the website. The field @@ -7100,7 +7257,7 @@ func (c *ProjectsLocationsCatalogsCompleteQueryCall) Do(opts ...googleapi.CallOp // "type": "string" // }, // "visitorId": { - // "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + // "description": "Required field. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", // "location": "query", // "type": "string" // } @@ -10050,6 +10207,158 @@ func (c *ProjectsLocationsCatalogsBranchesProductsPatchCall) Do(opts ...googleap } +// method id "retail.projects.locations.catalogs.branches.products.purge": + +type ProjectsLocationsCatalogsBranchesProductsPurgeCall struct { + s *Service + parent string + googlecloudretailv2alphapurgeproductsrequest *GoogleCloudRetailV2alphaPurgeProductsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Purge: Permanently deletes all selected Products under a branch. This +// process is asynchronous. If the request is valid, the removal will be +// enqueued and processed offline. Depending on the number of Products, +// this operation could take hours to complete. Before the operation +// completes, some Products may still be returned by GetProduct or +// ListProducts. Depending on the number of Products, this operation +// could take hours to complete. To get a sample of Products that would +// be deleted, set PurgeProductsRequest.force to false. +// +// - parent: The resource name of the branch under which the products +// are created. The format is +// `projects/${projectId}/locations/global/catalogs/${catalogId}/branch +// es/${branchId}`. +func (r *ProjectsLocationsCatalogsBranchesProductsService) Purge(parent string, googlecloudretailv2alphapurgeproductsrequest *GoogleCloudRetailV2alphaPurgeProductsRequest) *ProjectsLocationsCatalogsBranchesProductsPurgeCall { + c := &ProjectsLocationsCatalogsBranchesProductsPurgeCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudretailv2alphapurgeproductsrequest = googlecloudretailv2alphapurgeproductsrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCatalogsBranchesProductsPurgeCall) Fields(s ...googleapi.Field) *ProjectsLocationsCatalogsBranchesProductsPurgeCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCatalogsBranchesProductsPurgeCall) Context(ctx context.Context) *ProjectsLocationsCatalogsBranchesProductsPurgeCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCatalogsBranchesProductsPurgeCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCatalogsBranchesProductsPurgeCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudretailv2alphapurgeproductsrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2alpha/{+parent}/products:purge") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "retail.projects.locations.catalogs.branches.products.purge" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsCatalogsBranchesProductsPurgeCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, &googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + } + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, err + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Permanently deletes all selected Products under a branch. This process is asynchronous. If the request is valid, the removal will be enqueued and processed offline. Depending on the number of Products, this operation could take hours to complete. Before the operation completes, some Products may still be returned by GetProduct or ListProducts. Depending on the number of Products, this operation could take hours to complete. To get a sample of Products that would be deleted, set PurgeProductsRequest.force to false.", + // "flatPath": "v2alpha/projects/{projectsId}/locations/{locationsId}/catalogs/{catalogsId}/branches/{branchesId}/products:purge", + // "httpMethod": "POST", + // "id": "retail.projects.locations.catalogs.branches.products.purge", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The resource name of the branch under which the products are created. The format is `projects/${projectId}/locations/global/catalogs/${catalogId}/branches/${branchId}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/branches/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2alpha/{+parent}/products:purge", + // "request": { + // "$ref": "GoogleCloudRetailV2alphaPurgeProductsRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "retail.projects.locations.catalogs.branches.products.removeFulfillmentPlaces": type ProjectsLocationsCatalogsBranchesProductsRemoveFulfillmentPlacesCall struct { @@ -13766,14 +14075,15 @@ type ProjectsLocationsCatalogsUserEventsRejoinCall struct { header_ http.Header } -// Rejoin: Triggers a user event rejoin operation with latest product +// Rejoin: Starts a user event rejoin operation with latest product // catalog. Events will not be annotated with detailed product // information if product is missing from the catalog at the time the // user event is ingested, and these events are stored as unjoined -// events with a limited usage on training and serving. This API can be -// used to trigger a 'join' operation on specified events with latest +// events with a limited usage on training and serving. This method can +// be used to start a join operation on specified events with latest // version of product catalog. It can also be used to correct events -// joined with wrong product catalog. +// joined with the wrong product catalog. A rejoin operation can take +// hours or days to complete. // // - parent: The parent catalog resource name, such as // `projects/1234/locations/global/catalogs/default_catalog`. @@ -13875,7 +14185,7 @@ func (c *ProjectsLocationsCatalogsUserEventsRejoinCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Triggers a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This API can be used to trigger a 'join' operation on specified events with latest version of product catalog. It can also be used to correct events joined with wrong product catalog.", + // "description": "Starts a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This method can be used to start a join operation on specified events with latest version of product catalog. It can also be used to correct events joined with the wrong product catalog. A rejoin operation can take hours or days to complete.", // "flatPath": "v2alpha/projects/{projectsId}/locations/{locationsId}/catalogs/{catalogsId}/userEvents:rejoin", // "httpMethod": "POST", // "id": "retail.projects.locations.catalogs.userEvents.rejoin", diff --git a/retail/v2beta/retail-api.json b/retail/v2beta/retail-api.json index 5ffe06e8266..4d1ae5fd5bd 100644 --- a/retail/v2beta/retail-api.json +++ b/retail/v2beta/retail-api.json @@ -155,7 +155,7 @@ "type": "string" }, "visitorId": { - "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + "description": "Required field. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", "location": "query", "type": "string" } @@ -1395,7 +1395,7 @@ ] }, "rejoin": { - "description": "Triggers a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This API can be used to trigger a 'join' operation on specified events with latest version of product catalog. It can also be used to correct events joined with wrong product catalog.", + "description": "Starts a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This method can be used to start a join operation on specified events with latest version of product catalog. It can also be used to correct events joined with the wrong product catalog. A rejoin operation can take hours or days to complete.", "flatPath": "v2beta/projects/{projectsId}/locations/{locationsId}/catalogs/{catalogsId}/userEvents:rejoin", "httpMethod": "POST", "id": "retail.projects.locations.catalogs.userEvents.rejoin", @@ -1599,7 +1599,7 @@ } } }, - "revision": "20220303", + "revision": "20220316", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -2135,6 +2135,52 @@ "properties": {}, "type": "object" }, + "GoogleCloudRetailV2alphaPurgeProductsMetadata": { + "description": "Metadata related to the progress of the PurgeProducts operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudRetailV2alphaPurgeProductsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of entries that were deleted successfully.", + "format": "int64", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudRetailV2alphaPurgeProductsResponse": { + "description": "Response of the PurgeProductsRequest. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudRetailV2alphaPurgeProductsResponse", + "properties": { + "purgeCount": { + "description": "The total count of products purged as a result of the operation.", + "format": "int64", + "type": "string" + }, + "purgeSample": { + "description": "A sample of the product names that will be deleted. Only populated if `force` is set to false. A max of 100 names will be returned and the names are chosen at random.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaPurgeUserEventsResponse": { "description": "Response of the PurgeUserEventsRequest. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", "id": "GoogleCloudRetailV2alphaPurgeUserEventsResponse", @@ -2292,7 +2338,7 @@ ], "enumDescriptions": [ "Value used when unset. Defaults to CATALOG_LEVEL_ATTRIBUTE_CONFIG.", - "At this level, we honor the attribute configurations set in Product.attribtues.", + "At this level, we honor the attribute configurations set in Product.attributes.", "At this level, we honor the attribute configurations set in CatalogConfig.attribute_configs." ], "readOnly": true, @@ -2643,6 +2689,23 @@ "$ref": "GoogleCloudRetailV2betaRule", "description": "A rule control - a condition-action pair. Enacts a set action when the condition is triggered. For example: Boost \"gShoe\" when query full matches \"Running Shoes\"." }, + "searchSolutionUseCase": { + "description": "Required. Specifies the use case for the control. Affects what condition fields can be set. Only settable by search controls. Will default to SEARCH_SOLUTION_USE_CASE_SEARCH if not specified. Currently only allow one search_solution_use_case per control.", + "items": { + "enum": [ + "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED", + "SEARCH_SOLUTION_USE_CASE_SEARCH", + "SEARCH_SOLUTION_USE_CASE_BROWSE" + ], + "enumDescriptions": [ + "The value when it's unspecified. Defaults to SEARCH.", + "Search use case. Expects the traffic has a non-empty query.", + "Browse use case. Expects the traffic has an empty query." + ], + "type": "string" + }, + "type": "array" + }, "solutionTypes": { "description": "Required. Immutable. The solution types that the serving config is used for. Currently we support setting only one type of solution at creation time. Only `SOLUTION_TYPE_SEARCH` value is supported at the moment. If no solution type is provided at creation time, will default to SOLUTION_TYPE_SEARCH.", "items": { @@ -2814,7 +2877,7 @@ "type": "object" }, "GoogleCloudRetailV2betaImage": { - "description": "Product thumbnail/detail image.", + "description": "Product image. Recommendations AI and Retail Search do not use product images to improve prediction and search results. However, product images can be returned in results, and are shown in prediction or search previews in the console.", "id": "GoogleCloudRetailV2betaImage", "properties": { "height": { @@ -3110,7 +3173,7 @@ "id": "GoogleCloudRetailV2betaPredictRequest", "properties": { "filter": { - "description": "Filter for restricting prediction results with a length limit of 5,000 characters. Accepts values for tags and the `filterOutOfStockItems` flag. * Tag expressions. Restricts predictions to products that match all of the specified tags. Boolean operators `OR` and `NOT` are supported if the expression is enclosed in parentheses, and must be separated from the tag values by a space. `-\"tagA\"` is also supported and is equivalent to `NOT \"tagA\"`. Tag values must be double quoted UTF-8 encoded strings with a size limit of 1,000 characters. Note: \"Recently viewed\" models don't support tag filtering at the moment. * filterOutOfStockItems. Restricts predictions to products that do not have a stockState value of OUT_OF_STOCK. Examples: * tag=(\"Red\" OR \"Blue\") tag=\"New-Arrival\" tag=(NOT \"promotional\") * filterOutOfStockItems tag=(-\"promotional\") * filterOutOfStockItems If your filter blocks all prediction results, nothing will be returned. If you want generic (unfiltered) popular products to be returned instead, set `strictFiltering` to false in `PredictRequest.params`.", + "description": "Filter for restricting prediction results with a length limit of 5,000 characters. Accepts values for tags and the `filterOutOfStockItems` flag. * Tag expressions. Restricts predictions to products that match all of the specified tags. Boolean operators `OR` and `NOT` are supported if the expression is enclosed in parentheses, and must be separated from the tag values by a space. `-\"tagA\"` is also supported and is equivalent to `NOT \"tagA\"`. Tag values must be double quoted UTF-8 encoded strings with a size limit of 1,000 characters. Note: \"Recently viewed\" models don't support tag filtering at the moment. * filterOutOfStockItems. Restricts predictions to products that do not have a stockState value of OUT_OF_STOCK. Examples: * tag=(\"Red\" OR \"Blue\") tag=\"New-Arrival\" tag=(NOT \"promotional\") * filterOutOfStockItems tag=(-\"promotional\") * filterOutOfStockItems If your filter blocks all prediction results, the API will return generic (unfiltered) popular products. If you only want results strictly matching the filters, set `strictFiltering` to True in `PredictRequest.params` to receive empty results instead. Note that the API will never return items with storageStatus of \"EXPIRED\" or \"DELETED\" regardless of filter choices.", "type": "string" }, "labels": { @@ -3350,7 +3413,7 @@ "type": "string" }, "images": { - "description": "Product images for the product.Highly recommended to put the main image to the first. A maximum of 300 images are allowed. Corresponding properties: Google Merchant Center property [image_link](https://support.google.com/merchants/answer/6324350). Schema.org property [Product.image](https://schema.org/image).", + "description": "Product images for the product. We highly recommend putting the main image first. A maximum of 300 images are allowed. Corresponding properties: Google Merchant Center property [image_link](https://support.google.com/merchants/answer/6324350). Schema.org property [Product.image](https://schema.org/image).", "items": { "$ref": "GoogleCloudRetailV2betaImage" }, @@ -3940,7 +4003,7 @@ "type": "string" }, "canonicalFilter": { - "description": "The filter applied to every search request when quality improvement such as query expansion is needed. For example, if a query does not have enough results, an expanded query with SearchRequest.canonical_filter will be returned as a supplement of the original query. This field is strongly recommended to achieve high search quality. See SearchRequest.filter for more details about filter syntax.", + "description": "The default filter that is applied when a user performs a search without checking any filters on the search page. The filter applied to every search request when quality improvement such as query expansion is needed. For example, if a query does not have enough results, an expanded query with SearchRequest.canonical_filter will be returned as a supplement of the original query. This field is strongly recommended to achieve high search quality. See SearchRequest.filter for more details about filter syntax.", "type": "string" }, "dynamicFacetSpec": { @@ -4534,7 +4597,7 @@ "additionalProperties": { "$ref": "GoogleCloudRetailV2betaCustomAttribute" }, - "description": "Extra user event features to include in the recommendation model. This field needs to pass all below criteria, otherwise an INVALID_ARGUMENT error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendation, an example of extra user information is traffic_channel, i.e. how user arrives at the site. Users can arrive at the site by coming to the site directly, or coming through Google search, and etc.", + "description": "Extra user event features to include in the recommendation model. If you provide custom attributes for ingested user events, also include them in the user events that you associate with prediction requests. Custom attribute formatting must be consistent between imported events and events provided with prediction requests. This lets the Retail API use those custom attributes when training models and serving predictions, which helps improve recommendation quality. This field needs to pass all below criteria, otherwise an INVALID_ARGUMENT error is returned: * The key must be a UTF-8 encoded string with a length limit of 5,000 characters. * For text attributes, at most 400 values are allowed. Empty values are not allowed. Each value must be a UTF-8 encoded string with a length limit of 256 characters. * For number attributes, at most 400 values are allowed. For product recommendations, an example of extra user information is traffic_channel, which is how a user arrives at the site. Users can arrive at the site by coming to the site directly, coming through Google search, or in other ways.", "type": "object" }, "attributionToken": { diff --git a/retail/v2beta/retail-gen.go b/retail/v2beta/retail-gen.go index b209ad47f3a..467ada8eb2a 100644 --- a/retail/v2beta/retail-gen.go +++ b/retail/v2beta/retail-gen.go @@ -1317,6 +1317,84 @@ func (s *GoogleCloudRetailV2alphaImportUserEventsResponse) MarshalJSON() ([]byte type GoogleCloudRetailV2alphaPurgeMetadata struct { } +// GoogleCloudRetailV2alphaPurgeProductsMetadata: Metadata related to +// the progress of the PurgeProducts operation. This will be returned by +// the google.longrunning.Operation.metadata field. +type GoogleCloudRetailV2alphaPurgeProductsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudRetailV2alphaPurgeProductsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaPurgeProductsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRetailV2alphaPurgeProductsResponse: Response of the +// PurgeProductsRequest. If the long running operation is successfully +// done, then this message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudRetailV2alphaPurgeProductsResponse struct { + // PurgeCount: The total count of products purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // PurgeSample: A sample of the product names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudRetailV2alphaPurgeProductsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaPurgeProductsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaPurgeUserEventsResponse: Response of the // PurgeUserEventsRequest. If the long running operation is successfully // done, then this message is returned by the @@ -1604,7 +1682,7 @@ type GoogleCloudRetailV2betaAttributesConfig struct { // "ATTRIBUTE_CONFIG_LEVEL_UNSPECIFIED" - Value used when unset. // Defaults to CATALOG_LEVEL_ATTRIBUTE_CONFIG. // "PRODUCT_LEVEL_ATTRIBUTE_CONFIG" - At this level, we honor the - // attribute configurations set in Product.attribtues. + // attribute configurations set in Product.attributes. // "CATALOG_LEVEL_ATTRIBUTE_CONFIG" - At this level, we honor the // attribute configurations set in CatalogConfig.attribute_configs. AttributeConfigLevel string `json:"attributeConfigLevel,omitempty"` @@ -2279,6 +2357,21 @@ type GoogleCloudRetailV2betaControl struct { // query full matches "Running Shoes". Rule *GoogleCloudRetailV2betaRule `json:"rule,omitempty"` + // SearchSolutionUseCase: Required. Specifies the use case for the + // control. Affects what condition fields can be set. Only settable by + // search controls. Will default to SEARCH_SOLUTION_USE_CASE_SEARCH if + // not specified. Currently only allow one search_solution_use_case per + // control. + // + // Possible values: + // "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED" - The value when it's + // unspecified. Defaults to SEARCH. + // "SEARCH_SOLUTION_USE_CASE_SEARCH" - Search use case. Expects the + // traffic has a non-empty query. + // "SEARCH_SOLUTION_USE_CASE_BROWSE" - Browse use case. Expects the + // traffic has an empty query. + SearchSolutionUseCase []string `json:"searchSolutionUseCase,omitempty"` + // SolutionTypes: Required. Immutable. The solution types that the // serving config is used for. Currently we support setting only one // type of solution at creation time. Only `SOLUTION_TYPE_SEARCH` value @@ -2652,7 +2745,10 @@ func (s *GoogleCloudRetailV2betaGetDefaultBranchResponse) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRetailV2betaImage: Product thumbnail/detail image. +// GoogleCloudRetailV2betaImage: Product image. Recommendations AI and +// Retail Search do not use product images to improve prediction and +// search results. However, product images can be returned in results, +// and are shown in prediction or search previews in the console. type GoogleCloudRetailV2betaImage struct { // Height: Height of the image in number of pixels. This field must be // nonnegative. Otherwise, an INVALID_ARGUMENT error is returned. @@ -3253,9 +3349,11 @@ type GoogleCloudRetailV2betaPredictRequest struct { // OUT_OF_STOCK. Examples: * tag=("Red" OR "Blue") tag="New-Arrival" // tag=(NOT "promotional") * filterOutOfStockItems tag=(-"promotional") // * filterOutOfStockItems If your filter blocks all prediction results, - // nothing will be returned. If you want generic (unfiltered) popular - // products to be returned instead, set `strictFiltering` to false in - // `PredictRequest.params`. + // the API will return generic (unfiltered) popular products. If you + // only want results strictly matching the filters, set + // `strictFiltering` to True in `PredictRequest.params` to receive empty + // results instead. Note that the API will never return items with + // storageStatus of "EXPIRED" or "DELETED" regardless of filter choices. Filter string `json:"filter,omitempty"` // Labels: The labels applied to a resource must meet the following @@ -3699,8 +3797,8 @@ type GoogleCloudRetailV2betaProduct struct { // Schema.org property Product.sku (https://schema.org/sku). Id string `json:"id,omitempty"` - // Images: Product images for the product.Highly recommended to put the - // main image to the first. A maximum of 300 images are allowed. + // Images: Product images for the product. We highly recommend putting + // the main image first. A maximum of 300 images are allowed. // Corresponding properties: Google Merchant Center property image_link // (https://support.google.com/merchants/answer/6324350). Schema.org // property Product.image (https://schema.org/image). @@ -4939,9 +5037,11 @@ type GoogleCloudRetailV2betaSearchRequest struct { // search products under the default branch. Branch string `json:"branch,omitempty"` - // CanonicalFilter: The filter applied to every search request when - // quality improvement such as query expansion is needed. For example, - // if a query does not have enough results, an expanded query with + // CanonicalFilter: The default filter that is applied when a user + // performs a search without checking any filters on the search page. + // The filter applied to every search request when quality improvement + // such as query expansion is needed. For example, if a query does not + // have enough results, an expanded query with // SearchRequest.canonical_filter will be returned as a supplement of // the original query. This field is strongly recommended to achieve // high search quality. See SearchRequest.filter for more details about @@ -6042,16 +6142,23 @@ type GoogleCloudRetailV2betaSetInventoryResponse struct { // with customers' website. type GoogleCloudRetailV2betaUserEvent struct { // Attributes: Extra user event features to include in the - // recommendation model. This field needs to pass all below criteria, - // otherwise an INVALID_ARGUMENT error is returned: * The key must be a - // UTF-8 encoded string with a length limit of 5,000 characters. * For - // text attributes, at most 400 values are allowed. Empty values are not - // allowed. Each value must be a UTF-8 encoded string with a length - // limit of 256 characters. * For number attributes, at most 400 values - // are allowed. For product recommendation, an example of extra user - // information is traffic_channel, i.e. how user arrives at the site. - // Users can arrive at the site by coming to the site directly, or - // coming through Google search, and etc. + // recommendation model. If you provide custom attributes for ingested + // user events, also include them in the user events that you associate + // with prediction requests. Custom attribute formatting must be + // consistent between imported events and events provided with + // prediction requests. This lets the Retail API use those custom + // attributes when training models and serving predictions, which helps + // improve recommendation quality. This field needs to pass all below + // criteria, otherwise an INVALID_ARGUMENT error is returned: * The key + // must be a UTF-8 encoded string with a length limit of 5,000 + // characters. * For text attributes, at most 400 values are allowed. + // Empty values are not allowed. Each value must be a UTF-8 encoded + // string with a length limit of 256 characters. * For number + // attributes, at most 400 values are allowed. For product + // recommendations, an example of extra user information is + // traffic_channel, which is how a user arrives at the site. Users can + // arrive at the site by coming to the site directly, coming through + // Google search, or in other ways. Attributes map[string]GoogleCloudRetailV2betaCustomAttribute `json:"attributes,omitempty"` // AttributionToken: Highly recommended for user events that are the @@ -6677,8 +6784,8 @@ func (c *ProjectsLocationsCatalogsCompleteQueryCall) Query(query string) *Projec return c } -// VisitorId sets the optional parameter "visitorId": A unique -// identifier for tracking visitors. For example, this could be +// VisitorId sets the optional parameter "visitorId": Required field. A +// unique identifier for tracking visitors. For example, this could be // implemented with an HTTP cookie, which should be able to uniquely // identify a visitor on a single device. This unique identifier should // not change if the visitor logs in or out of the website. The field @@ -6833,7 +6940,7 @@ func (c *ProjectsLocationsCatalogsCompleteQueryCall) Do(opts ...googleapi.CallOp // "type": "string" // }, // "visitorId": { - // "description": "A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", + // "description": "Required field. A unique identifier for tracking visitors. For example, this could be implemented with an HTTP cookie, which should be able to uniquely identify a visitor on a single device. This unique identifier should not change if the visitor logs in or out of the website. The field must be a UTF-8 encoded string with a length limit of 128 characters. Otherwise, an INVALID_ARGUMENT error is returned.", // "location": "query", // "type": "string" // } @@ -13166,14 +13273,15 @@ type ProjectsLocationsCatalogsUserEventsRejoinCall struct { header_ http.Header } -// Rejoin: Triggers a user event rejoin operation with latest product +// Rejoin: Starts a user event rejoin operation with latest product // catalog. Events will not be annotated with detailed product // information if product is missing from the catalog at the time the // user event is ingested, and these events are stored as unjoined -// events with a limited usage on training and serving. This API can be -// used to trigger a 'join' operation on specified events with latest +// events with a limited usage on training and serving. This method can +// be used to start a join operation on specified events with latest // version of product catalog. It can also be used to correct events -// joined with wrong product catalog. +// joined with the wrong product catalog. A rejoin operation can take +// hours or days to complete. // // - parent: The parent catalog resource name, such as // `projects/1234/locations/global/catalogs/default_catalog`. @@ -13275,7 +13383,7 @@ func (c *ProjectsLocationsCatalogsUserEventsRejoinCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Triggers a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This API can be used to trigger a 'join' operation on specified events with latest version of product catalog. It can also be used to correct events joined with wrong product catalog.", + // "description": "Starts a user event rejoin operation with latest product catalog. Events will not be annotated with detailed product information if product is missing from the catalog at the time the user event is ingested, and these events are stored as unjoined events with a limited usage on training and serving. This method can be used to start a join operation on specified events with latest version of product catalog. It can also be used to correct events joined with the wrong product catalog. A rejoin operation can take hours or days to complete.", // "flatPath": "v2beta/projects/{projectsId}/locations/{locationsId}/catalogs/{catalogsId}/userEvents:rejoin", // "httpMethod": "POST", // "id": "retail.projects.locations.catalogs.userEvents.rejoin", diff --git a/servicecontrol/v1/servicecontrol-api.json b/servicecontrol/v1/servicecontrol-api.json index 8a675957893..35f801fc5a9 100644 --- a/servicecontrol/v1/servicecontrol-api.json +++ b/servicecontrol/v1/servicecontrol-api.json @@ -197,7 +197,7 @@ } } }, - "revision": "20220218", + "revision": "20220315", "rootUrl": "https://servicecontrol.googleapis.com/", "schemas": { "AllocateInfo": { @@ -332,6 +332,10 @@ "format": "int64", "type": "string" }, + "policyViolationInfo": { + "$ref": "PolicyViolationInfo", + "description": "Indicates the policy violations for this request. If the request is denied by the policy, violation information will be logged here." + }, "request": { "additionalProperties": { "description": "Properties of the object.", @@ -1252,6 +1256,39 @@ }, "type": "object" }, + "OrgPolicyViolationInfo": { + "description": "Represents OrgPolicy Violation information.", + "id": "OrgPolicyViolationInfo", + "properties": { + "payload": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Optional. Resource payload that is currently in scope and is subjected to orgpolicy conditions. This payload may be the subset of the actual Resource that may come in the request. This payload should not contain any core content.", + "type": "object" + }, + "resourceTags": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Tags referenced on the resource at the time of evaluation. These also include the federated tags, if they are supplied in the CheckOrgPolicy or CheckCustomConstraints Requests. Optional field as of now. These tags are the Cloud tags that are available on the resource during the policy evaluation and will be available as part of the OrgPolicy check response for logging purposes.", + "type": "object" + }, + "resourceType": { + "description": "Optional. Resource type that the orgpolicy is checked against. Example: compute.googleapis.com/Instance, store.googleapis.com/bucket", + "type": "string" + }, + "violationInfo": { + "description": "Optional. Policy violations", + "items": { + "$ref": "ViolationInfo" + }, + "type": "array" + } + }, + "type": "object" + }, "Peer": { "description": "This message defines attributes for a node that handles a network request. The node can be either a service or an application that sends, forwards, or receives the request. Service peers should fill in `principal` and `labels` as appropriate.", "id": "Peer", @@ -1283,6 +1320,17 @@ }, "type": "object" }, + "PolicyViolationInfo": { + "description": "Information related to policy violations for this request.", + "id": "PolicyViolationInfo", + "properties": { + "orgPolicyViolationInfo": { + "$ref": "OrgPolicyViolationInfo", + "description": "Indicates the orgpolicy violations for this resource." + } + }, + "type": "object" + }, "QuotaError": { "description": "Represents error information for QuotaOperation.", "id": "QuotaError", @@ -2057,6 +2105,41 @@ } }, "type": "object" + }, + "ViolationInfo": { + "description": "Provides information about the Policy violation info for this request.", + "id": "ViolationInfo", + "properties": { + "checkedValue": { + "description": "Optional. Value that is being checked for the policy. This could be in encrypted form (if pii sensitive). This field will only be emitted in LIST_POLICY types", + "type": "string" + }, + "constraint": { + "description": "Optional. Constraint name", + "type": "string" + }, + "errorMessage": { + "description": "Optional. Error message that policy is indicating.", + "type": "string" + }, + "policyType": { + "description": "Optional. Indicates the type of the policy.", + "enum": [ + "POLICY_TYPE_UNSPECIFIED", + "BOOLEAN_CONSTRAINT", + "LIST_CONSTRAINT", + "CUSTOM_CONSTRAINT" + ], + "enumDescriptions": [ + "Default value. This value should not be used.", + "Indicates boolean policy constraint", + "Indicates list policy constraint", + "Indicates custom policy constraint" + ], + "type": "string" + } + }, + "type": "object" } }, "servicePath": "", diff --git a/servicecontrol/v1/servicecontrol-gen.go b/servicecontrol/v1/servicecontrol-gen.go index 229997db334..cbc26328bf8 100644 --- a/servicecontrol/v1/servicecontrol-gen.go +++ b/servicecontrol/v1/servicecontrol-gen.go @@ -372,6 +372,11 @@ type AuditLog struct { // API method, if applicable. NumResponseItems int64 `json:"numResponseItems,omitempty,string"` + // PolicyViolationInfo: Indicates the policy violations for this + // request. If the request is denied by the policy, violation + // information will be logged here. + PolicyViolationInfo *PolicyViolationInfo `json:"policyViolationInfo,omitempty"` + // Request: The operation request. This may not include all request // parameters, such as those that are too large, privacy-sensitive, or // duplicated elsewhere in the log record. It should never include @@ -1809,6 +1814,54 @@ func (s *Operation) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// OrgPolicyViolationInfo: Represents OrgPolicy Violation information. +type OrgPolicyViolationInfo struct { + // Payload: Optional. Resource payload that is currently in scope and is + // subjected to orgpolicy conditions. This payload may be the subset of + // the actual Resource that may come in the request. This payload should + // not contain any core content. + Payload googleapi.RawMessage `json:"payload,omitempty"` + + // ResourceTags: Optional. Tags referenced on the resource at the time + // of evaluation. These also include the federated tags, if they are + // supplied in the CheckOrgPolicy or CheckCustomConstraints Requests. + // Optional field as of now. These tags are the Cloud tags that are + // available on the resource during the policy evaluation and will be + // available as part of the OrgPolicy check response for logging + // purposes. + ResourceTags map[string]string `json:"resourceTags,omitempty"` + + // ResourceType: Optional. Resource type that the orgpolicy is checked + // against. Example: compute.googleapis.com/Instance, + // store.googleapis.com/bucket + ResourceType string `json:"resourceType,omitempty"` + + // ViolationInfo: Optional. Policy violations + ViolationInfo []*ViolationInfo `json:"violationInfo,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Payload") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Payload") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *OrgPolicyViolationInfo) MarshalJSON() ([]byte, error) { + type NoMethod OrgPolicyViolationInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // Peer: This message defines attributes for a node that handles a // network request. The node can be either a service or an application // that sends, forwards, or receives the request. Service peers should @@ -1857,6 +1910,38 @@ func (s *Peer) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// PolicyViolationInfo: Information related to policy violations for +// this request. +type PolicyViolationInfo struct { + // OrgPolicyViolationInfo: Indicates the orgpolicy violations for this + // resource. + OrgPolicyViolationInfo *OrgPolicyViolationInfo `json:"orgPolicyViolationInfo,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "OrgPolicyViolationInfo") to unconditionally include in API requests. + // By default, fields with empty or default values are omitted from API + // requests. However, any non-pointer, non-interface field appearing in + // ForceSendFields will be sent to the server regardless of whether the + // field is empty or not. This may be used to include empty fields in + // Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "OrgPolicyViolationInfo") + // to include in API requests with the JSON null value. By default, + // fields with empty values are omitted from API requests. However, any + // field with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *PolicyViolationInfo) MarshalJSON() ([]byte, error) { + type NoMethod PolicyViolationInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // QuotaError: Represents error information for QuotaOperation. type QuotaError struct { // Code: Error code. @@ -3140,6 +3225,53 @@ func (s *V1LogEntrySourceLocation) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// ViolationInfo: Provides information about the Policy violation info +// for this request. +type ViolationInfo struct { + // CheckedValue: Optional. Value that is being checked for the policy. + // This could be in encrypted form (if pii sensitive). This field will + // only be emitted in LIST_POLICY types + CheckedValue string `json:"checkedValue,omitempty"` + + // Constraint: Optional. Constraint name + Constraint string `json:"constraint,omitempty"` + + // ErrorMessage: Optional. Error message that policy is indicating. + ErrorMessage string `json:"errorMessage,omitempty"` + + // PolicyType: Optional. Indicates the type of the policy. + // + // Possible values: + // "POLICY_TYPE_UNSPECIFIED" - Default value. This value should not be + // used. + // "BOOLEAN_CONSTRAINT" - Indicates boolean policy constraint + // "LIST_CONSTRAINT" - Indicates list policy constraint + // "CUSTOM_CONSTRAINT" - Indicates custom policy constraint + PolicyType string `json:"policyType,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CheckedValue") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CheckedValue") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *ViolationInfo) MarshalJSON() ([]byte, error) { + type NoMethod ViolationInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // method id "servicecontrol.services.allocateQuota": type ServicesAllocateQuotaCall struct { diff --git a/storagetransfer/v1/storagetransfer-api.json b/storagetransfer/v1/storagetransfer-api.json index 998035f4341..cec3ed6730c 100644 --- a/storagetransfer/v1/storagetransfer-api.json +++ b/storagetransfer/v1/storagetransfer-api.json @@ -11,7 +11,7 @@ "basePath": "", "baseUrl": "https://storagetransfer.googleapis.com/", "batchPath": "batch", - "description": "Transfers data from external data sources to a Google Cloud Storage bucket or between Google Cloud Storage buckets.", + "description": "Transfers data from external data sources to a Google Cloud Storage bucket or between Google Cloud Storage buckets. ", "discoveryVersion": "v1", "documentationLink": "https://cloud.google.com/storage-transfer/docs", "fullyEncodeReservedExpansion": true, @@ -600,7 +600,7 @@ } } }, - "revision": "20220303", + "revision": "20220310", "rootUrl": "https://storagetransfer.googleapis.com/", "schemas": { "AgentPool": {