@@ -25,25 +25,29 @@ import "google/protobuf/field_mask.proto";
2525import "google/shopping/merchant/products/v1beta/products_common.proto" ;
2626import "google/shopping/type/types.proto" ;
2727
28+ option csharp_namespace = "Google.Shopping.Merchant.Products.V1Beta" ;
2829option go_package = "cloud.google.com/go/shopping/merchant/products/apiv1beta/productspb;productspb" ;
2930option java_multiple_files = true ;
3031option java_outer_classname = "ProductInputsProto" ;
3132option java_package = "com.google.shopping.merchant.products.v1beta" ;
33+ option php_namespace = "Google\\Shopping\\Merchant\\Products\\V1beta" ;
34+ option ruby_package = "Google::Shopping::Merchant::Products::V1beta" ;
3235
3336// Service to use ProductInput resource.
34- // This service works for products with online channel only.
3537service ProductInputsService {
3638 option (google.api.default_host ) = "merchantapi.googleapis.com" ;
3739 option (google.api.oauth_scopes ) = "https://www.googleapis.com/auth/content" ;
3840
3941 // [Uploads a product input to your Merchant Center
40- // account](/merchant/api/guides/products/overview#upload-product-input). You
41- // must have a products data source to be able to insert a product. The unique
42- // identifier of the data source is passed as a query parameter in the request
43- // URL.
42+ // account](/merchant/api/guides/products/add-manage#add_a_product). You
43+ // must have a products [data
44+ // source](/merchant/api/guides/data-sources/api-sources#create-primary-data-source)
45+ // to be able to insert a product. The unique identifier of the data source is
46+ // passed as a query parameter in the request URL.
4447 //
45- // If an input with the same contentLanguage, offerId, and dataSource already
46- // exists, this method replaces that entry.
48+ // If a product input with the same contentLanguage, offerId, and dataSource
49+ // already exists, then the product input inserted by this method replaces
50+ // that entry.
4751 //
4852 // After inserting, updating, or deleting a product input, it may take several
4953 // minutes before the processed product can be retrieved.
@@ -115,10 +119,14 @@ message ProductInput {
115119
116120 // Identifier. The name of the product input.
117121 // Format: `accounts/{account}/productInputs/{productinput}`
118- // where the last section `productinput` consists of 4 parts :
119- // `channel~ content_language~feed_label~offer_id`
122+ // where the last section `productinput` consists of:
123+ // `content_language~feed_label~offer_id`
120124 // example for product input name is
121- // `accounts/123/productInputs/online~en~US~sku123`
125+ // `accounts/123/productInputs/en~US~sku123`. A legacy local product input
126+ // name would be `accounts/123/productInputs/local~en~US~sku123`.
127+ // Note: For calls to the v1beta version, the `productInput` section consists
128+ // of: `channel~content_language~feed_label~offer_id`, for example:
129+ // `accounts/123/productInputs/online~en~US~sku123`.
122130 string name = 1 [(google.api.field_behavior ) = IDENTIFIER ];
123131
124132 // Output only. The name of the processed product.
@@ -150,8 +158,8 @@ message ProductInput {
150158 (google.api.field_behavior ) = IMMUTABLE
151159 ];
152160
153- // Required. Immutable. The label that lets you categorize and identify your
154- // products. The maximum allowed characters are 20, and the supported
161+ // Required. Immutable. The feed label that lets you categorize and identify
162+ // your products. The maximum allowed characters are 20, and the supported
155163 // characters are `A-Z`, `0-9`, hyphen, and underscore. The feed label must
156164 // not include any spaces. For more information, see [Using feed
157165 // labels](//support.google.com/merchants/answer/14994087).
@@ -215,8 +223,8 @@ message InsertProductInputRequest {
215223 // Required. The primary or supplemental product data source name. If the
216224 // product already exists and data source provided is different, then the
217225 // product will be moved to a new data source. For more information, see
218- // [Overview of Data sources
219- // sub-API ](/merchant/api/guides/data-sources/overview ).
226+ // [Create a primary data
227+ // source ](/merchant/api/guides/data-sources/api-sources#create-primary-data-source ).
220228 //
221229 // Only API data sources are supported.
222230 //
@@ -260,16 +268,30 @@ message UpdateProductInputRequest {
260268 // Format: `accounts/{account}/dataSources/{datasource}`. For example,
261269 // `accounts/123456/dataSources/104628`.
262270 string data_source = 3 [(google.api.field_behavior ) = REQUIRED ];
271+
272+ // Optional. If true, the `{productInput}` in the `name` field of the request
273+ // will be interpreted as unpadded base64url-encoded and decoded during
274+ // request processing to match the decoded value. Default value is `false`.
275+ // Use this if your `{productInput}` contains special characters, such as
276+ // forward slash
277+ // `/` or other characters that are unpadded base64url-encoded (as per RFC
278+ // 7515: https://datatracker.ietf.org/doc/html/rfc7515#section-2).
279+ //
280+ // Note that future versions of the API will only accept unpadded
281+ // base64url-encoded product ids, so we strongly recommend proactively setting
282+ // this to `true` and encoding the product ids.
283+ bool product_id_base64_url_encoded = 4
284+ [(google.api.field_behavior ) = OPTIONAL ];
263285}
264286
265287// Request message for the DeleteProductInput method.
266288message DeleteProductInputRequest {
267289 // Required. The name of the product input resource to delete.
268290 // Format: `accounts/{account}/productInputs/{product}`
269- // where the last section `product` consists of 4 parts :
270- // `channel~ content_language~feed_label~offer_id`
291+ // where the last section `product` consists of:
292+ // `content_language~feed_label~offer_id`
271293 // example for product name is
272- // `accounts/123/productInputs/online~ en~US~sku123`.
294+ // `accounts/123/productInputs/en~US~sku123`.
273295 string name = 1 [
274296 (google.api.field_behavior ) = REQUIRED ,
275297 (google.api.resource_reference ) = {
@@ -282,4 +304,18 @@ message DeleteProductInputRequest {
282304 // `accounts/{account}/dataSources/{datasource}`. For example,
283305 // `accounts/123456/dataSources/104628`.
284306 string data_source = 2 [(google.api.field_behavior ) = REQUIRED ];
307+
308+ // Optional. If true, the `{productInput}` in the `name` field of the request
309+ // will be interpreted as unpadded base64url-encoded and decoded during
310+ // request processing to match the decoded value. Default value is `false`.
311+ // Use this if your `{productInput}` contains special characters, such as
312+ // forward slash
313+ // `/` or other characters that are unpadded base64url-encoded (as per RFC
314+ // 7515: https://datatracker.ietf.org/doc/html/rfc7515#section-2).
315+ //
316+ // Note that future versions of the API will only accept unpadded
317+ // base64url-encoded product ids, so we strongly recommend proactively setting
318+ // this to `true` and encoding the product ids.
319+ bool product_id_base64_url_encoded = 3
320+ [(google.api.field_behavior ) = OPTIONAL ];
285321}
0 commit comments