POST
/
v1
/
shipping
/
orders
/
massUpdate
Mass update orders
curl --request POST \
  --url https://{base_url_domain}/api/global/v1/shipping/orders/massUpdate \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "orders": {
    "ids": [
      2
    ]
  },
  "actions": {
    "setValues": {
      "order_reference": "O-382227",
      "require_overbox": false,
      "require_signature": "adult",
      "require_saturday_delivery": false,
      "desired_delivery_date": "2021-02-21",
      "shipping_method": "ups_03",
      "third_party_billing_group_id": 12,
      "custom_greeting": "<string>",
      "note": "<string>",
      "declared_value_service": true,
      "declared_value": {
        "amount": 99,
        "currency": "USD"
      },
      "backorder_policy": "default",
      "reason_for_export": "sold",
      "priority": 50,
      "allocation_options": {},
      "requested_ship_date": "2021-02-21T07:00:00Z",
      "generate_sscc": "pack",
      "other_shipping_options": {},
      "batch_tag": "Smalls-CartA",
      "telephone": "865-971-4663",
      "email": "celina.goalley@thompson-torp.com"
    },
    "updateAllocationOptions": {
      "set": {
        "algorithms": [
          "default"
        ]
      },
      "unset": [
        "dynamic_allocation"
      ]
    },
    "updateOtherShippingOptions": {
      "merge": {
        "reference_numbers": {
          "invoice": null
        }
      }
    },
    "cancel": {
      "items": [
        "all"
      ]
    },
    "hold": {
      "until": "2017-07-21T17:32:28Z",
      "comment": "<string>"
    },
    "unhold": {
      "comment": "<string>"
    },
    "updatePriority": {
      "operation": "boost",
      "amount": 50
    },
    "lockToWarehouse": {
      "warehouse_id": 3
    },
    "unlockFromWarehouse": {},
    "addComment": {
      "comment": "<string>"
    }
  },
  "onError": "continue"
}'
{
  "loaded": 1,
  "committed": 1,
  "failed": 1,
  "not-found": 1,
  "results": [
    {
      "resource": {
        "type": "Order",
        "id": 2
      },
      "status": "committed",
      "message": "<string>",
      "details": {
        "updatePriority": {
          "status": "success",
          "message": "<string>",
          "new_value": 123
        },
        "lockToWarehouse": {
          "status": "success",
          "message": "<string>"
        },
        "unlockFromWarehouse": {
          "status": "success",
          "message": "<string>"
        },
        "cancel": {
          "status": "success",
          "message": "<string>"
        },
        "hold": {
          "status": "success",
          "message": "<string>"
        },
        "unhold": {
          "status": "success",
          "message": "<string>"
        }
      }
    }
  ],
  "meta": {
    "processing_time": 123
  }
}

Authorizations

Authorization
string
header
required

Generate a JWT access token through a Custom Global Integration and provide it with each request in the Authorization header prefixed with "Bearer" and then a single space.

Body

application/json
orders
object
required

An object containing the orders to be updated.

actions
object
required

An object containing all of the actions to be taken on the specified Order ids.

onError
enum<string>
default:continue

The value determining how errors are to be handled.

  • continue The current entity will be rolled back and any remaining entities will continue to be processed.
  • stop The current entity will be rolled back and the request will stop processing any remaining entities.
  • abort The entire request will be rolled back.
Available options:
continue,
stop,
abort

Response

An object with orders mass update results.

loaded
integer
required

The number of entities that were successfully loaded.

Required range: x >= 0
committed
integer
required

The number of entities that were successfully updated.

Required range: x >= 0
failed
integer
required

The number of entities that failed to be updated.

Required range: x >= 0
not-found
integer
required

The number of entities that were not found.

Required range: x >= 0
results
OrderUpdateResult · object[]
required

The list of update results for the requested Order objects.

Minimum length: 1
meta
object
required