API reference
Orders
On this page
List orders
/ordersRequired scopes:read_orders
Query parameters
| Name | Type | Description |
|---|---|---|
limit | integer | Page size, 1–250 (default 50). default 50 · min 1 · max 250 |
cursor | string | next_cursor from the previous page. |
updated_since | string<date-time> | Only objects changed at or after this ISO-8601 time. |
created_since | string<date-time> | Only objects created at or after this ISO-8601 time. |
status | string | Order status. One of: |
payment_status | string | Payment status. One of: |
customer_id | integer | Of this customer. |
source | string | storefront, pos, subscription or api. |
email | string | Customer email. |
Example request
curl "https://api.sellorchard.com/v1/orders?limit=50" \
-H "Authorization: Bearer $SELLORCHARD_API_KEY"Response200Orders, newest first.
ShowHide response schema
dataarray of OrderrequiredShowHide item attributes
objectstringrequiredidintegerrequiredOrder id.
numberintegerrequiredOrder number.
namestringrequiredNumber with the store prefix.
statusstringrequiredOrder status.
One of:
pendingprocessingon_holdshippedready_for_pickupdeliveredcancelledrefundedpayment_statusstringrequiredPayment status.
One of:
unpaidauthorizedpaidpartially_refundedrefundedfailedfulfillment_statusstringrequiredunfulfilled, partial (some lines shipped) or fulfilled.
One of:
unfulfilledpartialfulfilledsourcestringrequiredWhere it was placed.
One of:
storefrontpossubscriptionapitestbooleanrequiredA test order (free-trial store).
emailstring<email> | nullrequiredCustomer email.
phonestring | nullrequiredPhone.
customer_idinteger | nullrequiredCustomer.
customer_namestring | nullrequiredName.
currencystringrequiredISO 4217 currency of every amount on the order.
subtotalstringrequiredLines before discounts.
pattern ^-?\d+\.\d{2}$
discount_totalstringrequiredDiscounts.
pattern ^-?\d+\.\d{2}$
shipping_totalstringrequiredShipping.
pattern ^-?\d+\.\d{2}$
tax_totalstringrequiredTaxes.
pattern ^-?\d+\.\d{2}$
totalstringrequiredTotal charged.
pattern ^-?\d+\.\d{2}$
refunded_totalstringrequiredRefunded so far.
pattern ^-?\d+\.\d{2}$
discount_codestring | nullrequiredDiscount code used.
payment_methodstringrequiredPayment method code.
payment_method_labelstringrequiredPayment method as shown.
line_itemsarray of LineItemrequiredLines.
ShowHide item attributes
idintegerrequiredLine item id.
product_idinteger | nullrequiredProduct (null if deleted).
variant_idinteger | nullrequiredVariant (null if deleted).
namestringrequiredProduct name when ordered.
variant_titlestring | nullrequiredVariant title.
skustring | nullrequiredSKU.
kindstringrequiredLine kind.
One of:
physicaldigitalgift_cardbookingquantityintegerrequiredQuantity.
unit_pricestringrequiredUnit price.
pattern ^-?\d+\.\d{2}$
discountstringrequiredDiscount on the line.
pattern ^-?\d+\.\d{2}$
taxstringrequiredTax on the line.
pattern ^-?\d+\.\d{2}$
line_totalstringrequiredunit_price × quantity (before discount).
pattern ^-?\d+\.\d{2}$
fulfilled_atstring<date-time> | nullrequiredWhen the line shipped.
fulfillmentstringrequiredDelivery method.
One of:
shippickupdigitalposshipping_lineobject | nullrequiredShowHide child attributes
titlestringrequiredShipping method.
pricestringrequiredIts price.
pattern ^-?\d+\.\d{2}$
shipping_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
billing_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
trackingobject | nullrequiredShowHide child attributes
companystring | nullCarrier.
numberstring | nullTracking number.
urlstring | nullTracking URL.
tagsarray of stringrequiredYour tags (PATCH /orders/{id}).
notestring | nullrequiredStaff note (PATCH /orders/{id}); not shown to the customer.
customer_notestring | nullrequiredNote from the customer.
location_idinteger | nullrequiredFulfilling location.
placed_atstring<date-time> | nullrequiredPlaced.
paid_atstring<date-time> | nullrequiredPaid.
fulfilled_atstring<date-time> | nullrequiredShipped.
delivered_atstring<date-time> | nullrequiredDelivered.
cancelled_atstring<date-time> | nullrequiredCancelled.
created_atstring<date-time>requiredCreated.
updated_atstring<date-time>requiredLast changed.
has_morebooleanrequiredMore pages after this one.
next_cursorstring | nullrequiredPass as
cursorfor the next page; null on the last page.
{
"data": [
{
"object": "order",
"id": 5521,
"number": 1042,
"name": "#1042",
"status": "processing",
"payment_status": "paid",
"fulfillment_status": "unfulfilled",
"source": "storefront",
"test": false,
"email": "ann@example.com",
"phone": "+15125550199",
"customer_id": 880,
"customer_name": "Ann Lee",
"currency": "USD",
"subtotal": "48.00",
"discount_total": "4.80",
"shipping_total": "5.00",
"tax_total": "3.17",
"total": "51.37",
"refunded_total": "0.00",
"discount_code": "WELCOME10",
"payment_method": "stripe",
"payment_method_label": "Card",
"line_items": [
{
"id": 9001,
"product_id": 120,
"variant_id": 311,
"name": "Organic cotton tee",
"variant_title": "Blue / Large",
"sku": "TEE-BL-L",
"kind": "physical",
"quantity": 2,
"unit_price": "24.00",
"discount": "4.80",
"tax": "3.17",
"line_total": "48.00",
"fulfilled_at": null
}
],
"fulfillment": "ship",
"shipping_line": {
"title": "Standard",
"price": "5.00"
},
"shipping_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"billing_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"tracking": null,
"tags": [
"wholesale"
],
"note": "Gift wrap",
"customer_note": "Please leave at the door.",
"location_id": 1,
"placed_at": "2026-11-02T15:00:00Z",
"paid_at": "2026-11-02T15:00:00Z",
"fulfilled_at": null,
"delivered_at": null,
"cancelled_at": null,
"created_at": "2026-11-02T15:00:00Z",
"updated_at": "2026-11-03T09:30:00Z"
}
],
"has_more": false,
"next_cursor": null
}Error responses
- 400
invalid_requestMalformed request (e.g. a bad cursor). - 401
authenticationMissing, invalid, expired or revoked API key. - 403
permissionThe key lacks the scope, or the store's plan doesn't include the API. - 422
invalid_requestInvalid parameters;errorslists each field. - 429
rate_limitedToo many requests. - 500
serverSomething went wrong on our side; safe to retry with the same Idempotency-Key.
Create an order
/ordersPriced by the same engine as checkout (catalogue prices unless given, group prices, discount codes, automatic discounts and taxes); stock is taken at the fulfilling location. Fires order.created (and order.paid when paid).
Required scopes:write_orders
Headers
| Name | Type | Description |
|---|---|---|
Idempotency-Key | string | Any unique string (e.g. a UUID, up to 255 characters). A retry with the same key and body within 24 hours gets the first response again (Idempotent-Replayed: true); the same key with a different body is a 409 conflict. |
Request body
line_itemsarray of objectrequiredUp to 100 lines. Stock is checked and taken (at the fulfilling location).
ShowHide item attributes
variant_idintegerrequiredVariant to sell.
quantityintegerrequiredQuantity (1–10000).
pricestring | number | nullUnit price to charge; leave out to use the catalogue price (group prices and quantity breaks included).
customerobjectrequiredid or email is required.
ShowHide child attributes
idinteger | nullAn existing customer…
emailstring<email> | null…or an email: found, or created.
first_namestring | nullFirst name (new customers).
last_namestring | nullLast name.
phonestring | nullPhone.
accepts_marketingbooleanEmail marketing consent (new customers).
shipping_addressAddressInput | any | nullShowHide child attributes
One of the following:
AddressInput
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1stringrequiredLine1.
line2string | nullLine2.
citystringrequiredCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystringrequiredISO 3166-1 alpha-2 country code.
min length 2 · max length 2
phonestring | nullPhone.
any | null
billing_addressAddressInput | any | nullDefaults to the shipping address.
ShowHide child attributes
One of the following:
AddressInput
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1stringrequiredLine1.
line2string | nullLine2.
citystringrequiredCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystringrequiredISO 3166-1 alpha-2 country code.
min length 2 · max length 2
phonestring | nullPhone.
any | null
shipping_lineobject | nullThe shipping charged (taxed like checkout shipping).
ShowHide child attributes
titlestringrequiredShown on the order.
pricestring | numberrequired
payment_statusstringpaid: recorded as paid outside SellOrchard (status processing). pending (default): unpaid (status pending).
One of:
paidpendingpayment_method_labelstring | nullHow it was paid, as shown on the order.
send_receiptbooleanEmail the order confirmation to the customer (and the new-order email to the store). Default false.
discount_codestring | nullA discount code to apply (checked like at checkout).
tagsarray of stringTags.
notestring | nullStaff note.
customer_notestring | nullCustomer note.
Example request
curl -X POST "https://api.sellorchard.com/v1/orders" \
-H "Authorization: Bearer $SELLORCHARD_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{
"line_items": [
{
"variant_id": 311,
"quantity": 2
},
{
"variant_id": 312,
"quantity": 1,
"price": "20.00"
}
],
"customer": {
"email": "ann@example.com",
"first_name": "Ann",
"last_name": "Lee"
}
}'Response201An order.
ShowHide response schema
dataOrderrequiredShowHide child attributes
objectstringrequiredidintegerrequiredOrder id.
numberintegerrequiredOrder number.
namestringrequiredNumber with the store prefix.
statusstringrequiredOrder status.
One of:
pendingprocessingon_holdshippedready_for_pickupdeliveredcancelledrefundedpayment_statusstringrequiredPayment status.
One of:
unpaidauthorizedpaidpartially_refundedrefundedfailedfulfillment_statusstringrequiredunfulfilled, partial (some lines shipped) or fulfilled.
One of:
unfulfilledpartialfulfilledsourcestringrequiredWhere it was placed.
One of:
storefrontpossubscriptionapitestbooleanrequiredA test order (free-trial store).
emailstring<email> | nullrequiredCustomer email.
phonestring | nullrequiredPhone.
customer_idinteger | nullrequiredCustomer.
customer_namestring | nullrequiredName.
currencystringrequiredISO 4217 currency of every amount on the order.
subtotalstringrequiredLines before discounts.
pattern ^-?\d+\.\d{2}$
discount_totalstringrequiredDiscounts.
pattern ^-?\d+\.\d{2}$
shipping_totalstringrequiredShipping.
pattern ^-?\d+\.\d{2}$
tax_totalstringrequiredTaxes.
pattern ^-?\d+\.\d{2}$
totalstringrequiredTotal charged.
pattern ^-?\d+\.\d{2}$
refunded_totalstringrequiredRefunded so far.
pattern ^-?\d+\.\d{2}$
discount_codestring | nullrequiredDiscount code used.
payment_methodstringrequiredPayment method code.
payment_method_labelstringrequiredPayment method as shown.
line_itemsarray of LineItemrequiredLines.
ShowHide item attributes
idintegerrequiredLine item id.
product_idinteger | nullrequiredProduct (null if deleted).
variant_idinteger | nullrequiredVariant (null if deleted).
namestringrequiredProduct name when ordered.
variant_titlestring | nullrequiredVariant title.
skustring | nullrequiredSKU.
kindstringrequiredLine kind.
One of:
physicaldigitalgift_cardbookingquantityintegerrequiredQuantity.
unit_pricestringrequiredUnit price.
pattern ^-?\d+\.\d{2}$
discountstringrequiredDiscount on the line.
pattern ^-?\d+\.\d{2}$
taxstringrequiredTax on the line.
pattern ^-?\d+\.\d{2}$
line_totalstringrequiredunit_price × quantity (before discount).
pattern ^-?\d+\.\d{2}$
fulfilled_atstring<date-time> | nullrequiredWhen the line shipped.
fulfillmentstringrequiredDelivery method.
One of:
shippickupdigitalposshipping_lineobject | nullrequiredShowHide child attributes
titlestringrequiredShipping method.
pricestringrequiredIts price.
pattern ^-?\d+\.\d{2}$
shipping_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
billing_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
trackingobject | nullrequiredShowHide child attributes
companystring | nullCarrier.
numberstring | nullTracking number.
urlstring | nullTracking URL.
tagsarray of stringrequiredYour tags (PATCH /orders/{id}).
notestring | nullrequiredStaff note (PATCH /orders/{id}); not shown to the customer.
customer_notestring | nullrequiredNote from the customer.
location_idinteger | nullrequiredFulfilling location.
placed_atstring<date-time> | nullrequiredPlaced.
paid_atstring<date-time> | nullrequiredPaid.
fulfilled_atstring<date-time> | nullrequiredShipped.
delivered_atstring<date-time> | nullrequiredDelivered.
cancelled_atstring<date-time> | nullrequiredCancelled.
created_atstring<date-time>requiredCreated.
updated_atstring<date-time>requiredLast changed.
{
"data": {
"object": "order",
"id": 5521,
"number": 1042,
"name": "#1042",
"status": "processing",
"payment_status": "paid",
"fulfillment_status": "unfulfilled",
"source": "storefront",
"test": false,
"email": "ann@example.com",
"phone": "+15125550199",
"customer_id": 880,
"customer_name": "Ann Lee",
"currency": "USD",
"subtotal": "48.00",
"discount_total": "4.80",
"shipping_total": "5.00",
"tax_total": "3.17",
"total": "51.37",
"refunded_total": "0.00",
"discount_code": "WELCOME10",
"payment_method": "stripe",
"payment_method_label": "Card",
"line_items": [
{
"id": 9001,
"product_id": 120,
"variant_id": 311,
"name": "Organic cotton tee",
"variant_title": "Blue / Large",
"sku": "TEE-BL-L",
"kind": "physical",
"quantity": 2,
"unit_price": "24.00",
"discount": "4.80",
"tax": "3.17",
"line_total": "48.00",
"fulfilled_at": null
}
],
"fulfillment": "ship",
"shipping_line": {
"title": "Standard",
"price": "5.00"
},
"shipping_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"billing_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"tracking": null,
"tags": [
"wholesale"
],
"note": "Gift wrap",
"customer_note": "Please leave at the door.",
"location_id": 1,
"placed_at": "2026-11-02T15:00:00Z",
"paid_at": "2026-11-02T15:00:00Z",
"fulfilled_at": null,
"delivered_at": null,
"cancelled_at": null,
"created_at": "2026-11-02T15:00:00Z",
"updated_at": "2026-11-03T09:30:00Z"
}
}Error responses
- 401
authenticationMissing, invalid, expired or revoked API key. - 403
permissionThe key lacks the scope, or the store's plan doesn't include the API. - 409
conflictThe Idempotency-Key was used with a different request, or that request is still running. - 422
invalid_requestInvalid parameters;errorslists each field. - 429
rate_limitedToo many requests. - 500
serverSomething went wrong on our side; safe to retry with the same Idempotency-Key.
Get an order
/orders/{id}Required scopes:read_orders
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | integer | The object id. |
Example request
curl "https://api.sellorchard.com/v1/orders/120" \
-H "Authorization: Bearer $SELLORCHARD_API_KEY"Response200An order.
ShowHide response schema
dataOrderrequiredShowHide child attributes
objectstringrequiredidintegerrequiredOrder id.
numberintegerrequiredOrder number.
namestringrequiredNumber with the store prefix.
statusstringrequiredOrder status.
One of:
pendingprocessingon_holdshippedready_for_pickupdeliveredcancelledrefundedpayment_statusstringrequiredPayment status.
One of:
unpaidauthorizedpaidpartially_refundedrefundedfailedfulfillment_statusstringrequiredunfulfilled, partial (some lines shipped) or fulfilled.
One of:
unfulfilledpartialfulfilledsourcestringrequiredWhere it was placed.
One of:
storefrontpossubscriptionapitestbooleanrequiredA test order (free-trial store).
emailstring<email> | nullrequiredCustomer email.
phonestring | nullrequiredPhone.
customer_idinteger | nullrequiredCustomer.
customer_namestring | nullrequiredName.
currencystringrequiredISO 4217 currency of every amount on the order.
subtotalstringrequiredLines before discounts.
pattern ^-?\d+\.\d{2}$
discount_totalstringrequiredDiscounts.
pattern ^-?\d+\.\d{2}$
shipping_totalstringrequiredShipping.
pattern ^-?\d+\.\d{2}$
tax_totalstringrequiredTaxes.
pattern ^-?\d+\.\d{2}$
totalstringrequiredTotal charged.
pattern ^-?\d+\.\d{2}$
refunded_totalstringrequiredRefunded so far.
pattern ^-?\d+\.\d{2}$
discount_codestring | nullrequiredDiscount code used.
payment_methodstringrequiredPayment method code.
payment_method_labelstringrequiredPayment method as shown.
line_itemsarray of LineItemrequiredLines.
ShowHide item attributes
idintegerrequiredLine item id.
product_idinteger | nullrequiredProduct (null if deleted).
variant_idinteger | nullrequiredVariant (null if deleted).
namestringrequiredProduct name when ordered.
variant_titlestring | nullrequiredVariant title.
skustring | nullrequiredSKU.
kindstringrequiredLine kind.
One of:
physicaldigitalgift_cardbookingquantityintegerrequiredQuantity.
unit_pricestringrequiredUnit price.
pattern ^-?\d+\.\d{2}$
discountstringrequiredDiscount on the line.
pattern ^-?\d+\.\d{2}$
taxstringrequiredTax on the line.
pattern ^-?\d+\.\d{2}$
line_totalstringrequiredunit_price × quantity (before discount).
pattern ^-?\d+\.\d{2}$
fulfilled_atstring<date-time> | nullrequiredWhen the line shipped.
fulfillmentstringrequiredDelivery method.
One of:
shippickupdigitalposshipping_lineobject | nullrequiredShowHide child attributes
titlestringrequiredShipping method.
pricestringrequiredIts price.
pattern ^-?\d+\.\d{2}$
shipping_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
billing_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
trackingobject | nullrequiredShowHide child attributes
companystring | nullCarrier.
numberstring | nullTracking number.
urlstring | nullTracking URL.
tagsarray of stringrequiredYour tags (PATCH /orders/{id}).
notestring | nullrequiredStaff note (PATCH /orders/{id}); not shown to the customer.
customer_notestring | nullrequiredNote from the customer.
location_idinteger | nullrequiredFulfilling location.
placed_atstring<date-time> | nullrequiredPlaced.
paid_atstring<date-time> | nullrequiredPaid.
fulfilled_atstring<date-time> | nullrequiredShipped.
delivered_atstring<date-time> | nullrequiredDelivered.
cancelled_atstring<date-time> | nullrequiredCancelled.
created_atstring<date-time>requiredCreated.
updated_atstring<date-time>requiredLast changed.
{
"data": {
"object": "order",
"id": 5521,
"number": 1042,
"name": "#1042",
"status": "processing",
"payment_status": "paid",
"fulfillment_status": "unfulfilled",
"source": "storefront",
"test": false,
"email": "ann@example.com",
"phone": "+15125550199",
"customer_id": 880,
"customer_name": "Ann Lee",
"currency": "USD",
"subtotal": "48.00",
"discount_total": "4.80",
"shipping_total": "5.00",
"tax_total": "3.17",
"total": "51.37",
"refunded_total": "0.00",
"discount_code": "WELCOME10",
"payment_method": "stripe",
"payment_method_label": "Card",
"line_items": [
{
"id": 9001,
"product_id": 120,
"variant_id": 311,
"name": "Organic cotton tee",
"variant_title": "Blue / Large",
"sku": "TEE-BL-L",
"kind": "physical",
"quantity": 2,
"unit_price": "24.00",
"discount": "4.80",
"tax": "3.17",
"line_total": "48.00",
"fulfilled_at": null
}
],
"fulfillment": "ship",
"shipping_line": {
"title": "Standard",
"price": "5.00"
},
"shipping_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"billing_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"tracking": null,
"tags": [
"wholesale"
],
"note": "Gift wrap",
"customer_note": "Please leave at the door.",
"location_id": 1,
"placed_at": "2026-11-02T15:00:00Z",
"paid_at": "2026-11-02T15:00:00Z",
"fulfilled_at": null,
"delivered_at": null,
"cancelled_at": null,
"created_at": "2026-11-02T15:00:00Z",
"updated_at": "2026-11-03T09:30:00Z"
}
}Error responses
- 401
authenticationMissing, invalid, expired or revoked API key. - 403
permissionThe key lacks the scope, or the store's plan doesn't include the API. - 404
not_foundNo such object in this store. - 429
rate_limitedToo many requests. - 500
serverSomething went wrong on our side; safe to retry with the same Idempotency-Key.
Update an order's tags and note
/orders/{id}Required scopes:write_orders
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | integer | The object id. |
Request body
tagsarray of stringReplaces the tags.
notestring | nullStaff note.
Example request
curl -X PATCH "https://api.sellorchard.com/v1/orders/120" \
-H "Authorization: Bearer $SELLORCHARD_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"tags": [
"vip"
],
"note": "Called the customer."
}'Response200An order.
ShowHide response schema
dataOrderrequiredShowHide child attributes
objectstringrequiredidintegerrequiredOrder id.
numberintegerrequiredOrder number.
namestringrequiredNumber with the store prefix.
statusstringrequiredOrder status.
One of:
pendingprocessingon_holdshippedready_for_pickupdeliveredcancelledrefundedpayment_statusstringrequiredPayment status.
One of:
unpaidauthorizedpaidpartially_refundedrefundedfailedfulfillment_statusstringrequiredunfulfilled, partial (some lines shipped) or fulfilled.
One of:
unfulfilledpartialfulfilledsourcestringrequiredWhere it was placed.
One of:
storefrontpossubscriptionapitestbooleanrequiredA test order (free-trial store).
emailstring<email> | nullrequiredCustomer email.
phonestring | nullrequiredPhone.
customer_idinteger | nullrequiredCustomer.
customer_namestring | nullrequiredName.
currencystringrequiredISO 4217 currency of every amount on the order.
subtotalstringrequiredLines before discounts.
pattern ^-?\d+\.\d{2}$
discount_totalstringrequiredDiscounts.
pattern ^-?\d+\.\d{2}$
shipping_totalstringrequiredShipping.
pattern ^-?\d+\.\d{2}$
tax_totalstringrequiredTaxes.
pattern ^-?\d+\.\d{2}$
totalstringrequiredTotal charged.
pattern ^-?\d+\.\d{2}$
refunded_totalstringrequiredRefunded so far.
pattern ^-?\d+\.\d{2}$
discount_codestring | nullrequiredDiscount code used.
payment_methodstringrequiredPayment method code.
payment_method_labelstringrequiredPayment method as shown.
line_itemsarray of LineItemrequiredLines.
ShowHide item attributes
idintegerrequiredLine item id.
product_idinteger | nullrequiredProduct (null if deleted).
variant_idinteger | nullrequiredVariant (null if deleted).
namestringrequiredProduct name when ordered.
variant_titlestring | nullrequiredVariant title.
skustring | nullrequiredSKU.
kindstringrequiredLine kind.
One of:
physicaldigitalgift_cardbookingquantityintegerrequiredQuantity.
unit_pricestringrequiredUnit price.
pattern ^-?\d+\.\d{2}$
discountstringrequiredDiscount on the line.
pattern ^-?\d+\.\d{2}$
taxstringrequiredTax on the line.
pattern ^-?\d+\.\d{2}$
line_totalstringrequiredunit_price × quantity (before discount).
pattern ^-?\d+\.\d{2}$
fulfilled_atstring<date-time> | nullrequiredWhen the line shipped.
fulfillmentstringrequiredDelivery method.
One of:
shippickupdigitalposshipping_lineobject | nullrequiredShowHide child attributes
titlestringrequiredShipping method.
pricestringrequiredIts price.
pattern ^-?\d+\.\d{2}$
shipping_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
billing_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
trackingobject | nullrequiredShowHide child attributes
companystring | nullCarrier.
numberstring | nullTracking number.
urlstring | nullTracking URL.
tagsarray of stringrequiredYour tags (PATCH /orders/{id}).
notestring | nullrequiredStaff note (PATCH /orders/{id}); not shown to the customer.
customer_notestring | nullrequiredNote from the customer.
location_idinteger | nullrequiredFulfilling location.
placed_atstring<date-time> | nullrequiredPlaced.
paid_atstring<date-time> | nullrequiredPaid.
fulfilled_atstring<date-time> | nullrequiredShipped.
delivered_atstring<date-time> | nullrequiredDelivered.
cancelled_atstring<date-time> | nullrequiredCancelled.
created_atstring<date-time>requiredCreated.
updated_atstring<date-time>requiredLast changed.
{
"data": {
"object": "order",
"id": 5521,
"number": 1042,
"name": "#1042",
"status": "processing",
"payment_status": "paid",
"fulfillment_status": "unfulfilled",
"source": "storefront",
"test": false,
"email": "ann@example.com",
"phone": "+15125550199",
"customer_id": 880,
"customer_name": "Ann Lee",
"currency": "USD",
"subtotal": "48.00",
"discount_total": "4.80",
"shipping_total": "5.00",
"tax_total": "3.17",
"total": "51.37",
"refunded_total": "0.00",
"discount_code": "WELCOME10",
"payment_method": "stripe",
"payment_method_label": "Card",
"line_items": [
{
"id": 9001,
"product_id": 120,
"variant_id": 311,
"name": "Organic cotton tee",
"variant_title": "Blue / Large",
"sku": "TEE-BL-L",
"kind": "physical",
"quantity": 2,
"unit_price": "24.00",
"discount": "4.80",
"tax": "3.17",
"line_total": "48.00",
"fulfilled_at": null
}
],
"fulfillment": "ship",
"shipping_line": {
"title": "Standard",
"price": "5.00"
},
"shipping_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"billing_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"tracking": null,
"tags": [
"wholesale"
],
"note": "Gift wrap",
"customer_note": "Please leave at the door.",
"location_id": 1,
"placed_at": "2026-11-02T15:00:00Z",
"paid_at": "2026-11-02T15:00:00Z",
"fulfilled_at": null,
"delivered_at": null,
"cancelled_at": null,
"created_at": "2026-11-02T15:00:00Z",
"updated_at": "2026-11-03T09:30:00Z"
}
}Error responses
- 401
authenticationMissing, invalid, expired or revoked API key. - 403
permissionThe key lacks the scope, or the store's plan doesn't include the API. - 404
not_foundNo such object in this store. - 422
invalid_requestInvalid parameters;errorslists each field. - 429
rate_limitedToo many requests. - 500
serverSomething went wrong on our side; safe to retry with the same Idempotency-Key.
Fulfil an order
/orders/{id}/fulfillmentsMarks lines (or the whole order) shipped with tracking; emails the customer like the admin does. Returns the order. Fires order.fulfilled once everything has shipped.
Required scopes:write_orders
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | integer | The object id. |
Headers
| Name | Type | Description |
|---|---|---|
Idempotency-Key | string | Any unique string (e.g. a UUID, up to 255 characters). A retry with the same key and body within 24 hours gets the first response again (Idempotent-Replayed: true); the same key with a different body is a 409 conflict. |
Request body
line_itemsarray of objectLines that shipped; leave out to fulfil the whole order.
ShowHide item attributes
idintegerrequiredLine item id.
quantityinteger | nullIgnored: whole lines are fulfilled.
tracking_numberstring | nullTracking number.
tracking_companystring | nullCarrier.
tracking_urlstring<uri> | nullTracking URL.
notifybooleanEmail the customer (default true).
Example request
curl -X POST "https://api.sellorchard.com/v1/orders/120/fulfillments" \
-H "Authorization: Bearer $SELLORCHARD_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{
"tracking_number": "1Z999AA10123456784",
"tracking_company": "UPS",
"notify": true
}'Response201An order.
ShowHide response schema
dataOrderrequiredShowHide child attributes
objectstringrequiredidintegerrequiredOrder id.
numberintegerrequiredOrder number.
namestringrequiredNumber with the store prefix.
statusstringrequiredOrder status.
One of:
pendingprocessingon_holdshippedready_for_pickupdeliveredcancelledrefundedpayment_statusstringrequiredPayment status.
One of:
unpaidauthorizedpaidpartially_refundedrefundedfailedfulfillment_statusstringrequiredunfulfilled, partial (some lines shipped) or fulfilled.
One of:
unfulfilledpartialfulfilledsourcestringrequiredWhere it was placed.
One of:
storefrontpossubscriptionapitestbooleanrequiredA test order (free-trial store).
emailstring<email> | nullrequiredCustomer email.
phonestring | nullrequiredPhone.
customer_idinteger | nullrequiredCustomer.
customer_namestring | nullrequiredName.
currencystringrequiredISO 4217 currency of every amount on the order.
subtotalstringrequiredLines before discounts.
pattern ^-?\d+\.\d{2}$
discount_totalstringrequiredDiscounts.
pattern ^-?\d+\.\d{2}$
shipping_totalstringrequiredShipping.
pattern ^-?\d+\.\d{2}$
tax_totalstringrequiredTaxes.
pattern ^-?\d+\.\d{2}$
totalstringrequiredTotal charged.
pattern ^-?\d+\.\d{2}$
refunded_totalstringrequiredRefunded so far.
pattern ^-?\d+\.\d{2}$
discount_codestring | nullrequiredDiscount code used.
payment_methodstringrequiredPayment method code.
payment_method_labelstringrequiredPayment method as shown.
line_itemsarray of LineItemrequiredLines.
ShowHide item attributes
idintegerrequiredLine item id.
product_idinteger | nullrequiredProduct (null if deleted).
variant_idinteger | nullrequiredVariant (null if deleted).
namestringrequiredProduct name when ordered.
variant_titlestring | nullrequiredVariant title.
skustring | nullrequiredSKU.
kindstringrequiredLine kind.
One of:
physicaldigitalgift_cardbookingquantityintegerrequiredQuantity.
unit_pricestringrequiredUnit price.
pattern ^-?\d+\.\d{2}$
discountstringrequiredDiscount on the line.
pattern ^-?\d+\.\d{2}$
taxstringrequiredTax on the line.
pattern ^-?\d+\.\d{2}$
line_totalstringrequiredunit_price × quantity (before discount).
pattern ^-?\d+\.\d{2}$
fulfilled_atstring<date-time> | nullrequiredWhen the line shipped.
fulfillmentstringrequiredDelivery method.
One of:
shippickupdigitalposshipping_lineobject | nullrequiredShowHide child attributes
titlestringrequiredShipping method.
pricestringrequiredIts price.
pattern ^-?\d+\.\d{2}$
shipping_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
billing_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
trackingobject | nullrequiredShowHide child attributes
companystring | nullCarrier.
numberstring | nullTracking number.
urlstring | nullTracking URL.
tagsarray of stringrequiredYour tags (PATCH /orders/{id}).
notestring | nullrequiredStaff note (PATCH /orders/{id}); not shown to the customer.
customer_notestring | nullrequiredNote from the customer.
location_idinteger | nullrequiredFulfilling location.
placed_atstring<date-time> | nullrequiredPlaced.
paid_atstring<date-time> | nullrequiredPaid.
fulfilled_atstring<date-time> | nullrequiredShipped.
delivered_atstring<date-time> | nullrequiredDelivered.
cancelled_atstring<date-time> | nullrequiredCancelled.
created_atstring<date-time>requiredCreated.
updated_atstring<date-time>requiredLast changed.
{
"data": {
"object": "order",
"id": 5521,
"number": 1042,
"name": "#1042",
"status": "processing",
"payment_status": "paid",
"fulfillment_status": "unfulfilled",
"source": "storefront",
"test": false,
"email": "ann@example.com",
"phone": "+15125550199",
"customer_id": 880,
"customer_name": "Ann Lee",
"currency": "USD",
"subtotal": "48.00",
"discount_total": "4.80",
"shipping_total": "5.00",
"tax_total": "3.17",
"total": "51.37",
"refunded_total": "0.00",
"discount_code": "WELCOME10",
"payment_method": "stripe",
"payment_method_label": "Card",
"line_items": [
{
"id": 9001,
"product_id": 120,
"variant_id": 311,
"name": "Organic cotton tee",
"variant_title": "Blue / Large",
"sku": "TEE-BL-L",
"kind": "physical",
"quantity": 2,
"unit_price": "24.00",
"discount": "4.80",
"tax": "3.17",
"line_total": "48.00",
"fulfilled_at": null
}
],
"fulfillment": "ship",
"shipping_line": {
"title": "Standard",
"price": "5.00"
},
"shipping_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"billing_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"tracking": null,
"tags": [
"wholesale"
],
"note": "Gift wrap",
"customer_note": "Please leave at the door.",
"location_id": 1,
"placed_at": "2026-11-02T15:00:00Z",
"paid_at": "2026-11-02T15:00:00Z",
"fulfilled_at": null,
"delivered_at": null,
"cancelled_at": null,
"created_at": "2026-11-02T15:00:00Z",
"updated_at": "2026-11-03T09:30:00Z"
}
}Error responses
- 401
authenticationMissing, invalid, expired or revoked API key. - 403
permissionThe key lacks the scope, or the store's plan doesn't include the API. - 404
not_foundNo such object in this store. - 409
conflictThe Idempotency-Key was used with a different request, or that request is still running. - 422
invalid_requestInvalid parameters;errorslists each field. - 429
rate_limitedToo many requests. - 500
serverSomething went wrong on our side; safe to retry with the same Idempotency-Key.
Cancel an order
/orders/{id}/cancelPending, on-hold, processing and ready-for-pickup orders. Fires order.cancelled (and refund.created / order.refunded with refund).
Required scopes:write_orders
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | integer | The object id. |
Headers
| Name | Type | Description |
|---|---|---|
Idempotency-Key | string | Any unique string (e.g. a UUID, up to 255 characters). A retry with the same key and body within 24 hours gets the first response again (Idempotent-Replayed: true); the same key with a different body is a 409 conflict. |
Request body
reasonstring | nullWhy (on the order timeline).
restockbooleanPut the items back into stock (default true).
refundbooleanRefund what was paid first (default false).
notifybooleanEmail the customer (default true).
Example request
curl -X POST "https://api.sellorchard.com/v1/orders/120/cancel" \
-H "Authorization: Bearer $SELLORCHARD_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{
"reason": "Customer changed their mind",
"restock": true,
"refund": true
}'Response200An order.
ShowHide response schema
dataOrderrequiredShowHide child attributes
objectstringrequiredidintegerrequiredOrder id.
numberintegerrequiredOrder number.
namestringrequiredNumber with the store prefix.
statusstringrequiredOrder status.
One of:
pendingprocessingon_holdshippedready_for_pickupdeliveredcancelledrefundedpayment_statusstringrequiredPayment status.
One of:
unpaidauthorizedpaidpartially_refundedrefundedfailedfulfillment_statusstringrequiredunfulfilled, partial (some lines shipped) or fulfilled.
One of:
unfulfilledpartialfulfilledsourcestringrequiredWhere it was placed.
One of:
storefrontpossubscriptionapitestbooleanrequiredA test order (free-trial store).
emailstring<email> | nullrequiredCustomer email.
phonestring | nullrequiredPhone.
customer_idinteger | nullrequiredCustomer.
customer_namestring | nullrequiredName.
currencystringrequiredISO 4217 currency of every amount on the order.
subtotalstringrequiredLines before discounts.
pattern ^-?\d+\.\d{2}$
discount_totalstringrequiredDiscounts.
pattern ^-?\d+\.\d{2}$
shipping_totalstringrequiredShipping.
pattern ^-?\d+\.\d{2}$
tax_totalstringrequiredTaxes.
pattern ^-?\d+\.\d{2}$
totalstringrequiredTotal charged.
pattern ^-?\d+\.\d{2}$
refunded_totalstringrequiredRefunded so far.
pattern ^-?\d+\.\d{2}$
discount_codestring | nullrequiredDiscount code used.
payment_methodstringrequiredPayment method code.
payment_method_labelstringrequiredPayment method as shown.
line_itemsarray of LineItemrequiredLines.
ShowHide item attributes
idintegerrequiredLine item id.
product_idinteger | nullrequiredProduct (null if deleted).
variant_idinteger | nullrequiredVariant (null if deleted).
namestringrequiredProduct name when ordered.
variant_titlestring | nullrequiredVariant title.
skustring | nullrequiredSKU.
kindstringrequiredLine kind.
One of:
physicaldigitalgift_cardbookingquantityintegerrequiredQuantity.
unit_pricestringrequiredUnit price.
pattern ^-?\d+\.\d{2}$
discountstringrequiredDiscount on the line.
pattern ^-?\d+\.\d{2}$
taxstringrequiredTax on the line.
pattern ^-?\d+\.\d{2}$
line_totalstringrequiredunit_price × quantity (before discount).
pattern ^-?\d+\.\d{2}$
fulfilled_atstring<date-time> | nullrequiredWhen the line shipped.
fulfillmentstringrequiredDelivery method.
One of:
shippickupdigitalposshipping_lineobject | nullrequiredShowHide child attributes
titlestringrequiredShipping method.
pricestringrequiredIts price.
pattern ^-?\d+\.\d{2}$
shipping_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
billing_addressAddress | any | nullrequiredShowHide child attributes
One of the following:
Address
first_namestring | nullFirst name.
last_namestring | nullLast name.
companystring | nullCompany.
line1string | nullLine1.
line2string | nullLine2.
citystring | nullCity.
regionstring | nullRegion.
postcodestring | nullPostcode.
countrystring | nullISO 3166-1 alpha-2 country code.
phonestring | nullPhone.
any | null
trackingobject | nullrequiredShowHide child attributes
companystring | nullCarrier.
numberstring | nullTracking number.
urlstring | nullTracking URL.
tagsarray of stringrequiredYour tags (PATCH /orders/{id}).
notestring | nullrequiredStaff note (PATCH /orders/{id}); not shown to the customer.
customer_notestring | nullrequiredNote from the customer.
location_idinteger | nullrequiredFulfilling location.
placed_atstring<date-time> | nullrequiredPlaced.
paid_atstring<date-time> | nullrequiredPaid.
fulfilled_atstring<date-time> | nullrequiredShipped.
delivered_atstring<date-time> | nullrequiredDelivered.
cancelled_atstring<date-time> | nullrequiredCancelled.
created_atstring<date-time>requiredCreated.
updated_atstring<date-time>requiredLast changed.
{
"data": {
"object": "order",
"id": 5521,
"number": 1042,
"name": "#1042",
"status": "processing",
"payment_status": "paid",
"fulfillment_status": "unfulfilled",
"source": "storefront",
"test": false,
"email": "ann@example.com",
"phone": "+15125550199",
"customer_id": 880,
"customer_name": "Ann Lee",
"currency": "USD",
"subtotal": "48.00",
"discount_total": "4.80",
"shipping_total": "5.00",
"tax_total": "3.17",
"total": "51.37",
"refunded_total": "0.00",
"discount_code": "WELCOME10",
"payment_method": "stripe",
"payment_method_label": "Card",
"line_items": [
{
"id": 9001,
"product_id": 120,
"variant_id": 311,
"name": "Organic cotton tee",
"variant_title": "Blue / Large",
"sku": "TEE-BL-L",
"kind": "physical",
"quantity": 2,
"unit_price": "24.00",
"discount": "4.80",
"tax": "3.17",
"line_total": "48.00",
"fulfilled_at": null
}
],
"fulfillment": "ship",
"shipping_line": {
"title": "Standard",
"price": "5.00"
},
"shipping_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"billing_address": {
"first_name": "Ann",
"last_name": "Lee",
"company": null,
"line1": "1 Main St",
"line2": "Apt 2",
"city": "Austin",
"region": "TX",
"postcode": "73301",
"country": "US",
"phone": "+15125550199"
},
"tracking": null,
"tags": [
"wholesale"
],
"note": "Gift wrap",
"customer_note": "Please leave at the door.",
"location_id": 1,
"placed_at": "2026-11-02T15:00:00Z",
"paid_at": "2026-11-02T15:00:00Z",
"fulfilled_at": null,
"delivered_at": null,
"cancelled_at": null,
"created_at": "2026-11-02T15:00:00Z",
"updated_at": "2026-11-03T09:30:00Z"
}
}Error responses
- 401
authenticationMissing, invalid, expired or revoked API key. - 403
permissionThe key lacks the scope, or the store's plan doesn't include the API. - 404
not_foundNo such object in this store. - 409
conflictThe Idempotency-Key was used with a different request, or that request is still running. - 422
invalid_requestInvalid parameters;errorslists each field. - 429
rate_limitedToo many requests. - 500
serverSomething went wrong on our side; safe to retry with the same Idempotency-Key.
Refund an order
/orders/{id}/refundsPaid orders only, up to what is left. Fires refund.created and order.refunded.
Required scopes:write_orders
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | integer | The object id. |
Headers
| Name | Type | Description |
|---|---|---|
Idempotency-Key | string | Any unique string (e.g. a UUID, up to 255 characters). A retry with the same key and body within 24 hours gets the first response again (Idempotent-Replayed: true); the same key with a different body is a 409 conflict. |
Request body
amountstring | number | nullAmount to refund (required without line_items; overrides their sum).
line_itemsarray of objectLines refunded: the amount is what was paid for those units.
ShowHide item attributes
idintegerrequiredLine item id.
quantityinteger | nullUnits (default all).
restockbooleanPut the line items back into stock (default false).
notestring | nullReason.
Example request
curl -X POST "https://api.sellorchard.com/v1/orders/120/refunds" \
-H "Authorization: Bearer $SELLORCHARD_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{
"line_items": [
{
"id": 9001,
"quantity": 1
}
],
"restock": true,
"note": "Damaged in transit"
}'Response201The refund.
ShowHide response schema
dataRefundrequiredShowHide child attributes
objectstringrequiredidintegerrequiredRefund id.
order_idintegerrequiredOrder.
amountstringrequiredRefunded.
pattern ^-?\d+\.\d{2}$
currencystringrequiredOrder currency.
notestring | nullrequiredWhat was recorded.
created_atstring<date-time>requiredWhen.
{
"data": {
"object": "refund",
"id": 70211,
"order_id": 5521,
"amount": "24.00",
"currency": "USD",
"note": "Refunded 24.00 USD — Damaged in transit (through the API (API key ERP)).",
"created_at": "2026-11-03T09:30:00Z"
}
}Error responses
- 401
authenticationMissing, invalid, expired or revoked API key. - 403
permissionThe key lacks the scope, or the store's plan doesn't include the API. - 404
not_foundNo such object in this store. - 409
conflictThe Idempotency-Key was used with a different request, or that request is still running. - 422
invalid_requestInvalid parameters;errorslists each field. - 429
rate_limitedToo many requests. - 500
serverSomething went wrong on our side; safe to retry with the same Idempotency-Key.
Add a note to an order
/orders/{id}/notesAdded to the order's timeline in the admin.
Required scopes:write_orders
Path parameters
| Name | Type | Description |
|---|---|---|
idrequired | integer | The object id. |
Headers
| Name | Type | Description |
|---|---|---|
Idempotency-Key | string | Any unique string (e.g. a UUID, up to 255 characters). A retry with the same key and body within 24 hours gets the first response again (Idempotent-Replayed: true); the same key with a different body is a 409 conflict. |
Request body
messagestringrequiredThe note (up to 2000 characters).
Example request
curl -X POST "https://api.sellorchard.com/v1/orders/120/notes" \
-H "Authorization: Bearer $SELLORCHARD_API_KEY" \
-H "Idempotency-Key: $(uuidgen)" \
-H "Content-Type: application/json" \
-d '{
"message": "Customer called about delivery"
}'Response201The note.
ShowHide response schema
dataOrderNoterequiredShowHide child attributes
objectstringrequiredidintegerrequiredNote id.
order_idintegerrequiredOrder.
messagestringrequiredText.
created_atstring<date-time>requiredWhen.
{
"data": {
"object": "order_note",
"id": 70212,
"order_id": 5521,
"message": "Customer called about delivery — via API key ERP",
"created_at": "2026-11-03T09:30:00Z"
}
}Error responses
- 401
authenticationMissing, invalid, expired or revoked API key. - 403
permissionThe key lacks the scope, or the store's plan doesn't include the API. - 404
not_foundNo such object in this store. - 409
conflictThe Idempotency-Key was used with a different request, or that request is still running. - 422
invalid_requestInvalid parameters;errorslists each field. - 429
rate_limitedToo many requests. - 500
serverSomething went wrong on our side; safe to retry with the same Idempotency-Key.