Skip to content
gist.link ↗

shipments

Query Shipping API — POST https://shipping.api.gist.link/graphql

The shipments query on the Shipping API.

shipping:query:shipments

The calling IAM key must hold this permission (or a wildcard that covers it: shipping:query:* or shipping:*) and the access token must have been minted with audience=shipping. See Permissions.

type Query {
shipments(filter: ShipmentFilter, sort: SortInput, first: Int, after: String): ShipmentConnection!
}
Argument Type Required Description
filter ShipmentFilter No —
sort SortInput No —
first Int No —
after String No —

ShipmentConnection! — see the Shipping types reference.

Terminal window
curl https://shipping.api.gist.link/graphql \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H 'Content-Type: application/json' \
-d @- <<'JSON'
{
"query": "query Shipments($filter: ShipmentFilter, $sort: SortInput, $first: Int, $after: String) { shipments(filter: $filter, sort: $sort, first: $first, after: $after) { totalCount edges { cursor node { uuid sourceApp sourceRef status createdAt } } } }",
"variables": {
"filter": {
"status": "example",
"sourceApp": "example",
"sourceRef": "example"
},
"sort": {
"field": "example",
"direction": "ASC"
},
"first": 10,
"after": "cursor"
}
}
JSON