Skip to content

OR04 - Patch update orders

Request

Description

Update orders information field by field: unspecified fields will not be updated. To remove the value for a field, send it with the 'null' value (not allowed for the required fields).

You cannot use API OR04 to update customer-related information if the customer has been anonymized.

A maximum of 100 orders can be sent at once.

Call Frequency
Maximum usage: Once per minute, 100 orders per call
Read More
Security
Front-Bearer-Token or OAuth-2
Bodyapplication/json
ordersArray of objects, [ 1 .. 100 ] itemsrequired

Orders to be updated, maximum number of orders per call: 100

curl -i -X PUT \
  https://your-instance.mirakl.net/api/orders \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "orders": [
      {
        "customer": {
          "accounting_contact": {
            "customer_id": "Customer_id_002"
          },
          "billing_address": {
            "city": "New York",
            "company": "simple customer",
            "company_2": "second information",
            "country": "USA",
            "country_iso_code": "USA",
            "phone_secondary": "213-509-6995",
            "state": "Manhattan",
            "street_1": "113 MacDougal Street",
            "street_2": "1st floor",
            "zip_code": "NY 10012"
          },
          "delivery_contact": {
            "customer_id": "Customer_id_003"
          },
          "organization": {
            "address": {
              "city": "New York",
              "country_iso_code": "USA",
              "state": "Manhattan",
              "street_1": "113 MacDougal Street",
              "street_2": "1st floor",
              "zip_code": "NY 10012"
            },
            "identification_number": "982837446",
            "name": "Limark Company Inc.",
            "tax_identification_number": "96-25472919"
          },
          "shipping_address": {
            "additional_info": "One article per box",
            "city": "New York",
            "civility": "M",
            "company": "LIMARK Company",
            "company_2": "Paris branch",
            "country": "USA",
            "country_iso_code": "USA",
            "firstname": "Smith",
            "internal_additional_info": "No additional information",
            "lastname": "Taylor",
            "phone": "213-509-6995",
            "phone_secondary": "213-509-6996",
            "state": "Manhattan",
            "street_1": "113 MacDougal Street",
            "street_2": "1st floor",
            "zip_code": "NY 10012"
          }
        },
        "invoice_details": {
          "document_details": [
            {
              "format": "PDF"
            },
            {
              "format": "cXML"
            }
          ],
          "payment_terms": {
            "days": 10,
            "type": "NET"
          }
        },
        "order_id": "Order_00014",
        "payment_destination": {
          "@type": "IBAN",
          "iban": "123456789",
          "payment_reference": "TX1000"
        },
        "payment_workflow": "PAY_ON_ACCEPTANCE",
        "shipping_deadline": "2020-03-20T16:38:31.131Z",
        "shop_statistics": {
          "excluded": true,
          "reason": "Reason for exclusion"
        }
      }
    ]
  }'

Responses

OK

Bodyapplication/json
updated_ordersArray of objects

A list of updated orders and orders in error objects

Response
{ "updated_orders": [ { … } ] }