Work from the terminal
Track parcels, watch one until it arrives, and script daily jobs with the trackified CLI.
The trackified CLI covers the API from your shell. This guide installs it, tracks a parcel end to end, and builds two small scripts.
- Install and sign in
brew install trackified/tap/trackified export TRACKIFIED_API_KEY=live_... trackified healthKeep the key in
TRACKIFIED_API_KEY. In versions 0.1.0 and 0.2.0,trackified loginrejects keys that start withlive_ortest_. - Track a parcel
trackified track 1Z999AA10123456784 --custom-id order_1042If the carrier can't be detected, ask which one it is, or pass a name:
trackified detect 1Z999AA10123456784 trackified track 9434650110837017316201 --carrier "USPS Priority Mail" - Watch it
trackified watch trk_... --interval 5mThis prints each new event until the parcel is delivered or returned. We check the carrier on our own schedule, every 30 minutes at the fastest, so a shorter interval rarely shows more.
- Look around
trackified list --status in_transit trackified get trk_... trackified usage
Script: exceptions report
Every command takes --json. This prints one line per parcel in exception, then asks for a fresh check on each:
#!/usr/bin/env bash
set -euo pipefail
trackified list --status exception --all --json |
jq -r '.[] | [.id, .custom_id // "-", .carrier, .tracking_number] | @tsv' |
while IFS=$'\t' read -r id custom carrier number; do
echo "$custom $carrier $number"
trackified retrack "$id" >/dev/null
doneScript: quota warning
#!/usr/bin/env bash
set -euo pipefail
left=$(trackified usage --json | jq '.trackings_remaining')
plan=$(trackified usage --json | jq -r '.plan')
if [ "$plan" != "scale" ] && [ "$left" -lt 50 ]; then
echo "Only $left trackings left this month" >&2
exit 1
fiOn Scale, trackings_remaining is always 0 because there's no monthly limit, hence the plan check.
Exit codes
Commands exit with 0 on success, 1 on an API error, and 2 on wrong usage, so set -e stops a script at the first failure. The CLI reference lists every command and flag.