EZToTrack Developers

Quick Start

Make your first API call in three steps.

  1. Get your API key

    You need an API key to authenticate requests. Get one from your administrator or create one via the admin API:

    POST http://localhost:5000/api/v2/api-keys
    Authorization: Bearer <your-jwt-token>
    Content-Type: application/json
    
    {
      "name": "My Integration",
      "scopes": ["vehicles:read", "drivers:read", "hos:read"]
    }

    Save the returned API key (prefixed with ezt_live_ or ezt_test_). It cannot be retrieved again.

  2. Make your first request

    Use your API key to list all vehicles in your fleet:

    curl -H "Authorization: Bearer ezt_live_abc123..." \
      https://publicapi.app.eztotrack.com/fleet/vehicles
    import requests
    
    API_KEY = "ezt_live_abc123..."
    BASE_URL = "https://publicapi.app.eztotrack.com"
    
    response = requests.get(
        f"{BASE_URL}/fleet/vehicles",
        headers={"Authorization": f"Bearer {API_KEY}"}
    )
    
    vehicles = response.json()
    for vehicle in vehicles["data"]:
        print(f"{vehicle['name']} — {vehicle['id']}")
    const API_KEY = "ezt_live_abc123...";
    const BASE_URL = "https://publicapi.app.eztotrack.com";
    
    const response = await fetch(`${BASE_URL}/fleet/vehicles`, {
      headers: { "Authorization": `Bearer ${API_KEY}` }
    });
    
    const { data } = await response.json();
    data.forEach(v => console.log(`${v.name} — ${v.id}`));
  3. Explore the response

    You'll receive a JSON response with your fleet vehicles:

    {
      "data": [
        {
          "id": "veh_12345",
          "name": "Truck 101",
          "make": "Freightliner",
          "model": "Cascadia",
          "year": 2023,
          "vin": "1FUJGBDV7PLKJ1234",
          "status": "active"
        }
      ],
      "pagination": {
        "endCursor": "eyJpZCI6MTIzNDV9",
        "hasNextPage": true
      }
    }

Next Steps

Authentication

Learn about API key scopes, error handling, and security best practices.

API Reference

Explore all available endpoints with interactive examples.