blob: fa533da927b4e6fc12c10ca813266a0f81befca3 [file] [log] [blame]
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="content_v2_1.html">Content API for Shopping</a> . <a href="content_v2_1.orders.html">orders</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070078 <code><a href="#acknowledge">acknowledge(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070079<p class="firstline">Marks an order as acknowledged.</p>
80<p class="toc_element">
81 <code><a href="#advancetestorder">advancetestorder(merchantId, orderId)</a></code></p>
Dan O'Mearadd494642020-05-01 07:42:23 -070082<p class="firstline">Sandbox only. Moves a test order from state "`inProgress`" to state "`pendingShipment`".</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070083<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070084 <code><a href="#cancel">cancel(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070085<p class="firstline">Cancels all line items in an order, making a full refund.</p>
86<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070087 <code><a href="#cancellineitem">cancellineitem(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070088<p class="firstline">Cancels a line item, making a full refund.</p>
89<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070090 <code><a href="#canceltestorderbycustomer">canceltestorderbycustomer(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070091<p class="firstline">Sandbox only. Cancels a test order for customer-initiated cancellation.</p>
92<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070093 <code><a href="#close">close()</a></code></p>
94<p class="firstline">Close httplib2 connections.</p>
95<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070096 <code><a href="#createtestorder">createtestorder(merchantId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070097<p class="firstline">Sandbox only. Creates a test order.</p>
98<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070099 <code><a href="#createtestreturn">createtestreturn(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700100<p class="firstline">Sandbox only. Creates a test return.</p>
101<p class="toc_element">
102 <code><a href="#get">get(merchantId, orderId)</a></code></p>
103<p class="firstline">Retrieves an order from your Merchant Center account.</p>
104<p class="toc_element">
105 <code><a href="#getbymerchantorderid">getbymerchantorderid(merchantId, merchantOrderId)</a></code></p>
106<p class="firstline">Retrieves an order using merchant order ID.</p>
107<p class="toc_element">
108 <code><a href="#gettestordertemplate">gettestordertemplate(merchantId, templateName, country=None)</a></code></p>
109<p class="firstline">Sandbox only. Retrieves an order template that can be used to quickly create a new order in sandbox.</p>
110<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700111 <code><a href="#instorerefundlineitem">instorerefundlineitem(merchantId, orderId, body=None)</a></code></p>
112<p class="firstline">Deprecated. Notifies that item return and refund was handled directly by merchant outside of Google payments processing (e.g. cash refund done in store).</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700113<p class="toc_element">
Bu Sun Kim65020912020-05-20 12:08:20 -0700114 <code><a href="#list">list(merchantId, acknowledged=None, maxResults=None, orderBy=None, pageToken=None, placedDateEnd=None, placedDateStart=None, statuses=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700115<p class="firstline">Lists the orders in your Merchant Center account.</p>
116<p class="toc_element">
117 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
118<p class="firstline">Retrieves the next page of results.</p>
119<p class="toc_element">
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700120 <code><a href="#refunditem">refunditem(merchantId, orderId, body=None)</a></code></p>
121<p class="firstline">Issues a partial or total refund for items and shipment.</p>
122<p class="toc_element">
123 <code><a href="#refundorder">refundorder(merchantId, orderId, body=None)</a></code></p>
124<p class="firstline">Issues a partial or total refund for an order.</p>
125<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700126 <code><a href="#rejectreturnlineitem">rejectreturnlineitem(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700127<p class="firstline">Rejects return on an line item.</p>
128<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700129 <code><a href="#returnrefundlineitem">returnrefundlineitem(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700130<p class="firstline">Returns and refunds a line item. Note that this method can only be called on fully shipped orders. Please also note that the Orderreturns API is the preferred way to handle returns after you receive a return from a customer. You can use Orderreturns.list or Orderreturns.get to search for the return, and then use Orderreturns.processreturn to issue the refund. If the return cannot be found, then we recommend using this API to issue a refund.</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700131<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700132 <code><a href="#setlineitemmetadata">setlineitemmetadata(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700133<p class="firstline">Sets (or overrides if it already exists) merchant provided annotations in the form of key-value pairs. A common use case would be to supply us with additional structured information about a line item that cannot be provided via other methods. Submitted key-value pairs can be retrieved as part of the orders resource.</p>
134<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700135 <code><a href="#shiplineitems">shiplineitems(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700136<p class="firstline">Marks line item(s) as shipped.</p>
137<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700138 <code><a href="#updatelineitemshippingdetails">updatelineitemshippingdetails(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700139<p class="firstline">Updates ship by and delivery by dates for a line item.</p>
140<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700141 <code><a href="#updatemerchantorderid">updatemerchantorderid(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700142<p class="firstline">Updates the merchant order ID for a given order.</p>
143<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700144 <code><a href="#updateshipment">updateshipment(merchantId, orderId, body=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700145<p class="firstline">Updates a shipment's status, carrier, and/or tracking ID.</p>
146<h3>Method Details</h3>
147<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700148 <code class="details" id="acknowledge">acknowledge(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700149 <pre>Marks an order as acknowledged.
150
151Args:
152 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
153 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700154 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700155 The object takes the form of:
156
157{
Bu Sun Kim65020912020-05-20 12:08:20 -0700158 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700159 }
160
161
162Returns:
163 An object of the form:
164
165 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700166 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -0700167 #
168 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700169 # - &quot;`duplicate`&quot;
170 # - &quot;`executed`&quot;
171 &quot;kind&quot;: &quot;content#ordersAcknowledgeResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersAcknowledgeResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700172 }</pre>
173</div>
174
175<div class="method">
176 <code class="details" id="advancetestorder">advancetestorder(merchantId, orderId)</code>
Bu Sun Kim65020912020-05-20 12:08:20 -0700177 <pre>Sandbox only. Moves a test order from state &quot;`inProgress`&quot; to state &quot;`pendingShipment`&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700178
179Args:
180 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
181 orderId: string, The ID of the test order to modify. (required)
182
183Returns:
184 An object of the form:
185
186 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700187 &quot;kind&quot;: &quot;content#ordersAdvanceTestOrderResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersAdvanceTestOrderResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700188 }</pre>
189</div>
190
191<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700192 <code class="details" id="cancel">cancel(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700193 <pre>Cancels all line items in an order, making a full refund.
194
195Args:
196 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
197 orderId: string, The ID of the order to cancel. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700198 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700199 The object takes the form of:
200
201{
Bu Sun Kim65020912020-05-20 12:08:20 -0700202 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
203 &quot;reason&quot;: &quot;A String&quot;, # The reason for the cancellation.
Dan O'Mearadd494642020-05-01 07:42:23 -0700204 #
205 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700206 # - &quot;`customerInitiatedCancel`&quot;
207 # - &quot;`invalidCoupon`&quot;
208 # - &quot;`malformedShippingAddress`&quot;
209 # - &quot;`noInventory`&quot;
210 # - &quot;`other`&quot;
211 # - &quot;`priceError`&quot;
212 # - &quot;`shippingPriceError`&quot;
213 # - &quot;`taxError`&quot;
214 # - &quot;`undeliverableShippingAddress`&quot;
215 # - &quot;`unsupportedPoBoxAddress`&quot;
216 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700217 }
218
219
220Returns:
221 An object of the form:
222
223 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700224 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -0700225 #
226 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700227 # - &quot;`duplicate`&quot;
228 # - &quot;`executed`&quot;
229 &quot;kind&quot;: &quot;content#ordersCancelResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersCancelResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700230 }</pre>
231</div>
232
233<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700234 <code class="details" id="cancellineitem">cancellineitem(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700235 <pre>Cancels a line item, making a full refund.
236
237Args:
238 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
239 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700240 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700241 The object takes the form of:
242
243{
Bu Sun Kim65020912020-05-20 12:08:20 -0700244 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item to cancel. Either lineItemId or productId is required.
245 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
246 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to cancel. This is the REST ID used in the products service. Either lineItemId or productId is required.
247 &quot;quantity&quot;: 42, # The quantity to cancel.
248 &quot;reason&quot;: &quot;A String&quot;, # The reason for the cancellation.
Dan O'Mearadd494642020-05-01 07:42:23 -0700249 #
250 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700251 # - &quot;`customerInitiatedCancel`&quot;
252 # - &quot;`invalidCoupon`&quot;
253 # - &quot;`malformedShippingAddress`&quot;
254 # - &quot;`noInventory`&quot;
255 # - &quot;`other`&quot;
256 # - &quot;`priceError`&quot;
257 # - &quot;`shippingPriceError`&quot;
258 # - &quot;`taxError`&quot;
259 # - &quot;`undeliverableShippingAddress`&quot;
260 # - &quot;`unsupportedPoBoxAddress`&quot;
261 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700262 }
263
264
265Returns:
266 An object of the form:
267
268 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700269 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -0700270 #
271 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700272 # - &quot;`duplicate`&quot;
273 # - &quot;`executed`&quot;
274 &quot;kind&quot;: &quot;content#ordersCancelLineItemResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersCancelLineItemResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700275 }</pre>
276</div>
277
278<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700279 <code class="details" id="canceltestorderbycustomer">canceltestorderbycustomer(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700280 <pre>Sandbox only. Cancels a test order for customer-initiated cancellation.
281
282Args:
283 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
284 orderId: string, The ID of the test order to cancel. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700285 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700286 The object takes the form of:
287
288{
Bu Sun Kim65020912020-05-20 12:08:20 -0700289 &quot;reason&quot;: &quot;A String&quot;, # The reason for the cancellation.
Dan O'Mearadd494642020-05-01 07:42:23 -0700290 #
291 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700292 # - &quot;`changedMind`&quot;
293 # - &quot;`orderedWrongItem`&quot;
294 # - &quot;`other`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700295 }
296
297
298Returns:
299 An object of the form:
300
301 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700302 &quot;kind&quot;: &quot;content#ordersCancelTestOrderByCustomerResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersCancelTestOrderByCustomerResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700303 }</pre>
304</div>
305
306<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700307 <code class="details" id="close">close()</code>
308 <pre>Close httplib2 connections.</pre>
309</div>
310
311<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700312 <code class="details" id="createtestorder">createtestorder(merchantId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700313 <pre>Sandbox only. Creates a test order.
314
315Args:
316 merchantId: string, The ID of the account that should manage the order. This cannot be a multi-client account. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700317 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700318 The object takes the form of:
319
320{
Bu Sun Kim65020912020-05-20 12:08:20 -0700321 &quot;country&quot;: &quot;A String&quot;, # The CLDR territory code of the country of the test order to create. Affects the currency and addresses of orders created via `template_name`, or the addresses of orders created via `test_order`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700322 #
323 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700324 # - &quot;`US`&quot;
325 # - &quot;`FR`&quot; Defaults to `US`.
326 &quot;templateName&quot;: &quot;A String&quot;, # The test order template to use. Specify as an alternative to `testOrder` as a shortcut for retrieving a template and then creating an order using that template.
327 #
328 # Acceptable values are:
329 # - &quot;`template1`&quot;
330 # - &quot;`template1a`&quot;
331 # - &quot;`template1b`&quot;
332 # - &quot;`template2`&quot;
333 # - &quot;`template3`&quot;
334 &quot;testOrder&quot;: { # The test order to create.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700335 &quot;deliveryDetails&quot;: { # Overrides the predefined delivery details if provided.
336 &quot;address&quot;: { # The delivery address
337 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
338 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
339 # John Smith
340 # 1600 Amphitheatre Parkway
341 # Mountain View, CA, 94043
342 # United States
343 &quot;A String&quot;,
344 ],
345 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
346 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
347 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
348 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
349 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
350 &quot;streetAddress&quot;: [ # Street-level part of the address.
351 &quot;A String&quot;,
352 ],
353 },
354 &quot;phoneNumber&quot;: &quot;A String&quot;, # The phone number of the person receiving the delivery.
355 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700356 &quot;enableOrderinvoices&quot;: True or False, # Whether the orderinvoices service should support this order.
357 &quot;kind&quot;: &quot;content#testOrder&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;`content#testOrder`&quot;
358 &quot;lineItems&quot;: [ # Required. Line items that are ordered. At least one line item must be provided.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700359 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700360 &quot;product&quot;: { # Required. Product data from the time of the order placement.
361 &quot;brand&quot;: &quot;A String&quot;, # Required. Brand of the item.
362 &quot;condition&quot;: &quot;A String&quot;, # Required. Condition or state of the item.
Dan O'Mearadd494642020-05-01 07:42:23 -0700363 #
364 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700365 # - &quot;`new`&quot;
366 &quot;contentLanguage&quot;: &quot;A String&quot;, # Required. The two-letter ISO 639-1 language code for the item.
367 #
368 # Acceptable values are:
369 # - &quot;`en`&quot;
370 # - &quot;`fr`&quot;
371 &quot;fees&quot;: [ # Fees for the item. Optional.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700372 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700373 &quot;amount&quot;: { # Amount of the fee.
374 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
375 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700376 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700377 &quot;name&quot;: &quot;A String&quot;, # Name of the fee.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700378 },
379 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700380 &quot;gtin&quot;: &quot;A String&quot;, # Global Trade Item Number (GTIN) of the item. Optional.
381 &quot;imageLink&quot;: &quot;A String&quot;, # Required. URL of an image of the item.
382 &quot;itemGroupId&quot;: &quot;A String&quot;, # Shared identifier for all variants of the same product. Optional.
383 &quot;mpn&quot;: &quot;A String&quot;, # Manufacturer Part Number (MPN) of the item. Optional.
384 &quot;offerId&quot;: &quot;A String&quot;, # Required. An identifier of the item.
385 &quot;price&quot;: { # Required. The price for the product. Tax is automatically calculated for orders where marketplace facilitator tax laws are applicable. Otherwise, tax settings from Merchant Center are applied.
386 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
387 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700388 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700389 &quot;targetCountry&quot;: &quot;A String&quot;, # Required. The CLDR territory code of the target country of the product.
390 &quot;title&quot;: &quot;A String&quot;, # Required. The title of the product.
391 &quot;variantAttributes&quot;: [ # Variant attributes for the item. Optional.
392 {
393 &quot;dimension&quot;: &quot;A String&quot;, # The dimension of the variant.
394 &quot;value&quot;: &quot;A String&quot;, # The value for the dimension.
395 },
396 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700397 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700398 &quot;quantityOrdered&quot;: 42, # Required. Number of items ordered.
399 &quot;returnInfo&quot;: { # Required. Details of the return policy for the line item.
400 &quot;daysToReturn&quot;: 42, # Required. How many days later the item can be returned.
401 &quot;isReturnable&quot;: True or False, # Required. Whether the item is returnable.
402 &quot;policyUrl&quot;: &quot;A String&quot;, # Required. URL of the item return policy.
403 },
404 &quot;shippingDetails&quot;: { # Required. Details of the requested shipping for the line item.
405 &quot;deliverByDate&quot;: &quot;A String&quot;, # Required. The delivery by date, in ISO 8601 format.
406 &quot;method&quot;: { # Required. Details of the shipping method.
407 &quot;carrier&quot;: &quot;A String&quot;, # The carrier for the shipping. Optional. See `shipments[].carrier` for a list of acceptable values.
408 &quot;maxDaysInTransit&quot;: 42, # Required. Maximum transit time.
409 &quot;methodName&quot;: &quot;A String&quot;, # Required. The name of the shipping method.
410 &quot;minDaysInTransit&quot;: 42, # Required. Minimum transit time.
411 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700412 &quot;pickupPromiseInMinutes&quot;: 42, # The promised time in minutes in which the order will be ready for pickup. This only applies to buy-online-pickup-in-store same-day order.
Bu Sun Kim65020912020-05-20 12:08:20 -0700413 &quot;shipByDate&quot;: &quot;A String&quot;, # Required. The ship by date, in ISO 8601 format.
414 &quot;type&quot;: &quot;A String&quot;, # Type of shipment. Indicates whether `deliveryDetails` or `pickupDetails` is applicable for this shipment.
Dan O'Mearadd494642020-05-01 07:42:23 -0700415 #
416 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700417 # - &quot;`delivery`&quot;
418 # - &quot;`pickup`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700419 },
420 },
421 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700422 &quot;notificationMode&quot;: &quot;A String&quot;, # Restricted. Do not use.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700423 &quot;pickupDetails&quot;: { # Overrides the predefined pickup details if provided.
424 &quot;locationCode&quot;: &quot;A String&quot;, # Required. Code of the location defined by provider or merchant.
425 &quot;pickupLocationAddress&quot;: { # Required. Pickup location address.
426 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
427 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
428 # John Smith
429 # 1600 Amphitheatre Parkway
430 # Mountain View, CA, 94043
431 # United States
432 &quot;A String&quot;,
433 ],
434 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
435 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
436 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
437 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
438 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
439 &quot;streetAddress&quot;: [ # Street-level part of the address.
440 &quot;A String&quot;,
441 ],
442 },
443 &quot;pickupLocationType&quot;: &quot;A String&quot;, # Pickup location type.
444 #
445 # Acceptable values are:
446 # - &quot;`locker`&quot;
447 # - &quot;`store`&quot;
448 # - &quot;`curbside`&quot;
449 &quot;pickupPersons&quot;: [ # Required. all pickup persons set by users.
450 {
451 &quot;name&quot;: &quot;A String&quot;, # Required. Full name of the pickup person.
452 &quot;phoneNumber&quot;: &quot;A String&quot;, # Required. The phone number of the person picking up the items.
453 },
454 ],
455 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700456 &quot;predefinedBillingAddress&quot;: &quot;A String&quot;, # Required. The billing address.
Dan O'Mearadd494642020-05-01 07:42:23 -0700457 #
458 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700459 # - &quot;`dwight`&quot;
460 # - &quot;`jim`&quot;
461 # - &quot;`pam`&quot;
462 &quot;predefinedDeliveryAddress&quot;: &quot;A String&quot;, # Required. Identifier of one of the predefined delivery addresses for the delivery.
Dan O'Mearadd494642020-05-01 07:42:23 -0700463 #
464 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700465 # - &quot;`dwight`&quot;
466 # - &quot;`jim`&quot;
467 # - &quot;`pam`&quot;
468 &quot;predefinedEmail&quot;: &quot;A String&quot;, # Required. Email address of the customer.
469 #
470 # Acceptable values are:
471 # - &quot;`pog.dwight.schrute@gmail.com`&quot;
472 # - &quot;`pog.jim.halpert@gmail.com`&quot;
473 # - &quot;`penpog.pam.beesly@gmail.comding`&quot;
474 &quot;predefinedPickupDetails&quot;: &quot;A String&quot;, # Identifier of one of the predefined pickup details. Required for orders containing line items with shipping type `pickup`.
475 #
476 # Acceptable values are:
477 # - &quot;`dwight`&quot;
478 # - &quot;`jim`&quot;
479 # - &quot;`pam`&quot;
480 &quot;promotions&quot;: [ # Promotions associated with the order.
481 {
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700482 &quot;applicableItems&quot;: [ # Items that this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. This field will also be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim65020912020-05-20 12:08:20 -0700483 {
484 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
485 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
486 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
487 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
488 },
489 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700490 &quot;appliedItems&quot;: [ # Items that this promotion have been applied to. Do not provide for `orders.createtestorder`. This field will be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim65020912020-05-20 12:08:20 -0700491 {
492 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
493 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
494 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
495 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
496 },
497 ],
498 &quot;endTime&quot;: &quot;A String&quot;, # Promotion end time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
499 &quot;funder&quot;: &quot;A String&quot;, # Required. The party funding the promotion. Only `merchant` is supported for `orders.createtestorder`.
500 #
501 # Acceptable values are:
502 # - &quot;`google`&quot;
503 # - &quot;`merchant`&quot;
504 &quot;merchantPromotionId&quot;: &quot;A String&quot;, # Required. This field is used to identify promotions within merchants&#x27; own systems.
505 &quot;priceValue&quot;: { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order.
506 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
507 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
508 },
509 &quot;shortTitle&quot;: &quot;A String&quot;, # A short title of the promotion to be shown on the checkout page. Do not provide for `orders.createtestorder`.
510 &quot;startTime&quot;: &quot;A String&quot;, # Promotion start time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
511 &quot;subtype&quot;: &quot;A String&quot;, # Required. The category of the promotion. Only `moneyOff` is supported for `orders.createtestorder`.
512 #
513 # Acceptable values are:
514 # - &quot;`buyMGetMoneyOff`&quot;
515 # - &quot;`buyMGetNMoneyOff`&quot;
516 # - &quot;`buyMGetNPercentOff`&quot;
517 # - &quot;`buyMGetPercentOff`&quot;
518 # - &quot;`freeGift`&quot;
519 # - &quot;`freeGiftWithItemId`&quot;
520 # - &quot;`freeGiftWithValue`&quot;
521 # - &quot;`freeShippingOvernight`&quot;
522 # - &quot;`freeShippingStandard`&quot;
523 # - &quot;`freeShippingTwoDay`&quot;
524 # - &quot;`moneyOff`&quot;
525 # - &quot;`percentOff`&quot;
526 # - &quot;`rewardPoints`&quot;
527 # - &quot;`salePrice`&quot;
528 &quot;taxValue&quot;: { # Estimated discount applied to tax (if allowed by law). Do not provide for `orders.createtestorder`.
529 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
530 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
531 },
532 &quot;title&quot;: &quot;A String&quot;, # Required. The title of the promotion.
533 &quot;type&quot;: &quot;A String&quot;, # Required. The scope of the promotion. Only `product` is supported for `orders.createtestorder`.
534 #
535 # Acceptable values are:
536 # - &quot;`product`&quot;
537 # - &quot;`shipping`&quot;
538 },
539 ],
540 &quot;shippingCost&quot;: { # Required. The price of shipping for all items. Shipping tax is automatically calculated for orders where marketplace facilitator tax laws are applicable. Otherwise, tax settings from Merchant Center are applied. Note that shipping is not taxed in certain states.
541 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
542 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
543 },
544 &quot;shippingOption&quot;: &quot;A String&quot;, # Required. The requested shipping option.
545 #
546 # Acceptable values are:
547 # - &quot;`economy`&quot;
548 # - &quot;`expedited`&quot;
549 # - &quot;`oneDay`&quot;
550 # - &quot;`sameDay`&quot;
551 # - &quot;`standard`&quot;
552 # - &quot;`twoDay`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700553 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700554 }
555
556
557Returns:
558 An object of the form:
559
560 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700561 &quot;kind&quot;: &quot;content#ordersCreateTestOrderResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersCreateTestOrderResponse&quot;.
562 &quot;orderId&quot;: &quot;A String&quot;, # The ID of the newly created test order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700563 }</pre>
564</div>
565
566<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700567 <code class="details" id="createtestreturn">createtestreturn(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700568 <pre>Sandbox only. Creates a test return.
569
570Args:
571 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
572 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700573 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700574 The object takes the form of:
575
576{
Bu Sun Kim65020912020-05-20 12:08:20 -0700577 &quot;items&quot;: [ # Returned items.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700578 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700579 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item to return.
580 &quot;quantity&quot;: 42, # Quantity that is returned.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700581 },
582 ],
583 }
584
585
586Returns:
587 An object of the form:
588
589 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700590 &quot;kind&quot;: &quot;content#ordersCreateTestReturnResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersCreateTestReturnResponse&quot;.
591 &quot;returnId&quot;: &quot;A String&quot;, # The ID of the newly created test order return.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700592 }</pre>
593</div>
594
595<div class="method">
596 <code class="details" id="get">get(merchantId, orderId)</code>
597 <pre>Retrieves an order from your Merchant Center account.
598
599Args:
600 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
601 orderId: string, The ID of the order. (required)
602
603Returns:
604 An object of the form:
605
Dan O'Mearadd494642020-05-01 07:42:23 -0700606 { # Order. Production access (all methods) requires the order manager role. Sandbox access does not. (== resource_for v2.orders ==) (== resource_for v2.1.orders ==)
Bu Sun Kim65020912020-05-20 12:08:20 -0700607 &quot;acknowledged&quot;: True or False, # Whether the order was acknowledged.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700608 &quot;annotations&quot;: [ # List of key-value pairs that are attached to a given order.
609 {
610 &quot;key&quot;: &quot;A String&quot;, # Key for additional google provided (as key-value pairs) annotation.
611 &quot;value&quot;: &quot;A String&quot;, # Value for additional google provided (as key-value pairs) annotation.
612 },
613 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700614 &quot;billingAddress&quot;: { # The billing address.
615 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
616 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
617 # John Smith
618 # 1600 Amphitheatre Parkway
619 # Mountain View, CA, 94043
620 # United States
621 &quot;A String&quot;,
622 ],
623 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
624 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
625 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
626 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
627 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
628 &quot;streetAddress&quot;: [ # Street-level part of the address.
629 &quot;A String&quot;,
630 ],
631 },
632 &quot;customer&quot;: { # The details of the customer who placed the order.
633 &quot;fullName&quot;: &quot;A String&quot;, # Full name of the customer.
634 &quot;invoiceReceivingEmail&quot;: &quot;A String&quot;, # Email address for the merchant to send value-added tax or invoice documentation of the order. Only the last document sent is made available to the customer. For more information, see About automated VAT invoicing for Shopping Actions.
635 &quot;loyaltyInfo&quot;: { # Loyalty program information.
636 &quot;loyaltyNumber&quot;: &quot;A String&quot;, # The loyalty card/membership number.
637 &quot;name&quot;: &quot;A String&quot;, # Name of card/membership holder, this field will be populated when
Dan O'Mearadd494642020-05-01 07:42:23 -0700638 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700639 &quot;marketingRightsInfo&quot;: { # Customer&#x27;s marketing preferences. Contains the marketing opt-in information that is current at the time that the merchant call. User preference selections can change from one order to the next so preferences must be checked with every order.
640 &quot;explicitMarketingPreference&quot;: &quot;A String&quot;, # Last known customer selection regarding marketing preferences. In certain cases this selection might not be known, so this field would be empty. If a customer selected `granted` in their most recent order, they can be subscribed to marketing emails. Customers who have chosen `denied` must not be subscribed, or must be unsubscribed if already opted-in.
Dan O'Mearadd494642020-05-01 07:42:23 -0700641 #
642 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700643 # - &quot;`denied`&quot;
644 # - &quot;`granted`&quot;
645 &quot;lastUpdatedTimestamp&quot;: &quot;A String&quot;, # Timestamp when last time marketing preference was updated. Could be empty, if user wasn&#x27;t offered a selection yet.
646 &quot;marketingEmailAddress&quot;: &quot;A String&quot;, # Email address that can be used for marketing purposes. The field may be empty even if `explicitMarketingPreference` is &#x27;granted&#x27;. This happens when retrieving an old order from the customer who deleted their account.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700647 },
648 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700649 &quot;deliveryDetails&quot;: { # Delivery details for shipments of type `delivery`.
650 &quot;address&quot;: { # The delivery address
651 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
652 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
653 # John Smith
654 # 1600 Amphitheatre Parkway
655 # Mountain View, CA, 94043
656 # United States
657 &quot;A String&quot;,
658 ],
659 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
660 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
661 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
662 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
663 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
664 &quot;streetAddress&quot;: [ # Street-level part of the address.
665 &quot;A String&quot;,
666 ],
667 },
668 &quot;phoneNumber&quot;: &quot;A String&quot;, # The phone number of the person receiving the delivery.
669 },
670 &quot;id&quot;: &quot;A String&quot;, # The REST ID of the order. Globally unique.
671 &quot;kind&quot;: &quot;content#order&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;`content#order`&quot;
672 &quot;lineItems&quot;: [ # Line items that are ordered.
673 {
674 &quot;adjustments&quot;: [ # Price and tax adjustments applied on the line item.
675 {
676 &quot;priceAdjustment&quot;: { # Adjustment for total price of the line item.
677 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
678 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
679 },
680 &quot;taxAdjustment&quot;: { # Adjustment for total tax of the line item.
681 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
682 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
683 },
684 &quot;type&quot;: &quot;A String&quot;, # Type of this adjustment.
685 #
686 # Acceptable values are:
687 # - &quot;`promotion`&quot;
688 },
689 ],
690 &quot;annotations&quot;: [ # Annotations that are attached to the line item.
691 {
692 &quot;key&quot;: &quot;A String&quot;, # Key for additional merchant provided (as key-value pairs) annotation about the line item.
693 &quot;value&quot;: &quot;A String&quot;, # Value for additional merchant provided (as key-value pairs) annotation about the line item.
694 },
695 ],
696 &quot;cancellations&quot;: [ # Cancellations of the line item.
697 {
698 &quot;actor&quot;: &quot;A String&quot;, # The actor that created the cancellation.
699 #
700 # Acceptable values are:
701 # - &quot;`customer`&quot;
702 # - &quot;`googleBot`&quot;
703 # - &quot;`googleCustomerService`&quot;
704 # - &quot;`googlePayments`&quot;
705 # - &quot;`googleSabre`&quot;
706 # - &quot;`merchant`&quot;
707 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the cancellation has been created, in ISO 8601 format.
708 &quot;quantity&quot;: 42, # The quantity that was canceled.
709 &quot;reason&quot;: &quot;A String&quot;, # The reason for the cancellation. Orders that are canceled with a noInventory reason will lead to the removal of the product from Shopping Actions until you make an update to that product. This will not affect your Shopping ads.
710 #
711 # Acceptable values are:
712 # - &quot;`autoPostInternal`&quot;
713 # - &quot;`autoPostInvalidBillingAddress`&quot;
714 # - &quot;`autoPostNoInventory`&quot;
715 # - &quot;`autoPostPriceError`&quot;
716 # - &quot;`autoPostUndeliverableShippingAddress`&quot;
717 # - &quot;`couponAbuse`&quot;
718 # - &quot;`customerCanceled`&quot;
719 # - &quot;`customerInitiatedCancel`&quot;
720 # - &quot;`customerSupportRequested`&quot;
721 # - &quot;`failToPushOrderGoogleError`&quot;
722 # - &quot;`failToPushOrderMerchantError`&quot;
723 # - &quot;`failToPushOrderMerchantFulfillmentError`&quot;
724 # - &quot;`failToPushOrderToMerchant`&quot;
725 # - &quot;`failToPushOrderToMerchantOutOfStock`&quot;
726 # - &quot;`invalidCoupon`&quot;
727 # - &quot;`malformedShippingAddress`&quot;
728 # - &quot;`merchantDidNotShipOnTime`&quot;
729 # - &quot;`noInventory`&quot;
730 # - &quot;`orderTimeout`&quot;
731 # - &quot;`other`&quot;
732 # - &quot;`paymentAbuse`&quot;
733 # - &quot;`paymentDeclined`&quot;
734 # - &quot;`priceError`&quot;
735 # - &quot;`returnRefundAbuse`&quot;
736 # - &quot;`shippingPriceError`&quot;
737 # - &quot;`taxError`&quot;
738 # - &quot;`undeliverableShippingAddress`&quot;
739 # - &quot;`unsupportedPoBoxAddress`&quot;
740 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
741 },
742 ],
743 &quot;id&quot;: &quot;A String&quot;, # The ID of the line item.
744 &quot;price&quot;: { # Total price for the line item. For example, if two items for $10 are purchased, the total price will be $20.
745 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
746 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
747 },
748 &quot;product&quot;: { # Product data as seen by customer from the time of the order placement. Note that certain attributes values (e.g. title or gtin) might be reformatted and no longer match values submitted via product feed.
749 &quot;brand&quot;: &quot;A String&quot;, # Brand of the item.
750 &quot;condition&quot;: &quot;A String&quot;, # Condition or state of the item.
751 #
752 # Acceptable values are:
753 # - &quot;`new`&quot;
754 # - &quot;`refurbished`&quot;
755 # - &quot;`used`&quot;
756 &quot;contentLanguage&quot;: &quot;A String&quot;, # The two-letter ISO 639-1 language code for the item.
757 &quot;fees&quot;: [ # Associated fees at order creation time.
758 {
759 &quot;amount&quot;: { # Amount of the fee.
760 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
761 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
762 },
763 &quot;name&quot;: &quot;A String&quot;, # Name of the fee.
764 },
765 ],
766 &quot;gtin&quot;: &quot;A String&quot;, # Global Trade Item Number (GTIN) of the item.
767 &quot;id&quot;: &quot;A String&quot;, # The REST ID of the product.
768 &quot;imageLink&quot;: &quot;A String&quot;, # URL of an image of the item.
769 &quot;itemGroupId&quot;: &quot;A String&quot;, # Shared identifier for all variants of the same product.
770 &quot;mpn&quot;: &quot;A String&quot;, # Manufacturer Part Number (MPN) of the item.
771 &quot;offerId&quot;: &quot;A String&quot;, # An identifier of the item.
772 &quot;price&quot;: { # Price of the item.
773 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
774 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
775 },
776 &quot;shownImage&quot;: &quot;A String&quot;, # URL to the cached image shown to the user when order was placed.
777 &quot;targetCountry&quot;: &quot;A String&quot;, # The CLDR territory code of the target country of the product.
778 &quot;title&quot;: &quot;A String&quot;, # The title of the product.
779 &quot;variantAttributes&quot;: [ # Variant attributes for the item. These are dimensions of the product, such as color, gender, material, pattern, and size. You can find a comprehensive list of variant attributes here.
780 {
781 &quot;dimension&quot;: &quot;A String&quot;, # The dimension of the variant.
782 &quot;value&quot;: &quot;A String&quot;, # The value for the dimension.
783 },
784 ],
785 },
786 &quot;quantityCanceled&quot;: 42, # Number of items canceled.
787 &quot;quantityDelivered&quot;: 42, # Number of items delivered.
788 &quot;quantityOrdered&quot;: 42, # Number of items ordered.
789 &quot;quantityPending&quot;: 42, # Number of items pending.
790 &quot;quantityReadyForPickup&quot;: 42, # Number of items ready for pickup.
791 &quot;quantityReturned&quot;: 42, # Number of items returned.
792 &quot;quantityShipped&quot;: 42, # Number of items shipped.
793 &quot;quantityUndeliverable&quot;: 42, # Number of items undeliverable.
794 &quot;returnInfo&quot;: { # Details of the return policy for the line item.
795 &quot;daysToReturn&quot;: 42, # Required. How many days later the item can be returned.
796 &quot;isReturnable&quot;: True or False, # Required. Whether the item is returnable.
797 &quot;policyUrl&quot;: &quot;A String&quot;, # Required. URL of the item return policy.
798 },
799 &quot;returns&quot;: [ # Returns of the line item.
800 {
801 &quot;actor&quot;: &quot;A String&quot;, # The actor that created the refund.
802 #
803 # Acceptable values are:
804 # - &quot;`customer`&quot;
805 # - &quot;`googleBot`&quot;
806 # - &quot;`googleCustomerService`&quot;
807 # - &quot;`googlePayments`&quot;
808 # - &quot;`googleSabre`&quot;
809 # - &quot;`merchant`&quot;
810 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the item has been created, in ISO 8601 format.
811 &quot;quantity&quot;: 42, # Quantity that is returned.
812 &quot;reason&quot;: &quot;A String&quot;, # The reason for the return.
813 #
814 # Acceptable values are:
815 # - &quot;`customerDiscretionaryReturn`&quot;
816 # - &quot;`customerInitiatedMerchantCancel`&quot;
817 # - &quot;`deliveredTooLate`&quot;
818 # - &quot;`expiredItem`&quot;
819 # - &quot;`invalidCoupon`&quot;
820 # - &quot;`malformedShippingAddress`&quot;
821 # - &quot;`other`&quot;
822 # - &quot;`productArrivedDamaged`&quot;
823 # - &quot;`productNotAsDescribed`&quot;
824 # - &quot;`qualityNotAsExpected`&quot;
825 # - &quot;`undeliverableShippingAddress`&quot;
826 # - &quot;`unsupportedPoBoxAddress`&quot;
827 # - &quot;`wrongProductShipped`&quot;
828 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
829 },
830 ],
831 &quot;shippingDetails&quot;: { # Details of the requested shipping for the line item.
832 &quot;deliverByDate&quot;: &quot;A String&quot;, # Required. The delivery by date, in ISO 8601 format.
833 &quot;method&quot;: { # Required. Details of the shipping method.
834 &quot;carrier&quot;: &quot;A String&quot;, # The carrier for the shipping. Optional. See `shipments[].carrier` for a list of acceptable values.
835 &quot;maxDaysInTransit&quot;: 42, # Required. Maximum transit time.
836 &quot;methodName&quot;: &quot;A String&quot;, # Required. The name of the shipping method.
837 &quot;minDaysInTransit&quot;: 42, # Required. Minimum transit time.
838 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700839 &quot;pickupPromiseInMinutes&quot;: 42, # The promised time in minutes in which the order will be ready for pickup. This only applies to buy-online-pickup-in-store same-day order.
Bu Sun Kim65020912020-05-20 12:08:20 -0700840 &quot;shipByDate&quot;: &quot;A String&quot;, # Required. The ship by date, in ISO 8601 format.
841 &quot;type&quot;: &quot;A String&quot;, # Type of shipment. Indicates whether `deliveryDetails` or `pickupDetails` is applicable for this shipment.
842 #
843 # Acceptable values are:
844 # - &quot;`delivery`&quot;
845 # - &quot;`pickup`&quot;
846 },
847 &quot;tax&quot;: { # Total tax amount for the line item. For example, if two items are purchased, and each have a cost tax of $2, the total tax amount will be $4.
848 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
849 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
850 },
851 },
852 ],
853 &quot;merchantId&quot;: &quot;A String&quot;,
854 &quot;merchantOrderId&quot;: &quot;A String&quot;, # Merchant-provided ID of the order.
855 &quot;netPriceAmount&quot;: { # The net amount for the order (price part). For example, if an order was originally for $100 and a refund was issued for $20, the net amount will be $80.
856 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
857 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
858 },
859 &quot;netTaxAmount&quot;: { # The net amount for the order (tax part). Note that in certain cases due to taxable base adjustment `netTaxAmount` might not match to a sum of tax field across all lineItems and refunds.
860 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
861 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
862 },
863 &quot;paymentStatus&quot;: &quot;A String&quot;, # The status of the payment.
864 #
865 # Acceptable values are:
866 # - &quot;`paymentCaptured`&quot;
867 # - &quot;`paymentRejected`&quot;
868 # - &quot;`paymentSecured`&quot;
869 # - &quot;`pendingAuthorization`&quot;
870 &quot;pickupDetails&quot;: { # Pickup details for shipments of type `pickup`.
871 &quot;address&quot;: { # Address of the pickup location where the shipment should be sent. Note that `recipientName` in the address is the name of the business at the pickup location.
872 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
873 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
874 # John Smith
875 # 1600 Amphitheatre Parkway
876 # Mountain View, CA, 94043
877 # United States
878 &quot;A String&quot;,
879 ],
880 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
881 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
882 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
883 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
884 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
885 &quot;streetAddress&quot;: [ # Street-level part of the address.
886 &quot;A String&quot;,
887 ],
888 },
889 &quot;collectors&quot;: [ # Collectors authorized to pick up shipment from the pickup location.
890 {
891 &quot;name&quot;: &quot;A String&quot;, # Name of the person picking up the shipment.
892 &quot;phoneNumber&quot;: &quot;A String&quot;, # Phone number of the person picking up the shipment.
893 },
894 ],
895 &quot;locationId&quot;: &quot;A String&quot;, # ID of the pickup location.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700896 &quot;pickupType&quot;: &quot;A String&quot;, # The pickup type of this order.
897 #
898 # Acceptable values are:
899 # - &quot;`merchantStore`&quot;
900 # - &quot;`merchantStoreCurbside`&quot;
901 # - &quot;`merchantStoreLocker`&quot;
902 # - &quot;`thirdPartyPickupPoint`&quot;
903 # - &quot;`thirdPartyLocker`&quot;
Bu Sun Kim65020912020-05-20 12:08:20 -0700904 },
905 &quot;placedDate&quot;: &quot;A String&quot;, # The date when the order was placed, in ISO 8601 format.
906 &quot;promotions&quot;: [ # Promotions associated with the order.
Dan O'Mearadd494642020-05-01 07:42:23 -0700907 #
908 # To determine which promotions apply to which products, check the `Promotions[].appliedItems[].lineItemId` field against the `LineItems[].id` field for each promotion. If a promotion is applied to more than 1 offerId, divide the discount value by the number of affected offers to determine how much discount to apply to each offerId.
909 #
910 # Examples:
911 # - To calculate price paid by the customer for a single line item including the discount: For each promotion, subtract the `LineItems[].adjustments[].priceAdjustment.value` amount from the `LineItems[].Price.value`.
912 # - To calculate price paid by the customer for a single line item including the discount in case of multiple quantity: For each promotion, divide the `LineItems[].adjustments[].priceAdjustment.value` by the quantity of products then subtract the resulting value from the `LineItems[].Product.Price.value` for each quantity item.
913 #
914 # Only 1 promotion can be applied to an offerId in a given order. To refund an item which had a promotion applied to it, make sure to refund the amount after first subtracting the promotion discount from the item price.
915 #
916 # More details about the program are here.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700917 {
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700918 &quot;applicableItems&quot;: [ # Items that this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. This field will also be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700919 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700920 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
921 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
922 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
923 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700924 },
925 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700926 &quot;appliedItems&quot;: [ # Items that this promotion have been applied to. Do not provide for `orders.createtestorder`. This field will be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700927 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700928 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
929 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
930 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
931 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700932 },
933 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700934 &quot;endTime&quot;: &quot;A String&quot;, # Promotion end time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
935 &quot;funder&quot;: &quot;A String&quot;, # Required. The party funding the promotion. Only `merchant` is supported for `orders.createtestorder`.
Dan O'Mearadd494642020-05-01 07:42:23 -0700936 #
937 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700938 # - &quot;`google`&quot;
939 # - &quot;`merchant`&quot;
940 &quot;merchantPromotionId&quot;: &quot;A String&quot;, # Required. This field is used to identify promotions within merchants&#x27; own systems.
941 &quot;priceValue&quot;: { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order.
942 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
943 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
944 },
945 &quot;shortTitle&quot;: &quot;A String&quot;, # A short title of the promotion to be shown on the checkout page. Do not provide for `orders.createtestorder`.
946 &quot;startTime&quot;: &quot;A String&quot;, # Promotion start time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
947 &quot;subtype&quot;: &quot;A String&quot;, # Required. The category of the promotion. Only `moneyOff` is supported for `orders.createtestorder`.
Dan O'Mearadd494642020-05-01 07:42:23 -0700948 #
949 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700950 # - &quot;`buyMGetMoneyOff`&quot;
951 # - &quot;`buyMGetNMoneyOff`&quot;
952 # - &quot;`buyMGetNPercentOff`&quot;
953 # - &quot;`buyMGetPercentOff`&quot;
954 # - &quot;`freeGift`&quot;
955 # - &quot;`freeGiftWithItemId`&quot;
956 # - &quot;`freeGiftWithValue`&quot;
957 # - &quot;`freeShippingOvernight`&quot;
958 # - &quot;`freeShippingStandard`&quot;
959 # - &quot;`freeShippingTwoDay`&quot;
960 # - &quot;`moneyOff`&quot;
961 # - &quot;`percentOff`&quot;
962 # - &quot;`rewardPoints`&quot;
963 # - &quot;`salePrice`&quot;
964 &quot;taxValue&quot;: { # Estimated discount applied to tax (if allowed by law). Do not provide for `orders.createtestorder`.
965 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
966 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
967 },
968 &quot;title&quot;: &quot;A String&quot;, # Required. The title of the promotion.
969 &quot;type&quot;: &quot;A String&quot;, # Required. The scope of the promotion. Only `product` is supported for `orders.createtestorder`.
970 #
971 # Acceptable values are:
972 # - &quot;`product`&quot;
973 # - &quot;`shipping`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700974 },
975 ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700976 &quot;refunds&quot;: [ # Refunds for the order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700977 {
Bu Sun Kim65020912020-05-20 12:08:20 -0700978 &quot;actor&quot;: &quot;A String&quot;, # The actor that created the refund.
Dan O'Mearadd494642020-05-01 07:42:23 -0700979 #
980 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -0700981 # - &quot;`customer`&quot;
982 # - &quot;`googleBot`&quot;
983 # - &quot;`googleCustomerService`&quot;
984 # - &quot;`googlePayments`&quot;
985 # - &quot;`googleSabre`&quot;
986 # - &quot;`merchant`&quot;
987 &quot;amount&quot;: { # The amount that is refunded.
988 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
989 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
990 },
991 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the item has been created, in ISO 8601 format.
992 &quot;reason&quot;: &quot;A String&quot;, # The reason for the refund.
993 #
994 # Acceptable values are:
995 # - &quot;`adjustment`&quot;
996 # - &quot;`autoPostInternal`&quot;
997 # - &quot;`autoPostInvalidBillingAddress`&quot;
998 # - &quot;`autoPostNoInventory`&quot;
999 # - &quot;`autoPostPriceError`&quot;
1000 # - &quot;`autoPostUndeliverableShippingAddress`&quot;
1001 # - &quot;`couponAbuse`&quot;
1002 # - &quot;`courtesyAdjustment`&quot;
1003 # - &quot;`customerCanceled`&quot;
1004 # - &quot;`customerDiscretionaryReturn`&quot;
1005 # - &quot;`customerInitiatedMerchantCancel`&quot;
1006 # - &quot;`customerSupportRequested`&quot;
1007 # - &quot;`deliveredLateByCarrier`&quot;
1008 # - &quot;`deliveredTooLate`&quot;
1009 # - &quot;`expiredItem`&quot;
1010 # - &quot;`failToPushOrderGoogleError`&quot;
1011 # - &quot;`failToPushOrderMerchantError`&quot;
1012 # - &quot;`failToPushOrderMerchantFulfillmentError`&quot;
1013 # - &quot;`failToPushOrderToMerchant`&quot;
1014 # - &quot;`failToPushOrderToMerchantOutOfStock`&quot;
1015 # - &quot;`feeAdjustment`&quot;
1016 # - &quot;`invalidCoupon`&quot;
1017 # - &quot;`lateShipmentCredit`&quot;
1018 # - &quot;`malformedShippingAddress`&quot;
1019 # - &quot;`merchantDidNotShipOnTime`&quot;
1020 # - &quot;`noInventory`&quot;
1021 # - &quot;`orderTimeout`&quot;
1022 # - &quot;`other`&quot;
1023 # - &quot;`paymentAbuse`&quot;
1024 # - &quot;`paymentDeclined`&quot;
1025 # - &quot;`priceAdjustment`&quot;
1026 # - &quot;`priceError`&quot;
1027 # - &quot;`productArrivedDamaged`&quot;
1028 # - &quot;`productNotAsDescribed`&quot;
1029 # - &quot;`promoReallocation`&quot;
1030 # - &quot;`qualityNotAsExpected`&quot;
1031 # - &quot;`returnRefundAbuse`&quot;
1032 # - &quot;`shippingCostAdjustment`&quot;
1033 # - &quot;`shippingPriceError`&quot;
1034 # - &quot;`taxAdjustment`&quot;
1035 # - &quot;`taxError`&quot;
1036 # - &quot;`undeliverableShippingAddress`&quot;
1037 # - &quot;`unsupportedPoBoxAddress`&quot;
1038 # - &quot;`wrongProductShipped`&quot;
1039 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
1040 },
1041 ],
1042 &quot;shipments&quot;: [ # Shipments of the order.
1043 {
1044 &quot;carrier&quot;: &quot;A String&quot;, # The carrier handling the shipment.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001045 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001046 # For supported carriers, Google includes the carrier name and tracking URL in emails to customers. For select supported carriers, Google also automatically updates the shipment status based on the provided shipment ID. Note: You can also use unsupported carriers, but emails to customers will not include the carrier name or tracking URL, and there will be no automatic order status updates.
1047 # Supported carriers for US are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001048 # - &quot;`ups`&quot; (United Parcel Service) automatic status updates
1049 # - &quot;`usps`&quot; (United States Postal Service) automatic status updates
1050 # - &quot;`fedex`&quot; (FedEx) automatic status updates
1051 # - &quot;`dhl`&quot; (DHL eCommerce) automatic status updates (US only)
1052 # - &quot;`ontrac`&quot; (OnTrac) automatic status updates
1053 # - &quot;`dhl express`&quot; (DHL Express)
1054 # - &quot;`deliv`&quot; (Deliv)
1055 # - &quot;`dynamex`&quot; (TForce)
1056 # - &quot;`lasership`&quot; (LaserShip)
1057 # - &quot;`mpx`&quot; (Military Parcel Xpress)
1058 # - &quot;`uds`&quot; (United Delivery Service)
1059 # - &quot;`efw`&quot; (Estes Forwarding Worldwide)
1060 # - &quot;`jd logistics`&quot; (JD Logistics)
1061 # - &quot;`yunexpress`&quot; (YunExpress)
1062 # - &quot;`china post`&quot; (China Post)
1063 # - &quot;`china ems`&quot; (China Post Express Mail Service)
1064 # - &quot;`singapore post`&quot; (Singapore Post)
1065 # - &quot;`pos malaysia`&quot; (Pos Malaysia)
1066 # - &quot;`postnl`&quot; (PostNL)
1067 # - &quot;`ptt`&quot; (PTT Turkish Post)
1068 # - &quot;`eub`&quot; (ePacket)
1069 # - &quot;`chukou1`&quot; (Chukou1 Logistics)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001070 # - &quot;`bestex`&quot; (Best Express)
1071 # - &quot;`canada post`&quot; (Canada Post)
1072 # - &quot;`purolator`&quot; (Purolator)
1073 # - &quot;`canpar`&quot; (Canpar)
1074 # - &quot;`india post`&quot; (India Post)
1075 # - &quot;`blue dart`&quot; (Blue Dart)
1076 # - &quot;`delhivery`&quot; (Delhivery)
1077 # - &quot;`dtdc`&quot; (DTDC)
1078 # - &quot;`tpc india`&quot; (TPC India)
Dan O'Mearadd494642020-05-01 07:42:23 -07001079 # Supported carriers for FR are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001080 # - &quot;`la poste`&quot; (La Poste) automatic status updates
1081 # - &quot;`colissimo`&quot; (Colissimo by La Poste) automatic status updates
1082 # - &quot;`ups`&quot; (United Parcel Service) automatic status updates
1083 # - &quot;`chronopost`&quot; (Chronopost by La Poste)
1084 # - &quot;`gls`&quot; (General Logistics Systems France)
1085 # - &quot;`dpd`&quot; (DPD Group by GeoPost)
1086 # - &quot;`bpost`&quot; (Belgian Post Group)
1087 # - &quot;`colis prive`&quot; (Colis Privé)
1088 # - &quot;`boxtal`&quot; (Boxtal)
1089 # - &quot;`geodis`&quot; (GEODIS)
1090 # - &quot;`tnt`&quot; (TNT)
1091 # - &quot;`db schenker`&quot; (DB Schenker)
1092 # - &quot;`aramex`&quot; (Aramex)
1093 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the shipment has been created, in ISO 8601 format.
1094 &quot;deliveryDate&quot;: &quot;A String&quot;, # Date on which the shipment has been delivered, in ISO 8601 format. Present only if `status` is `delivered`
1095 &quot;id&quot;: &quot;A String&quot;, # The ID of the shipment.
1096 &quot;lineItems&quot;: [ # The line items that are shipped.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001097 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001098 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item that is shipped. This value is assigned by Google when an order is created. Either lineItemId or productId is required.
1099 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to ship. This is the REST ID used in the products service. Either lineItemId or productId is required.
1100 &quot;quantity&quot;: 42, # The quantity that is shipped.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001101 },
1102 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001103 &quot;scheduledDeliveryDetails&quot;: { # Delivery details of the shipment if scheduling is needed.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001104 &quot;carrierPhoneNumber&quot;: &quot;A String&quot;, # The phone number of the carrier fulfilling the delivery. The phone number is formatted as the international notation in ITU-T Recommendation E.123 (e.g., &quot;+41 44 668 1800&quot;).
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001105 &quot;scheduledDate&quot;: &quot;A String&quot;, # The date a shipment is scheduled for delivery, in ISO 8601 format.
1106 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001107 &quot;shipmentGroupId&quot;: &quot;A String&quot;, # The shipment group ID of the shipment. This is set in shiplineitems request.
1108 &quot;status&quot;: &quot;A String&quot;, # The status of the shipment.
Dan O'Mearadd494642020-05-01 07:42:23 -07001109 #
1110 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001111 # - &quot;`delivered`&quot;
1112 # - &quot;`readyForPickup`&quot;
1113 # - &quot;`shipped`&quot;
1114 # - &quot;`undeliverable`&quot;
1115 &quot;trackingId&quot;: &quot;A String&quot;, # The tracking ID for the shipment.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001116 },
1117 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001118 &quot;shippingCost&quot;: { # The total cost of shipping for all items.
1119 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1120 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1121 },
1122 &quot;shippingCostTax&quot;: { # The tax for the total shipping cost.
1123 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1124 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1125 },
1126 &quot;status&quot;: &quot;A String&quot;, # The status of the order.
Dan O'Mearadd494642020-05-01 07:42:23 -07001127 #
1128 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001129 # - &quot;`canceled`&quot;
1130 # - &quot;`delivered`&quot;
1131 # - &quot;`inProgress`&quot;
1132 # - &quot;`partiallyDelivered`&quot;
1133 # - &quot;`partiallyReturned`&quot;
1134 # - &quot;`partiallyShipped`&quot;
1135 # - &quot;`pendingShipment`&quot;
1136 # - &quot;`returned`&quot;
1137 # - &quot;`shipped`&quot;
1138 &quot;taxCollector&quot;: &quot;A String&quot;, # The party responsible for collecting and remitting taxes.
Dan O'Mearadd494642020-05-01 07:42:23 -07001139 #
1140 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001141 # - &quot;`marketplaceFacilitator`&quot;
1142 # - &quot;`merchant`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001143 }</pre>
1144</div>
1145
1146<div class="method">
1147 <code class="details" id="getbymerchantorderid">getbymerchantorderid(merchantId, merchantOrderId)</code>
1148 <pre>Retrieves an order using merchant order ID.
1149
1150Args:
1151 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
1152 merchantOrderId: string, The merchant order ID to be looked for. (required)
1153
1154Returns:
1155 An object of the form:
1156
1157 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001158 &quot;kind&quot;: &quot;content#ordersGetByMerchantOrderIdResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersGetByMerchantOrderIdResponse&quot;.
1159 &quot;order&quot;: { # Order. Production access (all methods) requires the order manager role. Sandbox access does not. (== resource_for v2.orders ==) (== resource_for v2.1.orders ==) # The requested order.
1160 &quot;acknowledged&quot;: True or False, # Whether the order was acknowledged.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001161 &quot;annotations&quot;: [ # List of key-value pairs that are attached to a given order.
1162 {
1163 &quot;key&quot;: &quot;A String&quot;, # Key for additional google provided (as key-value pairs) annotation.
1164 &quot;value&quot;: &quot;A String&quot;, # Value for additional google provided (as key-value pairs) annotation.
1165 },
1166 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001167 &quot;billingAddress&quot;: { # The billing address.
1168 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
1169 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
1170 # John Smith
1171 # 1600 Amphitheatre Parkway
1172 # Mountain View, CA, 94043
1173 # United States
1174 &quot;A String&quot;,
1175 ],
1176 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
1177 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
1178 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
1179 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
1180 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
1181 &quot;streetAddress&quot;: [ # Street-level part of the address.
1182 &quot;A String&quot;,
1183 ],
1184 },
1185 &quot;customer&quot;: { # The details of the customer who placed the order.
1186 &quot;fullName&quot;: &quot;A String&quot;, # Full name of the customer.
1187 &quot;invoiceReceivingEmail&quot;: &quot;A String&quot;, # Email address for the merchant to send value-added tax or invoice documentation of the order. Only the last document sent is made available to the customer. For more information, see About automated VAT invoicing for Shopping Actions.
1188 &quot;loyaltyInfo&quot;: { # Loyalty program information.
1189 &quot;loyaltyNumber&quot;: &quot;A String&quot;, # The loyalty card/membership number.
1190 &quot;name&quot;: &quot;A String&quot;, # Name of card/membership holder, this field will be populated when
Dan O'Mearadd494642020-05-01 07:42:23 -07001191 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001192 &quot;marketingRightsInfo&quot;: { # Customer&#x27;s marketing preferences. Contains the marketing opt-in information that is current at the time that the merchant call. User preference selections can change from one order to the next so preferences must be checked with every order.
1193 &quot;explicitMarketingPreference&quot;: &quot;A String&quot;, # Last known customer selection regarding marketing preferences. In certain cases this selection might not be known, so this field would be empty. If a customer selected `granted` in their most recent order, they can be subscribed to marketing emails. Customers who have chosen `denied` must not be subscribed, or must be unsubscribed if already opted-in.
Dan O'Mearadd494642020-05-01 07:42:23 -07001194 #
1195 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001196 # - &quot;`denied`&quot;
1197 # - &quot;`granted`&quot;
1198 &quot;lastUpdatedTimestamp&quot;: &quot;A String&quot;, # Timestamp when last time marketing preference was updated. Could be empty, if user wasn&#x27;t offered a selection yet.
1199 &quot;marketingEmailAddress&quot;: &quot;A String&quot;, # Email address that can be used for marketing purposes. The field may be empty even if `explicitMarketingPreference` is &#x27;granted&#x27;. This happens when retrieving an old order from the customer who deleted their account.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001200 },
1201 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001202 &quot;deliveryDetails&quot;: { # Delivery details for shipments of type `delivery`.
1203 &quot;address&quot;: { # The delivery address
1204 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
1205 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
1206 # John Smith
1207 # 1600 Amphitheatre Parkway
1208 # Mountain View, CA, 94043
1209 # United States
1210 &quot;A String&quot;,
1211 ],
1212 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
1213 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
1214 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
1215 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
1216 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
1217 &quot;streetAddress&quot;: [ # Street-level part of the address.
1218 &quot;A String&quot;,
1219 ],
1220 },
1221 &quot;phoneNumber&quot;: &quot;A String&quot;, # The phone number of the person receiving the delivery.
1222 },
1223 &quot;id&quot;: &quot;A String&quot;, # The REST ID of the order. Globally unique.
1224 &quot;kind&quot;: &quot;content#order&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;`content#order`&quot;
1225 &quot;lineItems&quot;: [ # Line items that are ordered.
1226 {
1227 &quot;adjustments&quot;: [ # Price and tax adjustments applied on the line item.
1228 {
1229 &quot;priceAdjustment&quot;: { # Adjustment for total price of the line item.
1230 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1231 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1232 },
1233 &quot;taxAdjustment&quot;: { # Adjustment for total tax of the line item.
1234 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1235 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1236 },
1237 &quot;type&quot;: &quot;A String&quot;, # Type of this adjustment.
1238 #
1239 # Acceptable values are:
1240 # - &quot;`promotion`&quot;
1241 },
1242 ],
1243 &quot;annotations&quot;: [ # Annotations that are attached to the line item.
1244 {
1245 &quot;key&quot;: &quot;A String&quot;, # Key for additional merchant provided (as key-value pairs) annotation about the line item.
1246 &quot;value&quot;: &quot;A String&quot;, # Value for additional merchant provided (as key-value pairs) annotation about the line item.
1247 },
1248 ],
1249 &quot;cancellations&quot;: [ # Cancellations of the line item.
1250 {
1251 &quot;actor&quot;: &quot;A String&quot;, # The actor that created the cancellation.
1252 #
1253 # Acceptable values are:
1254 # - &quot;`customer`&quot;
1255 # - &quot;`googleBot`&quot;
1256 # - &quot;`googleCustomerService`&quot;
1257 # - &quot;`googlePayments`&quot;
1258 # - &quot;`googleSabre`&quot;
1259 # - &quot;`merchant`&quot;
1260 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the cancellation has been created, in ISO 8601 format.
1261 &quot;quantity&quot;: 42, # The quantity that was canceled.
1262 &quot;reason&quot;: &quot;A String&quot;, # The reason for the cancellation. Orders that are canceled with a noInventory reason will lead to the removal of the product from Shopping Actions until you make an update to that product. This will not affect your Shopping ads.
1263 #
1264 # Acceptable values are:
1265 # - &quot;`autoPostInternal`&quot;
1266 # - &quot;`autoPostInvalidBillingAddress`&quot;
1267 # - &quot;`autoPostNoInventory`&quot;
1268 # - &quot;`autoPostPriceError`&quot;
1269 # - &quot;`autoPostUndeliverableShippingAddress`&quot;
1270 # - &quot;`couponAbuse`&quot;
1271 # - &quot;`customerCanceled`&quot;
1272 # - &quot;`customerInitiatedCancel`&quot;
1273 # - &quot;`customerSupportRequested`&quot;
1274 # - &quot;`failToPushOrderGoogleError`&quot;
1275 # - &quot;`failToPushOrderMerchantError`&quot;
1276 # - &quot;`failToPushOrderMerchantFulfillmentError`&quot;
1277 # - &quot;`failToPushOrderToMerchant`&quot;
1278 # - &quot;`failToPushOrderToMerchantOutOfStock`&quot;
1279 # - &quot;`invalidCoupon`&quot;
1280 # - &quot;`malformedShippingAddress`&quot;
1281 # - &quot;`merchantDidNotShipOnTime`&quot;
1282 # - &quot;`noInventory`&quot;
1283 # - &quot;`orderTimeout`&quot;
1284 # - &quot;`other`&quot;
1285 # - &quot;`paymentAbuse`&quot;
1286 # - &quot;`paymentDeclined`&quot;
1287 # - &quot;`priceError`&quot;
1288 # - &quot;`returnRefundAbuse`&quot;
1289 # - &quot;`shippingPriceError`&quot;
1290 # - &quot;`taxError`&quot;
1291 # - &quot;`undeliverableShippingAddress`&quot;
1292 # - &quot;`unsupportedPoBoxAddress`&quot;
1293 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
1294 },
1295 ],
1296 &quot;id&quot;: &quot;A String&quot;, # The ID of the line item.
1297 &quot;price&quot;: { # Total price for the line item. For example, if two items for $10 are purchased, the total price will be $20.
1298 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1299 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1300 },
1301 &quot;product&quot;: { # Product data as seen by customer from the time of the order placement. Note that certain attributes values (e.g. title or gtin) might be reformatted and no longer match values submitted via product feed.
1302 &quot;brand&quot;: &quot;A String&quot;, # Brand of the item.
1303 &quot;condition&quot;: &quot;A String&quot;, # Condition or state of the item.
1304 #
1305 # Acceptable values are:
1306 # - &quot;`new`&quot;
1307 # - &quot;`refurbished`&quot;
1308 # - &quot;`used`&quot;
1309 &quot;contentLanguage&quot;: &quot;A String&quot;, # The two-letter ISO 639-1 language code for the item.
1310 &quot;fees&quot;: [ # Associated fees at order creation time.
1311 {
1312 &quot;amount&quot;: { # Amount of the fee.
1313 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1314 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1315 },
1316 &quot;name&quot;: &quot;A String&quot;, # Name of the fee.
1317 },
1318 ],
1319 &quot;gtin&quot;: &quot;A String&quot;, # Global Trade Item Number (GTIN) of the item.
1320 &quot;id&quot;: &quot;A String&quot;, # The REST ID of the product.
1321 &quot;imageLink&quot;: &quot;A String&quot;, # URL of an image of the item.
1322 &quot;itemGroupId&quot;: &quot;A String&quot;, # Shared identifier for all variants of the same product.
1323 &quot;mpn&quot;: &quot;A String&quot;, # Manufacturer Part Number (MPN) of the item.
1324 &quot;offerId&quot;: &quot;A String&quot;, # An identifier of the item.
1325 &quot;price&quot;: { # Price of the item.
1326 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1327 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1328 },
1329 &quot;shownImage&quot;: &quot;A String&quot;, # URL to the cached image shown to the user when order was placed.
1330 &quot;targetCountry&quot;: &quot;A String&quot;, # The CLDR territory code of the target country of the product.
1331 &quot;title&quot;: &quot;A String&quot;, # The title of the product.
1332 &quot;variantAttributes&quot;: [ # Variant attributes for the item. These are dimensions of the product, such as color, gender, material, pattern, and size. You can find a comprehensive list of variant attributes here.
1333 {
1334 &quot;dimension&quot;: &quot;A String&quot;, # The dimension of the variant.
1335 &quot;value&quot;: &quot;A String&quot;, # The value for the dimension.
1336 },
1337 ],
1338 },
1339 &quot;quantityCanceled&quot;: 42, # Number of items canceled.
1340 &quot;quantityDelivered&quot;: 42, # Number of items delivered.
1341 &quot;quantityOrdered&quot;: 42, # Number of items ordered.
1342 &quot;quantityPending&quot;: 42, # Number of items pending.
1343 &quot;quantityReadyForPickup&quot;: 42, # Number of items ready for pickup.
1344 &quot;quantityReturned&quot;: 42, # Number of items returned.
1345 &quot;quantityShipped&quot;: 42, # Number of items shipped.
1346 &quot;quantityUndeliverable&quot;: 42, # Number of items undeliverable.
1347 &quot;returnInfo&quot;: { # Details of the return policy for the line item.
1348 &quot;daysToReturn&quot;: 42, # Required. How many days later the item can be returned.
1349 &quot;isReturnable&quot;: True or False, # Required. Whether the item is returnable.
1350 &quot;policyUrl&quot;: &quot;A String&quot;, # Required. URL of the item return policy.
1351 },
1352 &quot;returns&quot;: [ # Returns of the line item.
1353 {
1354 &quot;actor&quot;: &quot;A String&quot;, # The actor that created the refund.
1355 #
1356 # Acceptable values are:
1357 # - &quot;`customer`&quot;
1358 # - &quot;`googleBot`&quot;
1359 # - &quot;`googleCustomerService`&quot;
1360 # - &quot;`googlePayments`&quot;
1361 # - &quot;`googleSabre`&quot;
1362 # - &quot;`merchant`&quot;
1363 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the item has been created, in ISO 8601 format.
1364 &quot;quantity&quot;: 42, # Quantity that is returned.
1365 &quot;reason&quot;: &quot;A String&quot;, # The reason for the return.
1366 #
1367 # Acceptable values are:
1368 # - &quot;`customerDiscretionaryReturn`&quot;
1369 # - &quot;`customerInitiatedMerchantCancel`&quot;
1370 # - &quot;`deliveredTooLate`&quot;
1371 # - &quot;`expiredItem`&quot;
1372 # - &quot;`invalidCoupon`&quot;
1373 # - &quot;`malformedShippingAddress`&quot;
1374 # - &quot;`other`&quot;
1375 # - &quot;`productArrivedDamaged`&quot;
1376 # - &quot;`productNotAsDescribed`&quot;
1377 # - &quot;`qualityNotAsExpected`&quot;
1378 # - &quot;`undeliverableShippingAddress`&quot;
1379 # - &quot;`unsupportedPoBoxAddress`&quot;
1380 # - &quot;`wrongProductShipped`&quot;
1381 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
1382 },
1383 ],
1384 &quot;shippingDetails&quot;: { # Details of the requested shipping for the line item.
1385 &quot;deliverByDate&quot;: &quot;A String&quot;, # Required. The delivery by date, in ISO 8601 format.
1386 &quot;method&quot;: { # Required. Details of the shipping method.
1387 &quot;carrier&quot;: &quot;A String&quot;, # The carrier for the shipping. Optional. See `shipments[].carrier` for a list of acceptable values.
1388 &quot;maxDaysInTransit&quot;: 42, # Required. Maximum transit time.
1389 &quot;methodName&quot;: &quot;A String&quot;, # Required. The name of the shipping method.
1390 &quot;minDaysInTransit&quot;: 42, # Required. Minimum transit time.
1391 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001392 &quot;pickupPromiseInMinutes&quot;: 42, # The promised time in minutes in which the order will be ready for pickup. This only applies to buy-online-pickup-in-store same-day order.
Bu Sun Kim65020912020-05-20 12:08:20 -07001393 &quot;shipByDate&quot;: &quot;A String&quot;, # Required. The ship by date, in ISO 8601 format.
1394 &quot;type&quot;: &quot;A String&quot;, # Type of shipment. Indicates whether `deliveryDetails` or `pickupDetails` is applicable for this shipment.
1395 #
1396 # Acceptable values are:
1397 # - &quot;`delivery`&quot;
1398 # - &quot;`pickup`&quot;
1399 },
1400 &quot;tax&quot;: { # Total tax amount for the line item. For example, if two items are purchased, and each have a cost tax of $2, the total tax amount will be $4.
1401 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1402 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1403 },
1404 },
1405 ],
1406 &quot;merchantId&quot;: &quot;A String&quot;,
1407 &quot;merchantOrderId&quot;: &quot;A String&quot;, # Merchant-provided ID of the order.
1408 &quot;netPriceAmount&quot;: { # The net amount for the order (price part). For example, if an order was originally for $100 and a refund was issued for $20, the net amount will be $80.
1409 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1410 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1411 },
1412 &quot;netTaxAmount&quot;: { # The net amount for the order (tax part). Note that in certain cases due to taxable base adjustment `netTaxAmount` might not match to a sum of tax field across all lineItems and refunds.
1413 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1414 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1415 },
1416 &quot;paymentStatus&quot;: &quot;A String&quot;, # The status of the payment.
1417 #
1418 # Acceptable values are:
1419 # - &quot;`paymentCaptured`&quot;
1420 # - &quot;`paymentRejected`&quot;
1421 # - &quot;`paymentSecured`&quot;
1422 # - &quot;`pendingAuthorization`&quot;
1423 &quot;pickupDetails&quot;: { # Pickup details for shipments of type `pickup`.
1424 &quot;address&quot;: { # Address of the pickup location where the shipment should be sent. Note that `recipientName` in the address is the name of the business at the pickup location.
1425 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
1426 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
1427 # John Smith
1428 # 1600 Amphitheatre Parkway
1429 # Mountain View, CA, 94043
1430 # United States
1431 &quot;A String&quot;,
1432 ],
1433 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
1434 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
1435 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
1436 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
1437 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
1438 &quot;streetAddress&quot;: [ # Street-level part of the address.
1439 &quot;A String&quot;,
1440 ],
1441 },
1442 &quot;collectors&quot;: [ # Collectors authorized to pick up shipment from the pickup location.
1443 {
1444 &quot;name&quot;: &quot;A String&quot;, # Name of the person picking up the shipment.
1445 &quot;phoneNumber&quot;: &quot;A String&quot;, # Phone number of the person picking up the shipment.
1446 },
1447 ],
1448 &quot;locationId&quot;: &quot;A String&quot;, # ID of the pickup location.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001449 &quot;pickupType&quot;: &quot;A String&quot;, # The pickup type of this order.
1450 #
1451 # Acceptable values are:
1452 # - &quot;`merchantStore`&quot;
1453 # - &quot;`merchantStoreCurbside`&quot;
1454 # - &quot;`merchantStoreLocker`&quot;
1455 # - &quot;`thirdPartyPickupPoint`&quot;
1456 # - &quot;`thirdPartyLocker`&quot;
Bu Sun Kim65020912020-05-20 12:08:20 -07001457 },
1458 &quot;placedDate&quot;: &quot;A String&quot;, # The date when the order was placed, in ISO 8601 format.
1459 &quot;promotions&quot;: [ # Promotions associated with the order.
Dan O'Mearadd494642020-05-01 07:42:23 -07001460 #
1461 # To determine which promotions apply to which products, check the `Promotions[].appliedItems[].lineItemId` field against the `LineItems[].id` field for each promotion. If a promotion is applied to more than 1 offerId, divide the discount value by the number of affected offers to determine how much discount to apply to each offerId.
1462 #
1463 # Examples:
1464 # - To calculate price paid by the customer for a single line item including the discount: For each promotion, subtract the `LineItems[].adjustments[].priceAdjustment.value` amount from the `LineItems[].Price.value`.
1465 # - To calculate price paid by the customer for a single line item including the discount in case of multiple quantity: For each promotion, divide the `LineItems[].adjustments[].priceAdjustment.value` by the quantity of products then subtract the resulting value from the `LineItems[].Product.Price.value` for each quantity item.
1466 #
1467 # Only 1 promotion can be applied to an offerId in a given order. To refund an item which had a promotion applied to it, make sure to refund the amount after first subtracting the promotion discount from the item price.
1468 #
1469 # More details about the program are here.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001470 {
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001471 &quot;applicableItems&quot;: [ # Items that this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. This field will also be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001472 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001473 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
1474 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
1475 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
1476 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001477 },
1478 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001479 &quot;appliedItems&quot;: [ # Items that this promotion have been applied to. Do not provide for `orders.createtestorder`. This field will be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001480 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001481 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
1482 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
1483 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
1484 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001485 },
1486 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001487 &quot;endTime&quot;: &quot;A String&quot;, # Promotion end time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
1488 &quot;funder&quot;: &quot;A String&quot;, # Required. The party funding the promotion. Only `merchant` is supported for `orders.createtestorder`.
Dan O'Mearadd494642020-05-01 07:42:23 -07001489 #
1490 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001491 # - &quot;`google`&quot;
1492 # - &quot;`merchant`&quot;
1493 &quot;merchantPromotionId&quot;: &quot;A String&quot;, # Required. This field is used to identify promotions within merchants&#x27; own systems.
1494 &quot;priceValue&quot;: { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order.
1495 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1496 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1497 },
1498 &quot;shortTitle&quot;: &quot;A String&quot;, # A short title of the promotion to be shown on the checkout page. Do not provide for `orders.createtestorder`.
1499 &quot;startTime&quot;: &quot;A String&quot;, # Promotion start time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
1500 &quot;subtype&quot;: &quot;A String&quot;, # Required. The category of the promotion. Only `moneyOff` is supported for `orders.createtestorder`.
Dan O'Mearadd494642020-05-01 07:42:23 -07001501 #
1502 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001503 # - &quot;`buyMGetMoneyOff`&quot;
1504 # - &quot;`buyMGetNMoneyOff`&quot;
1505 # - &quot;`buyMGetNPercentOff`&quot;
1506 # - &quot;`buyMGetPercentOff`&quot;
1507 # - &quot;`freeGift`&quot;
1508 # - &quot;`freeGiftWithItemId`&quot;
1509 # - &quot;`freeGiftWithValue`&quot;
1510 # - &quot;`freeShippingOvernight`&quot;
1511 # - &quot;`freeShippingStandard`&quot;
1512 # - &quot;`freeShippingTwoDay`&quot;
1513 # - &quot;`moneyOff`&quot;
1514 # - &quot;`percentOff`&quot;
1515 # - &quot;`rewardPoints`&quot;
1516 # - &quot;`salePrice`&quot;
1517 &quot;taxValue&quot;: { # Estimated discount applied to tax (if allowed by law). Do not provide for `orders.createtestorder`.
1518 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1519 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1520 },
1521 &quot;title&quot;: &quot;A String&quot;, # Required. The title of the promotion.
1522 &quot;type&quot;: &quot;A String&quot;, # Required. The scope of the promotion. Only `product` is supported for `orders.createtestorder`.
1523 #
1524 # Acceptable values are:
1525 # - &quot;`product`&quot;
1526 # - &quot;`shipping`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001527 },
1528 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001529 &quot;refunds&quot;: [ # Refunds for the order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001530 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001531 &quot;actor&quot;: &quot;A String&quot;, # The actor that created the refund.
Dan O'Mearadd494642020-05-01 07:42:23 -07001532 #
1533 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001534 # - &quot;`customer`&quot;
1535 # - &quot;`googleBot`&quot;
1536 # - &quot;`googleCustomerService`&quot;
1537 # - &quot;`googlePayments`&quot;
1538 # - &quot;`googleSabre`&quot;
1539 # - &quot;`merchant`&quot;
1540 &quot;amount&quot;: { # The amount that is refunded.
1541 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1542 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1543 },
1544 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the item has been created, in ISO 8601 format.
1545 &quot;reason&quot;: &quot;A String&quot;, # The reason for the refund.
1546 #
1547 # Acceptable values are:
1548 # - &quot;`adjustment`&quot;
1549 # - &quot;`autoPostInternal`&quot;
1550 # - &quot;`autoPostInvalidBillingAddress`&quot;
1551 # - &quot;`autoPostNoInventory`&quot;
1552 # - &quot;`autoPostPriceError`&quot;
1553 # - &quot;`autoPostUndeliverableShippingAddress`&quot;
1554 # - &quot;`couponAbuse`&quot;
1555 # - &quot;`courtesyAdjustment`&quot;
1556 # - &quot;`customerCanceled`&quot;
1557 # - &quot;`customerDiscretionaryReturn`&quot;
1558 # - &quot;`customerInitiatedMerchantCancel`&quot;
1559 # - &quot;`customerSupportRequested`&quot;
1560 # - &quot;`deliveredLateByCarrier`&quot;
1561 # - &quot;`deliveredTooLate`&quot;
1562 # - &quot;`expiredItem`&quot;
1563 # - &quot;`failToPushOrderGoogleError`&quot;
1564 # - &quot;`failToPushOrderMerchantError`&quot;
1565 # - &quot;`failToPushOrderMerchantFulfillmentError`&quot;
1566 # - &quot;`failToPushOrderToMerchant`&quot;
1567 # - &quot;`failToPushOrderToMerchantOutOfStock`&quot;
1568 # - &quot;`feeAdjustment`&quot;
1569 # - &quot;`invalidCoupon`&quot;
1570 # - &quot;`lateShipmentCredit`&quot;
1571 # - &quot;`malformedShippingAddress`&quot;
1572 # - &quot;`merchantDidNotShipOnTime`&quot;
1573 # - &quot;`noInventory`&quot;
1574 # - &quot;`orderTimeout`&quot;
1575 # - &quot;`other`&quot;
1576 # - &quot;`paymentAbuse`&quot;
1577 # - &quot;`paymentDeclined`&quot;
1578 # - &quot;`priceAdjustment`&quot;
1579 # - &quot;`priceError`&quot;
1580 # - &quot;`productArrivedDamaged`&quot;
1581 # - &quot;`productNotAsDescribed`&quot;
1582 # - &quot;`promoReallocation`&quot;
1583 # - &quot;`qualityNotAsExpected`&quot;
1584 # - &quot;`returnRefundAbuse`&quot;
1585 # - &quot;`shippingCostAdjustment`&quot;
1586 # - &quot;`shippingPriceError`&quot;
1587 # - &quot;`taxAdjustment`&quot;
1588 # - &quot;`taxError`&quot;
1589 # - &quot;`undeliverableShippingAddress`&quot;
1590 # - &quot;`unsupportedPoBoxAddress`&quot;
1591 # - &quot;`wrongProductShipped`&quot;
1592 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
1593 },
1594 ],
1595 &quot;shipments&quot;: [ # Shipments of the order.
1596 {
1597 &quot;carrier&quot;: &quot;A String&quot;, # The carrier handling the shipment.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001598 #
Dan O'Mearadd494642020-05-01 07:42:23 -07001599 # For supported carriers, Google includes the carrier name and tracking URL in emails to customers. For select supported carriers, Google also automatically updates the shipment status based on the provided shipment ID. Note: You can also use unsupported carriers, but emails to customers will not include the carrier name or tracking URL, and there will be no automatic order status updates.
1600 # Supported carriers for US are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001601 # - &quot;`ups`&quot; (United Parcel Service) automatic status updates
1602 # - &quot;`usps`&quot; (United States Postal Service) automatic status updates
1603 # - &quot;`fedex`&quot; (FedEx) automatic status updates
1604 # - &quot;`dhl`&quot; (DHL eCommerce) automatic status updates (US only)
1605 # - &quot;`ontrac`&quot; (OnTrac) automatic status updates
1606 # - &quot;`dhl express`&quot; (DHL Express)
1607 # - &quot;`deliv`&quot; (Deliv)
1608 # - &quot;`dynamex`&quot; (TForce)
1609 # - &quot;`lasership`&quot; (LaserShip)
1610 # - &quot;`mpx`&quot; (Military Parcel Xpress)
1611 # - &quot;`uds`&quot; (United Delivery Service)
1612 # - &quot;`efw`&quot; (Estes Forwarding Worldwide)
1613 # - &quot;`jd logistics`&quot; (JD Logistics)
1614 # - &quot;`yunexpress`&quot; (YunExpress)
1615 # - &quot;`china post`&quot; (China Post)
1616 # - &quot;`china ems`&quot; (China Post Express Mail Service)
1617 # - &quot;`singapore post`&quot; (Singapore Post)
1618 # - &quot;`pos malaysia`&quot; (Pos Malaysia)
1619 # - &quot;`postnl`&quot; (PostNL)
1620 # - &quot;`ptt`&quot; (PTT Turkish Post)
1621 # - &quot;`eub`&quot; (ePacket)
1622 # - &quot;`chukou1`&quot; (Chukou1 Logistics)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001623 # - &quot;`bestex`&quot; (Best Express)
1624 # - &quot;`canada post`&quot; (Canada Post)
1625 # - &quot;`purolator`&quot; (Purolator)
1626 # - &quot;`canpar`&quot; (Canpar)
1627 # - &quot;`india post`&quot; (India Post)
1628 # - &quot;`blue dart`&quot; (Blue Dart)
1629 # - &quot;`delhivery`&quot; (Delhivery)
1630 # - &quot;`dtdc`&quot; (DTDC)
1631 # - &quot;`tpc india`&quot; (TPC India)
Dan O'Mearadd494642020-05-01 07:42:23 -07001632 # Supported carriers for FR are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001633 # - &quot;`la poste`&quot; (La Poste) automatic status updates
1634 # - &quot;`colissimo`&quot; (Colissimo by La Poste) automatic status updates
1635 # - &quot;`ups`&quot; (United Parcel Service) automatic status updates
1636 # - &quot;`chronopost`&quot; (Chronopost by La Poste)
1637 # - &quot;`gls`&quot; (General Logistics Systems France)
1638 # - &quot;`dpd`&quot; (DPD Group by GeoPost)
1639 # - &quot;`bpost`&quot; (Belgian Post Group)
1640 # - &quot;`colis prive`&quot; (Colis Privé)
1641 # - &quot;`boxtal`&quot; (Boxtal)
1642 # - &quot;`geodis`&quot; (GEODIS)
1643 # - &quot;`tnt`&quot; (TNT)
1644 # - &quot;`db schenker`&quot; (DB Schenker)
1645 # - &quot;`aramex`&quot; (Aramex)
1646 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the shipment has been created, in ISO 8601 format.
1647 &quot;deliveryDate&quot;: &quot;A String&quot;, # Date on which the shipment has been delivered, in ISO 8601 format. Present only if `status` is `delivered`
1648 &quot;id&quot;: &quot;A String&quot;, # The ID of the shipment.
1649 &quot;lineItems&quot;: [ # The line items that are shipped.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001650 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001651 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item that is shipped. This value is assigned by Google when an order is created. Either lineItemId or productId is required.
1652 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to ship. This is the REST ID used in the products service. Either lineItemId or productId is required.
1653 &quot;quantity&quot;: 42, # The quantity that is shipped.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001654 },
1655 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001656 &quot;scheduledDeliveryDetails&quot;: { # Delivery details of the shipment if scheduling is needed.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001657 &quot;carrierPhoneNumber&quot;: &quot;A String&quot;, # The phone number of the carrier fulfilling the delivery. The phone number is formatted as the international notation in ITU-T Recommendation E.123 (e.g., &quot;+41 44 668 1800&quot;).
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001658 &quot;scheduledDate&quot;: &quot;A String&quot;, # The date a shipment is scheduled for delivery, in ISO 8601 format.
1659 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001660 &quot;shipmentGroupId&quot;: &quot;A String&quot;, # The shipment group ID of the shipment. This is set in shiplineitems request.
1661 &quot;status&quot;: &quot;A String&quot;, # The status of the shipment.
Dan O'Mearadd494642020-05-01 07:42:23 -07001662 #
1663 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001664 # - &quot;`delivered`&quot;
1665 # - &quot;`readyForPickup`&quot;
1666 # - &quot;`shipped`&quot;
1667 # - &quot;`undeliverable`&quot;
1668 &quot;trackingId&quot;: &quot;A String&quot;, # The tracking ID for the shipment.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001669 },
1670 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001671 &quot;shippingCost&quot;: { # The total cost of shipping for all items.
1672 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1673 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1674 },
1675 &quot;shippingCostTax&quot;: { # The tax for the total shipping cost.
1676 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1677 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1678 },
1679 &quot;status&quot;: &quot;A String&quot;, # The status of the order.
Dan O'Mearadd494642020-05-01 07:42:23 -07001680 #
1681 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001682 # - &quot;`canceled`&quot;
1683 # - &quot;`delivered`&quot;
1684 # - &quot;`inProgress`&quot;
1685 # - &quot;`partiallyDelivered`&quot;
1686 # - &quot;`partiallyReturned`&quot;
1687 # - &quot;`partiallyShipped`&quot;
1688 # - &quot;`pendingShipment`&quot;
1689 # - &quot;`returned`&quot;
1690 # - &quot;`shipped`&quot;
1691 &quot;taxCollector&quot;: &quot;A String&quot;, # The party responsible for collecting and remitting taxes.
Dan O'Mearadd494642020-05-01 07:42:23 -07001692 #
1693 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001694 # - &quot;`marketplaceFacilitator`&quot;
1695 # - &quot;`merchant`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001696 },
1697 }</pre>
1698</div>
1699
1700<div class="method">
1701 <code class="details" id="gettestordertemplate">gettestordertemplate(merchantId, templateName, country=None)</code>
1702 <pre>Sandbox only. Retrieves an order template that can be used to quickly create a new order in sandbox.
1703
1704Args:
1705 merchantId: string, The ID of the account that should manage the order. This cannot be a multi-client account. (required)
1706 templateName: string, The name of the template to retrieve. (required)
1707 Allowed values
1708 template1 -
1709 template1a -
1710 template1b -
1711 template2 -
Dan O'Mearadd494642020-05-01 07:42:23 -07001712 template3 -
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001713 template4 -
Dan O'Mearadd494642020-05-01 07:42:23 -07001714 country: string, The country of the template to retrieve. Defaults to `US`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001715
1716Returns:
1717 An object of the form:
1718
1719 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001720 &quot;kind&quot;: &quot;content#ordersGetTestOrderTemplateResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersGetTestOrderTemplateResponse&quot;.
1721 &quot;template&quot;: { # The requested test order template.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001722 &quot;deliveryDetails&quot;: { # Overrides the predefined delivery details if provided.
1723 &quot;address&quot;: { # The delivery address
1724 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
1725 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
1726 # John Smith
1727 # 1600 Amphitheatre Parkway
1728 # Mountain View, CA, 94043
1729 # United States
1730 &quot;A String&quot;,
1731 ],
1732 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
1733 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
1734 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
1735 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
1736 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
1737 &quot;streetAddress&quot;: [ # Street-level part of the address.
1738 &quot;A String&quot;,
1739 ],
1740 },
1741 &quot;phoneNumber&quot;: &quot;A String&quot;, # The phone number of the person receiving the delivery.
1742 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001743 &quot;enableOrderinvoices&quot;: True or False, # Whether the orderinvoices service should support this order.
1744 &quot;kind&quot;: &quot;content#testOrder&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;`content#testOrder`&quot;
1745 &quot;lineItems&quot;: [ # Required. Line items that are ordered. At least one line item must be provided.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001746 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001747 &quot;product&quot;: { # Required. Product data from the time of the order placement.
1748 &quot;brand&quot;: &quot;A String&quot;, # Required. Brand of the item.
1749 &quot;condition&quot;: &quot;A String&quot;, # Required. Condition or state of the item.
Dan O'Mearadd494642020-05-01 07:42:23 -07001750 #
1751 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001752 # - &quot;`new`&quot;
1753 &quot;contentLanguage&quot;: &quot;A String&quot;, # Required. The two-letter ISO 639-1 language code for the item.
1754 #
1755 # Acceptable values are:
1756 # - &quot;`en`&quot;
1757 # - &quot;`fr`&quot;
1758 &quot;fees&quot;: [ # Fees for the item. Optional.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001759 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001760 &quot;amount&quot;: { # Amount of the fee.
1761 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1762 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001763 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001764 &quot;name&quot;: &quot;A String&quot;, # Name of the fee.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001765 },
1766 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001767 &quot;gtin&quot;: &quot;A String&quot;, # Global Trade Item Number (GTIN) of the item. Optional.
1768 &quot;imageLink&quot;: &quot;A String&quot;, # Required. URL of an image of the item.
1769 &quot;itemGroupId&quot;: &quot;A String&quot;, # Shared identifier for all variants of the same product. Optional.
1770 &quot;mpn&quot;: &quot;A String&quot;, # Manufacturer Part Number (MPN) of the item. Optional.
1771 &quot;offerId&quot;: &quot;A String&quot;, # Required. An identifier of the item.
1772 &quot;price&quot;: { # Required. The price for the product. Tax is automatically calculated for orders where marketplace facilitator tax laws are applicable. Otherwise, tax settings from Merchant Center are applied.
1773 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1774 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001775 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001776 &quot;targetCountry&quot;: &quot;A String&quot;, # Required. The CLDR territory code of the target country of the product.
1777 &quot;title&quot;: &quot;A String&quot;, # Required. The title of the product.
1778 &quot;variantAttributes&quot;: [ # Variant attributes for the item. Optional.
1779 {
1780 &quot;dimension&quot;: &quot;A String&quot;, # The dimension of the variant.
1781 &quot;value&quot;: &quot;A String&quot;, # The value for the dimension.
1782 },
1783 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001784 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001785 &quot;quantityOrdered&quot;: 42, # Required. Number of items ordered.
1786 &quot;returnInfo&quot;: { # Required. Details of the return policy for the line item.
1787 &quot;daysToReturn&quot;: 42, # Required. How many days later the item can be returned.
1788 &quot;isReturnable&quot;: True or False, # Required. Whether the item is returnable.
1789 &quot;policyUrl&quot;: &quot;A String&quot;, # Required. URL of the item return policy.
1790 },
1791 &quot;shippingDetails&quot;: { # Required. Details of the requested shipping for the line item.
1792 &quot;deliverByDate&quot;: &quot;A String&quot;, # Required. The delivery by date, in ISO 8601 format.
1793 &quot;method&quot;: { # Required. Details of the shipping method.
1794 &quot;carrier&quot;: &quot;A String&quot;, # The carrier for the shipping. Optional. See `shipments[].carrier` for a list of acceptable values.
1795 &quot;maxDaysInTransit&quot;: 42, # Required. Maximum transit time.
1796 &quot;methodName&quot;: &quot;A String&quot;, # Required. The name of the shipping method.
1797 &quot;minDaysInTransit&quot;: 42, # Required. Minimum transit time.
1798 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001799 &quot;pickupPromiseInMinutes&quot;: 42, # The promised time in minutes in which the order will be ready for pickup. This only applies to buy-online-pickup-in-store same-day order.
Bu Sun Kim65020912020-05-20 12:08:20 -07001800 &quot;shipByDate&quot;: &quot;A String&quot;, # Required. The ship by date, in ISO 8601 format.
1801 &quot;type&quot;: &quot;A String&quot;, # Type of shipment. Indicates whether `deliveryDetails` or `pickupDetails` is applicable for this shipment.
Dan O'Mearadd494642020-05-01 07:42:23 -07001802 #
1803 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001804 # - &quot;`delivery`&quot;
1805 # - &quot;`pickup`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001806 },
1807 },
1808 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07001809 &quot;notificationMode&quot;: &quot;A String&quot;, # Restricted. Do not use.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001810 &quot;pickupDetails&quot;: { # Overrides the predefined pickup details if provided.
1811 &quot;locationCode&quot;: &quot;A String&quot;, # Required. Code of the location defined by provider or merchant.
1812 &quot;pickupLocationAddress&quot;: { # Required. Pickup location address.
1813 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
1814 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
1815 # John Smith
1816 # 1600 Amphitheatre Parkway
1817 # Mountain View, CA, 94043
1818 # United States
1819 &quot;A String&quot;,
1820 ],
1821 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
1822 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
1823 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
1824 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
1825 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
1826 &quot;streetAddress&quot;: [ # Street-level part of the address.
1827 &quot;A String&quot;,
1828 ],
1829 },
1830 &quot;pickupLocationType&quot;: &quot;A String&quot;, # Pickup location type.
1831 #
1832 # Acceptable values are:
1833 # - &quot;`locker`&quot;
1834 # - &quot;`store`&quot;
1835 # - &quot;`curbside`&quot;
1836 &quot;pickupPersons&quot;: [ # Required. all pickup persons set by users.
1837 {
1838 &quot;name&quot;: &quot;A String&quot;, # Required. Full name of the pickup person.
1839 &quot;phoneNumber&quot;: &quot;A String&quot;, # Required. The phone number of the person picking up the items.
1840 },
1841 ],
1842 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001843 &quot;predefinedBillingAddress&quot;: &quot;A String&quot;, # Required. The billing address.
Dan O'Mearadd494642020-05-01 07:42:23 -07001844 #
1845 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001846 # - &quot;`dwight`&quot;
1847 # - &quot;`jim`&quot;
1848 # - &quot;`pam`&quot;
1849 &quot;predefinedDeliveryAddress&quot;: &quot;A String&quot;, # Required. Identifier of one of the predefined delivery addresses for the delivery.
Dan O'Mearadd494642020-05-01 07:42:23 -07001850 #
1851 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001852 # - &quot;`dwight`&quot;
1853 # - &quot;`jim`&quot;
1854 # - &quot;`pam`&quot;
1855 &quot;predefinedEmail&quot;: &quot;A String&quot;, # Required. Email address of the customer.
1856 #
1857 # Acceptable values are:
1858 # - &quot;`pog.dwight.schrute@gmail.com`&quot;
1859 # - &quot;`pog.jim.halpert@gmail.com`&quot;
1860 # - &quot;`penpog.pam.beesly@gmail.comding`&quot;
1861 &quot;predefinedPickupDetails&quot;: &quot;A String&quot;, # Identifier of one of the predefined pickup details. Required for orders containing line items with shipping type `pickup`.
1862 #
1863 # Acceptable values are:
1864 # - &quot;`dwight`&quot;
1865 # - &quot;`jim`&quot;
1866 # - &quot;`pam`&quot;
1867 &quot;promotions&quot;: [ # Promotions associated with the order.
1868 {
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001869 &quot;applicableItems&quot;: [ # Items that this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. This field will also be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim65020912020-05-20 12:08:20 -07001870 {
1871 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
1872 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
1873 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
1874 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
1875 },
1876 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07001877 &quot;appliedItems&quot;: [ # Items that this promotion have been applied to. Do not provide for `orders.createtestorder`. This field will be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim65020912020-05-20 12:08:20 -07001878 {
1879 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
1880 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
1881 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
1882 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
1883 },
1884 ],
1885 &quot;endTime&quot;: &quot;A String&quot;, # Promotion end time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
1886 &quot;funder&quot;: &quot;A String&quot;, # Required. The party funding the promotion. Only `merchant` is supported for `orders.createtestorder`.
1887 #
1888 # Acceptable values are:
1889 # - &quot;`google`&quot;
1890 # - &quot;`merchant`&quot;
1891 &quot;merchantPromotionId&quot;: &quot;A String&quot;, # Required. This field is used to identify promotions within merchants&#x27; own systems.
1892 &quot;priceValue&quot;: { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order.
1893 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1894 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1895 },
1896 &quot;shortTitle&quot;: &quot;A String&quot;, # A short title of the promotion to be shown on the checkout page. Do not provide for `orders.createtestorder`.
1897 &quot;startTime&quot;: &quot;A String&quot;, # Promotion start time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
1898 &quot;subtype&quot;: &quot;A String&quot;, # Required. The category of the promotion. Only `moneyOff` is supported for `orders.createtestorder`.
1899 #
1900 # Acceptable values are:
1901 # - &quot;`buyMGetMoneyOff`&quot;
1902 # - &quot;`buyMGetNMoneyOff`&quot;
1903 # - &quot;`buyMGetNPercentOff`&quot;
1904 # - &quot;`buyMGetPercentOff`&quot;
1905 # - &quot;`freeGift`&quot;
1906 # - &quot;`freeGiftWithItemId`&quot;
1907 # - &quot;`freeGiftWithValue`&quot;
1908 # - &quot;`freeShippingOvernight`&quot;
1909 # - &quot;`freeShippingStandard`&quot;
1910 # - &quot;`freeShippingTwoDay`&quot;
1911 # - &quot;`moneyOff`&quot;
1912 # - &quot;`percentOff`&quot;
1913 # - &quot;`rewardPoints`&quot;
1914 # - &quot;`salePrice`&quot;
1915 &quot;taxValue&quot;: { # Estimated discount applied to tax (if allowed by law). Do not provide for `orders.createtestorder`.
1916 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1917 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1918 },
1919 &quot;title&quot;: &quot;A String&quot;, # Required. The title of the promotion.
1920 &quot;type&quot;: &quot;A String&quot;, # Required. The scope of the promotion. Only `product` is supported for `orders.createtestorder`.
1921 #
1922 # Acceptable values are:
1923 # - &quot;`product`&quot;
1924 # - &quot;`shipping`&quot;
1925 },
1926 ],
1927 &quot;shippingCost&quot;: { # Required. The price of shipping for all items. Shipping tax is automatically calculated for orders where marketplace facilitator tax laws are applicable. Otherwise, tax settings from Merchant Center are applied. Note that shipping is not taxed in certain states.
1928 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1929 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1930 },
1931 &quot;shippingOption&quot;: &quot;A String&quot;, # Required. The requested shipping option.
1932 #
1933 # Acceptable values are:
1934 # - &quot;`economy`&quot;
1935 # - &quot;`expedited`&quot;
1936 # - &quot;`oneDay`&quot;
1937 # - &quot;`sameDay`&quot;
1938 # - &quot;`standard`&quot;
1939 # - &quot;`twoDay`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001940 },
1941 }</pre>
1942</div>
1943
1944<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07001945 <code class="details" id="instorerefundlineitem">instorerefundlineitem(merchantId, orderId, body=None)</code>
1946 <pre>Deprecated. Notifies that item return and refund was handled directly by merchant outside of Google payments processing (e.g. cash refund done in store).
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001947Note: We recommend calling the returnrefundlineitem method to refund in-store returns. We will issue the refund directly to the customer. This helps to prevent possible differences arising between merchant and Google transaction records. We also recommend having the point of sale system communicate with Google to ensure that customers do not receive a double refund by first refunding via Google then via an in-store return.
1948
1949Args:
1950 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
1951 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07001952 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001953 The object takes the form of:
1954
1955{
Bu Sun Kim65020912020-05-20 12:08:20 -07001956 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item to return. Either lineItemId or productId is required.
1957 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
1958 &quot;priceAmount&quot;: { # The amount to be refunded. This may be pre-tax or post-tax depending on the location of the order. Required.
1959 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1960 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001961 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001962 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to return. This is the REST ID used in the products service. Either lineItemId or productId is required.
1963 &quot;quantity&quot;: 42, # The quantity to return and refund.
1964 &quot;reason&quot;: &quot;A String&quot;, # The reason for the return.
Dan O'Mearadd494642020-05-01 07:42:23 -07001965 #
1966 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001967 # - &quot;`customerDiscretionaryReturn`&quot;
1968 # - &quot;`customerInitiatedMerchantCancel`&quot;
1969 # - &quot;`deliveredTooLate`&quot;
1970 # - &quot;`expiredItem`&quot;
1971 # - &quot;`invalidCoupon`&quot;
1972 # - &quot;`malformedShippingAddress`&quot;
1973 # - &quot;`other`&quot;
1974 # - &quot;`productArrivedDamaged`&quot;
1975 # - &quot;`productNotAsDescribed`&quot;
1976 # - &quot;`qualityNotAsExpected`&quot;
1977 # - &quot;`undeliverableShippingAddress`&quot;
1978 # - &quot;`unsupportedPoBoxAddress`&quot;
1979 # - &quot;`wrongProductShipped`&quot;
1980 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
1981 &quot;taxAmount&quot;: { # The amount of tax to be refunded. Required.
1982 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
1983 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
1984 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001985 }
1986
1987
1988Returns:
1989 An object of the form:
1990
1991 {
Bu Sun Kim65020912020-05-20 12:08:20 -07001992 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -07001993 #
1994 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07001995 # - &quot;`duplicate`&quot;
1996 # - &quot;`executed`&quot;
1997 &quot;kind&quot;: &quot;content#ordersInStoreRefundLineItemResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersInStoreRefundLineItemResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001998 }</pre>
1999</div>
2000
2001<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -07002002 <code class="details" id="list">list(merchantId, acknowledged=None, maxResults=None, orderBy=None, pageToken=None, placedDateEnd=None, placedDateStart=None, statuses=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002003 <pre>Lists the orders in your Merchant Center account.
2004
2005Args:
2006 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
Bu Sun Kim65020912020-05-20 12:08:20 -07002007 acknowledged: boolean, Obtains orders that match the acknowledgement status. When set to true, obtains orders that have been acknowledged. When false, obtains orders that have not been acknowledged.
2008We recommend using this filter set to `false`, in conjunction with the `acknowledge` call, such that only un-acknowledged orders are returned.
2009 maxResults: integer, The maximum number of orders to return in the response, used for paging. The default value is 25 orders per page, and the maximum allowed value is 250 orders per page.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002010 orderBy: string, Order results by placement date in descending or ascending order.
2011
2012Acceptable values are:
2013- placedDateAsc
2014- placedDateDesc
2015 pageToken: string, The token returned by the previous request.
2016 placedDateEnd: string, Obtains orders placed before this date (exclusively), in ISO 8601 format.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002017 placedDateStart: string, Obtains orders placed after this date (inclusively), in ISO 8601 format.
Dan O'Mearadd494642020-05-01 07:42:23 -07002018 statuses: string, Obtains orders that match any of the specified statuses. Please note that `active` is a shortcut for `pendingShipment` and `partiallyShipped`, and `completed` is a shortcut for `shipped`, `partiallyDelivered`, `delivered`, `partiallyReturned`, `returned`, and `canceled`. (repeated)
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002019 Allowed values
2020 active -
2021 canceled -
2022 completed -
2023 delivered -
2024 inProgress -
2025 partiallyDelivered -
2026 partiallyReturned -
2027 partiallyShipped -
2028 pendingShipment -
2029 returned -
2030 shipped -
2031
2032Returns:
2033 An object of the form:
2034
2035 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002036 &quot;kind&quot;: &quot;content#ordersListResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersListResponse&quot;.
2037 &quot;nextPageToken&quot;: &quot;A String&quot;, # The token for the retrieval of the next page of orders.
2038 &quot;resources&quot;: [
Dan O'Mearadd494642020-05-01 07:42:23 -07002039 { # Order. Production access (all methods) requires the order manager role. Sandbox access does not. (== resource_for v2.orders ==) (== resource_for v2.1.orders ==)
Bu Sun Kim65020912020-05-20 12:08:20 -07002040 &quot;acknowledged&quot;: True or False, # Whether the order was acknowledged.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002041 &quot;annotations&quot;: [ # List of key-value pairs that are attached to a given order.
2042 {
2043 &quot;key&quot;: &quot;A String&quot;, # Key for additional google provided (as key-value pairs) annotation.
2044 &quot;value&quot;: &quot;A String&quot;, # Value for additional google provided (as key-value pairs) annotation.
2045 },
2046 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002047 &quot;billingAddress&quot;: { # The billing address.
2048 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
2049 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
2050 # John Smith
2051 # 1600 Amphitheatre Parkway
2052 # Mountain View, CA, 94043
2053 # United States
2054 &quot;A String&quot;,
2055 ],
2056 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
2057 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
2058 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
2059 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
2060 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
2061 &quot;streetAddress&quot;: [ # Street-level part of the address.
2062 &quot;A String&quot;,
2063 ],
2064 },
2065 &quot;customer&quot;: { # The details of the customer who placed the order.
2066 &quot;fullName&quot;: &quot;A String&quot;, # Full name of the customer.
2067 &quot;invoiceReceivingEmail&quot;: &quot;A String&quot;, # Email address for the merchant to send value-added tax or invoice documentation of the order. Only the last document sent is made available to the customer. For more information, see About automated VAT invoicing for Shopping Actions.
2068 &quot;loyaltyInfo&quot;: { # Loyalty program information.
2069 &quot;loyaltyNumber&quot;: &quot;A String&quot;, # The loyalty card/membership number.
2070 &quot;name&quot;: &quot;A String&quot;, # Name of card/membership holder, this field will be populated when
Dan O'Mearadd494642020-05-01 07:42:23 -07002071 },
Bu Sun Kim65020912020-05-20 12:08:20 -07002072 &quot;marketingRightsInfo&quot;: { # Customer&#x27;s marketing preferences. Contains the marketing opt-in information that is current at the time that the merchant call. User preference selections can change from one order to the next so preferences must be checked with every order.
2073 &quot;explicitMarketingPreference&quot;: &quot;A String&quot;, # Last known customer selection regarding marketing preferences. In certain cases this selection might not be known, so this field would be empty. If a customer selected `granted` in their most recent order, they can be subscribed to marketing emails. Customers who have chosen `denied` must not be subscribed, or must be unsubscribed if already opted-in.
Dan O'Mearadd494642020-05-01 07:42:23 -07002074 #
2075 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002076 # - &quot;`denied`&quot;
2077 # - &quot;`granted`&quot;
2078 &quot;lastUpdatedTimestamp&quot;: &quot;A String&quot;, # Timestamp when last time marketing preference was updated. Could be empty, if user wasn&#x27;t offered a selection yet.
2079 &quot;marketingEmailAddress&quot;: &quot;A String&quot;, # Email address that can be used for marketing purposes. The field may be empty even if `explicitMarketingPreference` is &#x27;granted&#x27;. This happens when retrieving an old order from the customer who deleted their account.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002080 },
2081 },
Bu Sun Kim65020912020-05-20 12:08:20 -07002082 &quot;deliveryDetails&quot;: { # Delivery details for shipments of type `delivery`.
2083 &quot;address&quot;: { # The delivery address
2084 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
2085 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
2086 # John Smith
2087 # 1600 Amphitheatre Parkway
2088 # Mountain View, CA, 94043
2089 # United States
2090 &quot;A String&quot;,
2091 ],
2092 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
2093 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
2094 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
2095 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
2096 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
2097 &quot;streetAddress&quot;: [ # Street-level part of the address.
2098 &quot;A String&quot;,
2099 ],
2100 },
2101 &quot;phoneNumber&quot;: &quot;A String&quot;, # The phone number of the person receiving the delivery.
2102 },
2103 &quot;id&quot;: &quot;A String&quot;, # The REST ID of the order. Globally unique.
2104 &quot;kind&quot;: &quot;content#order&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;`content#order`&quot;
2105 &quot;lineItems&quot;: [ # Line items that are ordered.
2106 {
2107 &quot;adjustments&quot;: [ # Price and tax adjustments applied on the line item.
2108 {
2109 &quot;priceAdjustment&quot;: { # Adjustment for total price of the line item.
2110 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2111 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2112 },
2113 &quot;taxAdjustment&quot;: { # Adjustment for total tax of the line item.
2114 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2115 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2116 },
2117 &quot;type&quot;: &quot;A String&quot;, # Type of this adjustment.
2118 #
2119 # Acceptable values are:
2120 # - &quot;`promotion`&quot;
2121 },
2122 ],
2123 &quot;annotations&quot;: [ # Annotations that are attached to the line item.
2124 {
2125 &quot;key&quot;: &quot;A String&quot;, # Key for additional merchant provided (as key-value pairs) annotation about the line item.
2126 &quot;value&quot;: &quot;A String&quot;, # Value for additional merchant provided (as key-value pairs) annotation about the line item.
2127 },
2128 ],
2129 &quot;cancellations&quot;: [ # Cancellations of the line item.
2130 {
2131 &quot;actor&quot;: &quot;A String&quot;, # The actor that created the cancellation.
2132 #
2133 # Acceptable values are:
2134 # - &quot;`customer`&quot;
2135 # - &quot;`googleBot`&quot;
2136 # - &quot;`googleCustomerService`&quot;
2137 # - &quot;`googlePayments`&quot;
2138 # - &quot;`googleSabre`&quot;
2139 # - &quot;`merchant`&quot;
2140 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the cancellation has been created, in ISO 8601 format.
2141 &quot;quantity&quot;: 42, # The quantity that was canceled.
2142 &quot;reason&quot;: &quot;A String&quot;, # The reason for the cancellation. Orders that are canceled with a noInventory reason will lead to the removal of the product from Shopping Actions until you make an update to that product. This will not affect your Shopping ads.
2143 #
2144 # Acceptable values are:
2145 # - &quot;`autoPostInternal`&quot;
2146 # - &quot;`autoPostInvalidBillingAddress`&quot;
2147 # - &quot;`autoPostNoInventory`&quot;
2148 # - &quot;`autoPostPriceError`&quot;
2149 # - &quot;`autoPostUndeliverableShippingAddress`&quot;
2150 # - &quot;`couponAbuse`&quot;
2151 # - &quot;`customerCanceled`&quot;
2152 # - &quot;`customerInitiatedCancel`&quot;
2153 # - &quot;`customerSupportRequested`&quot;
2154 # - &quot;`failToPushOrderGoogleError`&quot;
2155 # - &quot;`failToPushOrderMerchantError`&quot;
2156 # - &quot;`failToPushOrderMerchantFulfillmentError`&quot;
2157 # - &quot;`failToPushOrderToMerchant`&quot;
2158 # - &quot;`failToPushOrderToMerchantOutOfStock`&quot;
2159 # - &quot;`invalidCoupon`&quot;
2160 # - &quot;`malformedShippingAddress`&quot;
2161 # - &quot;`merchantDidNotShipOnTime`&quot;
2162 # - &quot;`noInventory`&quot;
2163 # - &quot;`orderTimeout`&quot;
2164 # - &quot;`other`&quot;
2165 # - &quot;`paymentAbuse`&quot;
2166 # - &quot;`paymentDeclined`&quot;
2167 # - &quot;`priceError`&quot;
2168 # - &quot;`returnRefundAbuse`&quot;
2169 # - &quot;`shippingPriceError`&quot;
2170 # - &quot;`taxError`&quot;
2171 # - &quot;`undeliverableShippingAddress`&quot;
2172 # - &quot;`unsupportedPoBoxAddress`&quot;
2173 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
2174 },
2175 ],
2176 &quot;id&quot;: &quot;A String&quot;, # The ID of the line item.
2177 &quot;price&quot;: { # Total price for the line item. For example, if two items for $10 are purchased, the total price will be $20.
2178 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2179 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2180 },
2181 &quot;product&quot;: { # Product data as seen by customer from the time of the order placement. Note that certain attributes values (e.g. title or gtin) might be reformatted and no longer match values submitted via product feed.
2182 &quot;brand&quot;: &quot;A String&quot;, # Brand of the item.
2183 &quot;condition&quot;: &quot;A String&quot;, # Condition or state of the item.
2184 #
2185 # Acceptable values are:
2186 # - &quot;`new`&quot;
2187 # - &quot;`refurbished`&quot;
2188 # - &quot;`used`&quot;
2189 &quot;contentLanguage&quot;: &quot;A String&quot;, # The two-letter ISO 639-1 language code for the item.
2190 &quot;fees&quot;: [ # Associated fees at order creation time.
2191 {
2192 &quot;amount&quot;: { # Amount of the fee.
2193 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2194 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2195 },
2196 &quot;name&quot;: &quot;A String&quot;, # Name of the fee.
2197 },
2198 ],
2199 &quot;gtin&quot;: &quot;A String&quot;, # Global Trade Item Number (GTIN) of the item.
2200 &quot;id&quot;: &quot;A String&quot;, # The REST ID of the product.
2201 &quot;imageLink&quot;: &quot;A String&quot;, # URL of an image of the item.
2202 &quot;itemGroupId&quot;: &quot;A String&quot;, # Shared identifier for all variants of the same product.
2203 &quot;mpn&quot;: &quot;A String&quot;, # Manufacturer Part Number (MPN) of the item.
2204 &quot;offerId&quot;: &quot;A String&quot;, # An identifier of the item.
2205 &quot;price&quot;: { # Price of the item.
2206 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2207 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2208 },
2209 &quot;shownImage&quot;: &quot;A String&quot;, # URL to the cached image shown to the user when order was placed.
2210 &quot;targetCountry&quot;: &quot;A String&quot;, # The CLDR territory code of the target country of the product.
2211 &quot;title&quot;: &quot;A String&quot;, # The title of the product.
2212 &quot;variantAttributes&quot;: [ # Variant attributes for the item. These are dimensions of the product, such as color, gender, material, pattern, and size. You can find a comprehensive list of variant attributes here.
2213 {
2214 &quot;dimension&quot;: &quot;A String&quot;, # The dimension of the variant.
2215 &quot;value&quot;: &quot;A String&quot;, # The value for the dimension.
2216 },
2217 ],
2218 },
2219 &quot;quantityCanceled&quot;: 42, # Number of items canceled.
2220 &quot;quantityDelivered&quot;: 42, # Number of items delivered.
2221 &quot;quantityOrdered&quot;: 42, # Number of items ordered.
2222 &quot;quantityPending&quot;: 42, # Number of items pending.
2223 &quot;quantityReadyForPickup&quot;: 42, # Number of items ready for pickup.
2224 &quot;quantityReturned&quot;: 42, # Number of items returned.
2225 &quot;quantityShipped&quot;: 42, # Number of items shipped.
2226 &quot;quantityUndeliverable&quot;: 42, # Number of items undeliverable.
2227 &quot;returnInfo&quot;: { # Details of the return policy for the line item.
2228 &quot;daysToReturn&quot;: 42, # Required. How many days later the item can be returned.
2229 &quot;isReturnable&quot;: True or False, # Required. Whether the item is returnable.
2230 &quot;policyUrl&quot;: &quot;A String&quot;, # Required. URL of the item return policy.
2231 },
2232 &quot;returns&quot;: [ # Returns of the line item.
2233 {
2234 &quot;actor&quot;: &quot;A String&quot;, # The actor that created the refund.
2235 #
2236 # Acceptable values are:
2237 # - &quot;`customer`&quot;
2238 # - &quot;`googleBot`&quot;
2239 # - &quot;`googleCustomerService`&quot;
2240 # - &quot;`googlePayments`&quot;
2241 # - &quot;`googleSabre`&quot;
2242 # - &quot;`merchant`&quot;
2243 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the item has been created, in ISO 8601 format.
2244 &quot;quantity&quot;: 42, # Quantity that is returned.
2245 &quot;reason&quot;: &quot;A String&quot;, # The reason for the return.
2246 #
2247 # Acceptable values are:
2248 # - &quot;`customerDiscretionaryReturn`&quot;
2249 # - &quot;`customerInitiatedMerchantCancel`&quot;
2250 # - &quot;`deliveredTooLate`&quot;
2251 # - &quot;`expiredItem`&quot;
2252 # - &quot;`invalidCoupon`&quot;
2253 # - &quot;`malformedShippingAddress`&quot;
2254 # - &quot;`other`&quot;
2255 # - &quot;`productArrivedDamaged`&quot;
2256 # - &quot;`productNotAsDescribed`&quot;
2257 # - &quot;`qualityNotAsExpected`&quot;
2258 # - &quot;`undeliverableShippingAddress`&quot;
2259 # - &quot;`unsupportedPoBoxAddress`&quot;
2260 # - &quot;`wrongProductShipped`&quot;
2261 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
2262 },
2263 ],
2264 &quot;shippingDetails&quot;: { # Details of the requested shipping for the line item.
2265 &quot;deliverByDate&quot;: &quot;A String&quot;, # Required. The delivery by date, in ISO 8601 format.
2266 &quot;method&quot;: { # Required. Details of the shipping method.
2267 &quot;carrier&quot;: &quot;A String&quot;, # The carrier for the shipping. Optional. See `shipments[].carrier` for a list of acceptable values.
2268 &quot;maxDaysInTransit&quot;: 42, # Required. Maximum transit time.
2269 &quot;methodName&quot;: &quot;A String&quot;, # Required. The name of the shipping method.
2270 &quot;minDaysInTransit&quot;: 42, # Required. Minimum transit time.
2271 },
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002272 &quot;pickupPromiseInMinutes&quot;: 42, # The promised time in minutes in which the order will be ready for pickup. This only applies to buy-online-pickup-in-store same-day order.
Bu Sun Kim65020912020-05-20 12:08:20 -07002273 &quot;shipByDate&quot;: &quot;A String&quot;, # Required. The ship by date, in ISO 8601 format.
2274 &quot;type&quot;: &quot;A String&quot;, # Type of shipment. Indicates whether `deliveryDetails` or `pickupDetails` is applicable for this shipment.
2275 #
2276 # Acceptable values are:
2277 # - &quot;`delivery`&quot;
2278 # - &quot;`pickup`&quot;
2279 },
2280 &quot;tax&quot;: { # Total tax amount for the line item. For example, if two items are purchased, and each have a cost tax of $2, the total tax amount will be $4.
2281 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2282 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2283 },
2284 },
2285 ],
2286 &quot;merchantId&quot;: &quot;A String&quot;,
2287 &quot;merchantOrderId&quot;: &quot;A String&quot;, # Merchant-provided ID of the order.
2288 &quot;netPriceAmount&quot;: { # The net amount for the order (price part). For example, if an order was originally for $100 and a refund was issued for $20, the net amount will be $80.
2289 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2290 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2291 },
2292 &quot;netTaxAmount&quot;: { # The net amount for the order (tax part). Note that in certain cases due to taxable base adjustment `netTaxAmount` might not match to a sum of tax field across all lineItems and refunds.
2293 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2294 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2295 },
2296 &quot;paymentStatus&quot;: &quot;A String&quot;, # The status of the payment.
2297 #
2298 # Acceptable values are:
2299 # - &quot;`paymentCaptured`&quot;
2300 # - &quot;`paymentRejected`&quot;
2301 # - &quot;`paymentSecured`&quot;
2302 # - &quot;`pendingAuthorization`&quot;
2303 &quot;pickupDetails&quot;: { # Pickup details for shipments of type `pickup`.
2304 &quot;address&quot;: { # Address of the pickup location where the shipment should be sent. Note that `recipientName` in the address is the name of the business at the pickup location.
2305 &quot;country&quot;: &quot;A String&quot;, # CLDR country code (e.g. &quot;US&quot;).
2306 &quot;fullAddress&quot;: [ # Strings representing the lines of the printed label for mailing the order, for example:
2307 # John Smith
2308 # 1600 Amphitheatre Parkway
2309 # Mountain View, CA, 94043
2310 # United States
2311 &quot;A String&quot;,
2312 ],
2313 &quot;isPostOfficeBox&quot;: True or False, # Whether the address is a post office box.
2314 &quot;locality&quot;: &quot;A String&quot;, # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs).
2315 &quot;postalCode&quot;: &quot;A String&quot;, # Postal Code or ZIP (e.g. &quot;94043&quot;).
2316 &quot;recipientName&quot;: &quot;A String&quot;, # Name of the recipient.
2317 &quot;region&quot;: &quot;A String&quot;, # Top-level administrative subdivision of the country. For example, a state like California (&quot;CA&quot;) or a province like Quebec (&quot;QC&quot;).
2318 &quot;streetAddress&quot;: [ # Street-level part of the address.
2319 &quot;A String&quot;,
2320 ],
2321 },
2322 &quot;collectors&quot;: [ # Collectors authorized to pick up shipment from the pickup location.
2323 {
2324 &quot;name&quot;: &quot;A String&quot;, # Name of the person picking up the shipment.
2325 &quot;phoneNumber&quot;: &quot;A String&quot;, # Phone number of the person picking up the shipment.
2326 },
2327 ],
2328 &quot;locationId&quot;: &quot;A String&quot;, # ID of the pickup location.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002329 &quot;pickupType&quot;: &quot;A String&quot;, # The pickup type of this order.
2330 #
2331 # Acceptable values are:
2332 # - &quot;`merchantStore`&quot;
2333 # - &quot;`merchantStoreCurbside`&quot;
2334 # - &quot;`merchantStoreLocker`&quot;
2335 # - &quot;`thirdPartyPickupPoint`&quot;
2336 # - &quot;`thirdPartyLocker`&quot;
Bu Sun Kim65020912020-05-20 12:08:20 -07002337 },
2338 &quot;placedDate&quot;: &quot;A String&quot;, # The date when the order was placed, in ISO 8601 format.
2339 &quot;promotions&quot;: [ # Promotions associated with the order.
Dan O'Mearadd494642020-05-01 07:42:23 -07002340 #
2341 # To determine which promotions apply to which products, check the `Promotions[].appliedItems[].lineItemId` field against the `LineItems[].id` field for each promotion. If a promotion is applied to more than 1 offerId, divide the discount value by the number of affected offers to determine how much discount to apply to each offerId.
2342 #
2343 # Examples:
2344 # - To calculate price paid by the customer for a single line item including the discount: For each promotion, subtract the `LineItems[].adjustments[].priceAdjustment.value` amount from the `LineItems[].Price.value`.
2345 # - To calculate price paid by the customer for a single line item including the discount in case of multiple quantity: For each promotion, divide the `LineItems[].adjustments[].priceAdjustment.value` by the quantity of products then subtract the resulting value from the `LineItems[].Product.Price.value` for each quantity item.
2346 #
2347 # Only 1 promotion can be applied to an offerId in a given order. To refund an item which had a promotion applied to it, make sure to refund the amount after first subtracting the promotion discount from the item price.
2348 #
2349 # More details about the program are here.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002350 {
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002351 &quot;applicableItems&quot;: [ # Items that this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. This field will also be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002352 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002353 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
2354 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
2355 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
2356 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002357 },
2358 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002359 &quot;appliedItems&quot;: [ # Items that this promotion have been applied to. Do not provide for `orders.createtestorder`. This field will be empty for shipping promotions because shipping is not tied to any specific item.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002360 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002361 &quot;lineItemId&quot;: &quot;A String&quot;, # The line item ID of a product. Do not provide for `orders.createtestorder`.
2362 &quot;offerId&quot;: &quot;A String&quot;, # Required. Offer ID of a product. Only for `orders.createtestorder`.
2363 &quot;productId&quot;: &quot;A String&quot;, # `orders.createtestorder`.
2364 &quot;quantity&quot;: 42, # The quantity of the associated product. Do not provide for `orders.createtestorder`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002365 },
2366 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002367 &quot;endTime&quot;: &quot;A String&quot;, # Promotion end time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
2368 &quot;funder&quot;: &quot;A String&quot;, # Required. The party funding the promotion. Only `merchant` is supported for `orders.createtestorder`.
Dan O'Mearadd494642020-05-01 07:42:23 -07002369 #
2370 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002371 # - &quot;`google`&quot;
2372 # - &quot;`merchant`&quot;
2373 &quot;merchantPromotionId&quot;: &quot;A String&quot;, # Required. This field is used to identify promotions within merchants&#x27; own systems.
2374 &quot;priceValue&quot;: { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order.
2375 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2376 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2377 },
2378 &quot;shortTitle&quot;: &quot;A String&quot;, # A short title of the promotion to be shown on the checkout page. Do not provide for `orders.createtestorder`.
2379 &quot;startTime&quot;: &quot;A String&quot;, # Promotion start time in ISO 8601 format. Date, time, and offset required, e.g., &quot;2020-01-02T09:00:00+01:00&quot; or &quot;2020-01-02T09:00:00Z&quot;.
2380 &quot;subtype&quot;: &quot;A String&quot;, # Required. The category of the promotion. Only `moneyOff` is supported for `orders.createtestorder`.
Dan O'Mearadd494642020-05-01 07:42:23 -07002381 #
2382 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002383 # - &quot;`buyMGetMoneyOff`&quot;
2384 # - &quot;`buyMGetNMoneyOff`&quot;
2385 # - &quot;`buyMGetNPercentOff`&quot;
2386 # - &quot;`buyMGetPercentOff`&quot;
2387 # - &quot;`freeGift`&quot;
2388 # - &quot;`freeGiftWithItemId`&quot;
2389 # - &quot;`freeGiftWithValue`&quot;
2390 # - &quot;`freeShippingOvernight`&quot;
2391 # - &quot;`freeShippingStandard`&quot;
2392 # - &quot;`freeShippingTwoDay`&quot;
2393 # - &quot;`moneyOff`&quot;
2394 # - &quot;`percentOff`&quot;
2395 # - &quot;`rewardPoints`&quot;
2396 # - &quot;`salePrice`&quot;
2397 &quot;taxValue&quot;: { # Estimated discount applied to tax (if allowed by law). Do not provide for `orders.createtestorder`.
2398 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2399 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2400 },
2401 &quot;title&quot;: &quot;A String&quot;, # Required. The title of the promotion.
2402 &quot;type&quot;: &quot;A String&quot;, # Required. The scope of the promotion. Only `product` is supported for `orders.createtestorder`.
2403 #
2404 # Acceptable values are:
2405 # - &quot;`product`&quot;
2406 # - &quot;`shipping`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002407 },
2408 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002409 &quot;refunds&quot;: [ # Refunds for the order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002410 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002411 &quot;actor&quot;: &quot;A String&quot;, # The actor that created the refund.
Dan O'Mearadd494642020-05-01 07:42:23 -07002412 #
2413 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002414 # - &quot;`customer`&quot;
2415 # - &quot;`googleBot`&quot;
2416 # - &quot;`googleCustomerService`&quot;
2417 # - &quot;`googlePayments`&quot;
2418 # - &quot;`googleSabre`&quot;
2419 # - &quot;`merchant`&quot;
2420 &quot;amount&quot;: { # The amount that is refunded.
2421 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2422 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2423 },
2424 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the item has been created, in ISO 8601 format.
2425 &quot;reason&quot;: &quot;A String&quot;, # The reason for the refund.
2426 #
2427 # Acceptable values are:
2428 # - &quot;`adjustment`&quot;
2429 # - &quot;`autoPostInternal`&quot;
2430 # - &quot;`autoPostInvalidBillingAddress`&quot;
2431 # - &quot;`autoPostNoInventory`&quot;
2432 # - &quot;`autoPostPriceError`&quot;
2433 # - &quot;`autoPostUndeliverableShippingAddress`&quot;
2434 # - &quot;`couponAbuse`&quot;
2435 # - &quot;`courtesyAdjustment`&quot;
2436 # - &quot;`customerCanceled`&quot;
2437 # - &quot;`customerDiscretionaryReturn`&quot;
2438 # - &quot;`customerInitiatedMerchantCancel`&quot;
2439 # - &quot;`customerSupportRequested`&quot;
2440 # - &quot;`deliveredLateByCarrier`&quot;
2441 # - &quot;`deliveredTooLate`&quot;
2442 # - &quot;`expiredItem`&quot;
2443 # - &quot;`failToPushOrderGoogleError`&quot;
2444 # - &quot;`failToPushOrderMerchantError`&quot;
2445 # - &quot;`failToPushOrderMerchantFulfillmentError`&quot;
2446 # - &quot;`failToPushOrderToMerchant`&quot;
2447 # - &quot;`failToPushOrderToMerchantOutOfStock`&quot;
2448 # - &quot;`feeAdjustment`&quot;
2449 # - &quot;`invalidCoupon`&quot;
2450 # - &quot;`lateShipmentCredit`&quot;
2451 # - &quot;`malformedShippingAddress`&quot;
2452 # - &quot;`merchantDidNotShipOnTime`&quot;
2453 # - &quot;`noInventory`&quot;
2454 # - &quot;`orderTimeout`&quot;
2455 # - &quot;`other`&quot;
2456 # - &quot;`paymentAbuse`&quot;
2457 # - &quot;`paymentDeclined`&quot;
2458 # - &quot;`priceAdjustment`&quot;
2459 # - &quot;`priceError`&quot;
2460 # - &quot;`productArrivedDamaged`&quot;
2461 # - &quot;`productNotAsDescribed`&quot;
2462 # - &quot;`promoReallocation`&quot;
2463 # - &quot;`qualityNotAsExpected`&quot;
2464 # - &quot;`returnRefundAbuse`&quot;
2465 # - &quot;`shippingCostAdjustment`&quot;
2466 # - &quot;`shippingPriceError`&quot;
2467 # - &quot;`taxAdjustment`&quot;
2468 # - &quot;`taxError`&quot;
2469 # - &quot;`undeliverableShippingAddress`&quot;
2470 # - &quot;`unsupportedPoBoxAddress`&quot;
2471 # - &quot;`wrongProductShipped`&quot;
2472 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
2473 },
2474 ],
2475 &quot;shipments&quot;: [ # Shipments of the order.
2476 {
2477 &quot;carrier&quot;: &quot;A String&quot;, # The carrier handling the shipment.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002478 #
Dan O'Mearadd494642020-05-01 07:42:23 -07002479 # For supported carriers, Google includes the carrier name and tracking URL in emails to customers. For select supported carriers, Google also automatically updates the shipment status based on the provided shipment ID. Note: You can also use unsupported carriers, but emails to customers will not include the carrier name or tracking URL, and there will be no automatic order status updates.
2480 # Supported carriers for US are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002481 # - &quot;`ups`&quot; (United Parcel Service) automatic status updates
2482 # - &quot;`usps`&quot; (United States Postal Service) automatic status updates
2483 # - &quot;`fedex`&quot; (FedEx) automatic status updates
2484 # - &quot;`dhl`&quot; (DHL eCommerce) automatic status updates (US only)
2485 # - &quot;`ontrac`&quot; (OnTrac) automatic status updates
2486 # - &quot;`dhl express`&quot; (DHL Express)
2487 # - &quot;`deliv`&quot; (Deliv)
2488 # - &quot;`dynamex`&quot; (TForce)
2489 # - &quot;`lasership`&quot; (LaserShip)
2490 # - &quot;`mpx`&quot; (Military Parcel Xpress)
2491 # - &quot;`uds`&quot; (United Delivery Service)
2492 # - &quot;`efw`&quot; (Estes Forwarding Worldwide)
2493 # - &quot;`jd logistics`&quot; (JD Logistics)
2494 # - &quot;`yunexpress`&quot; (YunExpress)
2495 # - &quot;`china post`&quot; (China Post)
2496 # - &quot;`china ems`&quot; (China Post Express Mail Service)
2497 # - &quot;`singapore post`&quot; (Singapore Post)
2498 # - &quot;`pos malaysia`&quot; (Pos Malaysia)
2499 # - &quot;`postnl`&quot; (PostNL)
2500 # - &quot;`ptt`&quot; (PTT Turkish Post)
2501 # - &quot;`eub`&quot; (ePacket)
2502 # - &quot;`chukou1`&quot; (Chukou1 Logistics)
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002503 # - &quot;`bestex`&quot; (Best Express)
2504 # - &quot;`canada post`&quot; (Canada Post)
2505 # - &quot;`purolator`&quot; (Purolator)
2506 # - &quot;`canpar`&quot; (Canpar)
2507 # - &quot;`india post`&quot; (India Post)
2508 # - &quot;`blue dart`&quot; (Blue Dart)
2509 # - &quot;`delhivery`&quot; (Delhivery)
2510 # - &quot;`dtdc`&quot; (DTDC)
2511 # - &quot;`tpc india`&quot; (TPC India)
Dan O'Mearadd494642020-05-01 07:42:23 -07002512 # Supported carriers for FR are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002513 # - &quot;`la poste`&quot; (La Poste) automatic status updates
2514 # - &quot;`colissimo`&quot; (Colissimo by La Poste) automatic status updates
2515 # - &quot;`ups`&quot; (United Parcel Service) automatic status updates
2516 # - &quot;`chronopost`&quot; (Chronopost by La Poste)
2517 # - &quot;`gls`&quot; (General Logistics Systems France)
2518 # - &quot;`dpd`&quot; (DPD Group by GeoPost)
2519 # - &quot;`bpost`&quot; (Belgian Post Group)
2520 # - &quot;`colis prive`&quot; (Colis Privé)
2521 # - &quot;`boxtal`&quot; (Boxtal)
2522 # - &quot;`geodis`&quot; (GEODIS)
2523 # - &quot;`tnt`&quot; (TNT)
2524 # - &quot;`db schenker`&quot; (DB Schenker)
2525 # - &quot;`aramex`&quot; (Aramex)
2526 &quot;creationDate&quot;: &quot;A String&quot;, # Date on which the shipment has been created, in ISO 8601 format.
2527 &quot;deliveryDate&quot;: &quot;A String&quot;, # Date on which the shipment has been delivered, in ISO 8601 format. Present only if `status` is `delivered`
2528 &quot;id&quot;: &quot;A String&quot;, # The ID of the shipment.
2529 &quot;lineItems&quot;: [ # The line items that are shipped.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002530 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002531 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item that is shipped. This value is assigned by Google when an order is created. Either lineItemId or productId is required.
2532 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to ship. This is the REST ID used in the products service. Either lineItemId or productId is required.
2533 &quot;quantity&quot;: 42, # The quantity that is shipped.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002534 },
2535 ],
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002536 &quot;scheduledDeliveryDetails&quot;: { # Delivery details of the shipment if scheduling is needed.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07002537 &quot;carrierPhoneNumber&quot;: &quot;A String&quot;, # The phone number of the carrier fulfilling the delivery. The phone number is formatted as the international notation in ITU-T Recommendation E.123 (e.g., &quot;+41 44 668 1800&quot;).
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002538 &quot;scheduledDate&quot;: &quot;A String&quot;, # The date a shipment is scheduled for delivery, in ISO 8601 format.
2539 },
Bu Sun Kim65020912020-05-20 12:08:20 -07002540 &quot;shipmentGroupId&quot;: &quot;A String&quot;, # The shipment group ID of the shipment. This is set in shiplineitems request.
2541 &quot;status&quot;: &quot;A String&quot;, # The status of the shipment.
Dan O'Mearadd494642020-05-01 07:42:23 -07002542 #
2543 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002544 # - &quot;`delivered`&quot;
2545 # - &quot;`readyForPickup`&quot;
2546 # - &quot;`shipped`&quot;
2547 # - &quot;`undeliverable`&quot;
2548 &quot;trackingId&quot;: &quot;A String&quot;, # The tracking ID for the shipment.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002549 },
2550 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002551 &quot;shippingCost&quot;: { # The total cost of shipping for all items.
2552 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2553 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2554 },
2555 &quot;shippingCostTax&quot;: { # The tax for the total shipping cost.
2556 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2557 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2558 },
2559 &quot;status&quot;: &quot;A String&quot;, # The status of the order.
Dan O'Mearadd494642020-05-01 07:42:23 -07002560 #
2561 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002562 # - &quot;`canceled`&quot;
2563 # - &quot;`delivered`&quot;
2564 # - &quot;`inProgress`&quot;
2565 # - &quot;`partiallyDelivered`&quot;
2566 # - &quot;`partiallyReturned`&quot;
2567 # - &quot;`partiallyShipped`&quot;
2568 # - &quot;`pendingShipment`&quot;
2569 # - &quot;`returned`&quot;
2570 # - &quot;`shipped`&quot;
2571 &quot;taxCollector&quot;: &quot;A String&quot;, # The party responsible for collecting and remitting taxes.
Dan O'Mearadd494642020-05-01 07:42:23 -07002572 #
2573 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002574 # - &quot;`marketplaceFacilitator`&quot;
2575 # - &quot;`merchant`&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002576 },
2577 ],
2578 }</pre>
2579</div>
2580
2581<div class="method">
2582 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
2583 <pre>Retrieves the next page of results.
2584
2585Args:
2586 previous_request: The request for the previous page. (required)
2587 previous_response: The response from the request for the previous page. (required)
2588
2589Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -07002590 A request object that you can call &#x27;execute()&#x27; on to request the next
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002591 page. Returns None if there are no more items in the collection.
2592 </pre>
2593</div>
2594
2595<div class="method">
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002596 <code class="details" id="refunditem">refunditem(merchantId, orderId, body=None)</code>
2597 <pre>Issues a partial or total refund for items and shipment.
2598
2599Args:
2600 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
2601 orderId: string, The ID of the order to refund. (required)
2602 body: object, The request body.
2603 The object takes the form of:
2604
2605{
2606 &quot;items&quot;: [ # The items that are refunded. Either Item or Shipping must be provided in the request.
2607 {
2608 &quot;amount&quot;: { # The total amount that is refunded. (e.g. refunding $5 each for 2 products should be done by setting quantity to 2 and amount to 10$) In case of multiple refunds, this should be the amount you currently want to refund to the customer.
2609 &quot;priceAmount&quot;: { # The pre-tax or post-tax price depends on the location of the order. - For countries (e.g. US) where price attribute excludes tax, this field corresponds to the pre-tax value. - For coutries (e.g. France) where price attribute includes tax, this field corresponds to the post-tax value .
2610 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2611 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2612 },
2613 &quot;taxAmount&quot;: { # Tax value, present only for countries where price attribute excludes tax (e.g. US). No tax is referenced as 0 value with the corresponding `currency`.
2614 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2615 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2616 },
2617 },
2618 &quot;fullRefund&quot;: True or False, # If true, the full item will be refunded. If this is true, amount should not be provided and will be ignored.
2619 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item. Either lineItemId or productId is required.
2620 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product. This is the REST ID used in the products service. Either lineItemId or productId is required.
2621 &quot;quantity&quot;: 42, # The number of products that are refunded.
2622 },
2623 ],
2624 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
2625 &quot;reason&quot;: &quot;A String&quot;, # The reason for the refund.
2626 #
2627 # Acceptable values are:
2628 # - &quot;`shippingCostAdjustment`&quot;
2629 # - &quot;`priceAdjustment`&quot;
2630 # - &quot;`taxAdjustment`&quot;
2631 # - &quot;`feeAdjustment`&quot;
2632 # - &quot;`courtesyAdjustment`&quot;
2633 # - &quot;`adjustment`&quot;
2634 # - &quot;`customerCancelled`&quot;
2635 # - &quot;`noInventory`&quot;
2636 # - &quot;`productNotAsDescribed`&quot;
2637 # - &quot;`undeliverableShippingAddress`&quot;
2638 # - &quot;`wrongProductShipped`&quot;
2639 # - &quot;`lateShipmentCredit`&quot;
2640 # - &quot;`deliveredLateByCarrier`&quot;
2641 # - &quot;`productArrivedDamaged`&quot;
2642 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
2643 &quot;shipping&quot;: { # The refund on shipping. Optional, but either Item or Shipping must be provided in the request.
2644 &quot;amount&quot;: { # The amount that is refunded. If this is not the first refund for the shipment, this should be the newly refunded amount.
2645 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2646 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2647 },
2648 &quot;fullRefund&quot;: True or False, # If set to true, all shipping costs for the order will be refunded. If this is true, amount should not be provided and will be ignored.
2649 },
2650 }
2651
2652
2653Returns:
2654 An object of the form:
2655
2656 {
2657 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
2658 #
2659 # Acceptable values are:
2660 # - &quot;`duplicate`&quot;
2661 # - &quot;`executed`&quot;
2662 &quot;kind&quot;: &quot;content#ordersRefundItemResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersRefundItemResponse&quot;.
2663 }</pre>
2664</div>
2665
2666<div class="method">
2667 <code class="details" id="refundorder">refundorder(merchantId, orderId, body=None)</code>
2668 <pre>Issues a partial or total refund for an order.
2669
2670Args:
2671 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
2672 orderId: string, The ID of the order to refund. (required)
2673 body: object, The request body.
2674 The object takes the form of:
2675
2676{
2677 &quot;amount&quot;: { # The amount that is refunded. If this is not the first refund for the order, this should be the newly refunded amount.
2678 &quot;priceAmount&quot;: { # The pre-tax or post-tax price depends on the location of the order. - For countries (e.g. US) where price attribute excludes tax, this field corresponds to the pre-tax value. - For coutries (e.g. France) where price attribute includes tax, this field corresponds to the post-tax value .
2679 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2680 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2681 },
2682 &quot;taxAmount&quot;: { # Tax value, present only for countries where price attribute excludes tax (e.g. US). No tax is referenced as 0 value with the corresponding `currency`.
2683 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2684 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2685 },
2686 },
2687 &quot;fullRefund&quot;: True or False, # If true, the full order will be refunded, including shipping. If this is true, amount should not be provided and will be ignored.
2688 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
2689 &quot;reason&quot;: &quot;A String&quot;, # The reason for the refund.
2690 #
2691 # Acceptable values are:
2692 # - &quot;`courtesyAdjustment`&quot;
2693 # - &quot;`other`&quot;
2694 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
2695 }
2696
2697
2698Returns:
2699 An object of the form:
2700
2701 {
2702 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
2703 #
2704 # Acceptable values are:
2705 # - &quot;`duplicate`&quot;
2706 # - &quot;`executed`&quot;
2707 &quot;kind&quot;: &quot;content#ordersRefundOrderResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersRefundOrderResponse&quot;.
2708 }</pre>
2709</div>
2710
2711<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07002712 <code class="details" id="rejectreturnlineitem">rejectreturnlineitem(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002713 <pre>Rejects return on an line item.
2714
2715Args:
2716 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
2717 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002718 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002719 The object takes the form of:
2720
2721{
Bu Sun Kim65020912020-05-20 12:08:20 -07002722 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item to return. Either lineItemId or productId is required.
2723 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
2724 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to return. This is the REST ID used in the products service. Either lineItemId or productId is required.
2725 &quot;quantity&quot;: 42, # The quantity to return and refund.
2726 &quot;reason&quot;: &quot;A String&quot;, # The reason for the return.
Dan O'Mearadd494642020-05-01 07:42:23 -07002727 #
2728 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002729 # - &quot;`damagedOrUsed`&quot;
2730 # - &quot;`missingComponent`&quot;
2731 # - &quot;`notEligible`&quot;
2732 # - &quot;`other`&quot;
2733 # - &quot;`outOfReturnWindow`&quot;
2734 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002735 }
2736
2737
2738Returns:
2739 An object of the form:
2740
2741 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002742 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -07002743 #
2744 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002745 # - &quot;`duplicate`&quot;
2746 # - &quot;`executed`&quot;
2747 &quot;kind&quot;: &quot;content#ordersRejectReturnLineItemResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersRejectReturnLineItemResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002748 }</pre>
2749</div>
2750
2751<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07002752 <code class="details" id="returnrefundlineitem">returnrefundlineitem(merchantId, orderId, body=None)</code>
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002753 <pre>Returns and refunds a line item. Note that this method can only be called on fully shipped orders. Please also note that the Orderreturns API is the preferred way to handle returns after you receive a return from a customer. You can use Orderreturns.list or Orderreturns.get to search for the return, and then use Orderreturns.processreturn to issue the refund. If the return cannot be found, then we recommend using this API to issue a refund.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002754
2755Args:
2756 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
2757 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002758 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002759 The object takes the form of:
2760
2761{
Bu Sun Kim65020912020-05-20 12:08:20 -07002762 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item to return. Either lineItemId or productId is required.
2763 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
2764 &quot;priceAmount&quot;: { # The amount to be refunded. This may be pre-tax or post-tax depending on the location of the order. If omitted, refundless return is assumed.
2765 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2766 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002767 },
Bu Sun Kim65020912020-05-20 12:08:20 -07002768 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to return. This is the REST ID used in the products service. Either lineItemId or productId is required.
2769 &quot;quantity&quot;: 42, # The quantity to return and refund.
2770 &quot;reason&quot;: &quot;A String&quot;, # The reason for the return.
Dan O'Mearadd494642020-05-01 07:42:23 -07002771 #
2772 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002773 # - &quot;`customerDiscretionaryReturn`&quot;
2774 # - &quot;`customerInitiatedMerchantCancel`&quot;
2775 # - &quot;`deliveredTooLate`&quot;
2776 # - &quot;`expiredItem`&quot;
2777 # - &quot;`invalidCoupon`&quot;
2778 # - &quot;`malformedShippingAddress`&quot;
2779 # - &quot;`other`&quot;
2780 # - &quot;`productArrivedDamaged`&quot;
2781 # - &quot;`productNotAsDescribed`&quot;
2782 # - &quot;`qualityNotAsExpected`&quot;
2783 # - &quot;`undeliverableShippingAddress`&quot;
2784 # - &quot;`unsupportedPoBoxAddress`&quot;
2785 # - &quot;`wrongProductShipped`&quot;
2786 &quot;reasonText&quot;: &quot;A String&quot;, # The explanation of the reason.
2787 &quot;taxAmount&quot;: { # The amount of tax to be refunded. Optional, but if filled, then priceAmount must be set. Calculated automatically if not provided.
2788 &quot;currency&quot;: &quot;A String&quot;, # The currency of the price.
2789 &quot;value&quot;: &quot;A String&quot;, # The price represented as a number.
2790 },
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002791 }
2792
2793
2794Returns:
2795 An object of the form:
2796
2797 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002798 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -07002799 #
2800 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002801 # - &quot;`duplicate`&quot;
2802 # - &quot;`executed`&quot;
2803 &quot;kind&quot;: &quot;content#ordersReturnRefundLineItemResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersReturnRefundLineItemResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002804 }</pre>
2805</div>
2806
2807<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07002808 <code class="details" id="setlineitemmetadata">setlineitemmetadata(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002809 <pre>Sets (or overrides if it already exists) merchant provided annotations in the form of key-value pairs. A common use case would be to supply us with additional structured information about a line item that cannot be provided via other methods. Submitted key-value pairs can be retrieved as part of the orders resource.
2810
2811Args:
2812 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
2813 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002814 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002815 The object takes the form of:
2816
2817{
Bu Sun Kim65020912020-05-20 12:08:20 -07002818 &quot;annotations&quot;: [
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002819 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002820 &quot;key&quot;: &quot;A String&quot;, # Key for additional merchant provided (as key-value pairs) annotation about the line item.
2821 &quot;value&quot;: &quot;A String&quot;, # Value for additional merchant provided (as key-value pairs) annotation about the line item.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002822 },
2823 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002824 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item to set metadata. Either lineItemId or productId is required.
2825 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
2826 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to set metadata. This is the REST ID used in the products service. Either lineItemId or productId is required.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002827 }
2828
2829
2830Returns:
2831 An object of the form:
2832
2833 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002834 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -07002835 #
2836 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002837 # - &quot;`duplicate`&quot;
2838 # - &quot;`executed`&quot;
2839 &quot;kind&quot;: &quot;content#ordersSetLineItemMetadataResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersSetLineItemMetadataResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002840 }</pre>
2841</div>
2842
2843<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07002844 <code class="details" id="shiplineitems">shiplineitems(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002845 <pre>Marks line item(s) as shipped.
2846
2847Args:
2848 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
2849 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002850 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002851 The object takes the form of:
2852
2853{
Bu Sun Kim65020912020-05-20 12:08:20 -07002854 &quot;lineItems&quot;: [ # Line items to ship.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002855 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002856 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item that is shipped. This value is assigned by Google when an order is created. Either lineItemId or productId is required.
2857 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to ship. This is the REST ID used in the products service. Either lineItemId or productId is required.
2858 &quot;quantity&quot;: 42, # The quantity that is shipped.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002859 },
2860 ],
Bu Sun Kim65020912020-05-20 12:08:20 -07002861 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
2862 &quot;shipmentGroupId&quot;: &quot;A String&quot;, # ID of the shipment group. Required for orders that use the orderinvoices service.
2863 &quot;shipmentInfos&quot;: [ # Shipment information. This field is repeated because a single line item can be shipped in several packages (and have several tracking IDs).
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002864 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002865 &quot;carrier&quot;: &quot;A String&quot;, # The carrier handling the shipment. See `shipments[].carrier` in the Orders resource representation for a list of acceptable values.
2866 &quot;shipmentId&quot;: &quot;A String&quot;, # Required. The ID of the shipment. This is assigned by the merchant and is unique to each shipment.
2867 &quot;trackingId&quot;: &quot;A String&quot;, # The tracking ID for the shipment.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002868 },
2869 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002870 }
2871
2872
2873Returns:
2874 An object of the form:
2875
2876 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002877 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -07002878 #
2879 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002880 # - &quot;`duplicate`&quot;
2881 # - &quot;`executed`&quot;
2882 &quot;kind&quot;: &quot;content#ordersShipLineItemsResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersShipLineItemsResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002883 }</pre>
2884</div>
2885
2886<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07002887 <code class="details" id="updatelineitemshippingdetails">updatelineitemshippingdetails(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002888 <pre>Updates ship by and delivery by dates for a line item.
2889
2890Args:
2891 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
2892 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002893 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002894 The object takes the form of:
2895
2896{
Bu Sun Kim65020912020-05-20 12:08:20 -07002897 &quot;deliverByDate&quot;: &quot;A String&quot;, # Updated delivery by date, in ISO 8601 format. If not specified only ship by date is updated.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002898 #
2899 # Provided date should be within 1 year timeframe and can not be a date in the past.
Bu Sun Kim65020912020-05-20 12:08:20 -07002900 &quot;lineItemId&quot;: &quot;A String&quot;, # The ID of the line item to set metadata. Either lineItemId or productId is required.
2901 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
2902 &quot;productId&quot;: &quot;A String&quot;, # The ID of the product to set metadata. This is the REST ID used in the products service. Either lineItemId or productId is required.
2903 &quot;shipByDate&quot;: &quot;A String&quot;, # Updated ship by date, in ISO 8601 format. If not specified only deliver by date is updated.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002904 #
2905 # Provided date should be within 1 year timeframe and can not be a date in the past.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002906 }
2907
2908
2909Returns:
2910 An object of the form:
2911
2912 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002913 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -07002914 #
2915 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002916 # - &quot;`duplicate`&quot;
2917 # - &quot;`executed`&quot;
2918 &quot;kind&quot;: &quot;content#ordersUpdateLineItemShippingDetailsResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersUpdateLineItemShippingDetailsResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002919 }</pre>
2920</div>
2921
2922<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07002923 <code class="details" id="updatemerchantorderid">updatemerchantorderid(merchantId, orderId, body=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002924 <pre>Updates the merchant order ID for a given order.
2925
2926Args:
2927 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
2928 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002929 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002930 The object takes the form of:
2931
2932{
Bu Sun Kim65020912020-05-20 12:08:20 -07002933 &quot;merchantOrderId&quot;: &quot;A String&quot;, # The merchant order id to be assigned to the order. Must be unique per merchant.
2934 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002935 }
2936
2937
2938Returns:
2939 An object of the form:
2940
2941 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002942 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -07002943 #
2944 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002945 # - &quot;`duplicate`&quot;
2946 # - &quot;`executed`&quot;
2947 &quot;kind&quot;: &quot;content#ordersUpdateMerchantOrderIdResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersUpdateMerchantOrderIdResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002948 }</pre>
2949</div>
2950
2951<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -07002952 <code class="details" id="updateshipment">updateshipment(merchantId, orderId, body=None)</code>
Bu Sun Kim65020912020-05-20 12:08:20 -07002953 <pre>Updates a shipment&#x27;s status, carrier, and/or tracking ID.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002954
2955Args:
2956 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required)
2957 orderId: string, The ID of the order. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07002958 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002959 The object takes the form of:
2960
2961{
Bu Sun Kim65020912020-05-20 12:08:20 -07002962 &quot;carrier&quot;: &quot;A String&quot;, # The carrier handling the shipment. Not updated if missing. See `shipments[].carrier` in the Orders resource representation for a list of acceptable values.
2963 &quot;deliveryDate&quot;: &quot;A String&quot;, # Date on which the shipment has been delivered, in ISO 8601 format. Optional and can be provided only if `status` is `delivered`.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002964 &quot;lastPickupDate&quot;: &quot;A String&quot;, # Date after which the pickup will expire, in ISO 8601 format. Required only when order is buy-online-pickup-in-store(BOPIS) and `status` is `ready for pickup`.
Bu Sun Kim65020912020-05-20 12:08:20 -07002965 &quot;operationId&quot;: &quot;A String&quot;, # The ID of the operation. Unique across all operations for a given order.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002966 &quot;readyPickupDate&quot;: &quot;A String&quot;, # Date on which the shipment has been ready for pickup, in ISO 8601 format. Optional and can be provided only if `status` is `ready for pickup`.
Bu Sun Kim65020912020-05-20 12:08:20 -07002967 &quot;shipmentId&quot;: &quot;A String&quot;, # The ID of the shipment.
2968 &quot;status&quot;: &quot;A String&quot;, # New status for the shipment. Not updated if missing.
Dan O'Mearadd494642020-05-01 07:42:23 -07002969 #
2970 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002971 # - &quot;`delivered`&quot;
2972 # - &quot;`undeliverable`&quot;
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002973 # - &quot;`readyForPickup`&quot;
Bu Sun Kim65020912020-05-20 12:08:20 -07002974 &quot;trackingId&quot;: &quot;A String&quot;, # The tracking ID for the shipment. Not updated if missing.
Bu Sun Kimd059ad82020-07-22 17:02:09 -07002975 &quot;undeliveredDate&quot;: &quot;A String&quot;, # Date on which the shipment has been undeliverable, in ISO 8601 format. Optional and can be provided only if `status` is `undeliverable`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002976 }
2977
2978
2979Returns:
2980 An object of the form:
2981
2982 {
Bu Sun Kim65020912020-05-20 12:08:20 -07002983 &quot;executionStatus&quot;: &quot;A String&quot;, # The status of the execution.
Dan O'Mearadd494642020-05-01 07:42:23 -07002984 #
2985 # Acceptable values are:
Bu Sun Kim65020912020-05-20 12:08:20 -07002986 # - &quot;`duplicate`&quot;
2987 # - &quot;`executed`&quot;
2988 &quot;kind&quot;: &quot;content#ordersUpdateShipmentResponse&quot;, # Identifies what kind of resource this is. Value: the fixed string &quot;content#ordersUpdateShipmentResponse&quot;.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07002989 }</pre>
2990</div>
2991
2992</body></html>