diff --git a/packages/google-shopping-merchant-products/README.md b/packages/google-shopping-merchant-products/README.md index 1504353088b..515fc2d50b6 100644 --- a/packages/google-shopping-merchant-products/README.md +++ b/packages/google-shopping-merchant-products/README.md @@ -44,7 +44,7 @@ Google APIs Client Libraries, in [Client Libraries Explained][explained]. 1. [Select or create a Cloud Platform project][projects]. 1. [Enable billing for your project][billing]. 1. [Enable the Merchant API API][enable_api]. -1. [Set up authentication with a service account][auth] so you can access the +1. [Set up authentication][auth] so you can access the API from your local workstation. ### Installing the client library @@ -187,4 +187,4 @@ See [LICENSE](https://github.com/googleapis/google-cloud-node/blob/main/LICENSE) [projects]: https://console.cloud.google.com/project [billing]: https://support.google.com/cloud/answer/6293499#enable-billing [enable_api]: https://console.cloud.google.com/flows/enableapi?apiid=merchantapi.googleapis.com -[auth]: https://cloud.google.com/docs/authentication/getting-started +[auth]: https://cloud.google.com/docs/authentication/external/set-up-adc-local diff --git a/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/productinputs.proto b/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/productinputs.proto index 88cbe1d5f1c..53315dd6bd9 100644 --- a/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/productinputs.proto +++ b/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/productinputs.proto @@ -65,16 +65,16 @@ service ProductInputsService { // processed product that you see in Merchant Center, in Shopping ads, or across // Google surfaces. Product inputs, rules and supplemental data source data are // combined to create the processed -// [product][google.shopping.content.bundles.Products.Product]. +// [Product][google.shopping.merchant.products.v1beta.Product]. // // Required product input attributes to pass data validation checks are // primarily defined in the [Products Data // Specification](https://support.google.com/merchants/answer/188494). // // The following attributes are required: -// [feedLabel][google.shopping.content.bundles.Products.feed_label], -// [contentLanguage][google.shopping.content.bundles.Products.content_language] -// and [offerId][google.shopping.content.bundles.Products.offer_id]. +// [feedLabel][google.shopping.merchant.products.v1beta.Product.feed_label], +// [contentLanguage][google.shopping.merchant.products.v1beta.Product.content_language] +// and [offerId][google.shopping.merchant.products.v1beta.Product.offer_id]. // // After inserting, updating, or deleting a product input, it may take several // minutes before the processed product can be retrieved. @@ -93,6 +93,10 @@ message ProductInput { // Identifier. The name of the product input. // Format: // `"{productinput.name=accounts/{account}/productInputs/{productinput}}"` + // where the last section `productinput` consists of 4 parts: + // channel~content_language~feed_label~offer_id + // example for product input name is + // "accounts/123/productInputs/online~en~US~sku123" string name = 1 [(google.api.field_behavior) = IDENTIFIER]; // Output only. The name of the processed product. @@ -193,6 +197,10 @@ message InsertProductInputRequest { message DeleteProductInputRequest { // Required. The name of the product input resource to delete. // Format: accounts/{account}/productInputs/{product} + // where the last section `product` consists of 4 parts: + // channel~content_language~feed_label~offer_id + // example for product name is + // "accounts/123/productInputs/online~en~US~sku123" string name = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { diff --git a/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/products.proto b/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/products.proto index d163bb7a4ec..755e10ea675 100644 --- a/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/products.proto +++ b/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/products.proto @@ -64,10 +64,10 @@ service ProductsService { } // The processed product, built from multiple [product -// inputs][[google.shopping.content.bundles.Products.ProductInput] after -// applying rules and supplemental data sources. This processed product matches -// what is shown in your Merchant Center account and in Shopping ads and other -// surfaces across Google. Each product is built from exactly one primary +// inputs][google.shopping.merchant.products.v1main.ProductInput] +// after applying rules and supplemental data sources. This processed product +// matches what is shown in your Merchant Center account and in Shopping ads and +// other surfaces across Google. Each product is built from exactly one primary // data source product input, and multiple supplemental data source inputs. // After inserting, updating, or deleting a product input, it may take // several minutes before the updated processed product can be retrieved. @@ -84,7 +84,10 @@ message Product { // The name of the product. // Format: - // `"{product.name=accounts/{account}/products/{product}}"` + // `"{product.name=accounts/{account}/products/{product}}"` where the last + // section `product` consists of 4 parts: + // channel~content_language~feed_label~offer_id + // example for product name is "accounts/123/products/online~en~US~sku123" string name = 1; // Output only. The @@ -148,6 +151,10 @@ message Product { message GetProductRequest { // Required. The name of the product to retrieve. // Format: `accounts/{account}/products/{product}` + // where the last section `product` consists of 4 parts: + // channel~content_language~feed_label~offer_id + // example for product name is + // "accounts/123/products/online~en~US~sku123" string name = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -169,7 +176,7 @@ message ListProductsRequest { // The maximum number of products to return. The service may return fewer than // this value. - // The maximum value is 1000; values above 1000 will be coerced to 1000. + // The maximum value is 250; values above 250 will be coerced to 250. // If unspecified, the maximum number of products will be returned. int32 page_size = 2; diff --git a/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/products_common.proto b/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/products_common.proto index 4bab62e28a6..a221ff1f2b1 100644 --- a/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/products_common.proto +++ b/packages/google-shopping-merchant-products/protos/google/shopping/merchant/products/v1beta/products_common.proto @@ -117,10 +117,11 @@ message Attributes { // categories through the API. optional string google_product_category = 25; - // Global Trade Item Number + // Global Trade Item Numbers // ([GTIN](https://support.google.com/merchants/answer/188494#gtin)) of the // item. - optional string gtin = 26; + // You can provide up to 10 GTINs. + repeated string gtin = 26; // Shared identifier for all variants of the same product. optional string item_group_id = 27; @@ -235,8 +236,7 @@ message Attributes { // Tax information. repeated Tax taxes = 51; - // The tax category of the product, used to configure detailed tax nexus - // in account-level tax settings. + // The tax category of the product. optional string tax_category = 52; // The energy efficiency class as defined in EU directive 2010/30/EU. @@ -521,6 +521,17 @@ message LoyaltyProgram { // The amount of loyalty points earned on a purchase. optional int64 loyalty_points = 5; + + // A date range during which the item is eligible for member price. If not + // specified, the member price is always applicable. The date range is + // represented by a pair of ISO 8601 dates separated by a space, + // comma, or slash. + optional google.type.Interval member_price_effective_date = 6; + + // The label of the shipping benefit. If the field has value, this offer has + // loyalty shipping benefit. If the field value isn't provided, the item is + // not eligible for loyalty shipping for the given loyalty tier. + optional string shipping_label = 7; } // The Shipping of the product. @@ -558,48 +569,48 @@ message Shipping { // Minimum handling time (inclusive) between when the order is received and // shipped in business days. 0 means that the order is shipped on the same // day as it is received if it happens before the cut-off time. - // [minHandlingTime][google.shopping.content.bundles.Products.Shipping.min_handling_time] + // [minHandlingTime][google.shopping.merchant.products.v1beta.Shipping.min_handling_time] // can only be present together with - // [maxHandlingTime][google.shopping.content.bundles.Products.Shipping.max_handling_time]; + // [maxHandlingTime][google.shopping.merchant.products.v1beta.Shipping.max_handling_time]; // but it is not required if - // [maxHandlingTime][google.shopping.content.bundles.Products.Shipping.max_handling_time] + // [maxHandlingTime][google.shopping.merchant.products.v1beta.Shipping.max_handling_time] // is present. optional int64 min_handling_time = 8; // Maximum handling time (inclusive) between when the order is received and // shipped in business days. 0 means that the order is shipped on the same // day as it is received if it happens before the cut-off time. Both - // [maxHandlingTime][google.shopping.content.bundles.Products.Shipping.max_handling_time] + // [maxHandlingTime][google.shopping.merchant.products.v1beta.Shipping.max_handling_time] // and - // [maxTransitTime][google.shopping.content.bundles.Products.Shipping.max_transit_time] + // [maxTransitTime][google.shopping.merchant.products.v1beta.Shipping.max_transit_time] // are required if providing shipping speeds. - // [minHandlingTime][google.shopping.content.bundles.Products.Shipping.min_handling_time] + // [minHandlingTime][google.shopping.merchant.products.v1beta.Shipping.min_handling_time] // is optional if - // [maxHandlingTime][google.shopping.content.bundles.Products.Shipping.max_handling_time] + // [maxHandlingTime][google.shopping.merchant.products.v1beta.Shipping.max_handling_time] // is present. optional int64 max_handling_time = 9; // Minimum transit time (inclusive) between when the order has shipped and // when it is delivered in business days. 0 means that the order is // delivered on the same day as it ships. - // [minTransitTime][google.shopping.content.bundles.Products.Shipping.min_transit_time] + // [minTransitTime][google.shopping.merchant.products.v1beta.Shipping.min_transit_time] // can only be present together with - // [maxTransitTime][google.shopping.content.bundles.Products.Shipping.max_transit_time]; + // [maxTransitTime][google.shopping.merchant.products.v1beta.Shipping.max_transit_time]; // but it is not required if - // [maxTransitTime][google.shopping.content.bundles.Products.Shipping.max_transit_time] + // [maxTransitTime][google.shopping.merchant.products.v1beta.Shipping.max_transit_time] // is present. optional int64 min_transit_time = 10; // Maximum transit time (inclusive) between when the order has shipped and // when it is delivered in business days. 0 means that the order is // delivered on the same day as it ships. Both - // [maxHandlingTime][google.shopping.content.bundles.Products.Shipping.max_handling_time] + // [maxHandlingTime][google.shopping.merchant.products.v1beta.Shipping.max_handling_time] // and - // [maxTransitTime][google.shopping.content.bundles.Products.Shipping.max_transit_time] + // [maxTransitTime][google.shopping.merchant.products.v1beta.Shipping.max_transit_time] // are required if providing shipping speeds. - // [minTransitTime][google.shopping.content.bundles.Products.Shipping.min_transit_time] + // [minTransitTime][google.shopping.merchant.products.v1beta.Shipping.min_transit_time] // is optional if - // [maxTransitTime][google.shopping.content.bundles.Products.Shipping.max_transit_time] + // [maxTransitTime][google.shopping.merchant.products.v1beta.Shipping.max_transit_time] // is present. optional int64 max_transit_time = 11; } diff --git a/packages/google-shopping-merchant-products/protos/protos.d.ts b/packages/google-shopping-merchant-products/protos/protos.d.ts index badb2c01aeb..abbb840fcfb 100644 --- a/packages/google-shopping-merchant-products/protos/protos.d.ts +++ b/packages/google-shopping-merchant-products/protos/protos.d.ts @@ -526,7 +526,7 @@ export namespace google { googleProductCategory?: (string|null); /** Attributes gtin */ - gtin?: (string|null); + gtin?: (string[]|null); /** Attributes itemGroupId */ itemGroupId?: (string|null); @@ -812,7 +812,7 @@ export namespace google { public googleProductCategory?: (string|null); /** Attributes gtin. */ - public gtin?: (string|null); + public gtin: string[]; /** Attributes itemGroupId. */ public itemGroupId?: (string|null); @@ -1075,9 +1075,6 @@ export namespace google { /** Attributes _googleProductCategory. */ public _googleProductCategory?: "googleProductCategory"; - /** Attributes _gtin. */ - public _gtin?: "gtin"; - /** Attributes _itemGroupId. */ public _itemGroupId?: "itemGroupId"; @@ -2159,6 +2156,12 @@ export namespace google { /** LoyaltyProgram loyaltyPoints */ loyaltyPoints?: (number|Long|string|null); + + /** LoyaltyProgram memberPriceEffectiveDate */ + memberPriceEffectiveDate?: (google.type.IInterval|null); + + /** LoyaltyProgram shippingLabel */ + shippingLabel?: (string|null); } /** Represents a LoyaltyProgram. */ @@ -2185,6 +2188,12 @@ export namespace google { /** LoyaltyProgram loyaltyPoints. */ public loyaltyPoints?: (number|Long|string|null); + /** LoyaltyProgram memberPriceEffectiveDate. */ + public memberPriceEffectiveDate?: (google.type.IInterval|null); + + /** LoyaltyProgram shippingLabel. */ + public shippingLabel?: (string|null); + /** LoyaltyProgram _programLabel. */ public _programLabel?: "programLabel"; @@ -2200,6 +2209,12 @@ export namespace google { /** LoyaltyProgram _loyaltyPoints. */ public _loyaltyPoints?: "loyaltyPoints"; + /** LoyaltyProgram _memberPriceEffectiveDate. */ + public _memberPriceEffectiveDate?: "memberPriceEffectiveDate"; + + /** LoyaltyProgram _shippingLabel. */ + public _shippingLabel?: "shippingLabel"; + /** * Creates a new LoyaltyProgram instance using the specified properties. * @param [properties] Properties to set diff --git a/packages/google-shopping-merchant-products/protos/protos.js b/packages/google-shopping-merchant-products/protos/protos.js index d0d10d95251..d83b9249d18 100644 --- a/packages/google-shopping-merchant-products/protos/protos.js +++ b/packages/google-shopping-merchant-products/protos/protos.js @@ -1168,7 +1168,7 @@ * @property {string|null} [condition] Attributes condition * @property {string|null} [gender] Attributes gender * @property {string|null} [googleProductCategory] Attributes googleProductCategory - * @property {string|null} [gtin] Attributes gtin + * @property {Array.|null} [gtin] Attributes gtin * @property {string|null} [itemGroupId] Attributes itemGroupId * @property {string|null} [material] Attributes material * @property {string|null} [mpn] Attributes mpn @@ -1252,6 +1252,7 @@ */ function Attributes(properties) { this.additionalImageLinks = []; + this.gtin = []; this.loyaltyPrograms = []; this.productTypes = []; this.shipping = []; @@ -1437,11 +1438,11 @@ /** * Attributes gtin. - * @member {string|null|undefined} gtin + * @member {Array.} gtin * @memberof google.shopping.merchant.products.v1beta.Attributes * @instance */ - Attributes.prototype.gtin = null; + Attributes.prototype.gtin = $util.emptyArray; /** * Attributes itemGroupId. @@ -2190,17 +2191,6 @@ set: $util.oneOfSetter($oneOfFields) }); - /** - * Attributes _gtin. - * @member {"gtin"|undefined} _gtin - * @memberof google.shopping.merchant.products.v1beta.Attributes - * @instance - */ - Object.defineProperty(Attributes.prototype, "_gtin", { - get: $util.oneOfGetter($oneOfFields = ["gtin"]), - set: $util.oneOfSetter($oneOfFields) - }); - /** * Attributes _itemGroupId. * @member {"itemGroupId"|undefined} _itemGroupId @@ -2667,8 +2657,9 @@ writer.uint32(/* id 24, wireType 2 =*/194).string(message.gender); if (message.googleProductCategory != null && Object.hasOwnProperty.call(message, "googleProductCategory")) writer.uint32(/* id 25, wireType 2 =*/202).string(message.googleProductCategory); - if (message.gtin != null && Object.hasOwnProperty.call(message, "gtin")) - writer.uint32(/* id 26, wireType 2 =*/210).string(message.gtin); + if (message.gtin != null && message.gtin.length) + for (var i = 0; i < message.gtin.length; ++i) + writer.uint32(/* id 26, wireType 2 =*/210).string(message.gtin[i]); if (message.itemGroupId != null && Object.hasOwnProperty.call(message, "itemGroupId")) writer.uint32(/* id 27, wireType 2 =*/218).string(message.itemGroupId); if (message.material != null && Object.hasOwnProperty.call(message, "material")) @@ -2940,7 +2931,9 @@ break; } case 26: { - message.gtin = reader.string(); + if (!(message.gtin && message.gtin.length)) + message.gtin = []; + message.gtin.push(reader.string()); break; } case 27: { @@ -3400,9 +3393,11 @@ return "googleProductCategory: string expected"; } if (message.gtin != null && message.hasOwnProperty("gtin")) { - properties._gtin = 1; - if (!$util.isString(message.gtin)) - return "gtin: string expected"; + if (!Array.isArray(message.gtin)) + return "gtin: array expected"; + for (var i = 0; i < message.gtin.length; ++i) + if (!$util.isString(message.gtin[i])) + return "gtin: string[] expected"; } if (message.itemGroupId != null && message.hasOwnProperty("itemGroupId")) { properties._itemGroupId = 1; @@ -3882,8 +3877,13 @@ message.gender = String(object.gender); if (object.googleProductCategory != null) message.googleProductCategory = String(object.googleProductCategory); - if (object.gtin != null) - message.gtin = String(object.gtin); + if (object.gtin) { + if (!Array.isArray(object.gtin)) + throw TypeError(".google.shopping.merchant.products.v1beta.Attributes.gtin: array expected"); + message.gtin = []; + for (var i = 0; i < object.gtin.length; ++i) + message.gtin[i] = String(object.gtin[i]); + } if (object.itemGroupId != null) message.itemGroupId = String(object.itemGroupId); if (object.material != null) @@ -4239,6 +4239,7 @@ if (options.arrays || options.defaults) { object.additionalImageLinks = []; object.lifestyleImageLinks = []; + object.gtin = []; object.productTypes = []; object.shipping = []; object.sizeTypes = []; @@ -4383,10 +4384,10 @@ if (options.oneofs) object._googleProductCategory = "googleProductCategory"; } - if (message.gtin != null && message.hasOwnProperty("gtin")) { - object.gtin = message.gtin; - if (options.oneofs) - object._gtin = "gtin"; + if (message.gtin && message.gtin.length) { + object.gtin = []; + for (var j = 0; j < message.gtin.length; ++j) + object.gtin[j] = message.gtin[j]; } if (message.itemGroupId != null && message.hasOwnProperty("itemGroupId")) { object.itemGroupId = message.itemGroupId; @@ -6875,6 +6876,8 @@ * @property {google.shopping.type.IPrice|null} [price] LoyaltyProgram price * @property {google.shopping.type.IPrice|null} [cashbackForFutureUse] LoyaltyProgram cashbackForFutureUse * @property {number|Long|null} [loyaltyPoints] LoyaltyProgram loyaltyPoints + * @property {google.type.IInterval|null} [memberPriceEffectiveDate] LoyaltyProgram memberPriceEffectiveDate + * @property {string|null} [shippingLabel] LoyaltyProgram shippingLabel */ /** @@ -6932,6 +6935,22 @@ */ LoyaltyProgram.prototype.loyaltyPoints = null; + /** + * LoyaltyProgram memberPriceEffectiveDate. + * @member {google.type.IInterval|null|undefined} memberPriceEffectiveDate + * @memberof google.shopping.merchant.products.v1beta.LoyaltyProgram + * @instance + */ + LoyaltyProgram.prototype.memberPriceEffectiveDate = null; + + /** + * LoyaltyProgram shippingLabel. + * @member {string|null|undefined} shippingLabel + * @memberof google.shopping.merchant.products.v1beta.LoyaltyProgram + * @instance + */ + LoyaltyProgram.prototype.shippingLabel = null; + // OneOf field names bound to virtual getters and setters var $oneOfFields; @@ -6990,6 +7009,28 @@ set: $util.oneOfSetter($oneOfFields) }); + /** + * LoyaltyProgram _memberPriceEffectiveDate. + * @member {"memberPriceEffectiveDate"|undefined} _memberPriceEffectiveDate + * @memberof google.shopping.merchant.products.v1beta.LoyaltyProgram + * @instance + */ + Object.defineProperty(LoyaltyProgram.prototype, "_memberPriceEffectiveDate", { + get: $util.oneOfGetter($oneOfFields = ["memberPriceEffectiveDate"]), + set: $util.oneOfSetter($oneOfFields) + }); + + /** + * LoyaltyProgram _shippingLabel. + * @member {"shippingLabel"|undefined} _shippingLabel + * @memberof google.shopping.merchant.products.v1beta.LoyaltyProgram + * @instance + */ + Object.defineProperty(LoyaltyProgram.prototype, "_shippingLabel", { + get: $util.oneOfGetter($oneOfFields = ["shippingLabel"]), + set: $util.oneOfSetter($oneOfFields) + }); + /** * Creates a new LoyaltyProgram instance using the specified properties. * @function create @@ -7024,6 +7065,10 @@ $root.google.shopping.type.Price.encode(message.cashbackForFutureUse, writer.uint32(/* id 4, wireType 2 =*/34).fork()).ldelim(); if (message.loyaltyPoints != null && Object.hasOwnProperty.call(message, "loyaltyPoints")) writer.uint32(/* id 5, wireType 0 =*/40).int64(message.loyaltyPoints); + if (message.memberPriceEffectiveDate != null && Object.hasOwnProperty.call(message, "memberPriceEffectiveDate")) + $root.google.type.Interval.encode(message.memberPriceEffectiveDate, writer.uint32(/* id 6, wireType 2 =*/50).fork()).ldelim(); + if (message.shippingLabel != null && Object.hasOwnProperty.call(message, "shippingLabel")) + writer.uint32(/* id 7, wireType 2 =*/58).string(message.shippingLabel); return writer; }; @@ -7078,6 +7123,14 @@ message.loyaltyPoints = reader.int64(); break; } + case 6: { + message.memberPriceEffectiveDate = $root.google.type.Interval.decode(reader, reader.uint32()); + break; + } + case 7: { + message.shippingLabel = reader.string(); + break; + } default: reader.skipType(tag & 7); break; @@ -7145,6 +7198,19 @@ if (!$util.isInteger(message.loyaltyPoints) && !(message.loyaltyPoints && $util.isInteger(message.loyaltyPoints.low) && $util.isInteger(message.loyaltyPoints.high))) return "loyaltyPoints: integer|Long expected"; } + if (message.memberPriceEffectiveDate != null && message.hasOwnProperty("memberPriceEffectiveDate")) { + properties._memberPriceEffectiveDate = 1; + { + var error = $root.google.type.Interval.verify(message.memberPriceEffectiveDate); + if (error) + return "memberPriceEffectiveDate." + error; + } + } + if (message.shippingLabel != null && message.hasOwnProperty("shippingLabel")) { + properties._shippingLabel = 1; + if (!$util.isString(message.shippingLabel)) + return "shippingLabel: string expected"; + } return null; }; @@ -7183,6 +7249,13 @@ message.loyaltyPoints = object.loyaltyPoints; else if (typeof object.loyaltyPoints === "object") message.loyaltyPoints = new $util.LongBits(object.loyaltyPoints.low >>> 0, object.loyaltyPoints.high >>> 0).toNumber(); + if (object.memberPriceEffectiveDate != null) { + if (typeof object.memberPriceEffectiveDate !== "object") + throw TypeError(".google.shopping.merchant.products.v1beta.LoyaltyProgram.memberPriceEffectiveDate: object expected"); + message.memberPriceEffectiveDate = $root.google.type.Interval.fromObject(object.memberPriceEffectiveDate); + } + if (object.shippingLabel != null) + message.shippingLabel = String(object.shippingLabel); return message; }; @@ -7227,6 +7300,16 @@ if (options.oneofs) object._loyaltyPoints = "loyaltyPoints"; } + if (message.memberPriceEffectiveDate != null && message.hasOwnProperty("memberPriceEffectiveDate")) { + object.memberPriceEffectiveDate = $root.google.type.Interval.toObject(message.memberPriceEffectiveDate, options); + if (options.oneofs) + object._memberPriceEffectiveDate = "memberPriceEffectiveDate"; + } + if (message.shippingLabel != null && message.hasOwnProperty("shippingLabel")) { + object.shippingLabel = message.shippingLabel; + if (options.oneofs) + object._shippingLabel = "shippingLabel"; + } return object; }; diff --git a/packages/google-shopping-merchant-products/protos/protos.json b/packages/google-shopping-merchant-products/protos/protos.json index 32570c8a759..d607ce9d53a 100644 --- a/packages/google-shopping-merchant-products/protos/protos.json +++ b/packages/google-shopping-merchant-products/protos/protos.json @@ -1,4 +1,7 @@ { + "options": { + "syntax": "proto3" + }, "nested": { "google": { "nested": { @@ -276,11 +279,6 @@ "googleProductCategory" ] }, - "_gtin": { - "oneof": [ - "gtin" - ] - }, "_itemGroupId": { "oneof": [ "itemGroupId" @@ -593,11 +591,9 @@ } }, "gtin": { + "rule": "repeated", "type": "string", - "id": 26, - "options": { - "proto3_optional": true - } + "id": 26 }, "itemGroupId": { "type": "string", @@ -1182,6 +1178,16 @@ "oneof": [ "loyaltyPoints" ] + }, + "_memberPriceEffectiveDate": { + "oneof": [ + "memberPriceEffectiveDate" + ] + }, + "_shippingLabel": { + "oneof": [ + "shippingLabel" + ] } }, "fields": { @@ -1219,6 +1225,20 @@ "options": { "proto3_optional": true } + }, + "memberPriceEffectiveDate": { + "type": "google.type.Interval", + "id": 6, + "options": { + "proto3_optional": true + } + }, + "shippingLabel": { + "type": "string", + "id": 7, + "options": { + "proto3_optional": true + } } } }, diff --git a/packages/google-shopping-merchant-products/samples/generated/v1beta/product_inputs_service.delete_product_input.js b/packages/google-shopping-merchant-products/samples/generated/v1beta/product_inputs_service.delete_product_input.js index 6e2b1d656fb..4f7f38aebbe 100644 --- a/packages/google-shopping-merchant-products/samples/generated/v1beta/product_inputs_service.delete_product_input.js +++ b/packages/google-shopping-merchant-products/samples/generated/v1beta/product_inputs_service.delete_product_input.js @@ -31,6 +31,10 @@ function main(name, dataSource) { /** * Required. The name of the product input resource to delete. * Format: accounts/{account}/productInputs/{product} + * where the last section `product` consists of 4 parts: + * channel~content_language~feed_label~offer_id + * example for product name is + * "accounts/123/productInputs/online~en~US~sku123" */ // const name = 'abc123' /** diff --git a/packages/google-shopping-merchant-products/samples/generated/v1beta/products_service.get_product.js b/packages/google-shopping-merchant-products/samples/generated/v1beta/products_service.get_product.js index 60d5a9e551e..e66121fbbfa 100644 --- a/packages/google-shopping-merchant-products/samples/generated/v1beta/products_service.get_product.js +++ b/packages/google-shopping-merchant-products/samples/generated/v1beta/products_service.get_product.js @@ -31,6 +31,10 @@ function main(name) { /** * Required. The name of the product to retrieve. * Format: `accounts/{account}/products/{product}` + * where the last section `product` consists of 4 parts: + * channel~content_language~feed_label~offer_id + * example for product name is + * "accounts/123/products/online~en~US~sku123" */ // const name = 'abc123' diff --git a/packages/google-shopping-merchant-products/samples/generated/v1beta/products_service.list_products.js b/packages/google-shopping-merchant-products/samples/generated/v1beta/products_service.list_products.js index 5a97e8416c6..84c6741b8e0 100644 --- a/packages/google-shopping-merchant-products/samples/generated/v1beta/products_service.list_products.js +++ b/packages/google-shopping-merchant-products/samples/generated/v1beta/products_service.list_products.js @@ -36,7 +36,7 @@ function main(parent) { /** * The maximum number of products to return. The service may return fewer than * this value. - * The maximum value is 1000; values above 1000 will be coerced to 1000. + * The maximum value is 250; values above 250 will be coerced to 250. * If unspecified, the maximum number of products will be returned. */ // const pageSize = 1234 diff --git a/packages/google-shopping-merchant-products/samples/generated/v1beta/snippet_metadata_google.shopping.merchant.products.v1beta.json b/packages/google-shopping-merchant-products/samples/generated/v1beta/snippet_metadata_google.shopping.merchant.products.v1beta.json index 94c484247bd..b5468a77f55 100644 --- a/packages/google-shopping-merchant-products/samples/generated/v1beta/snippet_metadata_google.shopping.merchant.products.v1beta.json +++ b/packages/google-shopping-merchant-products/samples/generated/v1beta/snippet_metadata_google.shopping.merchant.products.v1beta.json @@ -70,7 +70,7 @@ "segments": [ { "start": 25, - "end": 61, + "end": 65, "type": "FULL" } ], @@ -114,7 +114,7 @@ "segments": [ { "start": 25, - "end": 54, + "end": 58, "type": "FULL" } ], diff --git a/packages/google-shopping-merchant-products/src/v1beta/product_inputs_service_client.ts b/packages/google-shopping-merchant-products/src/v1beta/product_inputs_service_client.ts index da6bd10b0bb..6d8b5792f7f 100644 --- a/packages/google-shopping-merchant-products/src/v1beta/product_inputs_service_client.ts +++ b/packages/google-shopping-merchant-products/src/v1beta/product_inputs_service_client.ts @@ -496,6 +496,10 @@ export class ProductInputsServiceClient { * @param {string} request.name * Required. The name of the product input resource to delete. * Format: accounts/{account}/productInputs/{product} + * where the last section `product` consists of 4 parts: + * channel~content_language~feed_label~offer_id + * example for product name is + * "accounts/123/productInputs/online~en~US~sku123" * @param {string} request.dataSource * Required. The primary or supplemental data source from which the product * input should be deleted. Format: diff --git a/packages/google-shopping-merchant-products/src/v1beta/products_service_client.ts b/packages/google-shopping-merchant-products/src/v1beta/products_service_client.ts index b748eb81dd1..892455173d0 100644 --- a/packages/google-shopping-merchant-products/src/v1beta/products_service_client.ts +++ b/packages/google-shopping-merchant-products/src/v1beta/products_service_client.ts @@ -397,6 +397,10 @@ export class ProductsServiceClient { * @param {string} request.name * Required. The name of the product to retrieve. * Format: `accounts/{account}/products/{product}` + * where the last section `product` consists of 4 parts: + * channel~content_language~feed_label~offer_id + * example for product name is + * "accounts/123/products/online~en~US~sku123" * @param {object} [options] * Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details. * @returns {Promise} - The promise which resolves to an array. @@ -503,7 +507,7 @@ export class ProductsServiceClient { * @param {number} request.pageSize * The maximum number of products to return. The service may return fewer than * this value. - * The maximum value is 1000; values above 1000 will be coerced to 1000. + * The maximum value is 250; values above 250 will be coerced to 250. * If unspecified, the maximum number of products will be returned. * @param {string} request.pageToken * A page token, received from a previous `ListProducts` call. @@ -608,7 +612,7 @@ export class ProductsServiceClient { * @param {number} request.pageSize * The maximum number of products to return. The service may return fewer than * this value. - * The maximum value is 1000; values above 1000 will be coerced to 1000. + * The maximum value is 250; values above 250 will be coerced to 250. * If unspecified, the maximum number of products will be returned. * @param {string} request.pageToken * A page token, received from a previous `ListProducts` call. @@ -661,7 +665,7 @@ export class ProductsServiceClient { * @param {number} request.pageSize * The maximum number of products to return. The service may return fewer than * this value. - * The maximum value is 1000; values above 1000 will be coerced to 1000. + * The maximum value is 250; values above 250 will be coerced to 250. * If unspecified, the maximum number of products will be returned. * @param {string} request.pageToken * A page token, received from a previous `ListProducts` call.