Skip to content
gist.link ↗

labels

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

The labels query on the Shipping API.

shipping:query:labels

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 {
labels(filter: LabelFilter, sort: SortInput, first: Int, after: String): LabelConnection!
}
Argument Type Required Description
filter LabelFilter No —
sort SortInput No —
first Int No —
after String No —

LabelConnection! — 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 Labels($filter: LabelFilter, $sort: SortInput, $first: Int, $after: String) { labels(filter: $filter, sort: $sort, first: $first, after: $after) { totalCount edges { cursor node { uuid carrier serviceLevel trackingNumber trackingUrl format status trackingStatus } } } }",
"variables": {
"filter": {
"status": "example",
"trackingStatus": "example",
"carrier": "example"
},
"sort": {
"field": "example",
"direction": "ASC"
},
"first": 10,
"after": "cursor"
}
}
JSON