1<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"> 78 <code><a href="#acknowledge">acknowledge(merchantId, orderId, body)</a></code></p> 79<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> 82<p class="firstline">Sandbox only. Moves a test order from state "inProgress" to state "pendingShipment".</p> 83<p class="toc_element"> 84 <code><a href="#cancel">cancel(merchantId, orderId, body)</a></code></p> 85<p class="firstline">Cancels all line items in an order, making a full refund.</p> 86<p class="toc_element"> 87 <code><a href="#cancellineitem">cancellineitem(merchantId, orderId, body)</a></code></p> 88<p class="firstline">Cancels a line item, making a full refund.</p> 89<p class="toc_element"> 90 <code><a href="#canceltestorderbycustomer">canceltestorderbycustomer(merchantId, orderId, body)</a></code></p> 91<p class="firstline">Sandbox only. Cancels a test order for customer-initiated cancellation.</p> 92<p class="toc_element"> 93 <code><a href="#createtestorder">createtestorder(merchantId, body)</a></code></p> 94<p class="firstline">Sandbox only. Creates a test order.</p> 95<p class="toc_element"> 96 <code><a href="#createtestreturn">createtestreturn(merchantId, orderId, body)</a></code></p> 97<p class="firstline">Sandbox only. Creates a test return.</p> 98<p class="toc_element"> 99 <code><a href="#get">get(merchantId, orderId)</a></code></p> 100<p class="firstline">Retrieves an order from your Merchant Center account.</p> 101<p class="toc_element"> 102 <code><a href="#getbymerchantorderid">getbymerchantorderid(merchantId, merchantOrderId)</a></code></p> 103<p class="firstline">Retrieves an order using merchant order ID.</p> 104<p class="toc_element"> 105 <code><a href="#gettestordertemplate">gettestordertemplate(merchantId, templateName, country=None)</a></code></p> 106<p class="firstline">Sandbox only. Retrieves an order template that can be used to quickly create a new order in sandbox.</p> 107<p class="toc_element"> 108 <code><a href="#instorerefundlineitem">instorerefundlineitem(merchantId, orderId, body)</a></code></p> 109<p class="firstline">Notifies that item return and refund was handled directly by merchant outside of Google payments processing (e.g. cash refund done in store).</p> 110<p class="toc_element"> 111 <code><a href="#list">list(merchantId, orderBy=None, pageToken=None, placedDateEnd=None, acknowledged=None, maxResults=None, placedDateStart=None, statuses=None)</a></code></p> 112<p class="firstline">Lists the orders in your Merchant Center account.</p> 113<p class="toc_element"> 114 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> 115<p class="firstline">Retrieves the next page of results.</p> 116<p class="toc_element"> 117 <code><a href="#rejectreturnlineitem">rejectreturnlineitem(merchantId, orderId, body)</a></code></p> 118<p class="firstline">Rejects return on an line item.</p> 119<p class="toc_element"> 120 <code><a href="#returnrefundlineitem">returnrefundlineitem(merchantId, orderId, body)</a></code></p> 121<p class="firstline">Returns and refunds a line item. Note that this method can only be called on fully shipped orders.</p> 122<p class="toc_element"> 123 <code><a href="#setlineitemmetadata">setlineitemmetadata(merchantId, orderId, body)</a></code></p> 124<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> 125<p class="toc_element"> 126 <code><a href="#shiplineitems">shiplineitems(merchantId, orderId, body)</a></code></p> 127<p class="firstline">Marks line item(s) as shipped.</p> 128<p class="toc_element"> 129 <code><a href="#updatelineitemshippingdetails">updatelineitemshippingdetails(merchantId, orderId, body)</a></code></p> 130<p class="firstline">Updates ship by and delivery by dates for a line item.</p> 131<p class="toc_element"> 132 <code><a href="#updatemerchantorderid">updatemerchantorderid(merchantId, orderId, body)</a></code></p> 133<p class="firstline">Updates the merchant order ID for a given order.</p> 134<p class="toc_element"> 135 <code><a href="#updateshipment">updateshipment(merchantId, orderId, body)</a></code></p> 136<p class="firstline">Updates a shipment's status, carrier, and/or tracking ID.</p> 137<h3>Method Details</h3> 138<div class="method"> 139 <code class="details" id="acknowledge">acknowledge(merchantId, orderId, body)</code> 140 <pre>Marks an order as acknowledged. 141 142Args: 143 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 144 orderId: string, The ID of the order. (required) 145 body: object, The request body. (required) 146 The object takes the form of: 147 148{ 149 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 150 } 151 152 153Returns: 154 An object of the form: 155 156 { 157 "kind": "content#ordersAcknowledgeResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersAcknowledgeResponse". 158 "executionStatus": "A String", # The status of the execution. 159 }</pre> 160</div> 161 162<div class="method"> 163 <code class="details" id="advancetestorder">advancetestorder(merchantId, orderId)</code> 164 <pre>Sandbox only. Moves a test order from state "inProgress" to state "pendingShipment". 165 166Args: 167 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 168 orderId: string, The ID of the test order to modify. (required) 169 170Returns: 171 An object of the form: 172 173 { 174 "kind": "content#ordersAdvanceTestOrderResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersAdvanceTestOrderResponse". 175 }</pre> 176</div> 177 178<div class="method"> 179 <code class="details" id="cancel">cancel(merchantId, orderId, body)</code> 180 <pre>Cancels all line items in an order, making a full refund. 181 182Args: 183 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 184 orderId: string, The ID of the order to cancel. (required) 185 body: object, The request body. (required) 186 The object takes the form of: 187 188{ 189 "reason": "A String", # The reason for the cancellation. 190 "reasonText": "A String", # The explanation of the reason. 191 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 192 } 193 194 195Returns: 196 An object of the form: 197 198 { 199 "kind": "content#ordersCancelResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersCancelResponse". 200 "executionStatus": "A String", # The status of the execution. 201 }</pre> 202</div> 203 204<div class="method"> 205 <code class="details" id="cancellineitem">cancellineitem(merchantId, orderId, body)</code> 206 <pre>Cancels a line item, making a full refund. 207 208Args: 209 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 210 orderId: string, The ID of the order. (required) 211 body: object, The request body. (required) 212 The object takes the form of: 213 214{ 215 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 216 "reason": "A String", # The reason for the cancellation. 217 "reasonText": "A String", # The explanation of the reason. 218 "lineItemId": "A String", # The ID of the line item to cancel. Either lineItemId or productId is required. 219 "productId": "A String", # The ID of the product to cancel. This is the REST ID used in the products service. Either lineItemId or productId is required. 220 "quantity": 42, # The quantity to cancel. 221 } 222 223 224Returns: 225 An object of the form: 226 227 { 228 "kind": "content#ordersCancelLineItemResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersCancelLineItemResponse". 229 "executionStatus": "A String", # The status of the execution. 230 }</pre> 231</div> 232 233<div class="method"> 234 <code class="details" id="canceltestorderbycustomer">canceltestorderbycustomer(merchantId, orderId, body)</code> 235 <pre>Sandbox only. Cancels a test order for customer-initiated cancellation. 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 test order to cancel. (required) 240 body: object, The request body. (required) 241 The object takes the form of: 242 243{ 244 "reason": "A String", # The reason for the cancellation. 245 } 246 247 248Returns: 249 An object of the form: 250 251 { 252 "kind": "content#ordersCancelTestOrderByCustomerResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersCancelTestOrderByCustomerResponse". 253 }</pre> 254</div> 255 256<div class="method"> 257 <code class="details" id="createtestorder">createtestorder(merchantId, body)</code> 258 <pre>Sandbox only. Creates a test order. 259 260Args: 261 merchantId: string, The ID of the account that should manage the order. This cannot be a multi-client account. (required) 262 body: object, The request body. (required) 263 The object takes the form of: 264 265{ 266 "country": "A String", # 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. 267 # 268 # Acceptable values are: 269 # - "US" 270 # - "FR" Defaults to US. 271 "testOrder": { # The test order to create. 272 "promotions": [ # Promotions associated with the order. 273 { 274 "shortTitle": "A String", # A short title of the promotion to be shown on the checkout page. 275 "title": "A String", # The title of the promotion. 276 "priceValue": { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order. 277 "currency": "A String", # The currency of the price. 278 "value": "A String", # The price represented as a number. 279 }, 280 "taxValue": { # Estimated discount applied to tax (if allowed by law). 281 "currency": "A String", # The currency of the price. 282 "value": "A String", # The price represented as a number. 283 }, 284 "merchantPromotionId": "A String", # This field is used to identify promotions within merchants' own systems. 285 "subtype": "A String", # The category of the promotion. 286 "appliedItems": [ # Items which this promotion have been applied to. 287 { 288 "quantity": 42, # The quantity of the associated product. 289 "lineItemId": "A String", 290 "productId": "A String", 291 }, 292 ], 293 "applicableItems": [ # Items which this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. 294 { 295 "quantity": 42, # The quantity of the associated product. 296 "lineItemId": "A String", 297 "productId": "A String", 298 }, 299 ], 300 "type": "A String", # The scope of the promotion. 301 "funder": "A String", # The party funding the promotion. 302 }, 303 ], 304 "predefinedEmail": "A String", # Email address of the customer. 305 "kind": "content#testOrder", # Identifies what kind of resource this is. Value: the fixed string "content#testOrder". 306 "notificationMode": "A String", # Determines if test order must be pulled by merchant or pushed to merchant via push integration. 307 "predefinedDeliveryAddress": "A String", # Identifier of one of the predefined delivery addresses for the delivery. 308 "shippingCost": { # The price of shipping for all items. Shipping tax is automatically calculated for MFL orders. For non-MFL orders, tax settings from Merchant Center are applied. Note that shipping is not taxed in certain states. 309 "currency": "A String", # The currency of the price. 310 "value": "A String", # The price represented as a number. 311 }, 312 "shippingOption": "A String", # The requested shipping option. 313 "enableOrderinvoices": True or False, # Whether the orderinvoices service should support this order. 314 "lineItems": [ # Line items that are ordered. At least one line item must be provided. 315 { 316 "returnInfo": { # Details of the return policy for the line item. 317 "policyUrl": "A String", # URL of the item return policy. 318 "isReturnable": True or False, # Whether the item is returnable. 319 "daysToReturn": 42, # How many days later the item can be returned. 320 }, 321 "product": { # Product data from the time of the order placement. 322 "targetCountry": "A String", # The CLDR territory code of the target country of the product. 323 "contentLanguage": "A String", # The two-letter ISO 639-1 language code for the item. 324 "title": "A String", # The title of the product. 325 "mpn": "A String", # Manufacturer Part Number (MPN) of the item. Optional. 326 "variantAttributes": [ # Variant attributes for the item. Optional. 327 { 328 "dimension": "A String", # The dimension of the variant. 329 "value": "A String", # The value for the dimension. 330 }, 331 ], 332 "brand": "A String", # Brand of the item. 333 "itemGroupId": "A String", # Shared identifier for all variants of the same product. Optional. 334 "offerId": "A String", # An identifier of the item. 335 "imageLink": "A String", # URL of an image of the item. 336 "gtin": "A String", # Global Trade Item Number (GTIN) of the item. Optional. 337 "fees": [ # Fees for the item. Optional. 338 { 339 "amount": { # Amount of the fee. 340 "currency": "A String", # The currency of the price. 341 "value": "A String", # The price represented as a number. 342 }, 343 "name": "A String", # Name of the fee. 344 }, 345 ], 346 "price": { # The price for the product. Tax is automatically calculated for MFL orders. For non-MFL orders, tax settings from Merchant Center are applied. 347 "currency": "A String", # The currency of the price. 348 "value": "A String", # The price represented as a number. 349 }, 350 "condition": "A String", # Condition or state of the item. 351 }, 352 "quantityOrdered": 42, # Number of items ordered. 353 "shippingDetails": { # Details of the requested shipping for the line item. 354 "deliverByDate": "A String", # The delivery by date, in ISO 8601 format. 355 "method": { # Details of the shipping method. 356 "minDaysInTransit": 42, # Minimum transit time. 357 "carrier": "A String", # The carrier for the shipping. Optional. See shipments[].carrier for a list of acceptable values. 358 "methodName": "A String", # The name of the shipping method. 359 "maxDaysInTransit": 42, # Maximum transit time. 360 }, 361 "shipByDate": "A String", # The ship by date, in ISO 8601 format. 362 }, 363 }, 364 ], 365 "predefinedBillingAddress": "A String", # The billing address. 366 }, 367 "templateName": "A String", # 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. 368 } 369 370 371Returns: 372 An object of the form: 373 374 { 375 "orderId": "A String", # The ID of the newly created test order. 376 "kind": "content#ordersCreateTestOrderResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersCreateTestOrderResponse". 377 }</pre> 378</div> 379 380<div class="method"> 381 <code class="details" id="createtestreturn">createtestreturn(merchantId, orderId, body)</code> 382 <pre>Sandbox only. Creates a test return. 383 384Args: 385 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 386 orderId: string, The ID of the order. (required) 387 body: object, The request body. (required) 388 The object takes the form of: 389 390{ 391 "items": [ # Returned items. 392 { 393 "lineItemId": "A String", # The ID of the line item to return. 394 "quantity": 42, # Quantity that is returned. 395 }, 396 ], 397 } 398 399 400Returns: 401 An object of the form: 402 403 { 404 "returnId": "A String", # The ID of the newly created test order return. 405 "kind": "content#ordersCreateTestReturnResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersCreateTestReturnResponse". 406 }</pre> 407</div> 408 409<div class="method"> 410 <code class="details" id="get">get(merchantId, orderId)</code> 411 <pre>Retrieves an order from your Merchant Center account. 412 413Args: 414 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 415 orderId: string, The ID of the order. (required) 416 417Returns: 418 An object of the form: 419 420 { # Order. All methods require the order manager role. 421 "customer": { # The details of the customer who placed the order. 422 "fullName": "A String", # Full name of the customer. 423 "marketingRightsInfo": { # Customer'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. 424 "explicitMarketingPreference": "A String", # 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. 425 "lastUpdatedTimestamp": "A String", # Timestamp when last time marketing preference was updated. Could be empty, if user wasn't offered a selection yet. 426 "marketingEmailAddress": "A String", # Email address that can be used for marketing purposes. The field may be empty even if explicitMarketingPreference is 'granted'. This happens when retrieving an old order from the customer who deleted their account. 427 }, 428 }, 429 "promotions": [ # Promotions associated with the order. 430 { 431 "shortTitle": "A String", # A short title of the promotion to be shown on the checkout page. 432 "title": "A String", # The title of the promotion. 433 "priceValue": { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order. 434 "currency": "A String", # The currency of the price. 435 "value": "A String", # The price represented as a number. 436 }, 437 "taxValue": { # Estimated discount applied to tax (if allowed by law). 438 "currency": "A String", # The currency of the price. 439 "value": "A String", # The price represented as a number. 440 }, 441 "merchantPromotionId": "A String", # This field is used to identify promotions within merchants' own systems. 442 "subtype": "A String", # The category of the promotion. 443 "appliedItems": [ # Items which this promotion have been applied to. 444 { 445 "quantity": 42, # The quantity of the associated product. 446 "lineItemId": "A String", 447 "productId": "A String", 448 }, 449 ], 450 "applicableItems": [ # Items which this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. 451 { 452 "quantity": 42, # The quantity of the associated product. 453 "lineItemId": "A String", 454 "productId": "A String", 455 }, 456 ], 457 "type": "A String", # The scope of the promotion. 458 "funder": "A String", # The party funding the promotion. 459 }, 460 ], 461 "kind": "content#order", # Identifies what kind of resource this is. Value: the fixed string "content#order". 462 "shippingCostTax": { # The tax for the total shipping cost. 463 "currency": "A String", # The currency of the price. 464 "value": "A String", # The price represented as a number. 465 }, 466 "shipments": [ # Shipments of the order. 467 { 468 "status": "A String", # The status of the shipment. 469 "creationDate": "A String", # Date on which the shipment has been created, in ISO 8601 format. 470 "carrier": "A String", # The carrier handling the shipment. 471 # 472 # Acceptable values for US are: 473 # - "gsx" 474 # - "ups" 475 # - "usps" 476 # - "fedex" 477 # - "dhl" 478 # - "ecourier" 479 # - "cxt" 480 # - "google" 481 # - "ontrac" 482 # - "emsy" 483 # - "ont" 484 # - "deliv" 485 # - "dynamex" 486 # - "lasership" 487 # - "mpx" 488 # - "uds" 489 # - "efw" 490 # 491 # Acceptable values for FR are: 492 # - "colissimo" 493 # - "chronopost" 494 # - "gls" 495 # - "dpd" 496 # - "bpost" 497 "trackingId": "A String", # The tracking ID for the shipment. 498 "deliveryDate": "A String", # Date on which the shipment has been delivered, in ISO 8601 format. Present only if status is delivered 499 "lineItems": [ # The line items that are shipped. 500 { 501 "quantity": 42, # The quantity that is shipped. 502 "lineItemId": "A String", # The ID of the line item that is shipped. Either lineItemId or productId is required. 503 "productId": "A String", # The ID of the product to ship. This is the REST ID used in the products service. Either lineItemId or productId is required. 504 }, 505 ], 506 "id": "A String", # The ID of the shipment. 507 }, 508 ], 509 "refunds": [ # Refunds for the order. 510 { 511 "amount": { # The amount that is refunded. 512 "currency": "A String", # The currency of the price. 513 "value": "A String", # The price represented as a number. 514 }, 515 "creationDate": "A String", # Date on which the item has been created, in ISO 8601 format. 516 "reason": "A String", # The reason for the refund. 517 "actor": "A String", # The actor that created the refund. 518 "reasonText": "A String", # The explanation of the reason. 519 }, 520 ], 521 "taxCollector": "A String", # The party responsible for collecting and remitting taxes. 522 "acknowledged": True or False, # Whether the order was acknowledged. 523 "paymentStatus": "A String", # The status of the payment. 524 "merchantId": "A String", 525 "merchantOrderId": "A String", # Merchant-provided ID of the order. 526 "status": "A String", # The status of the order. 527 "netTaxAmount": { # 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. 528 "currency": "A String", # The currency of the price. 529 "value": "A String", # The price represented as a number. 530 }, 531 "billingAddress": { # The billing address. 532 "locality": "A String", # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs). 533 "country": "A String", # CLDR country code (e.g. "US"). 534 "fullAddress": [ # Strings representing the lines of the printed label for mailing the order, for example: 535 # John Smith 536 # 1600 Amphitheatre Parkway 537 # Mountain View, CA, 94043 538 # United States 539 "A String", 540 ], 541 "streetAddress": [ # Street-level part of the address. 542 "A String", 543 ], 544 "postalCode": "A String", # Postal Code or ZIP (e.g. "94043"). 545 "recipientName": "A String", # Name of the recipient. 546 "isPostOfficeBox": True or False, # Whether the address is a post office box. 547 "region": "A String", # Top-level administrative subdivision of the country. For example, a state like California ("CA") or a province like Quebec ("QC"). 548 }, 549 "netPriceAmount": { # 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. 550 "currency": "A String", # The currency of the price. 551 "value": "A String", # The price represented as a number. 552 }, 553 "placedDate": "A String", # The date when the order was placed, in ISO 8601 format. 554 "lineItems": [ # Line items that are ordered. 555 { 556 "product": { # 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. 557 "targetCountry": "A String", # The CLDR territory code of the target country of the product. 558 "shownImage": "A String", # URL to the cached image shown to the user when order was placed. 559 "contentLanguage": "A String", # The two-letter ISO 639-1 language code for the item. 560 "title": "A String", # The title of the product. 561 "mpn": "A String", # Manufacturer Part Number (MPN) of the item. 562 "variantAttributes": [ # 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. 563 { 564 "dimension": "A String", # The dimension of the variant. 565 "value": "A String", # The value for the dimension. 566 }, 567 ], 568 "brand": "A String", # Brand of the item. 569 "itemGroupId": "A String", # Shared identifier for all variants of the same product. 570 "offerId": "A String", # An identifier of the item. 571 "price": { # Price of the item. 572 "currency": "A String", # The currency of the price. 573 "value": "A String", # The price represented as a number. 574 }, 575 "imageLink": "A String", # URL of an image of the item. 576 "gtin": "A String", # Global Trade Item Number (GTIN) of the item. 577 "fees": [ # Associated fees at order creation time. 578 { 579 "amount": { # Amount of the fee. 580 "currency": "A String", # The currency of the price. 581 "value": "A String", # The price represented as a number. 582 }, 583 "name": "A String", # Name of the fee. 584 }, 585 ], 586 "id": "A String", # The REST ID of the product. 587 "condition": "A String", # Condition or state of the item. 588 }, 589 "quantityPending": 42, # Number of items pending. 590 "quantityDelivered": 42, # Number of items delivered. 591 "returnInfo": { # Details of the return policy for the line item. 592 "policyUrl": "A String", # URL of the item return policy. 593 "isReturnable": True or False, # Whether the item is returnable. 594 "daysToReturn": 42, # How many days later the item can be returned. 595 }, 596 "quantityOrdered": 42, # Number of items ordered. 597 "price": { # Total price for the line item. For example, if two items for $10 are purchased, the total price will be $20. 598 "currency": "A String", # The currency of the price. 599 "value": "A String", # The price represented as a number. 600 }, 601 "adjustments": [ # Price and tax adjustments applied on the line item. 602 { 603 "type": "A String", # Type of this adjustment. 604 "priceAdjustment": { # Adjustment for total price of the line item. 605 "currency": "A String", # The currency of the price. 606 "value": "A String", # The price represented as a number. 607 }, 608 "taxAdjustment": { # Adjustment for total tax of the line item. 609 "currency": "A String", # The currency of the price. 610 "value": "A String", # The price represented as a number. 611 }, 612 }, 613 ], 614 "tax": { # 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. 615 "currency": "A String", # The currency of the price. 616 "value": "A String", # The price represented as a number. 617 }, 618 "cancellations": [ # Cancellations of the line item. 619 { 620 "reason": "A String", # The reason for the cancellation. Orders that are cancelled 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. 621 "creationDate": "A String", # Date on which the cancellation has been created, in ISO 8601 format. 622 "reasonText": "A String", # The explanation of the reason. 623 "actor": "A String", # The actor that created the cancellation. 624 "quantity": 42, # The quantity that was canceled. 625 }, 626 ], 627 "quantityCanceled": 42, # Number of items canceled. 628 "annotations": [ # Annotations that are attached to the line item. 629 { 630 "value": "A String", # Value for additional merchant provided (as key-value pairs) annotation about the line item. 631 "key": "A String", # Key for additional merchant provided (as key-value pairs) annotation about the line item. 632 }, 633 ], 634 "returns": [ # Returns of the line item. 635 { 636 "reason": "A String", # The reason for the return. 637 "creationDate": "A String", # Date on which the item has been created, in ISO 8601 format. 638 "reasonText": "A String", # The explanation of the reason. 639 "actor": "A String", # The actor that created the refund. 640 "quantity": 42, # Quantity that is returned. 641 }, 642 ], 643 "quantityShipped": 42, # Number of items shipped. 644 "quantityReturned": 42, # Number of items returned. 645 "id": "A String", # The ID of the line item. 646 "shippingDetails": { # Details of the requested shipping for the line item. 647 "deliverByDate": "A String", # The delivery by date, in ISO 8601 format. 648 "method": { # Details of the shipping method. 649 "minDaysInTransit": 42, # Minimum transit time. 650 "carrier": "A String", # The carrier for the shipping. Optional. See shipments[].carrier for a list of acceptable values. 651 "methodName": "A String", # The name of the shipping method. 652 "maxDaysInTransit": 42, # Maximum transit time. 653 }, 654 "shipByDate": "A String", # The ship by date, in ISO 8601 format. 655 }, 656 }, 657 ], 658 "shippingCost": { # The total cost of shipping for all items. 659 "currency": "A String", # The currency of the price. 660 "value": "A String", # The price represented as a number. 661 }, 662 "id": "A String", # The REST ID of the order. Globally unique. 663 "deliveryDetails": { # Delivery details for shipments. 664 "phoneNumber": "A String", # The phone number of the person receiving the delivery. 665 "address": { # The delivery address 666 "locality": "A String", # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs). 667 "country": "A String", # CLDR country code (e.g. "US"). 668 "fullAddress": [ # Strings representing the lines of the printed label for mailing the order, for example: 669 # John Smith 670 # 1600 Amphitheatre Parkway 671 # Mountain View, CA, 94043 672 # United States 673 "A String", 674 ], 675 "streetAddress": [ # Street-level part of the address. 676 "A String", 677 ], 678 "postalCode": "A String", # Postal Code or ZIP (e.g. "94043"). 679 "recipientName": "A String", # Name of the recipient. 680 "isPostOfficeBox": True or False, # Whether the address is a post office box. 681 "region": "A String", # Top-level administrative subdivision of the country. For example, a state like California ("CA") or a province like Quebec ("QC"). 682 }, 683 }, 684 }</pre> 685</div> 686 687<div class="method"> 688 <code class="details" id="getbymerchantorderid">getbymerchantorderid(merchantId, merchantOrderId)</code> 689 <pre>Retrieves an order using merchant order ID. 690 691Args: 692 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 693 merchantOrderId: string, The merchant order ID to be looked for. (required) 694 695Returns: 696 An object of the form: 697 698 { 699 "kind": "content#ordersGetByMerchantOrderIdResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersGetByMerchantOrderIdResponse". 700 "order": { # Order. All methods require the order manager role. # The requested order. 701 "customer": { # The details of the customer who placed the order. 702 "fullName": "A String", # Full name of the customer. 703 "marketingRightsInfo": { # Customer'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. 704 "explicitMarketingPreference": "A String", # 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. 705 "lastUpdatedTimestamp": "A String", # Timestamp when last time marketing preference was updated. Could be empty, if user wasn't offered a selection yet. 706 "marketingEmailAddress": "A String", # Email address that can be used for marketing purposes. The field may be empty even if explicitMarketingPreference is 'granted'. This happens when retrieving an old order from the customer who deleted their account. 707 }, 708 }, 709 "promotions": [ # Promotions associated with the order. 710 { 711 "shortTitle": "A String", # A short title of the promotion to be shown on the checkout page. 712 "title": "A String", # The title of the promotion. 713 "priceValue": { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order. 714 "currency": "A String", # The currency of the price. 715 "value": "A String", # The price represented as a number. 716 }, 717 "taxValue": { # Estimated discount applied to tax (if allowed by law). 718 "currency": "A String", # The currency of the price. 719 "value": "A String", # The price represented as a number. 720 }, 721 "merchantPromotionId": "A String", # This field is used to identify promotions within merchants' own systems. 722 "subtype": "A String", # The category of the promotion. 723 "appliedItems": [ # Items which this promotion have been applied to. 724 { 725 "quantity": 42, # The quantity of the associated product. 726 "lineItemId": "A String", 727 "productId": "A String", 728 }, 729 ], 730 "applicableItems": [ # Items which this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. 731 { 732 "quantity": 42, # The quantity of the associated product. 733 "lineItemId": "A String", 734 "productId": "A String", 735 }, 736 ], 737 "type": "A String", # The scope of the promotion. 738 "funder": "A String", # The party funding the promotion. 739 }, 740 ], 741 "kind": "content#order", # Identifies what kind of resource this is. Value: the fixed string "content#order". 742 "shippingCostTax": { # The tax for the total shipping cost. 743 "currency": "A String", # The currency of the price. 744 "value": "A String", # The price represented as a number. 745 }, 746 "shipments": [ # Shipments of the order. 747 { 748 "status": "A String", # The status of the shipment. 749 "creationDate": "A String", # Date on which the shipment has been created, in ISO 8601 format. 750 "carrier": "A String", # The carrier handling the shipment. 751 # 752 # Acceptable values for US are: 753 # - "gsx" 754 # - "ups" 755 # - "usps" 756 # - "fedex" 757 # - "dhl" 758 # - "ecourier" 759 # - "cxt" 760 # - "google" 761 # - "ontrac" 762 # - "emsy" 763 # - "ont" 764 # - "deliv" 765 # - "dynamex" 766 # - "lasership" 767 # - "mpx" 768 # - "uds" 769 # - "efw" 770 # 771 # Acceptable values for FR are: 772 # - "colissimo" 773 # - "chronopost" 774 # - "gls" 775 # - "dpd" 776 # - "bpost" 777 "trackingId": "A String", # The tracking ID for the shipment. 778 "deliveryDate": "A String", # Date on which the shipment has been delivered, in ISO 8601 format. Present only if status is delivered 779 "lineItems": [ # The line items that are shipped. 780 { 781 "quantity": 42, # The quantity that is shipped. 782 "lineItemId": "A String", # The ID of the line item that is shipped. Either lineItemId or productId is required. 783 "productId": "A String", # The ID of the product to ship. This is the REST ID used in the products service. Either lineItemId or productId is required. 784 }, 785 ], 786 "id": "A String", # The ID of the shipment. 787 }, 788 ], 789 "refunds": [ # Refunds for the order. 790 { 791 "amount": { # The amount that is refunded. 792 "currency": "A String", # The currency of the price. 793 "value": "A String", # The price represented as a number. 794 }, 795 "creationDate": "A String", # Date on which the item has been created, in ISO 8601 format. 796 "reason": "A String", # The reason for the refund. 797 "actor": "A String", # The actor that created the refund. 798 "reasonText": "A String", # The explanation of the reason. 799 }, 800 ], 801 "taxCollector": "A String", # The party responsible for collecting and remitting taxes. 802 "acknowledged": True or False, # Whether the order was acknowledged. 803 "paymentStatus": "A String", # The status of the payment. 804 "merchantId": "A String", 805 "merchantOrderId": "A String", # Merchant-provided ID of the order. 806 "status": "A String", # The status of the order. 807 "netTaxAmount": { # 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. 808 "currency": "A String", # The currency of the price. 809 "value": "A String", # The price represented as a number. 810 }, 811 "billingAddress": { # The billing address. 812 "locality": "A String", # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs). 813 "country": "A String", # CLDR country code (e.g. "US"). 814 "fullAddress": [ # Strings representing the lines of the printed label for mailing the order, for example: 815 # John Smith 816 # 1600 Amphitheatre Parkway 817 # Mountain View, CA, 94043 818 # United States 819 "A String", 820 ], 821 "streetAddress": [ # Street-level part of the address. 822 "A String", 823 ], 824 "postalCode": "A String", # Postal Code or ZIP (e.g. "94043"). 825 "recipientName": "A String", # Name of the recipient. 826 "isPostOfficeBox": True or False, # Whether the address is a post office box. 827 "region": "A String", # Top-level administrative subdivision of the country. For example, a state like California ("CA") or a province like Quebec ("QC"). 828 }, 829 "netPriceAmount": { # 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. 830 "currency": "A String", # The currency of the price. 831 "value": "A String", # The price represented as a number. 832 }, 833 "placedDate": "A String", # The date when the order was placed, in ISO 8601 format. 834 "lineItems": [ # Line items that are ordered. 835 { 836 "product": { # 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. 837 "targetCountry": "A String", # The CLDR territory code of the target country of the product. 838 "shownImage": "A String", # URL to the cached image shown to the user when order was placed. 839 "contentLanguage": "A String", # The two-letter ISO 639-1 language code for the item. 840 "title": "A String", # The title of the product. 841 "mpn": "A String", # Manufacturer Part Number (MPN) of the item. 842 "variantAttributes": [ # 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. 843 { 844 "dimension": "A String", # The dimension of the variant. 845 "value": "A String", # The value for the dimension. 846 }, 847 ], 848 "brand": "A String", # Brand of the item. 849 "itemGroupId": "A String", # Shared identifier for all variants of the same product. 850 "offerId": "A String", # An identifier of the item. 851 "price": { # Price of the item. 852 "currency": "A String", # The currency of the price. 853 "value": "A String", # The price represented as a number. 854 }, 855 "imageLink": "A String", # URL of an image of the item. 856 "gtin": "A String", # Global Trade Item Number (GTIN) of the item. 857 "fees": [ # Associated fees at order creation time. 858 { 859 "amount": { # Amount of the fee. 860 "currency": "A String", # The currency of the price. 861 "value": "A String", # The price represented as a number. 862 }, 863 "name": "A String", # Name of the fee. 864 }, 865 ], 866 "id": "A String", # The REST ID of the product. 867 "condition": "A String", # Condition or state of the item. 868 }, 869 "quantityPending": 42, # Number of items pending. 870 "quantityDelivered": 42, # Number of items delivered. 871 "returnInfo": { # Details of the return policy for the line item. 872 "policyUrl": "A String", # URL of the item return policy. 873 "isReturnable": True or False, # Whether the item is returnable. 874 "daysToReturn": 42, # How many days later the item can be returned. 875 }, 876 "quantityOrdered": 42, # Number of items ordered. 877 "price": { # Total price for the line item. For example, if two items for $10 are purchased, the total price will be $20. 878 "currency": "A String", # The currency of the price. 879 "value": "A String", # The price represented as a number. 880 }, 881 "adjustments": [ # Price and tax adjustments applied on the line item. 882 { 883 "type": "A String", # Type of this adjustment. 884 "priceAdjustment": { # Adjustment for total price of the line item. 885 "currency": "A String", # The currency of the price. 886 "value": "A String", # The price represented as a number. 887 }, 888 "taxAdjustment": { # Adjustment for total tax of the line item. 889 "currency": "A String", # The currency of the price. 890 "value": "A String", # The price represented as a number. 891 }, 892 }, 893 ], 894 "tax": { # 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. 895 "currency": "A String", # The currency of the price. 896 "value": "A String", # The price represented as a number. 897 }, 898 "cancellations": [ # Cancellations of the line item. 899 { 900 "reason": "A String", # The reason for the cancellation. Orders that are cancelled 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. 901 "creationDate": "A String", # Date on which the cancellation has been created, in ISO 8601 format. 902 "reasonText": "A String", # The explanation of the reason. 903 "actor": "A String", # The actor that created the cancellation. 904 "quantity": 42, # The quantity that was canceled. 905 }, 906 ], 907 "quantityCanceled": 42, # Number of items canceled. 908 "annotations": [ # Annotations that are attached to the line item. 909 { 910 "value": "A String", # Value for additional merchant provided (as key-value pairs) annotation about the line item. 911 "key": "A String", # Key for additional merchant provided (as key-value pairs) annotation about the line item. 912 }, 913 ], 914 "returns": [ # Returns of the line item. 915 { 916 "reason": "A String", # The reason for the return. 917 "creationDate": "A String", # Date on which the item has been created, in ISO 8601 format. 918 "reasonText": "A String", # The explanation of the reason. 919 "actor": "A String", # The actor that created the refund. 920 "quantity": 42, # Quantity that is returned. 921 }, 922 ], 923 "quantityShipped": 42, # Number of items shipped. 924 "quantityReturned": 42, # Number of items returned. 925 "id": "A String", # The ID of the line item. 926 "shippingDetails": { # Details of the requested shipping for the line item. 927 "deliverByDate": "A String", # The delivery by date, in ISO 8601 format. 928 "method": { # Details of the shipping method. 929 "minDaysInTransit": 42, # Minimum transit time. 930 "carrier": "A String", # The carrier for the shipping. Optional. See shipments[].carrier for a list of acceptable values. 931 "methodName": "A String", # The name of the shipping method. 932 "maxDaysInTransit": 42, # Maximum transit time. 933 }, 934 "shipByDate": "A String", # The ship by date, in ISO 8601 format. 935 }, 936 }, 937 ], 938 "shippingCost": { # The total cost of shipping for all items. 939 "currency": "A String", # The currency of the price. 940 "value": "A String", # The price represented as a number. 941 }, 942 "id": "A String", # The REST ID of the order. Globally unique. 943 "deliveryDetails": { # Delivery details for shipments. 944 "phoneNumber": "A String", # The phone number of the person receiving the delivery. 945 "address": { # The delivery address 946 "locality": "A String", # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs). 947 "country": "A String", # CLDR country code (e.g. "US"). 948 "fullAddress": [ # Strings representing the lines of the printed label for mailing the order, for example: 949 # John Smith 950 # 1600 Amphitheatre Parkway 951 # Mountain View, CA, 94043 952 # United States 953 "A String", 954 ], 955 "streetAddress": [ # Street-level part of the address. 956 "A String", 957 ], 958 "postalCode": "A String", # Postal Code or ZIP (e.g. "94043"). 959 "recipientName": "A String", # Name of the recipient. 960 "isPostOfficeBox": True or False, # Whether the address is a post office box. 961 "region": "A String", # Top-level administrative subdivision of the country. For example, a state like California ("CA") or a province like Quebec ("QC"). 962 }, 963 }, 964 }, 965 }</pre> 966</div> 967 968<div class="method"> 969 <code class="details" id="gettestordertemplate">gettestordertemplate(merchantId, templateName, country=None)</code> 970 <pre>Sandbox only. Retrieves an order template that can be used to quickly create a new order in sandbox. 971 972Args: 973 merchantId: string, The ID of the account that should manage the order. This cannot be a multi-client account. (required) 974 templateName: string, The name of the template to retrieve. (required) 975 Allowed values 976 template1 - 977 template1a - 978 template1b - 979 template2 - 980 country: string, The country of the template to retrieve. Defaults to US. 981 982Returns: 983 An object of the form: 984 985 { 986 "kind": "content#ordersGetTestOrderTemplateResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersGetTestOrderTemplateResponse". 987 "template": { # The requested test order template. 988 "promotions": [ # Promotions associated with the order. 989 { 990 "shortTitle": "A String", # A short title of the promotion to be shown on the checkout page. 991 "title": "A String", # The title of the promotion. 992 "priceValue": { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order. 993 "currency": "A String", # The currency of the price. 994 "value": "A String", # The price represented as a number. 995 }, 996 "taxValue": { # Estimated discount applied to tax (if allowed by law). 997 "currency": "A String", # The currency of the price. 998 "value": "A String", # The price represented as a number. 999 }, 1000 "merchantPromotionId": "A String", # This field is used to identify promotions within merchants' own systems. 1001 "subtype": "A String", # The category of the promotion. 1002 "appliedItems": [ # Items which this promotion have been applied to. 1003 { 1004 "quantity": 42, # The quantity of the associated product. 1005 "lineItemId": "A String", 1006 "productId": "A String", 1007 }, 1008 ], 1009 "applicableItems": [ # Items which this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. 1010 { 1011 "quantity": 42, # The quantity of the associated product. 1012 "lineItemId": "A String", 1013 "productId": "A String", 1014 }, 1015 ], 1016 "type": "A String", # The scope of the promotion. 1017 "funder": "A String", # The party funding the promotion. 1018 }, 1019 ], 1020 "predefinedEmail": "A String", # Email address of the customer. 1021 "kind": "content#testOrder", # Identifies what kind of resource this is. Value: the fixed string "content#testOrder". 1022 "notificationMode": "A String", # Determines if test order must be pulled by merchant or pushed to merchant via push integration. 1023 "predefinedDeliveryAddress": "A String", # Identifier of one of the predefined delivery addresses for the delivery. 1024 "shippingCost": { # The price of shipping for all items. Shipping tax is automatically calculated for MFL orders. For non-MFL orders, tax settings from Merchant Center are applied. Note that shipping is not taxed in certain states. 1025 "currency": "A String", # The currency of the price. 1026 "value": "A String", # The price represented as a number. 1027 }, 1028 "shippingOption": "A String", # The requested shipping option. 1029 "enableOrderinvoices": True or False, # Whether the orderinvoices service should support this order. 1030 "lineItems": [ # Line items that are ordered. At least one line item must be provided. 1031 { 1032 "returnInfo": { # Details of the return policy for the line item. 1033 "policyUrl": "A String", # URL of the item return policy. 1034 "isReturnable": True or False, # Whether the item is returnable. 1035 "daysToReturn": 42, # How many days later the item can be returned. 1036 }, 1037 "product": { # Product data from the time of the order placement. 1038 "targetCountry": "A String", # The CLDR territory code of the target country of the product. 1039 "contentLanguage": "A String", # The two-letter ISO 639-1 language code for the item. 1040 "title": "A String", # The title of the product. 1041 "mpn": "A String", # Manufacturer Part Number (MPN) of the item. Optional. 1042 "variantAttributes": [ # Variant attributes for the item. Optional. 1043 { 1044 "dimension": "A String", # The dimension of the variant. 1045 "value": "A String", # The value for the dimension. 1046 }, 1047 ], 1048 "brand": "A String", # Brand of the item. 1049 "itemGroupId": "A String", # Shared identifier for all variants of the same product. Optional. 1050 "offerId": "A String", # An identifier of the item. 1051 "imageLink": "A String", # URL of an image of the item. 1052 "gtin": "A String", # Global Trade Item Number (GTIN) of the item. Optional. 1053 "fees": [ # Fees for the item. Optional. 1054 { 1055 "amount": { # Amount of the fee. 1056 "currency": "A String", # The currency of the price. 1057 "value": "A String", # The price represented as a number. 1058 }, 1059 "name": "A String", # Name of the fee. 1060 }, 1061 ], 1062 "price": { # The price for the product. Tax is automatically calculated for MFL orders. For non-MFL orders, tax settings from Merchant Center are applied. 1063 "currency": "A String", # The currency of the price. 1064 "value": "A String", # The price represented as a number. 1065 }, 1066 "condition": "A String", # Condition or state of the item. 1067 }, 1068 "quantityOrdered": 42, # Number of items ordered. 1069 "shippingDetails": { # Details of the requested shipping for the line item. 1070 "deliverByDate": "A String", # The delivery by date, in ISO 8601 format. 1071 "method": { # Details of the shipping method. 1072 "minDaysInTransit": 42, # Minimum transit time. 1073 "carrier": "A String", # The carrier for the shipping. Optional. See shipments[].carrier for a list of acceptable values. 1074 "methodName": "A String", # The name of the shipping method. 1075 "maxDaysInTransit": 42, # Maximum transit time. 1076 }, 1077 "shipByDate": "A String", # The ship by date, in ISO 8601 format. 1078 }, 1079 }, 1080 ], 1081 "predefinedBillingAddress": "A String", # The billing address. 1082 }, 1083 }</pre> 1084</div> 1085 1086<div class="method"> 1087 <code class="details" id="instorerefundlineitem">instorerefundlineitem(merchantId, orderId, body)</code> 1088 <pre>Notifies that item return and refund was handled directly by merchant outside of Google payments processing (e.g. cash refund done in store). 1089Note: 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. 1090 1091Args: 1092 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 1093 orderId: string, The ID of the order. (required) 1094 body: object, The request body. (required) 1095 The object takes the form of: 1096 1097{ 1098 "priceAmount": { # The amount to be refunded. This may be pre-tax or post-tax depending on the location of the order. Required. 1099 "currency": "A String", # The currency of the price. 1100 "value": "A String", # The price represented as a number. 1101 }, 1102 "taxAmount": { # The amount of tax to be refunded. Required. 1103 "currency": "A String", # The currency of the price. 1104 "value": "A String", # The price represented as a number. 1105 }, 1106 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 1107 "reason": "A String", # The reason for the return. 1108 "reasonText": "A String", # The explanation of the reason. 1109 "lineItemId": "A String", # The ID of the line item to return. Either lineItemId or productId is required. 1110 "quantity": 42, # The quantity to return and refund. 1111 "productId": "A String", # The ID of the product to return. This is the REST ID used in the products service. Either lineItemId or productId is required. 1112 } 1113 1114 1115Returns: 1116 An object of the form: 1117 1118 { 1119 "kind": "content#ordersInStoreRefundLineItemResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersInStoreRefundLineItemResponse". 1120 "executionStatus": "A String", # The status of the execution. 1121 }</pre> 1122</div> 1123 1124<div class="method"> 1125 <code class="details" id="list">list(merchantId, orderBy=None, pageToken=None, placedDateEnd=None, acknowledged=None, maxResults=None, placedDateStart=None, statuses=None)</code> 1126 <pre>Lists the orders in your Merchant Center account. 1127 1128Args: 1129 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 1130 orderBy: string, Order results by placement date in descending or ascending order. 1131 1132Acceptable values are: 1133- placedDateAsc 1134- placedDateDesc 1135 pageToken: string, The token returned by the previous request. 1136 placedDateEnd: string, Obtains orders placed before this date (exclusively), in ISO 8601 format. 1137 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. 1138We recommend using this filter set to false, in conjunction with the acknowledge call, such that only un-acknowledged orders are returned. 1139 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. 1140 placedDateStart: string, Obtains orders placed after this date (inclusively), in ISO 8601 format. 1141 statuses: string, Obtains orders that match any of the specified statuses. Multiple values can be specified with comma separation. Additionally, 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) 1142 Allowed values 1143 active - 1144 canceled - 1145 completed - 1146 delivered - 1147 inProgress - 1148 partiallyDelivered - 1149 partiallyReturned - 1150 partiallyShipped - 1151 pendingShipment - 1152 returned - 1153 shipped - 1154 1155Returns: 1156 An object of the form: 1157 1158 { 1159 "nextPageToken": "A String", # The token for the retrieval of the next page of orders. 1160 "kind": "content#ordersListResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersListResponse". 1161 "resources": [ 1162 { # Order. All methods require the order manager role. 1163 "customer": { # The details of the customer who placed the order. 1164 "fullName": "A String", # Full name of the customer. 1165 "marketingRightsInfo": { # Customer'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. 1166 "explicitMarketingPreference": "A String", # 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. 1167 "lastUpdatedTimestamp": "A String", # Timestamp when last time marketing preference was updated. Could be empty, if user wasn't offered a selection yet. 1168 "marketingEmailAddress": "A String", # Email address that can be used for marketing purposes. The field may be empty even if explicitMarketingPreference is 'granted'. This happens when retrieving an old order from the customer who deleted their account. 1169 }, 1170 }, 1171 "promotions": [ # Promotions associated with the order. 1172 { 1173 "shortTitle": "A String", # A short title of the promotion to be shown on the checkout page. 1174 "title": "A String", # The title of the promotion. 1175 "priceValue": { # Estimated discount applied to price. Amount is pre-tax or post-tax depending on location of order. 1176 "currency": "A String", # The currency of the price. 1177 "value": "A String", # The price represented as a number. 1178 }, 1179 "taxValue": { # Estimated discount applied to tax (if allowed by law). 1180 "currency": "A String", # The currency of the price. 1181 "value": "A String", # The price represented as a number. 1182 }, 1183 "merchantPromotionId": "A String", # This field is used to identify promotions within merchants' own systems. 1184 "subtype": "A String", # The category of the promotion. 1185 "appliedItems": [ # Items which this promotion have been applied to. 1186 { 1187 "quantity": 42, # The quantity of the associated product. 1188 "lineItemId": "A String", 1189 "productId": "A String", 1190 }, 1191 ], 1192 "applicableItems": [ # Items which this promotion may be applied to. If empty, there are no restrictions on applicable items and quantity. 1193 { 1194 "quantity": 42, # The quantity of the associated product. 1195 "lineItemId": "A String", 1196 "productId": "A String", 1197 }, 1198 ], 1199 "type": "A String", # The scope of the promotion. 1200 "funder": "A String", # The party funding the promotion. 1201 }, 1202 ], 1203 "kind": "content#order", # Identifies what kind of resource this is. Value: the fixed string "content#order". 1204 "shippingCostTax": { # The tax for the total shipping cost. 1205 "currency": "A String", # The currency of the price. 1206 "value": "A String", # The price represented as a number. 1207 }, 1208 "shipments": [ # Shipments of the order. 1209 { 1210 "status": "A String", # The status of the shipment. 1211 "creationDate": "A String", # Date on which the shipment has been created, in ISO 8601 format. 1212 "carrier": "A String", # The carrier handling the shipment. 1213 # 1214 # Acceptable values for US are: 1215 # - "gsx" 1216 # - "ups" 1217 # - "usps" 1218 # - "fedex" 1219 # - "dhl" 1220 # - "ecourier" 1221 # - "cxt" 1222 # - "google" 1223 # - "ontrac" 1224 # - "emsy" 1225 # - "ont" 1226 # - "deliv" 1227 # - "dynamex" 1228 # - "lasership" 1229 # - "mpx" 1230 # - "uds" 1231 # - "efw" 1232 # 1233 # Acceptable values for FR are: 1234 # - "colissimo" 1235 # - "chronopost" 1236 # - "gls" 1237 # - "dpd" 1238 # - "bpost" 1239 "trackingId": "A String", # The tracking ID for the shipment. 1240 "deliveryDate": "A String", # Date on which the shipment has been delivered, in ISO 8601 format. Present only if status is delivered 1241 "lineItems": [ # The line items that are shipped. 1242 { 1243 "quantity": 42, # The quantity that is shipped. 1244 "lineItemId": "A String", # The ID of the line item that is shipped. Either lineItemId or productId is required. 1245 "productId": "A String", # The ID of the product to ship. This is the REST ID used in the products service. Either lineItemId or productId is required. 1246 }, 1247 ], 1248 "id": "A String", # The ID of the shipment. 1249 }, 1250 ], 1251 "refunds": [ # Refunds for the order. 1252 { 1253 "amount": { # The amount that is refunded. 1254 "currency": "A String", # The currency of the price. 1255 "value": "A String", # The price represented as a number. 1256 }, 1257 "creationDate": "A String", # Date on which the item has been created, in ISO 8601 format. 1258 "reason": "A String", # The reason for the refund. 1259 "actor": "A String", # The actor that created the refund. 1260 "reasonText": "A String", # The explanation of the reason. 1261 }, 1262 ], 1263 "taxCollector": "A String", # The party responsible for collecting and remitting taxes. 1264 "acknowledged": True or False, # Whether the order was acknowledged. 1265 "paymentStatus": "A String", # The status of the payment. 1266 "merchantId": "A String", 1267 "merchantOrderId": "A String", # Merchant-provided ID of the order. 1268 "status": "A String", # The status of the order. 1269 "netTaxAmount": { # 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. 1270 "currency": "A String", # The currency of the price. 1271 "value": "A String", # The price represented as a number. 1272 }, 1273 "billingAddress": { # The billing address. 1274 "locality": "A String", # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs). 1275 "country": "A String", # CLDR country code (e.g. "US"). 1276 "fullAddress": [ # Strings representing the lines of the printed label for mailing the order, for example: 1277 # John Smith 1278 # 1600 Amphitheatre Parkway 1279 # Mountain View, CA, 94043 1280 # United States 1281 "A String", 1282 ], 1283 "streetAddress": [ # Street-level part of the address. 1284 "A String", 1285 ], 1286 "postalCode": "A String", # Postal Code or ZIP (e.g. "94043"). 1287 "recipientName": "A String", # Name of the recipient. 1288 "isPostOfficeBox": True or False, # Whether the address is a post office box. 1289 "region": "A String", # Top-level administrative subdivision of the country. For example, a state like California ("CA") or a province like Quebec ("QC"). 1290 }, 1291 "netPriceAmount": { # 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. 1292 "currency": "A String", # The currency of the price. 1293 "value": "A String", # The price represented as a number. 1294 }, 1295 "placedDate": "A String", # The date when the order was placed, in ISO 8601 format. 1296 "lineItems": [ # Line items that are ordered. 1297 { 1298 "product": { # 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. 1299 "targetCountry": "A String", # The CLDR territory code of the target country of the product. 1300 "shownImage": "A String", # URL to the cached image shown to the user when order was placed. 1301 "contentLanguage": "A String", # The two-letter ISO 639-1 language code for the item. 1302 "title": "A String", # The title of the product. 1303 "mpn": "A String", # Manufacturer Part Number (MPN) of the item. 1304 "variantAttributes": [ # 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. 1305 { 1306 "dimension": "A String", # The dimension of the variant. 1307 "value": "A String", # The value for the dimension. 1308 }, 1309 ], 1310 "brand": "A String", # Brand of the item. 1311 "itemGroupId": "A String", # Shared identifier for all variants of the same product. 1312 "offerId": "A String", # An identifier of the item. 1313 "price": { # Price of the item. 1314 "currency": "A String", # The currency of the price. 1315 "value": "A String", # The price represented as a number. 1316 }, 1317 "imageLink": "A String", # URL of an image of the item. 1318 "gtin": "A String", # Global Trade Item Number (GTIN) of the item. 1319 "fees": [ # Associated fees at order creation time. 1320 { 1321 "amount": { # Amount of the fee. 1322 "currency": "A String", # The currency of the price. 1323 "value": "A String", # The price represented as a number. 1324 }, 1325 "name": "A String", # Name of the fee. 1326 }, 1327 ], 1328 "id": "A String", # The REST ID of the product. 1329 "condition": "A String", # Condition or state of the item. 1330 }, 1331 "quantityPending": 42, # Number of items pending. 1332 "quantityDelivered": 42, # Number of items delivered. 1333 "returnInfo": { # Details of the return policy for the line item. 1334 "policyUrl": "A String", # URL of the item return policy. 1335 "isReturnable": True or False, # Whether the item is returnable. 1336 "daysToReturn": 42, # How many days later the item can be returned. 1337 }, 1338 "quantityOrdered": 42, # Number of items ordered. 1339 "price": { # Total price for the line item. For example, if two items for $10 are purchased, the total price will be $20. 1340 "currency": "A String", # The currency of the price. 1341 "value": "A String", # The price represented as a number. 1342 }, 1343 "adjustments": [ # Price and tax adjustments applied on the line item. 1344 { 1345 "type": "A String", # Type of this adjustment. 1346 "priceAdjustment": { # Adjustment for total price of the line item. 1347 "currency": "A String", # The currency of the price. 1348 "value": "A String", # The price represented as a number. 1349 }, 1350 "taxAdjustment": { # Adjustment for total tax of the line item. 1351 "currency": "A String", # The currency of the price. 1352 "value": "A String", # The price represented as a number. 1353 }, 1354 }, 1355 ], 1356 "tax": { # 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. 1357 "currency": "A String", # The currency of the price. 1358 "value": "A String", # The price represented as a number. 1359 }, 1360 "cancellations": [ # Cancellations of the line item. 1361 { 1362 "reason": "A String", # The reason for the cancellation. Orders that are cancelled 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. 1363 "creationDate": "A String", # Date on which the cancellation has been created, in ISO 8601 format. 1364 "reasonText": "A String", # The explanation of the reason. 1365 "actor": "A String", # The actor that created the cancellation. 1366 "quantity": 42, # The quantity that was canceled. 1367 }, 1368 ], 1369 "quantityCanceled": 42, # Number of items canceled. 1370 "annotations": [ # Annotations that are attached to the line item. 1371 { 1372 "value": "A String", # Value for additional merchant provided (as key-value pairs) annotation about the line item. 1373 "key": "A String", # Key for additional merchant provided (as key-value pairs) annotation about the line item. 1374 }, 1375 ], 1376 "returns": [ # Returns of the line item. 1377 { 1378 "reason": "A String", # The reason for the return. 1379 "creationDate": "A String", # Date on which the item has been created, in ISO 8601 format. 1380 "reasonText": "A String", # The explanation of the reason. 1381 "actor": "A String", # The actor that created the refund. 1382 "quantity": 42, # Quantity that is returned. 1383 }, 1384 ], 1385 "quantityShipped": 42, # Number of items shipped. 1386 "quantityReturned": 42, # Number of items returned. 1387 "id": "A String", # The ID of the line item. 1388 "shippingDetails": { # Details of the requested shipping for the line item. 1389 "deliverByDate": "A String", # The delivery by date, in ISO 8601 format. 1390 "method": { # Details of the shipping method. 1391 "minDaysInTransit": 42, # Minimum transit time. 1392 "carrier": "A String", # The carrier for the shipping. Optional. See shipments[].carrier for a list of acceptable values. 1393 "methodName": "A String", # The name of the shipping method. 1394 "maxDaysInTransit": 42, # Maximum transit time. 1395 }, 1396 "shipByDate": "A String", # The ship by date, in ISO 8601 format. 1397 }, 1398 }, 1399 ], 1400 "shippingCost": { # The total cost of shipping for all items. 1401 "currency": "A String", # The currency of the price. 1402 "value": "A String", # The price represented as a number. 1403 }, 1404 "id": "A String", # The REST ID of the order. Globally unique. 1405 "deliveryDetails": { # Delivery details for shipments. 1406 "phoneNumber": "A String", # The phone number of the person receiving the delivery. 1407 "address": { # The delivery address 1408 "locality": "A String", # City, town or commune. May also include dependent localities or sublocalities (e.g. neighborhoods or suburbs). 1409 "country": "A String", # CLDR country code (e.g. "US"). 1410 "fullAddress": [ # Strings representing the lines of the printed label for mailing the order, for example: 1411 # John Smith 1412 # 1600 Amphitheatre Parkway 1413 # Mountain View, CA, 94043 1414 # United States 1415 "A String", 1416 ], 1417 "streetAddress": [ # Street-level part of the address. 1418 "A String", 1419 ], 1420 "postalCode": "A String", # Postal Code or ZIP (e.g. "94043"). 1421 "recipientName": "A String", # Name of the recipient. 1422 "isPostOfficeBox": True or False, # Whether the address is a post office box. 1423 "region": "A String", # Top-level administrative subdivision of the country. For example, a state like California ("CA") or a province like Quebec ("QC"). 1424 }, 1425 }, 1426 }, 1427 ], 1428 }</pre> 1429</div> 1430 1431<div class="method"> 1432 <code class="details" id="list_next">list_next(previous_request, previous_response)</code> 1433 <pre>Retrieves the next page of results. 1434 1435Args: 1436 previous_request: The request for the previous page. (required) 1437 previous_response: The response from the request for the previous page. (required) 1438 1439Returns: 1440 A request object that you can call 'execute()' on to request the next 1441 page. Returns None if there are no more items in the collection. 1442 </pre> 1443</div> 1444 1445<div class="method"> 1446 <code class="details" id="rejectreturnlineitem">rejectreturnlineitem(merchantId, orderId, body)</code> 1447 <pre>Rejects return on an line item. 1448 1449Args: 1450 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 1451 orderId: string, The ID of the order. (required) 1452 body: object, The request body. (required) 1453 The object takes the form of: 1454 1455{ 1456 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 1457 "reason": "A String", # The reason for the return. 1458 "reasonText": "A String", # The explanation of the reason. 1459 "lineItemId": "A String", # The ID of the line item to return. Either lineItemId or productId is required. 1460 "productId": "A String", # The ID of the product to return. This is the REST ID used in the products service. Either lineItemId or productId is required. 1461 "quantity": 42, # The quantity to return and refund. 1462 } 1463 1464 1465Returns: 1466 An object of the form: 1467 1468 { 1469 "kind": "content#ordersRejectReturnLineItemResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersRejectReturnLineItemResponse". 1470 "executionStatus": "A String", # The status of the execution. 1471 }</pre> 1472</div> 1473 1474<div class="method"> 1475 <code class="details" id="returnrefundlineitem">returnrefundlineitem(merchantId, orderId, body)</code> 1476 <pre>Returns and refunds a line item. Note that this method can only be called on fully shipped orders. 1477 1478Args: 1479 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 1480 orderId: string, The ID of the order. (required) 1481 body: object, The request body. (required) 1482 The object takes the form of: 1483 1484{ 1485 "priceAmount": { # 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. 1486 "currency": "A String", # The currency of the price. 1487 "value": "A String", # The price represented as a number. 1488 }, 1489 "taxAmount": { # The amount of tax to be refunded. Optional, but if filled, then priceAmount must be set. Calculated automatically if not provided. 1490 "currency": "A String", # The currency of the price. 1491 "value": "A String", # The price represented as a number. 1492 }, 1493 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 1494 "reason": "A String", # The reason for the return. 1495 "reasonText": "A String", # The explanation of the reason. 1496 "lineItemId": "A String", # The ID of the line item to return. Either lineItemId or productId is required. 1497 "quantity": 42, # The quantity to return and refund. 1498 "productId": "A String", # The ID of the product to return. This is the REST ID used in the products service. Either lineItemId or productId is required. 1499 } 1500 1501 1502Returns: 1503 An object of the form: 1504 1505 { 1506 "kind": "content#ordersReturnRefundLineItemResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersReturnRefundLineItemResponse". 1507 "executionStatus": "A String", # The status of the execution. 1508 }</pre> 1509</div> 1510 1511<div class="method"> 1512 <code class="details" id="setlineitemmetadata">setlineitemmetadata(merchantId, orderId, body)</code> 1513 <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. 1514 1515Args: 1516 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 1517 orderId: string, The ID of the order. (required) 1518 body: object, The request body. (required) 1519 The object takes the form of: 1520 1521{ 1522 "productId": "A String", # The ID of the product to set metadata. This is the REST ID used in the products service. Either lineItemId or productId is required. 1523 "annotations": [ 1524 { 1525 "value": "A String", # Value for additional merchant provided (as key-value pairs) annotation about the line item. 1526 "key": "A String", # Key for additional merchant provided (as key-value pairs) annotation about the line item. 1527 }, 1528 ], 1529 "lineItemId": "A String", # The ID of the line item to set metadata. Either lineItemId or productId is required. 1530 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 1531 } 1532 1533 1534Returns: 1535 An object of the form: 1536 1537 { 1538 "kind": "content#ordersSetLineItemMetadataResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersSetLineItemMetadataResponse". 1539 "executionStatus": "A String", # The status of the execution. 1540 }</pre> 1541</div> 1542 1543<div class="method"> 1544 <code class="details" id="shiplineitems">shiplineitems(merchantId, orderId, body)</code> 1545 <pre>Marks line item(s) as shipped. 1546 1547Args: 1548 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 1549 orderId: string, The ID of the order. (required) 1550 body: object, The request body. (required) 1551 The object takes the form of: 1552 1553{ 1554 "lineItems": [ # Line items to ship. 1555 { 1556 "quantity": 42, # The quantity that is shipped. 1557 "lineItemId": "A String", # The ID of the line item that is shipped. Either lineItemId or productId is required. 1558 "productId": "A String", # The ID of the product to ship. This is the REST ID used in the products service. Either lineItemId or productId is required. 1559 }, 1560 ], 1561 "shipmentInfos": [ # Shipment information. This field is repeated because a single line item can be shipped in several packages (and have several tracking IDs). 1562 { 1563 "carrier": "A String", # The carrier handling the shipment. See shipments[].carrier in the Orders resource representation for a list of acceptable values. 1564 "trackingId": "A String", # The tracking ID for the shipment. 1565 "shipmentId": "A String", # The ID of the shipment. This is assigned by the merchant and is unique to each shipment. 1566 }, 1567 ], 1568 "shipmentGroupId": "A String", # ID of the shipment group. Required for orders that use the orderinvoices service. 1569 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 1570 } 1571 1572 1573Returns: 1574 An object of the form: 1575 1576 { 1577 "kind": "content#ordersShipLineItemsResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersShipLineItemsResponse". 1578 "executionStatus": "A String", # The status of the execution. 1579 }</pre> 1580</div> 1581 1582<div class="method"> 1583 <code class="details" id="updatelineitemshippingdetails">updatelineitemshippingdetails(merchantId, orderId, body)</code> 1584 <pre>Updates ship by and delivery by dates for a line item. 1585 1586Args: 1587 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 1588 orderId: string, The ID of the order. (required) 1589 body: object, The request body. (required) 1590 The object takes the form of: 1591 1592{ 1593 "deliverByDate": "A String", # Updated delivery by date, in ISO 8601 format. If not specified only ship by date is updated. 1594 # 1595 # Provided date should be within 1 year timeframe and can not be a date in the past. 1596 "shipByDate": "A String", # Updated ship by date, in ISO 8601 format. If not specified only deliver by date is updated. 1597 # 1598 # Provided date should be within 1 year timeframe and can not be a date in the past. 1599 "productId": "A String", # The ID of the product to set metadata. This is the REST ID used in the products service. Either lineItemId or productId is required. 1600 "lineItemId": "A String", # The ID of the line item to set metadata. Either lineItemId or productId is required. 1601 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 1602 } 1603 1604 1605Returns: 1606 An object of the form: 1607 1608 { 1609 "kind": "content#ordersUpdateLineItemShippingDetailsResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersUpdateLineItemShippingDetailsResponse". 1610 "executionStatus": "A String", # The status of the execution. 1611 }</pre> 1612</div> 1613 1614<div class="method"> 1615 <code class="details" id="updatemerchantorderid">updatemerchantorderid(merchantId, orderId, body)</code> 1616 <pre>Updates the merchant order ID for a given order. 1617 1618Args: 1619 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 1620 orderId: string, The ID of the order. (required) 1621 body: object, The request body. (required) 1622 The object takes the form of: 1623 1624{ 1625 "merchantOrderId": "A String", # The merchant order id to be assigned to the order. Must be unique per merchant. 1626 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 1627 } 1628 1629 1630Returns: 1631 An object of the form: 1632 1633 { 1634 "kind": "content#ordersUpdateMerchantOrderIdResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersUpdateMerchantOrderIdResponse". 1635 "executionStatus": "A String", # The status of the execution. 1636 }</pre> 1637</div> 1638 1639<div class="method"> 1640 <code class="details" id="updateshipment">updateshipment(merchantId, orderId, body)</code> 1641 <pre>Updates a shipment's status, carrier, and/or tracking ID. 1642 1643Args: 1644 merchantId: string, The ID of the account that manages the order. This cannot be a multi-client account. (required) 1645 orderId: string, The ID of the order. (required) 1646 body: object, The request body. (required) 1647 The object takes the form of: 1648 1649{ 1650 "status": "A String", # New status for the shipment. Not updated if missing. 1651 "carrier": "A String", # The carrier handling the shipment. Not updated if missing. See shipments[].carrier in the Orders resource representation for a list of acceptable values. 1652 "trackingId": "A String", # The tracking ID for the shipment. Not updated if missing. 1653 "shipmentId": "A String", # The ID of the shipment. 1654 "deliveryDate": "A String", # Date on which the shipment has been delivered, in ISO 8601 format. Optional and can be provided only if status is delivered. 1655 "operationId": "A String", # The ID of the operation. Unique across all operations for a given order. 1656 } 1657 1658 1659Returns: 1660 An object of the form: 1661 1662 { 1663 "kind": "content#ordersUpdateShipmentResponse", # Identifies what kind of resource this is. Value: the fixed string "content#ordersUpdateShipmentResponse". 1664 "executionStatus": "A String", # The status of the execution. 1665 }</pre> 1666</div> 1667 1668</body></html>