Skip to main content
The tif1 CLI provides quick access to F1 data without writing Python code.

Installation

The CLI is included with tif1. Verify installation:

Global Options

These options work with all commands.

Commands

events

List all events (Grand Prix) for a given year.
Options:

sessions

List available sessions for a specific event.

laps

Fetch and display lap data.
Options: Examples:

telemetry

Fetch telemetry data for a specific lap.
Options: Examples:

drivers

List drivers in a session.
Options:

weather

Display weather data for a session.
Options:

compare

Compare lap times between drivers.
Options:

cache

Manage the local cache.
Subcommands: Examples:

config

Display or modify configuration.
Subcommands: Examples:

Output Formats

Most commands support multiple output formats.

JSON

CSV

Parquet

Piping and Scripting

The CLI is designed to work well in shell scripts.

Environment Variables

The CLI respects all tif1 environment variables.

Shell Completion

Enable tab completion in the shell.

Error Handling

The CLI provides clear error messages and exit codes.

Best Practices

Use Quotes

Always quote event names with spaces, for example "Monaco Grand Prix".

Export Large Data

Use --export instead of printing large datasets to the terminal.

Enable Caching

Keep the cache enabled for repeated queries.

Check Availability

Use events and sessions to verify that data exists first.
Last modified on September 3, 2026