Skip to content

Commit

Permalink
feat: [css] UpdateCssProduct is added to CssProductInput proto (#5899)
Browse files Browse the repository at this point in the history
* feat: UpdateCssProduct is added to CssProductInput proto
docs: Mark `freshness_time` as deprecated
docs : Mark `feed_id` as deprecated
docs: A comment for field `page_size` in message `.google.shopping.css.v1.ListChildAccountsRequest` is changed
docs: A comment for field `low_price` in message `.google.shopping.css.v1.Attributes` is changed
docs: A comment for field `high_price` in message `.google.shopping.css.v1.Attributes` is changed
docs: A comment for field `number_of_offers` in message `.google.shopping.css.v1.Attributes` is changed
docs: A comment for field `headline_offer_price` in message `.google.shopping.css.v1.Attributes` is changed
docs: A comment for field `headline_offer_shipping_price` in message `.google.shopping.css.v1.Attributes` is changed
docs: A comment for field `approved_countries` in message `.google.shopping.css.v1.CssProductStatus` is changed
docs: A comment for field `pending_countries` in message `.google.shopping.css.v1.CssProductStatus` is changed
docs: A comment for field `disapproved_countries` in message `.google.shopping.css.v1.CssProductStatus` is changed
docs: A comment for field `servability` in message `.google.shopping.css.v1.CssProductStatus` is changed
docs: A comment for field `applicable_countries` in message `.google.shopping.css.v1.CssProductStatus` is changed
docs: A comment for field `feed_id` in message`.google.shopping.css.v1.InsertCssProductInputRequest` is changed
docs: A comment for message `CssProduct` is changed

PiperOrigin-RevId: 708397816

Source-Link: googleapis/googleapis@892e72f

Source-Link: googleapis/googleapis-gen@09992f0
Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLXNob3BwaW5nLWNzcy8uT3dsQm90LnlhbWwiLCJoIjoiMDk5OTJmMGQ5NDViZWIwOTIxMjJmYTFiZGY0NTNmNTMyMWJjMGY4YyJ9

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] authored Jan 11, 2025
1 parent d8d7c9a commit 03a1088
Show file tree
Hide file tree
Showing 18 changed files with 1,258 additions and 43 deletions.
1 change: 1 addition & 0 deletions packages/google-shopping-css/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/
| Accounts_service.update_labels | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-shopping-css/samples/generated/v1/accounts_service.update_labels.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-shopping-css/samples/generated/v1/accounts_service.update_labels.js,packages/google-shopping-css/samples/README.md) |
| Css_product_inputs_service.delete_css_product_input | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-shopping-css/samples/generated/v1/css_product_inputs_service.delete_css_product_input.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-shopping-css/samples/generated/v1/css_product_inputs_service.delete_css_product_input.js,packages/google-shopping-css/samples/README.md) |
| Css_product_inputs_service.insert_css_product_input | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-shopping-css/samples/generated/v1/css_product_inputs_service.insert_css_product_input.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-shopping-css/samples/generated/v1/css_product_inputs_service.insert_css_product_input.js,packages/google-shopping-css/samples/README.md) |
| Css_product_inputs_service.update_css_product_input | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-shopping-css/samples/generated/v1/css_product_inputs_service.update_css_product_input.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-shopping-css/samples/generated/v1/css_product_inputs_service.update_css_product_input.js,packages/google-shopping-css/samples/README.md) |
| Css_products_service.get_css_product | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-shopping-css/samples/generated/v1/css_products_service.get_css_product.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-shopping-css/samples/generated/v1/css_products_service.get_css_product.js,packages/google-shopping-css/samples/README.md) |
| Css_products_service.list_css_products | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-shopping-css/samples/generated/v1/css_products_service.list_css_products.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-shopping-css/samples/generated/v1/css_products_service.list_css_products.js,packages/google-shopping-css/samples/README.md) |
| Quickstart | [source code](https://github.com/googleapis/google-cloud-node/blob/main/packages/google-shopping-css/samples/quickstart.js) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/google-cloud-node&page=editor&open_in_editor=packages/google-shopping-css/samples/quickstart.js,packages/google-shopping-css/samples/README.md) |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ message ListChildAccountsRequest {

// Optional. The maximum number of accounts to return. The service may return
// fewer than this value. If unspecified, at most 50 accounts will be
// returned. The maximum value is 1000; values above 1000 will be coerced to
// 1000.
// returned. The maximum value is 100; values above 100 will be coerced to
// 100.
int32 page_size = 4 [(google.api.field_behavior) = OPTIONAL];

// Optional. A page token, received from a previous `ListChildAccounts` call.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,19 +40,19 @@ message Attributes {
// within the context of Product Ads.
optional string cpp_ads_redirect = 42;

// Low Price of the aggregate offer.
// Low Price of the CSS Product.
google.shopping.type.Price low_price = 3;

// High Price of the aggregate offer.
// High Price of the CSS Product.
google.shopping.type.Price high_price = 4;

// The number of aggregate offers.
// The number of CSS Products.
optional int64 number_of_offers = 5;

// Condition of the headline offer.
optional string headline_offer_condition = 6;

// Headline Price of the aggregate offer.
// Headline Price of the CSS Product.
google.shopping.type.Price headline_offer_price = 7;

// Link to the headline offer.
Expand All @@ -61,7 +61,7 @@ message Attributes {
// Mobile Link to the headline offer.
optional string headline_offer_mobile_link = 9;

// Headline Price of the aggregate offer.
// Headline Price of the CSS Product.
google.shopping.type.Price headline_offer_shipping_price = 41;

// Title of the item.
Expand Down Expand Up @@ -281,15 +281,15 @@ message CssProductStatus {
// The name of the destination
string destination = 1;

// List of country codes (ISO 3166-1 alpha-2) where the aggregate offer is
// List of country codes (ISO 3166-1 alpha-2) where the CSS Product is
// approved.
repeated string approved_countries = 2;

// List of country codes (ISO 3166-1 alpha-2) where the aggregate offer is
// List of country codes (ISO 3166-1 alpha-2) where the CSS Product is
// pending approval.
repeated string pending_countries = 3;

// List of country codes (ISO 3166-1 alpha-2) where the aggregate offer is
// List of country codes (ISO 3166-1 alpha-2) where the CSS Product is
// disapproved.
repeated string disapproved_countries = 4;
}
Expand All @@ -299,7 +299,7 @@ message CssProductStatus {
// The error code of the issue.
string code = 1;

// How this issue affects serving of the aggregate offer.
// How this issue affects serving of the CSS Product.
string servability = 2;

// Whether the issue can be resolved by the merchant.
Expand All @@ -321,7 +321,7 @@ message CssProductStatus {
string documentation = 8;

// List of country codes (ISO 3166-1 alpha-2) where issue applies to the
// aggregate offer.
// CSS Product.
repeated string applicable_countries = 9;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import "google/api/client.proto";
import "google/api/field_behavior.proto";
import "google/api/resource.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/field_mask.proto";
import "google/protobuf/timestamp.proto";
import "google/shopping/css/v1/css_product_common.proto";
import "google/shopping/type/types.proto";
Expand Down Expand Up @@ -53,6 +54,19 @@ service CssProductInputsService {
};
}

// Updates the existing Css Product input in your CSS Center account.
//
// After inserting, updating, or deleting a CSS Product input, it may take
// several minutes before the processed Css Product can be retrieved.
rpc UpdateCssProductInput(UpdateCssProductInputRequest)
returns (CssProductInput) {
option (google.api.http) = {
patch: "/v1/{css_product_input.name=accounts/*/cssProductInputs/*}"
body: "css_product_input"
};
option (google.api.method_signature) = "css_product_input,update_mask";
}

// Deletes a CSS Product input from your CSS Center account.
//
// After a delete it may take several minutes until the input is no longer
Expand Down Expand Up @@ -105,6 +119,7 @@ message CssProductInput {
// valid region code. For example: 'DE' for Germany, 'FR' for France.
string feed_label = 5 [(google.api.field_behavior) = REQUIRED];

// DEPRECATED. Use expiration_date instead.
// Represents the existing version (freshness) of the CSS Product, which
// can be used to preserve the right order when multiple updates are done at
// the same time.
Expand All @@ -122,7 +137,7 @@ message CssProductInput {
//
// If the operation is prevented, the aborted exception will be
// thrown.
google.protobuf.Timestamp freshness_time = 6;
google.protobuf.Timestamp freshness_time = 6 [deprecated = true];

// A list of CSS Product attributes.
Attributes attributes = 7;
Expand Down Expand Up @@ -151,12 +166,40 @@ message InsertCssProductInputRequest {
CssProductInput css_product_input = 2
[(google.api.field_behavior) = REQUIRED];

// Required. The primary or supplemental feed id. If CSS Product already
// exists and feed id provided is different, then the CSS Product will be
// moved to a new feed. Note: For now, CSSs do not need to provide feed ids as
// we create feeds on the fly. We do not have supplemental feed support for
// CSS Products yet.
int64 feed_id = 3 [(google.api.field_behavior) = REQUIRED];
// Optional. DEPRECATED. Feed id is not required for CSS Products.
// The primary or supplemental feed id. If CSS Product already exists and
// feed id provided is different, then the CSS Product will be moved to a
// new feed.
// Note: For now, CSSs do not need to provide feed ids as we create
// feeds on the fly.
// We do not have supplemental feed support for CSS Products yet.
int64 feed_id = 3 [deprecated = true, (google.api.field_behavior) = OPTIONAL];
}

// Request message for the UpdateCssProductInput method.
message UpdateCssProductInputRequest {
// Required. The CSS product input resource to update. Information you submit
// will be applied to the processed CSS product as well.
CssProductInput css_product_input = 1
[(google.api.field_behavior) = REQUIRED];

// The list of CSS product attributes to be updated.
//
// If the update mask is omitted, then it is treated as implied field mask
// equivalent to all fields that are populated (have a non-empty value).
//
// Attributes specified in the update mask without a value specified in the
// body will be deleted from the CSS product.
//
// Update mask can only be specified for top level fields in
// attributes and custom attributes.
//
// To specify the update mask for custom attributes you need to add the
// `custom_attribute.` prefix.
//
// Providing special "*" value for full CSS product replacement is not
// supported.
google.protobuf.FieldMask update_mask = 2;
}

// Request message for the DeleteCssProductInput method.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ message GetCssProductRequest {
];
}

// The processed CSS Product(a.k.a Aggregate Offer internally).
// The processed CSS Product.
message CssProduct {
option (google.api.resource) = {
type: "css.googleapis.com/CssProduct"
Expand Down
Loading

0 comments on commit 03a1088

Please sign in to comment.