Create Order
POST/commerce/orders
Create order for a specified connection
Request
Query Parameters
The ID of the credential.
Header Parameters
Default value: bearer YOUR_API_KEY
- application/json
Body
Array [
]
A string used to retrieve orders with a specific order number.
A string used to retrieve orders with a specific order status.
A string used to retrieve orders with a specific fulfillment status.
A specific value used to retrieve orders with a matching shipping total.
A specific value used to retrieve orders with a matching discount total.
A specific value used to retrieve orders with a matching tax total.
A specific value used to retrieve orders with a matching total price.
A string used to retrieve orders with a specific currency.
lineItems
object[]
required
An array of objects, each representing a line item in the order.
Most commerce platforms require this field to properly identify products
A string used to retrieve orders with a specific payment status.
billingAddress
object
required
An object representing the billing address of the customer.
A string representing the first line of the billing address.
An optional string representing additional address information.
A string representing the city of the billing address.
A string representing the country code of the billing address.
A string representing the first name of the person associated with the billing address.
A string representing the last name of the person associated with the billing address.
A string representing the phone number associated with the billing address.
A string representing the region (e.g. state, province) of the billing address.
A string representing the postal code of the billing address.
shippingAddress
object
An object representing the shipping address of the customer.
A string representing the first line of the billing address.
An optional string representing additional address information.
A string representing the city of the billing address.
A string representing the country code of the billing address.
A string representing the first name of the person associated with the billing address.
A string representing the last name of the person associated with the billing address.
A string representing the phone number associated with the billing address.
A string representing the region (e.g. state, province) of the billing address.
A string representing the postal code of the billing address.
customer
object
required
An object representing the customer who placed the order.
A unique identifier for the customer.
The first name of the customer.
The last name of the customer.
The email address of the customer.
The phone number of the customer.
An object containing remote fields that are not supported by the common model. The keys are the names of the fields of the corresponding resource in the remote app, and the values can be strings, numbers, arrays or objects.
Responses
- 200
- 400
200
- application/json
- Schema
- Example (from schema)
- Result
Schema
Array [
]
order
object
lineItems
object[]
Default value: 0
customer
object
Default value: true
{
"order": {
"id": "00000000-0000-0000-0000-000000000000",
"remoteId": "2191357149242",
"orderStatus": "Active",
"lineItems": [
{
"quantity": 1,
"productId": "4463254208570",
"price": "1000.00",
"unitCost": "",
"currency": "USD",
"variantId": "31586061353018",
"title": "T-Shirt",
"sku": "shirt-01"
}
],
"orderNumber": "1001",
"paymentStatus": "Paid",
"customer": {
"customerId": "3046096732218",
"firstName": "Chase",
"lastName": "Red",
"phone": "",
"email": "chasered@runalloy.com"
},
"currency": "USD",
"totalPrice": "1000.00",
"totalDiscount": "0.00",
"totalShipping": "0.00",
"totalTax": "0.00",
"fulfillmentStatus": "unfulfilled",
"remoteCreatedAt": "2023-11-19T17:00:17.000Z",
"remoteUpdatedAt": "2023-11-19T17:00:17.000Z",
"remoteDeleted": false,
"createdAt": "2024-02-22T11:17:53.264Z",
"updatedAt": "2024-02-22T13:54:03.445Z"
}
}
{
"order": {
"id": "00000000-0000-0000-0000-000000000000",
"remoteId": "2191357149242",
"orderStatus": "Active",
"lineItems": [
{
"quantity": 1,
"productId": "4463254208570",
"price": "1000.00",
"unitCost": "",
"currency": "USD",
"variantId": "31586061353018",
"title": "T-Shirt",
"sku": "shirt-01"
}
],
"orderNumber": "1001",
"paymentStatus": "Paid",
"customer": {
"customerId": "3046096732218",
"firstName": "Chase",
"lastName": "Red",
"phone": "",
"email": "chasered@runalloy.com"
},
"currency": "USD",
"totalPrice": "1000.00",
"totalDiscount": "0.00",
"totalShipping": "0.00",
"totalTax": "0.00",
"fulfillmentStatus": "unfulfilled",
"remoteCreatedAt": "2023-11-19T17:00:17.000Z",
"remoteUpdatedAt": "2023-11-19T17:00:17.000Z",
"remoteDeleted": false,
"createdAt": "2024-02-22T11:17:53.264Z",
"updatedAt": "2024-02-22T13:54:03.445Z"
}
}
400
- application/json
- Schema
- Example (from schema)
- Result
Schema
{}
{}