OpenAPI 3.1.02026-08-143874115.7 MB
a84d4905fdbb
Shipments
List Shipments
Returns a paginated list of shipments for an account.
get/shipments
Query parameters
account_idstring
The account to list shipments for. Defaults to the acting account.
status'unknown' | 'pre_transit' | 'in_transit' | 'out_for_delivery' | 'delivered' | 'available_for_pickup' | 'return_to_sender' | 'failure' | 'cancelled' | 'error'
Filter to shipments with this delivery status.
payment_idstring[]
Only shipments fulfilling these payments, each prefixed pay_. Repeat the parameter to pass several, up to 100 per request — one paginated list covers all of them.
[ "pay_xxxxxxxxxxxxxx" ]
created_beforestring
Return shipments created before this ISO 8601 timestamp.
created_afterstring
Return shipments created after this ISO 8601 timestamp.
order'created_at'
The field to sort by.
direction'asc' | 'desc'
The sort direction.
firstinteger
The number of shipments to return.
afterstring
A cursor; returns shipments after this position.
lastinteger
The number of shipments to return from the end of the range.
beforestring
A cursor; returns shipments before this position.
Response
excludes the created_after boundary row
Example response
{
"data": [
{
"account_id": "biz_xxxxxxxxxxxxxx",
"carrier": "ups",
"checkpoints": [
{
"location": "PHILADELPHIA, PA",
"message": "Picked up",
"status": "in_transit",
"timestamp": "2026-01-01T12:00:00.000Z"
}
],
"created_at": "2026-01-01T12:00:00.000Z",
"id": "ship_xxxxxxxxxxxxxx",
"payment_id": "pay_xxxxxxxxxxxxxx",
"status": "in_transit",
"tracking_number": "1Z999AA10123456784",
"tracking_url": "https://track.aftership.com/xxxxxxxxxxxxxxxxxx",
"updated_at": "2026-01-01T12:00:00.000Z"
}
],
"page_info": {
"end_cursor": "WyJjdXJzb3IiLDFd",
"start_cursor": "WyJjdXJzb3IiLDFd"
}
}