Shipments
Adding Shipments

Adding Shipments

You can add shipments to TrackLogy two ways: through the dashboard UI or via the REST API.

Via the Dashboard

  1. Go to my.tracklogy.com (opens in a new tab) and log in
  2. Navigate to Shipments in the sidebar
  3. Click Add Shipment
  4. Enter the tracking number and optional details (carrier, customer info, order ID)
  5. Click Save — the shipment appears in your list and tracking begins immediately

Via the REST API

Use the POST /v1/shipments endpoint to create shipments programmatically.

Required Fields

  • tracking_number — The carrier-issued tracking number (string, required)

Optional but Recommended Fields

  • tracking_provider — Carrier slug (e.g. fedex, ups, dhl). If omitted, TrackLogy attempts auto-detection.
  • customer_email — Required for email notifications to fire
  • customer_phone — Required for SMS notifications to fire
  • order_id or order_number — Used in notification templates as {order_id}

Examples

curl -X POST https://api.tracklogy.com/v1/shipments \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "tracking_number": "9400111899223456789012",
    "tracking_provider": "usps",
    "customer_name": "John Doe",
    "customer_email": "[email protected]",
    "customer_phone": "+12125550100",
    "order_id": "ORD-5001",
    "order_number": "#5001",
    "destination_country": "US",
    "postal_code": "10001"
  }'

Success Response

{
  "success": true,
  "message": "Shipment created",
  "data": {
    "shipment": {
      "id": 42,
      "tracking_number": "9400111899223456789012",
      "tracking_provider": "usps",
      "status": "pending",
      "customer_name": "John Doe",
      "customer_email": "[email protected]",
      "order_id": "ORD-5001",
      "created_at": "2025-05-07T10:00:00Z"
    },
    "detected_tracking_provider": "usps"
  }
}

Error: Duplicate Tracking Number

If a shipment with the same tracking number already exists in your workspace, you'll receive:

{
  "success": false,
  "error": {
    "code": 409,
    "message": "A shipment with this tracking number already exists"
  }
}

Error: Tracker Balance Exhausted

{
  "success": false,
  "error": {
    "code": 402,
    "message": "Tracker balance is not available"
  },
  "data": {
    "billing": { ... }
  }
}

New shipments always start with status: "pending". The tracking engine updates the status asynchronously within minutes of creation.