AfterShip Orders API
The Orders API from AfterShip — 4 operation(s) for orders.
The Orders API from AfterShip — 4 operation(s) for orders.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
find_apisBrowse and filter every API in the catalog.get_api_artifactsOne API's artifacts, grouped by type.get_openapiThe primary OpenAPI for this API.find_similar_apisAPIs that look like this one.apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.resolveTurn a domain, URL or GitHub org into the provider it belongs to.find_cohortsEvery scored population of providers in the catalog.curl "https://apis.io/api/v1/apis/aftership-orders-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
openapi: 3.2.0
info:
title: Overview Orders API
version: 2026-07
summary: API Overview
contact:
name: AfterShip Support
url: https://www.aftership.com/contact-us
email: support@aftership.com
termsOfService: https://www.aftership.com/legal/terms-of-service
description: '> OAS Schema can be downloaded [here](https://stoplight.io/api/v1/projects/automizely/docs-api-automizely-com-commerce/nodes/reference/api.json?branch=testing%2F2026-07&deref=optimizedBundle)'
servers:
- url: https://api.aftership.com/commerce/2026-07
description: API Endpoint
security:
- as-api-key: []
tags:
- name: Orders
paths:
/orders:
post:
summary: Create an order
responses:
'201':
description: ''
content:
application/json:
schema:
type: object
description: ''
properties:
meta:
$ref: '#/components/schemas/Meta.v1'
data:
$ref: '#/components/schemas/Order.v1'
examples:
Example 1:
value:
meta:
code: 20100
type: Created
message: The request was successfully processed by AfterShip.
data:
id: '5187092316403'
store:
id: 0ecb8ff7efa84d7d8f763ed7b21851d1
name: '#1086'
number: '1086'
currency: HKD
status: open
financial_status: unpaid
fulfillment_status: unfulfilled
order_total: '97'
shipping_total: '5'
tax_total: '10'
discount_total: '1'
subtotal: '90'
items:
- id: '13097711141107'
sku: SKU001
quantity: 1
unit_weight:
unit: kg
value: 10
unit_price:
currency: USD
amount: '10'
product_title: Power Mobile Phone
product_variant_title: Power Mobile Phone Pro
discount: '10'
tax: '10'
product_id: '8021450916083'
product_variant_id: '43768285298931'
hs_code: '554521'
origin_country_region: USA
image_urls:
- https://www.example.com/product/phone/image.jpg
product_tags:
- mobile-phone
product_categories:
- mobile-phone
returnable_quantity: 1
note: Created by AfterShip
source_created_at: '2021-04-15T20:02:09Z'
source_updated_at: '2021-04-16T20:02:09Z'
created_at: '2021-04-15T20:02:09Z'
updated_at: '2021-04-16T20:02:09Z'
customer:
id: '5127837778090'
first_name: John
last_name: Doe
emails:
- john.doe@example.com
locale: en-US
phones:
- '+11234567890'
shipping_address:
type: business
street_1: 1234 Elm Street
street_2: Apt 5
street_3: ''
city: New York
state: NY
postal_code: '10001'
country_region: USA
company: My Company
first_name: John
last_name: Doe
email: john.doe@example.com
phone: '+11234567890'
billing_address:
type: business
street_1: 1234 Elm Street
street_2: Apt 5
street_3: ''
city: New York
state: NY
postal_code: '10001'
country_region: USA
company: My Company
first_name: John
last_name: Doe
email: john.doe@example.com
phone: '+11234567890'
tags:
- mobile-phone
shipping_method: standard shipping
delivery_method: shipping
pickup_location:
location_id: string
address:
type: business
street_1: 1234 Elm Street
street_2: Apt 5
street_3: ''
city: New York
state: NY
postal_code: '10001'
country_region: USA
company: My Company
first_name: John
last_name: Doe
email: john.doe@example.com
phone: '+11234567890'
coordinate:
latitude: 43
longitude: -75
opening_hours:
sunday:
open: true
from: '10:30'
to: '20:30'
monday:
open: true
from: '10:30'
to: '20:30'
tuesday:
open: true
from: '10:30'
to: '20:30'
wednesday:
open: true
from: '10:30'
to: '20:30'
thursday:
open: true
from: '10:30'
to: '20:30'
friday:
open: true
from: '10:30'
to: '20:30'
saturday:
open: true
from: '10:30'
to: '20:30'
pickup_info:
instructions: string
estimated_ready_for_pickup_at:
min: '2019-08-24T14:15:22Z'
max: '2019-08-24T14:15:22Z'
pickup_deadline_at: '2019-08-24T14:15:22Z'
operationId: create-order
description: "Create an order. \n\n> Please refer to the common scenario documentation for the usage of AfterShip Tracking, Shipping and Returns.\n\n> If you receive **41204 error (The store could not be found)**, please create a store with the [Create a store](https://www.aftership.com/docs/commerce/2025-04/hadtz8qj5if6w-create-a-store) endpoint before calling this API.\n\n\n<div style=\"visibility:hidden; height: 0\">[url](../docs/common_scenarios/tracking/bopis.md)</div>"
parameters:
- $ref: '#/components/parameters/as-store-id'
tags:
- Orders
requestBody:
content:
application/json:
schema:
type: object
additionalProperties: false
required:
- currency
- number
- status
- order_total
- items
- delivery_method
properties:
id:
type: string
description: A custom identifier for the order. If not provided, the system will generate a UUID. Must be unique within the store and immutable. You can use this ID to manage the resource in subsequent API calls.
maxLength: 128
example: my-custom-id-123
pattern: ^[a-zA-Z0-9_-]+$
x-stoplight:
id: mjrpj72to49gw
name:
type: string
description: The order name.
maxLength: 256
example: '#1086'
currency:
type:
- string
description: Specifies the currency for the order, adhering to the [ISO 4217 Currency Codes standard](https://en.wikipedia.org/wiki/ISO_4217).
example: USD
pattern: ^[A-Z]{3}$
number:
type: string
description: The order number.
maxLength: 64
example: '1086'
status:
type: string
enum:
- open
- closed
- canceled
description: The status of the order.
financial_status:
type:
- string
- 'null'
enum:
- partially_paid
- paid
- partially_refunded
- refunded
- unpaid
description: The status of payments associated with the order. Defaults to `null` if not provided.
fulfillment_status:
type:
- string
- 'null'
enum:
- unfulfilled
- partially_fulfilled
- fulfilled
description: 'The fulfillment status associated with the order. If not provided, this value is determined automatically. Since fulfillment has not been created at the time of order creation, it defaults to unfulfilled.
If you provide a value for this field when creating an order, you are responsible for updating the status manually from then onward. If you want AfterShip to manage the status automatically, do not provide this field when creating orders.'
order_total:
type: string
description: "Final amount paid by the customer, including of charges.\n\nFormula: \n`order_total = subtotal + shipping_total + tax_total`"
maxLength: 100
example: '97'
subtotal:
type: string
description: "Total after discounts, excluding taxes and shipping\n\nFormula: \n`subtotal = sum of all items' price`\n\n`1 item price = items.*.unit_price * items.*.quantity - items.*.discount`"
maxLength: 100
example: '90'
shipping_total:
type: string
description: The total shipping fee applied to the price of the order.
maxLength: 100
example: '5'
tax_total:
type: string
description: The sum of all the taxes applied to the order.
maxLength: 100
example: '10'
discount_total:
type: string
description: The total discounts applied to the order. The value should be equal to the sum of all item discounts.
maxLength: 100
example: '1'
items:
type: array
description: Purchased items of the order.
maxItems: 300
minItems: 1
items:
$ref: '#/components/schemas/Order_item.v1'
note:
type: string
description: A note that the shop owner can optionally attach to the order.
maxLength: 5000
example: Created by AfterShip
source_created_at:
type: string
description: The date and time, formatted in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), indicating when the order was created in your e-commerce system.
example: '2021-04-15T20:02:09Z'
source_updated_at:
type: string
description: The date and time, formatted in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601), indicating when the order was updated in your e-commerce system.
example: '2021-04-16T20:02:09Z'
customer:
$ref: '#/components/schemas/Customer.v1'
description: Customer information of the order.
shipping_address:
$ref: '#/components/schemas/Address.v1'
description: Shipping address of the order.
billing_address:
$ref: '#/components/schemas/Address.v1'
description: Billing address of the order.
tags:
type: array
description: Tags attached to the order.
maxItems: 100
items:
type: string
example: mobile-phone
shipping_method:
type: string
description: The name of the shipping method.
maxLength: 256
example: standard shipping
delivery_method:
type: string
x-stoplight:
id: ewm9fia1h0hfj
enum:
- shipping
- pickup
description: 'Delivery method of the order.
For orders requiring shipping to buyers, please specify `shipping`. For Buy Online, Pick Up In Store (BOPIS) orders, please specify `pickup`.
For further details on pickup / BOPIS orders, refer to our comprehensive [BOPIS introduction page](../docs/common_scenarios/tracking/bopis.md).
'
example: shipping
pickup_location:
type: object
x-stoplight:
id: 2oi1vnzlgtdc3
description: 'To indicate the pickup location of the order when the delivery method of the order is `pickup`.
For further details on pickup / BOPIS orders, refer to our comprehensive [BOPIS introduction page](../docs/common_scenarios/tracking/bopis.md).'
required:
- location_id
properties:
location_id:
type: string
x-stoplight:
id: s961j2vomx6rx
description: The unique identifier for the address. You can find or create the corresponding value [here](https://organization.automizely.com/warehouses).
example: b1cd63f641844a8e94208bad3c011ea3
pickup_info:
$ref: '#/components/schemas/Pickup.v1'
x-stoplight:
id: xuy8sphna6ej7
description: 'To indicate the detailed pickup instruction of the order when the delivery method of the order is `pickup`.
For further details on pickup / BOPIS orders, refer to our comprehensive [BOPIS introduction page](../docs/common_scenarios/tracking/bopis.md).'
status_timestamps:
$ref: '#/components/schemas/Status_timestamps.v1'
x-stoplight:
id: 8vvvtyweol0o1
custom_fields:
$ref: '#/components/schemas/Order_custom_fields.v1'
x-stoplight:
id: ep64tykxqyu8q
examples:
Example 1:
value:
id: '5187092316403'
name: '#1086'
number: '1086'
currency: USD
status: open
financial_status: partially_paid
fulfillment_status: unfulfilled
order_total: '97'
shipping_total: '5'
tax_total: '10'
discount_total: '1'
subtotal: '90'
items:
- id: '13097711141107'
sku: SKU001
quantity: 1
unit_weight:
unit: kg
value: 10
unit_price:
currency: USD
amount: '10'
product_title: Power Mobile Phone
product_variant_title: Power Mobile Phone Pro
discount: '10'
tax: '10'
product_id: '8021450916083'
product_variant_id: '43768285298931'
hs_code: '554521'
origin_country_region: USA
image_urls:
- https://www.example.com/product/phone/image.jpg
product_tags:
- mobile-phone
product_categories:
- mobile-phone
returnable_quantity: 1
note: Created by AfterShip
source_created_at: '2021-04-15T20:02:09Z'
source_updated_at: '2021-04-16T20:02:09Z'
customer:
id: '5127837778090'
first_name: John
last_name: Doe
emails:
- john.doe@example.com
locale: en-US
phones:
- '+11234567890'
shipping_address:
type: business
street_1: 1234 Elm Street
street_2: Apt 5
street_3: ''
city: New York
state: NY
postal_code: '10001'
country_region: USA
company: My Company
first_name: John
last_name: Doe
email: john.doe@example.com
phone: '+11234567890'
billing_address:
type: business
street_1: 1234 Elm Street
street_2: Apt 5
street_3: ''
city: New York
state: NY
postal_code: '10001'
country_region: USA
company: My Company
first_name: John
last_name: Doe
email: john.doe@example.com
phone: '+11234567890'
tags:
- mobile-phone
shipping_method: standard shipping
delivery_method: shipping
pickup_location:
location_id: b1cd63f641844a8e94208bad3c011ea3
pickup_info:
instructions: string
estimated_ready_for_pickup_at:
min: '2019-08-24T14:15:22Z'
max: '2019-08-24T14:15:22Z'
pickup_deadline_at: '2019-08-24T14:15:22Z'
x-stoplight:
id: hwj8tr3xn41rq
get:
summary: Get orders
operationId: get-orders
responses:
'200':
description: ''
content:
application/json:
schema:
type: object
properties:
meta:
$ref: '#/components/schemas/Meta.v1'
x-stoplight:
id: uhj872nkb4v0x
data:
type: object
x-stoplight:
id: zfgwol14rqk1u
properties:
orders:
type: array
x-stoplight:
id: e5ryg71wgv6j0
minItems: 0
maxItems: 50
items:
$ref: '#/components/schemas/Order.v1'
x-stoplight:
id: dw6s26g5cmgjt
pagination:
$ref: '#/components/schemas/Pagination.v2'
x-stoplight:
id: 3uev4y3k91nv0
parameter_string:
type: string
x-stoplight:
id: 38ln8athl4tux
description: A string that includes the request parameters.
example: limit=10&page=1
examples:
Example 1:
value:
meta:
code: 20000
type: OK
message: The request was successfully processed by AfterShip.
data:
orders:
- id: '5187092316403'
store:
id: 0ecb8ff7efa84d7d8f763ed7b21851d1
name: '#1086'
number: '1086'
currency: HKD
status: open
financial_status: unpaid
fulfillment_status: unfulfilled
order_total: '97'
shipping_total: '5'
tax_total: '10'
discount_total: '1'
subtotal: '90'
items:
- id: '13097711141107'
sku: SKU001
quantity: 1
unit_weight:
unit: kg
value: 10
unit_price:
currency: USD
amount: '10'
product_title: Power Mobile Phone
product_variant_title: Power Mobile Phone Pro
discount: '10'
tax: '10'
product_id: '8021450916083'
product_variant_id: '43768285298931'
hs_code: '554521'
origin_country_region: USA
image_urls:
- https://www.example.com/product/phone/image.jpg
product_tags:
- mobile-phone
product_categories:
- mobile-phone
returnable_quantity: 1
note: Created by AfterShip
source_created_at: '2021-04-15T20:02:09Z'
source_updated_at: '2021-04-16T20:02:09Z'
created_at: '2021-04-15T20:02:09Z'
updated_at: '2021-04-16T20:02:09Z'
customer:
id: '5127837778090'
first_name: John
last_name: Doe
emails:
- john.doe@example.com
locale: en-US
phones:
- '+11234567890'
shipping_address:
type: business
street_1: 1234 Elm Street
street_2: Apt 5
street_3: ''
city: New York
state: NY
postal_code: '10001'
country_region: USA
company: My Company
first_name: John
last_name: Doe
email: john.doe@example.com
phone: '+11234567890'
billing_address:
type: business
street_1: 1234 Elm Street
street_2: Apt 5
street_3: ''
city: New York
state: NY
postal_code: '10001'
country_region: USA
company: My Company
first_name: John
last_name: Doe
email: john.doe@example.com
phone: '+11234567890'
tags:
- mobile-phone
shipping_method: standard shipping
delivery_method: shipping
pickup_location:
location_id: e9ec84ff351e45e089a7b75ae497e1ae
address:
type: business
street_1: 1234 Elm Street
street_2: Apt 5
street_3: ''
city: New York
state: NY
postal_code: '10001'
country_region: USA
company: My Company
first_name: John
last_name: Doe
email: john.doe@example.com
phone: '+11234567890'
coordinate:
latitude: 43
longitude: -75
opening_hours:
sunday:
open: true
from: '10:30'
to: '20:30'
monday:
open: true
from: '10:30'
to: '20:30'
tuesday:
open: true
from: '10:30'
to: '20:30'
wednesday:
open: true
from: '10:30'
to: '20:30'
thursday:
open: true
from: '10:30'
to: '20:30'
friday:
open: true
from: '10:30'
to: '20:30'
saturday:
open: true
from: '10:30'
to: '20:30'
pickup_info:
instructions: Shop open from Mon to Fri
estimated_ready_for_pickup_at:
min: '2021-04-15T20:02:09Z'
max: '2021-04-15T20:02:09Z'
pickup_deadline_at: '2021-04-15T20:02:09Z'
pagination:
page: 0
limit: 0
has_next_page: true
parameter_string: limit=10&page=1
x-stoplight:
id: kr3dy6e5ma49n
description: Get order results with multiple orders.
parameters:
- schema:
type: string
in: query
name: ids[]
description: 'Each element should be less than 128 characters. Count of the elements should be less than 50. Every id should be used as an independent query param, as the following url example shows: /orders?ids[]=5247009653041&ids[]=5081836323059 '
- schema:
type: integer
maximum: 50
minimum: 1
in: query
name: limit
description: The maximum number of results to show on a page. Default is 10.
- schema:
type: integer
minimum: 1
maximum: 200
in: query
name: page
description: Current page of the collection. Default is 1.
- schema:
type: string
enum:
- -source_created_at
- +source_created_at
- -source_updated_at
- +source_updated_at
example: -source_created_at
in: query
name: sort
description: Sort the results list by the given value. Default is '-source_created_at' .
- $ref: '#/components/parameters/as-store-id'
tags:
- Orders
/orders/{id}:
parameters:
- schema:
type: string
name: id
in: path
required: true
description: The ID of the order.
get:
summary: Get order by ID
responses:
'200':
description: ''
content:
application/json:
schema:
type: object
properties:
meta:
$ref: '#/components/schemas/Meta.v1'
data:
$ref: '#/components/schemas/Order.v1'
examples:
Example 1:
value:
meta:
code: 20000
type: OK
message: The request was successfully processed by AfterShip.
data:
id: '5187092316403'
store:
id: 0ecb8ff7efa84d7d8f763ed7b21851d1
name: '#1086'
number: '1086'
currency: HKD
status: open
financial_status: unpaid
fulfillment_status: unfulfilled
order_total: '97'
shipping_total: '5'
tax_total: '10'
discount_total: '1'
subtotal: '90'
items:
- id: '13097711141107'
sku: SKU001
quantity: 1
unit_weight:
unit: kg
value: 10
unit_price:
currency: USD
amount: '10'
product_title: Power Mobile Phone
product_variant_title: Power Mobile Phone Pro
discount: '10'
tax: '10'
product_id: '8021450916083'
product_variant_id: '43768285298931'
hs_code: '554521'
origin_country_region: USA
image_urls:
- https://www.example.com/product/phone/image.jpg
product_tags:
- mobile-phone
product_categories:
- mobile-phone
returnable_quantity: 1
note: Created by AfterShip
source_created_at: '2021-04-15T20:02:09Z'
source_updated_at: '2021-04-16T20:02:09Z'
created_at: '2021-04-15T20:02:09Z'
updated_at: '2021-04-16T20:02:09Z'
customer:
id: '5127837778090'
first_name: John
last_name: Doe
emails:
- john.doe@example.com
locale: en-US
phones:
- '+11234567890'
shipping_address:
type: business
street_1: 1234 Elm Street
street_2: Apt 5
# --- truncated at 32 KB (87 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/aftership/refs/heads/main/openapi/aftership-orders-api-openapi.yml