batches
List batches
List the batches associated with your ShipStation account.
get/v2/batches
Request
- Base URL: https://api.shipstation.com
- URL: https://api.shipstation.com/v2/batches
- Auth: API key in header api-key
Query parameters
status'open' | 'queued' | 'processing' | 'completed' | 'completed_with_errors' | 'archived' | 'notifying' | 'invalid'
The possible batch status values
pageinteger
Return a specific page of results. Defaults to the first page. If set to a number that's greater than the number of pages of results, an empty page is returned.
page_sizeinteger
The number of results to return per response.
sort_dir'asc' | 'desc'
Controls the sort order of queries
| Value | Description |
|---|---|
| asc | Return results in ascending order |
| desc | Return results in descending order |
Controls the sort order of the query.
batch_numberstring
Batch Number
sort_by'ship_date' | 'processed_at' | 'created_at'
The possible batches sort by values
Response
The request was a success.
Example response
{
"batches": [
{
"batch_id": "se-28529731",
"batch_number": "123456",
"external_batch_id": "12323aaaar",
"batch_notes": "Batch for morning shipment",
"created_at": "2018-09-23T15:00:00.000Z",
"processed_at": "2018-09-23T15:00:00.000Z",
"errors": 2,
"process_errors": [
{
"message": "Body of request cannot be null."
}
],
"warnings": 1,
"completed": 1,
"forms": 3,
"count": 2,
"batch_shipments_url": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"type": "child"
},
"batch_labels_url": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"type": "child"
},
"batch_errors_url": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"type": "child"
},
"label_download": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"pdf": "http://api.shipstation.com/v2/labels/se-28529731",
"png": "http://api.shipstation.com/v2/labels/se-28529731",
"zpl": "http://api.shipstation.com/v2/labels/se-28529731"
},
"form_download": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"type": "child"
},
"paperless_download": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"instructions": "any instructions",
"handoff_code": "122334"
}
}
],
"total": 10,
"page": 1,
"pages": 10,
"links": {
"first": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"type": "child"
},
"last": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"type": "child"
},
"prev": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"type": "child"
},
"next": {
"href": "http://api.shipstation.com/v2/labels/se-28529731",
"type": "child"
}
}
}Changes
No recorded changes to this operation across all 1 revision of this API.