Skip to Content
FastracDocs
API reference

List shipments

GET
/b2b/shipments

Lists your shipments, newest first, with filters and per-status counts. Unpaid shipments are never listed. Use it for an order dashboard, or to find a shipment after a timeout.

data.count covers all your shipments in the startDate–endDate range and ignores the other filters. count.RTS adds up RTS_CONFIRMED and RTS_TRANSIT.

Requires the READ_ORDER permission.

Authorization

bearerAuth
headerAuthorizationBearer <token>

An access token from the OAuth2 client-credentials grant. Exchange your API key (client_id + client_secret) at the token endpoint and send Authorization: Bearer <access_token>.

Query Parameters

search?string

Matches shipment code, airway bill, order code, or receiver name or phone (partial, case-insensitive).

Lengthlength <= 100
orderCode?string

Only shipments of this order (partial match).

Lengthlength <= 50
courierCode?string

Only shipments with this courier. Case-insensitive.

courierServiceId?integer

Only shipments with this courier service (id from List courier services).

Range1 <= value
status?string

Only shipments in this status.

Value in"WAITING_FOR_PAYMENT""CONFIRMED""PENDING_PICKUP""PENDING_DROPOFF""IN_TRANSIT""PROBLEM_SHIPMENT""DELIVERED""CANCELLED""RTS_CONFIRMED""RTS_TRANSIT""RTS_PROBLEM_SHIPMENT""RTS_DELIVERED"
startDate?string

Created at or after this time. ISO 8601; include an offset, for example 2026-11-01T00:00:00+07:00.

Formatdate-time
endDate?string

Created at or before this time. ISO 8601; include an offset.

Formatdate-time
source?string

Only shipments created through this channel. API orders are B2B; dashboard orders are CLIENT_DASHBOARD.

Value in"B2B""CLIENT_DASHBOARD""WEB""ANDROID""IOS""SHOP"
limit?integer

Items per page. Values above 100 are capped at 100.

Range1 <= value <= 100
Default25
cursor?string

The nextCursor from the previous page. Omit for the first page.

Response Body

One page of shipments.

application/json
  1. response
statusCode*integer
message*string
data*
Example Request
curl -X GET 'https://sandbox-api.fastrac.example/b2b/shipments'
Example Response
{  "statusCode": 200,  "message": "Shipments retrieved.",  "data": {    "count": {      "PENDING_PICKUP": 3,      "PENDING_DROPOFF": 1,      "IN_TRANSIT": 12,      "DELIVERED": 248,      "CANCELLED": 7,      "RTS": 2    },    "shipments": [      {        "id": 18452,        "code": "SHP-261120-K9M2Q7",        "orderId": 9021,        "orderCode": "FSO-261120-A1B2C3",        "source": "B2B",        "userId": 512,        "userEmail": "[email protected]",        "airwayBill": "CM12345678901",        "trackingUrl": null,        "courierCode": "JNE",        "courierName": "JNE",        "courierServiceId": 12,        "courierServiceCode": "REG",        "courierServiceName": "JNE Reguler",        "status": "IN_TRANSIT",        "createdAt": "2026-11-20T02:05:11.000Z",        "recipient": {          "name": "Rina Kartika",          "phoneNumber": "081298765432",          "fullAddress": "Jl. Braga No. 8, Braga, Sumur Bandung, Kota Bandung"        },        "cursor": "MTg0NTI="      }    ],    "nextCursor": "MTg0NTI="  }}

Was this page helpful?