# Terminal CLI

> Query fleet telematics data using the Terminal CLI - vehicles, drivers, safety events, HOS, trips, locations, and more Use when this capability is needed.

- Skill: `tomevault-io/terminal-cli` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add tomevault-io/terminal-cli`
- Raw SKILL.md: https://api.skillmd.com/api/skills/tomevault-io/terminal-cli/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Integrations & APIs
- Author: tomevault-io (https://skillmd.com/u/tomevault-io)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/tomevault-io/terminal-cli

---


# Terminal CLI

Terminal is a unified API for fleet telematics data. It connects to various Telematics Service Providers (TSPs) and normalizes data across vehicles, drivers, safety events, hours of service, trips, and more.

The `terminal` CLI lets you query this data from the command line.

## When to Use This Skill

Use this skill when the user asks about:

- Vehicle locations, trips, or movement
- Driver information or activity
- Safety events (harsh braking, speeding, collisions)
- Hours of Service (HOS) logs or violations
- Fault codes or vehicle diagnostics
- IFTA fuel tax summaries
- Fleet or telematics data in general

## Prerequisites

Before running queries, verify the CLI is configured:

```bash
terminal config show
```

Most commands require a **connection token** which identifies the specific fleet/TSP connection. If not configured, ask the user to provide one:

```bash
terminal config set connection-token con_tkn_xxx
```

## Available CLI Commands

### Vehicles

- `terminal list-vehicles` - List all vehicles
- `terminal get-vehicle --id <vehicle_id>` - Get specific vehicle details
- `terminal list-latest-vehicle-locations` - Current vehicle locations
- `terminal list-historical-vehicle-locations --vehicle-id <id> --start-at <iso_date> --end-at <iso_date>` - Historical locations
- `terminal list-historical-vehicle-stats --vehicle-id <id> --start-at <iso_date> --end-at <iso_date>` - Historical stats (odometer, fuel, engine hours)

### Drivers

- `terminal list-drivers` - List all drivers
- `terminal get-driver --id <driver_id>` - Get specific driver

### Safety

- `terminal list-safety-events` - List safety events (harsh braking, speeding, etc.)
- `terminal get-safety-event --id <event_id>` - Get specific safety event details
- `terminal get-event-camera-media --event-id <id>` - Get camera footage for an event

### Hours of Service (HOS)

- `terminal list-hoslogs` - List HOS log entries
- `terminal list-hosdaily-logs` - List daily HOS summaries
- `terminal list-hosavailable-time` - Get available driving time for drivers

### Trips

- `terminal list-trips` - List historical trips with start/end locations, distance, duration

### Fault Codes

- `terminal list-fault-code-events` - List vehicle fault code events (check engine lights, diagnostic codes)

### IFTA

- `terminal get-iftasummary --start-month <YYYY-MM> --end-month <YYYY-MM>` - Get IFTA fuel tax summary by jurisdiction

### Trailers

- `terminal list-trailers` - List trailers
- `terminal list-latest-trailer-locations` - Current trailer locations

### Devices

- `terminal list-devices` - List ELD/telematics devices

### Groups

- `terminal list-groups` - List vehicle/driver groups

### Issues

- `terminal list-issues` - List data sync issues
- `terminal resolve-issue --id <issue_id>` - Resolve an issue

### Connections

- `terminal list-connections` - List all TSP connections
- `terminal get-current-connection` - Get current connection details

### Providers

- `terminal list-providers` - List available TSP providers (no connection token required)

## Common Options

All list commands support:

- `--format json|pretty|table` - Output format (default: json)
- `--all` - Auto-paginate to fetch all results
- `--limit <n>` - Limit results per page
- `--cursor <cursor>` - Pagination cursor

Date filtering (where supported):

- `--start-at <iso_date>` - Start date (ISO 8601 format)
- `--end-at <iso_date>` - End date (ISO 8601 format)
- `--modified-after <iso_date>` - Filter by modification date

## Example Queries

**"How many safety events for driver X this week?"**

```bash
terminal list-safety-events --driver-id drv_xxx --start-at 2024-01-01T00:00:00Z --format table
```

**"Where was vehicle ABC on January 2nd?"**

```bash
terminal list-historical-vehicle-locations --vehicle-id vcl_xxx --start-at 2024-01-02T00:00:00Z --end-at 2024-01-02T23:59:59Z --format table
```

**"Which vehicles have active movement?"**

```bash
terminal list-latest-vehicle-locations --format table
```

Then filter for vehicles with recent timestamps and non-zero speed.

**"Show all HOS violations"**

```bash
terminal list-hoslogs --format table
```

Then filter for violation entries.

**"What's the IFTA summary for Q4?"**

```bash
terminal get-iftasummary --start-month 2024-10 --end-month 2024-12 --format pretty
```

## Workflow

1. First, verify CLI configuration with `terminal config show`
2. If connection token is missing, ask user to provide it
3. Run appropriate query command(s)
4. Parse JSON output to answer the user's question
5. If data needs filtering/aggregation, process the results
6. Present findings clearly with relevant details

## Troubleshooting

If commands fail:

- Check `terminal config show` for configuration
- Verify API key is set: `terminal config set api-key sk_xxx`
- Verify connection token is set: `terminal config set connection-token con_tkn_xxx`
- Use `--format pretty` for readable error messages
- Try `terminal list-providers` (no auth required) to test connectivity

---
> Converted and distributed by [TomeVault](https://tomevault.io/claim/terminal-api) — claim your Tome and manage your conversions.
<!-- tomevault:4.0:skill_md:2026-04-13 -->

