@google-shopping/lfp 0.4.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +15 -0
- package/README.md +12 -11
- package/build/protos/google/shopping/merchant/lfp/v1beta/lfpmerchantstate.proto +201 -0
- package/build/protos/protos.d.ts +663 -2
- package/build/protos/protos.js +2109 -173
- package/build/protos/protos.json +261 -16
- package/build/src/index.d.ts +4 -1
- package/build/src/index.js +4 -7
- package/build/src/index.js.map +1 -1
- package/build/src/v1beta/gapic_metadata.json +24 -0
- package/build/src/v1beta/index.d.ts +1 -0
- package/build/src/v1beta/index.js +3 -1
- package/build/src/v1beta/index.js.map +1 -1
- package/build/src/v1beta/lfp_inventory_service_client.d.ts +24 -0
- package/build/src/v1beta/lfp_inventory_service_client.js +37 -1
- package/build/src/v1beta/lfp_inventory_service_client.js.map +1 -1
- package/build/src/v1beta/lfp_inventory_service_proto_list.json +1 -0
- package/build/src/v1beta/lfp_merchant_state_service_client.d.ts +273 -0
- package/build/src/v1beta/lfp_merchant_state_service_client.js +517 -0
- package/build/src/v1beta/lfp_merchant_state_service_client.js.map +1 -0
- package/build/src/v1beta/lfp_merchant_state_service_client_config.json +43 -0
- package/build/src/v1beta/lfp_merchant_state_service_proto_list.json +7 -0
- package/build/src/v1beta/lfp_sale_service_client.d.ts +24 -0
- package/build/src/v1beta/lfp_sale_service_client.js +37 -1
- package/build/src/v1beta/lfp_sale_service_client.js.map +1 -1
- package/build/src/v1beta/lfp_sale_service_proto_list.json +1 -0
- package/build/src/v1beta/lfp_store_service_client.d.ts +24 -0
- package/build/src/v1beta/lfp_store_service_client.js +52 -6
- package/build/src/v1beta/lfp_store_service_client.js.map +1 -1
- package/build/src/v1beta/lfp_store_service_proto_list.json +1 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
@@ -1,5 +1,20 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## [0.5.0](https://github.com/googleapis/google-cloud-node/compare/lfp-v0.4.1...lfp-v0.5.0) (2025-05-09)
|
4
|
+
|
5
|
+
|
6
|
+
### Features
|
7
|
+
|
8
|
+
* [merchantapi] Add GetLfpMerchantState method ([#6259](https://github.com/googleapis/google-cloud-node/issues/6259)) ([31d2647](https://github.com/googleapis/google-cloud-node/commit/31d264703dc99125aae56551999d86cdedfc1b81))
|
9
|
+
* Multiple ai-platform updates ([0b8b1a7](https://github.com/googleapis/google-cloud-node/commit/0b8b1a75f33bdf94000321d239834b9b10757862))
|
10
|
+
|
11
|
+
## [0.4.1](https://github.com/googleapis/google-cloud-node/compare/lfp-v0.4.0...lfp-v0.4.1) (2025-03-21)
|
12
|
+
|
13
|
+
|
14
|
+
### Bug Fixes
|
15
|
+
|
16
|
+
* [Many APIs] await/catch promises, and update listOperationsAsync return type ([#6191](https://github.com/googleapis/google-cloud-node/issues/6191)) ([c9adc61](https://github.com/googleapis/google-cloud-node/commit/c9adc6150ad09630854554c2ed7e558fb3e04315))
|
17
|
+
|
3
18
|
## [0.4.0](https://github.com/googleapis/google-cloud-node/compare/lfp-v0.3.0...lfp-v0.4.0) (2025-03-18)
|
4
19
|
|
5
20
|
|
package/README.md
CHANGED
@@ -44,7 +44,7 @@ Google APIs Client Libraries, in [Client Libraries Explained][explained].
|
|
44
44
|
1. [Select or create a Cloud Platform project][projects].
|
45
45
|
1. [Enable billing for your project][billing].
|
46
46
|
1. [Enable the Merchant API API][enable_api].
|
47
|
-
1. [Set up authentication
|
47
|
+
1. [Set up authentication][auth] so you can access the
|
48
48
|
API from your local workstation.
|
49
49
|
|
50
50
|
### Installing the client library
|
@@ -122,13 +122,14 @@ Samples are in the [`samples/`](https://github.com/googleapis/google-cloud-node/
|
|
122
122
|
|
123
123
|
| Sample | Source Code | Try it |
|
124
124
|
| --------------------------- | --------------------------------- | ------ |
|
125
|
-
| Lfp_inventory_service.insert_lfp_inventory | [source code](https://github.com/googleapis/google-cloud-node/blob/
|
126
|
-
|
|
127
|
-
|
|
128
|
-
| Lfp_store_service.
|
129
|
-
| Lfp_store_service.
|
130
|
-
| Lfp_store_service.
|
131
|
-
|
|
125
|
+
| Lfp_inventory_service.insert_lfp_inventory | [source code](https://github.com/googleapis/google-cloud-node/blob/master/packages/google-shopping-merchant-lfp/samples/generated/v1beta/lfp_inventory_service.insert_lfp_inventory.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-merchant-lfp/samples/generated/v1beta/lfp_inventory_service.insert_lfp_inventory.js,packages/google-shopping-merchant-lfp/samples/README.md) |
|
126
|
+
| Lfp_merchant_state_service.get_lfp_merchant_state | [source code](https://github.com/googleapis/google-cloud-node/blob/master/packages/google-shopping-merchant-lfp/samples/generated/v1beta/lfp_merchant_state_service.get_lfp_merchant_state.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-merchant-lfp/samples/generated/v1beta/lfp_merchant_state_service.get_lfp_merchant_state.js,packages/google-shopping-merchant-lfp/samples/README.md) |
|
127
|
+
| Lfp_sale_service.insert_lfp_sale | [source code](https://github.com/googleapis/google-cloud-node/blob/master/packages/google-shopping-merchant-lfp/samples/generated/v1beta/lfp_sale_service.insert_lfp_sale.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-merchant-lfp/samples/generated/v1beta/lfp_sale_service.insert_lfp_sale.js,packages/google-shopping-merchant-lfp/samples/README.md) |
|
128
|
+
| Lfp_store_service.delete_lfp_store | [source code](https://github.com/googleapis/google-cloud-node/blob/master/packages/google-shopping-merchant-lfp/samples/generated/v1beta/lfp_store_service.delete_lfp_store.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-merchant-lfp/samples/generated/v1beta/lfp_store_service.delete_lfp_store.js,packages/google-shopping-merchant-lfp/samples/README.md) |
|
129
|
+
| Lfp_store_service.get_lfp_store | [source code](https://github.com/googleapis/google-cloud-node/blob/master/packages/google-shopping-merchant-lfp/samples/generated/v1beta/lfp_store_service.get_lfp_store.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-merchant-lfp/samples/generated/v1beta/lfp_store_service.get_lfp_store.js,packages/google-shopping-merchant-lfp/samples/README.md) |
|
130
|
+
| Lfp_store_service.insert_lfp_store | [source code](https://github.com/googleapis/google-cloud-node/blob/master/packages/google-shopping-merchant-lfp/samples/generated/v1beta/lfp_store_service.insert_lfp_store.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-merchant-lfp/samples/generated/v1beta/lfp_store_service.insert_lfp_store.js,packages/google-shopping-merchant-lfp/samples/README.md) |
|
131
|
+
| Lfp_store_service.list_lfp_stores | [source code](https://github.com/googleapis/google-cloud-node/blob/master/packages/google-shopping-merchant-lfp/samples/generated/v1beta/lfp_store_service.list_lfp_stores.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-merchant-lfp/samples/generated/v1beta/lfp_store_service.list_lfp_stores.js,packages/google-shopping-merchant-lfp/samples/README.md) |
|
132
|
+
| Quickstart | [source code](https://github.com/googleapis/google-cloud-node/blob/master/packages/google-shopping-merchant-lfp/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-merchant-lfp/samples/quickstart.js,packages/google-shopping-merchant-lfp/samples/README.md) |
|
132
133
|
|
133
134
|
|
134
135
|
|
@@ -177,7 +178,7 @@ More Information: [Google Cloud Platform Launch Stages][launch_stages]
|
|
177
178
|
|
178
179
|
## Contributing
|
179
180
|
|
180
|
-
Contributions welcome! See the [Contributing Guide](https://github.com/googleapis/google-cloud-node/blob/
|
181
|
+
Contributions welcome! See the [Contributing Guide](https://github.com/googleapis/google-cloud-node/blob/master/CONTRIBUTING.md).
|
181
182
|
|
182
183
|
Please note that this `README.md`, the `samples/README.md`,
|
183
184
|
and a variety of configuration files in this repository (including `.nycrc` and `tsconfig.json`)
|
@@ -189,7 +190,7 @@ to its templates in
|
|
189
190
|
|
190
191
|
Apache Version 2.0
|
191
192
|
|
192
|
-
See [LICENSE](https://github.com/googleapis/google-cloud-node/blob/
|
193
|
+
See [LICENSE](https://github.com/googleapis/google-cloud-node/blob/master/LICENSE)
|
193
194
|
|
194
195
|
[client-docs]: https://cloud.google.com/nodejs/docs/reference/merchantapi/latest
|
195
196
|
[product-docs]: https://developers.google.com/merchant/api
|
@@ -197,4 +198,4 @@ See [LICENSE](https://github.com/googleapis/google-cloud-node/blob/main/LICENSE)
|
|
197
198
|
[projects]: https://console.cloud.google.com/project
|
198
199
|
[billing]: https://support.google.com/cloud/answer/6293499#enable-billing
|
199
200
|
[enable_api]: https://console.cloud.google.com/flows/enableapi?apiid=merchantapi.googleapis.com
|
200
|
-
[auth]: https://cloud.google.com/docs/authentication/
|
201
|
+
[auth]: https://cloud.google.com/docs/authentication/external/set-up-adc-local
|
@@ -0,0 +1,201 @@
|
|
1
|
+
// Copyright 2025 Google LLC
|
2
|
+
//
|
3
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
4
|
+
// you may not use this file except in compliance with the License.
|
5
|
+
// You may obtain a copy of the License at
|
6
|
+
//
|
7
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
8
|
+
//
|
9
|
+
// Unless required by applicable law or agreed to in writing, software
|
10
|
+
// distributed under the License is distributed on an "AS IS" BASIS,
|
11
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
12
|
+
// See the License for the specific language governing permissions and
|
13
|
+
// limitations under the License.
|
14
|
+
|
15
|
+
syntax = "proto3";
|
16
|
+
|
17
|
+
package google.shopping.merchant.lfp.v1beta;
|
18
|
+
|
19
|
+
import "google/api/annotations.proto";
|
20
|
+
import "google/api/client.proto";
|
21
|
+
import "google/api/field_behavior.proto";
|
22
|
+
import "google/api/resource.proto";
|
23
|
+
|
24
|
+
option go_package = "cloud.google.com/go/shopping/merchant/lfp/apiv1beta/lfppb;lfppb";
|
25
|
+
option java_multiple_files = true;
|
26
|
+
option java_outer_classname = "LfpMerchantStateProto";
|
27
|
+
option java_package = "com.google.shopping.merchant.lfp.v1beta";
|
28
|
+
|
29
|
+
// Service for a [LFP
|
30
|
+
// partner](https://support.google.com/merchants/answer/7676652) to get the
|
31
|
+
// state of a merchant.
|
32
|
+
service LfpMerchantStateService {
|
33
|
+
option (google.api.default_host) = "merchantapi.googleapis.com";
|
34
|
+
option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/content";
|
35
|
+
|
36
|
+
// Gets the LFP state of a merchant
|
37
|
+
rpc GetLfpMerchantState(GetLfpMerchantStateRequest)
|
38
|
+
returns (LfpMerchantState) {
|
39
|
+
option (google.api.http) = {
|
40
|
+
get: "/lfp/v1beta/{name=accounts/*/lfpMerchantStates/*}"
|
41
|
+
};
|
42
|
+
option (google.api.method_signature) = "name";
|
43
|
+
}
|
44
|
+
}
|
45
|
+
|
46
|
+
// The LFP state of a merchant.
|
47
|
+
message LfpMerchantState {
|
48
|
+
option (google.api.resource) = {
|
49
|
+
type: "merchantapi.googleapis.com/LfpMerchantState"
|
50
|
+
pattern: "accounts/{account}/lfpMerchantStates/{lfp_merchant_state}"
|
51
|
+
plural: "lfpMerchantStates"
|
52
|
+
singular: "lfpMerchantState"
|
53
|
+
};
|
54
|
+
|
55
|
+
// The state of a specific merchant's store.
|
56
|
+
message LfpStoreState {
|
57
|
+
// The state of matching `LfpStore` to a Google Business Profile listing.
|
58
|
+
enum StoreMatchingState {
|
59
|
+
// Store matching state unspecified.
|
60
|
+
STORE_MATCHING_STATE_UNSPECIFIED = 0;
|
61
|
+
|
62
|
+
// The `LfpStore` is successfully matched with a Google Business Profile
|
63
|
+
// store.
|
64
|
+
STORE_MATCHING_STATE_MATCHED = 1;
|
65
|
+
|
66
|
+
// The `LfpStore` is not matched with a Google Business Profile store.
|
67
|
+
STORE_MATCHING_STATE_FAILED = 2;
|
68
|
+
}
|
69
|
+
|
70
|
+
// Required. Immutable. The identifier of this store.
|
71
|
+
string store_code = 1 [
|
72
|
+
(google.api.field_behavior) = REQUIRED,
|
73
|
+
(google.api.field_behavior) = IMMUTABLE
|
74
|
+
];
|
75
|
+
|
76
|
+
// Output only. The store matching state.
|
77
|
+
StoreMatchingState matching_state = 2
|
78
|
+
[(google.api.field_behavior) = OUTPUT_ONLY];
|
79
|
+
|
80
|
+
// The hint of why the matching has failed (only set if matching_state is
|
81
|
+
// FAILED).
|
82
|
+
string matching_state_hint = 3;
|
83
|
+
}
|
84
|
+
|
85
|
+
// The inventory statistics for a merchant.
|
86
|
+
message InventoryStats {
|
87
|
+
// Number of entries (understanding entry as a pair of product and store)
|
88
|
+
// that were built based on provided inventories/sales and submitted to
|
89
|
+
// Google.
|
90
|
+
int64 submitted_entries = 1;
|
91
|
+
|
92
|
+
// Number of submitted in stock entries.
|
93
|
+
int64 submitted_in_stock_entries = 2;
|
94
|
+
|
95
|
+
// Number of entries that were built based on provided
|
96
|
+
// inventories/sales and couldn't be submitted to Google due to errors like
|
97
|
+
// missing product.
|
98
|
+
int64 unsubmitted_entries = 3;
|
99
|
+
|
100
|
+
// Number of products from provided inventories/sales that were created from
|
101
|
+
// matches to existing online products provided by the merchant or to the
|
102
|
+
// Google catalog.
|
103
|
+
int64 submitted_products = 4;
|
104
|
+
}
|
105
|
+
|
106
|
+
// Country-specific settings for the merchant.
|
107
|
+
message CountrySettings {
|
108
|
+
// The possible verification states for different merchant programs.
|
109
|
+
enum VerificationState {
|
110
|
+
// Verification state unspecified.
|
111
|
+
VERIFICATION_STATE_UNSPECIFIED = 0;
|
112
|
+
|
113
|
+
// Verification state not approved.
|
114
|
+
VERIFICATION_STATE_NOT_APPROVED = 1;
|
115
|
+
|
116
|
+
// Verification state in progress.
|
117
|
+
VERIFICATION_STATE_IN_PROGRESS = 2;
|
118
|
+
|
119
|
+
// Verification state approved.
|
120
|
+
VERIFICATION_STATE_APPROVED = 3;
|
121
|
+
}
|
122
|
+
|
123
|
+
// The possible [product page
|
124
|
+
// types](https://support.google.com/merchants/topic/15148370) for a
|
125
|
+
// merchant.
|
126
|
+
enum ProductPageType {
|
127
|
+
// Product page type unspecified.
|
128
|
+
PRODUCT_PAGE_TYPE_UNSPECIFIED = 0;
|
129
|
+
|
130
|
+
// Google hosted product page.
|
131
|
+
GOOGLE_HOSTED = 1;
|
132
|
+
|
133
|
+
// Merchant hosted product page.
|
134
|
+
MERCHANT_HOSTED = 2;
|
135
|
+
|
136
|
+
// Merchant hosted store specific product page.
|
137
|
+
MERCHANT_HOSTED_STORE_SPECIFIC = 3;
|
138
|
+
}
|
139
|
+
|
140
|
+
// Required. The [CLDR territory
|
141
|
+
// code](https://github.com/unicode-org/cldr/blob/latest/common/main/en.xml)
|
142
|
+
// for the country for which these settings are defined.
|
143
|
+
string region_code = 1 [(google.api.field_behavior) = REQUIRED];
|
144
|
+
|
145
|
+
// True if this merchant has enabled free local listings in MC.
|
146
|
+
bool free_local_listings_enabled = 2;
|
147
|
+
|
148
|
+
// True if this merchant has enabled local inventory ads in MC.
|
149
|
+
bool local_inventory_ads_enabled = 3;
|
150
|
+
|
151
|
+
// Output only. The verification state of this merchant's inventory check.
|
152
|
+
VerificationState inventory_verification_state = 4
|
153
|
+
[(google.api.field_behavior) = OUTPUT_ONLY];
|
154
|
+
|
155
|
+
// Output only. The product page type selected by this merchant.
|
156
|
+
ProductPageType product_page_type = 5
|
157
|
+
[(google.api.field_behavior) = OUTPUT_ONLY];
|
158
|
+
|
159
|
+
// Output only. The verification state of this merchant's instock serving
|
160
|
+
// feature.
|
161
|
+
VerificationState instock_serving_verification_state = 6
|
162
|
+
[(google.api.field_behavior) = OUTPUT_ONLY];
|
163
|
+
|
164
|
+
// Output only. The verification state of this merchant's pickup serving
|
165
|
+
// feature.
|
166
|
+
VerificationState pickup_serving_verification_state = 7
|
167
|
+
[(google.api.field_behavior) = OUTPUT_ONLY];
|
168
|
+
}
|
169
|
+
|
170
|
+
// Identifier. The name of the `LfpMerchantState` resource. Format:
|
171
|
+
// `accounts/{account}/lfpMerchantStates/{target_merchant}`
|
172
|
+
string name = 1 [(google.api.field_behavior) = IDENTIFIER];
|
173
|
+
|
174
|
+
// Number of [GBPs](https://www.google.com/business/) this merchant has access
|
175
|
+
// to.
|
176
|
+
int64 linked_gbps = 2;
|
177
|
+
|
178
|
+
// Output only. The state per store from the specified merchant. The field
|
179
|
+
// will be absent if the merchant has no stores submitted through LFP.
|
180
|
+
repeated LfpStoreState store_states = 3
|
181
|
+
[(google.api.field_behavior) = OUTPUT_ONLY];
|
182
|
+
|
183
|
+
// The inventory statistics for the merchant. The field will be absent if the
|
184
|
+
// merchant has no inventory submitted through LFP.
|
185
|
+
InventoryStats inventory_stats = 4;
|
186
|
+
|
187
|
+
// Country-specific settings for the merchant.
|
188
|
+
repeated CountrySettings country_settings = 5;
|
189
|
+
}
|
190
|
+
|
191
|
+
// Request message for the GetLfpMerchantState method.
|
192
|
+
message GetLfpMerchantStateRequest {
|
193
|
+
// Required. The name of the state to retrieve.
|
194
|
+
// Format: `accounts/{account}/lfpMerchantStates/{target_merchant}`
|
195
|
+
string name = 1 [
|
196
|
+
(google.api.field_behavior) = REQUIRED,
|
197
|
+
(google.api.resource_reference) = {
|
198
|
+
type: "merchantapi.googleapis.com/LfpMerchantState"
|
199
|
+
}
|
200
|
+
];
|
201
|
+
}
|