Update order
PATCH/api/v2/orders/{order_id}
Updates the attributes of an existing order. Only orders that are in draft can be changes.
Authorization
Add HTTP header Authorization with the received API key as the bearer token:
- Authorization
- API Key
Parameters
URL parameters
| Property | Type | Description |
|---|---|---|
order_id | string | Order ID Unique identifier for order. uuid |
Request body
- Content-Type
application/json- Body
- UpdateOrderRequestrequired
| Property | Type | Description |
|---|---|---|
order | Schema that is used to update an existing order. All fields are optional and will be used to patch fields. Nills are accepted an will result in updating the field to an empty value. required | |
receiver | Schema that is used to update an existing receiver field in an order. All fields are optional and will be used to patch fields. Nills are accepted an will result in updating the field to an empty value. nullable | |
| required | ||
address2 | string | Address2 address field. nullable length 1...255 |
business_name | string | Name of business for address. If this name is supplied, it will indicate that the address type is business. If left empty, it indicates that the address type is a consumer. nullable length 1...255 |
city | string | City of address. nullable length 2...30 |
country_code | string | ISO country code. nullable length 2...2 |
email_address | string | Email address compatible with RFC 5322. nullable length 3...320 |
eori_number | string | Economic Operators Registration and Identification number that is required by businesses to ship internationally. nullable length 3...17 |
family_name | string | nullable length 1...30 |
given_name | string | nullable length 1...30 |
house_number | string | House number in an address. May also contain house number extensions. nullable length 1...14 |
id | string | Unique ID for an address. Can be a ID of an existing sender_address or a unique ID of a parcelshop. In all other cases this ID is empty. nullable length 1...64 |
phone_number | string | Phone number that may consist of a country code. nullable length 2...30 |
state_code | string | State code for an address. The state code should be applicable for the country. So NY (New York) for country_code US (United States) or YT (Yukon) for country_code CA (Canada) nullable length 2...3 |
street_name | string | Street name is an identifying name given to a street or road. nullable length 2...55 |
vat | string | Value-added tax identification number or VAT identification number (VATIN). nullable length 3...14 |
zip_code | string | The zipcode of an address. nullable length 1...10 |
reference | string | Custom reference code to identify your shipments or orders nullable length 1...255 |
sender | Schema that is used to update an existing sender field in an order. All fields are optional and will be used to patch fields. Nills are accepted an will result in updating the field to an empty value. nullable | |
| required | ||
address2 | string | Address2 address field. nullable length 1...255 |
business_name | string | Name of business for address. If this name is supplied, it will indicate that the address type is business. If left empty, it indicates that the address type is a consumer. nullable length 1...255 |
city | string | City of address. nullable length 2...30 |
country_code | string | ISO country code. nullable length 2...2 |
email_address | string | Email address compatible with RFC 5322. nullable length 3...320 |
eori_number | string | Economic Operators Registration and Identification number that is required by businesses to ship internationally. nullable length 3...17 |
family_name | string | nullable length 1...30 |
given_name | string | nullable length 1...30 |
house_number | string | House number in an address. May also contain house number extensions. nullable length 1...14 |
id | string | Unique ID for an address. Can be a ID of an existing sender_address or a unique ID of a parcelshop. In all other cases this ID is empty. nullable length 1...64 |
phone_number | string | Phone number that may consist of a country code. nullable length 2...30 |
state_code | string | State code for an address. The state code should be applicable for the country. So NY (New York) for country_code US (United States) or YT (Yukon) for country_code CA (Canada) nullable length 2...3 |
street_name | string | Street name is an identifying name given to a street or road. nullable length 2...55 |
vat | string | Value-added tax identification number or VAT identification number (VATIN). nullable length 3...14 |
zip_code | string | The zipcode of an address. nullable length 1...10 |
Request example
Response
Response body
- Content-Type
application/json- Body
| Property | Type | Description |
|---|---|---|
order | A collection of shipments. Contains data for orders that are persisted. required | |
| required | ||
reference | string | Custom reference code to identify your shipments or orders required length 1...255 |
| required | ||
id | string | Unique identifier for order. required uuid |
inserted_at | string | Date time in ISO 8601 format (YYYY-MM-DD HH:MM:SS) in UTC required date-time |
order_code | string | Unique human readable identifier of an order in Wuunder. length 13...13 |
receiver | Specifies the full legal address of a business or person, including street, house number, zip code, city, and country that is used to send the order to. required | |
sender | Specifies the full legal address of a business or person, including street, house number, zip code, city, and country that is used to send the order from. required | |
shipments | ||
status | string | required |
status_history | object | Contains all historical events that took place on this shipment or order. required |
updated_at | string | Date time in ISO 8601 format (YYYY-MM-DD HH:MM:SS) in UTC required date-time |