Skip to main content

Logfire CLI

The Rust command-line interface for Pydantic Logfire. Sign in, query your traces and logs, manage projects and tokens, and connect your coding agent to Logfire from the terminal.

This package installs the native CLI, not the Python instrumentation SDK. Install an application SDK separately to send telemetry; see the Logfire documentation.

Install

Try it with uv:

uvx logfire-cli --help

Install it as an isolated command-line tool:

uv tool install logfire-cli
logfire --help

Or use pipx install logfire-cli. In an activated virtual environment, you can also run python -m pip install logfire-cli.

The package provides both logfire and logfire-cli. If another package already provides a logfire command, use logfire-cli or uvx logfire-cli to select this CLI explicitly.

Python 3.9 or newer is required for the launcher. Wheels include the matching prebuilt binary for macOS (ARM64 and x86-64), Windows (ARM64, x86, and x86-64), GNU/Linux (ARM64, ARMv7, x86, x86-64, PowerPC 64 LE, RISC-V 64, and IBM Z), and musl Linux (ARM64, ARMv6, ARMv7, x86, and x86-64). You do not need Rust installed. GNU/Linux requires glibc 2.17 or newer, except RISC-V 64, which requires glibc 2.31. The musl wheels support compatible Alpine Linux versions.

New to Logfire

From your application's directory, create an account, organization, and first project in one guided flow:

logfire --region us signup --org acme --project my-app
logfire --org acme project current

Replace acme and my-app with the real names you want. Use --region eu for the EU region. Browser OAuth credentials go to the operating system credential store; the project SDK credential stays under .logfire/ in your application.

Then add instrumentation with an installed coding agent:

logfire --org acme setup

Use an existing account

Use your real organization name in place of acme, and eu instead of us if your data is in the EU region:

logfire --region us --org acme auth
logfire --org acme mcp projects

Complete sign-in and approve access in your browser. OAuth credentials are stored in the OS credential store, scoped to the Logfire origin and organization.

Choose a project from the list, then query its data through the hosted Model Context Protocol (MCP) server:

logfire --org acme mcp query run 'SELECT message FROM records LIMIT 20' --project my-app

For scripts, make the target explicit and request non-interactive JSON output:

logfire --org acme --no-input --output json mcp projects

Connect a local project

From your application's directory, create or choose a project interactively:

logfire --org acme init

To connect an exact existing project without a picker:

logfire --org acme init use --name my-app --permission send
logfire project current

OAuth remains in the OS credential store; the SDK token stays with the local project. Keep credential files out of version control.

To create additional read or write tokens for that project:

logfire --org acme token read
logfire --org acme token write

Each command creates a new token and prints the secret once to standard output. Store it securely; do not paste it into logs, issues, or chat. These commands do not replace the project's saved SDK write token.

Run Python with automatic instrumentation

The CLI selects the active project interpreter and delegates instrumentation to the Logfire Python SDK installed in that environment:

logfire run app.py
logfire run -m uvicorn main:app
logfire run pytest tests/

Use --python .venv/bin/python when interpreter discovery is ambiguous. Run logfire help run for selection rules and passthrough behavior.

Set up instrumentation with a coding agent

With Codex or Claude Code installed, run this from your application's directory:

logfire --region us --org acme setup

The CLI detects installed agents and hands off the Logfire setup instructions bundled with this release. The agent can change your project to add instrumentation, using its normal permission and approval controls.

If you already know the exact project and setup task, pass them explicitly:

logfire --region us --org acme setup --project api --task instrumentation

Use bare setup when you want the CLI and agent to discover the task from the current directory.

To inspect the instructions without launching an agent:

logfire --region us --org acme setup --print-prompt

Help and updates

logfire help
logfire help mcp
logfire help setup
uv tool upgrade logfire-cli

Use the upgrade command for a uv tool install installation; otherwise upgrade with the package manager you used to install it.

See the Logfire documentation for application instrumentation and platform guides. Logfire CLI is licensed under the MIT license.

Release files for logfire-cli 0.1.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for logfire-cli 0.1.5
File
logfire_cli-0.1.5-py3-none-win_arm64.whl Python 3 none Windows ARM64 Details
logfire_cli-0.1.5-py3-none-win_amd64.whl Python 3 none Windows x86-64 Details
logfire_cli-0.1.5-py3-none-win32.whl Python 3 none Windows x86-32 Details
logfire_cli-0.1.5-py3-none-musllinux_1_2_x86_64.whl Python 3 none Linux musl 1.2+ x86-64 Details
logfire_cli-0.1.5-py3-none-musllinux_1_2_i686.whl Python 3 none Linux musl 1.2+ x86-32 Details
logfire_cli-0.1.5-py3-none-musllinux_1_2_armv7l.whl Python 3 none Linux musl 1.2+ ARMv7l Details
logfire_cli-0.1.5-py3-none-musllinux_1_2_aarch64.whl Python 3 none Linux musl 1.2+ ARM64 Details
logfire_cli-0.1.5-py3-none-manylinux_2_31_riscv64.whl Python 3 none Linux glibc 2.31+ RISC-V 64 Details
logfire_cli-0.1.5-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl Python 3 none Linux glibc 2.17+ x86-64 Details
logfire_cli-0.1.5-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl Python 3 none Linux glibc 2.17+ IBM System/390x Details
logfire_cli-0.1.5-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl Python 3 none Linux glibc 2.17+ PowerPC 64-le Details
logfire_cli-0.1.5-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl Python 3 none Linux glibc 2.17+ x86-32 Details
logfire_cli-0.1.5-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl Python 3 none Linux glibc 2.17+ ARMv7l Details
logfire_cli-0.1.5-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl Python 3 none Linux glibc 2.17+ ARM64 Details
logfire_cli-0.1.5-py3-none-macosx_11_0_arm64.whl Python 3 none macOS 11.0+ ARM64 Details
logfire_cli-0.1.5-py3-none-macosx_10_12_x86_64.whl Python 3 none macOS 10.12+ x86-64 Details
logfire_cli-0.1.5-py3-none-linux_armv6l.whl Python 3 none linux armv6l Details

Total release size: 55.8 MB

Release files / logfire_cli-0.1.5-py3-none-win_arm64.whl

Download URL logfire_cli-0.1.5-py3-none-win_arm64.whl
Size 2.7 MB
Tags Python 3 Windows ARM64
SHA-256 checksum
How to use checksums
3b7b38ea9e3ed35d20531a19678f5ca17d3e393157f5831b721b7e05797dbd98
BLAKE2b-256 checksum
How to use checksums
df46bcd4476154131fe8ba259d7ce157ccfc0192ac19a2459292ebb16a100dd8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-win_amd64.whl

Download URL logfire_cli-0.1.5-py3-none-win_amd64.whl
Size 2.9 MB
Tags Python 3 Windows x86-64
SHA-256 checksum
How to use checksums
70ebd8a97c20d077c36fbba52e7bdf7f614bf4ef557600284f2db8c5fbbaa6a7
BLAKE2b-256 checksum
How to use checksums
5f09af55b31a7da4fd77dd7758670970a8901c5ac2c9ba859004e728a191a810
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-win32.whl

Download URL logfire_cli-0.1.5-py3-none-win32.whl
Size 2.7 MB
Tags Python 3 Windows x86-32
SHA-256 checksum
How to use checksums
61fa2d632334fd80666d8c5d4f639a16c25274ee3f03ffbdf17e21cb6a09fce6
BLAKE2b-256 checksum
How to use checksums
15787ab11806f461b3e691484279418a50fa2f21d4075228aa28b007deee8bc7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-musllinux_1_2_x86_64.whl

Download URL logfire_cli-0.1.5-py3-none-musllinux_1_2_x86_64.whl
Size 3.7 MB
Tags Linux musl 1.2+ x86-64 Python 3
SHA-256 checksum
How to use checksums
03f695c2da03abbfbe50012826586723b09817ba65af7f2402bc68ec808afc26
BLAKE2b-256 checksum
How to use checksums
0cc71677ea62f4e3cf5f4a2396cff0162dbfd5a504b4764d95c921e3aedd9b20
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-musllinux_1_2_i686.whl

Download URL logfire_cli-0.1.5-py3-none-musllinux_1_2_i686.whl
Size 3.4 MB
Tags Linux musl 1.2+ x86-32 Python 3
SHA-256 checksum
How to use checksums
0bf4d564973040054686dedecc64361ece2c24e0fd4d85b0dc119466cb938ea8
BLAKE2b-256 checksum
How to use checksums
bca73087ad5b11071f68cb20305ad2ad6e6f2ac5ffa16c8f744c408eec88b4c9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-musllinux_1_2_armv7l.whl

Download URL logfire_cli-0.1.5-py3-none-musllinux_1_2_armv7l.whl
Size 3.3 MB
Tags Linux musl 1.2+ ARMv7l Python 3
SHA-256 checksum
How to use checksums
146fb5217b35a553e5483cb56e0ea51ab6e92625bb31f0a2f1a7a6ec7a1652fa
BLAKE2b-256 checksum
How to use checksums
55d11b113e26d6ad04488b39c0a071ba25b1e1c9a246a4d6d1dddc2d7137ab45
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-musllinux_1_2_aarch64.whl

Download URL logfire_cli-0.1.5-py3-none-musllinux_1_2_aarch64.whl
Size 3.5 MB
Tags Linux musl 1.2+ ARM64 Python 3
SHA-256 checksum
How to use checksums
d78a8c90f2e6bf57c641aed4ecc0f39c88c8b836fb990c3aed7d3ca5790ee0ff
BLAKE2b-256 checksum
How to use checksums
ddb6d181c4b6e3fab6124d133cbff4befe2ed6116e485b736956e4d6c9b5434c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-manylinux_2_31_riscv64.whl

Download URL logfire_cli-0.1.5-py3-none-manylinux_2_31_riscv64.whl
Size 3.4 MB
Tags Linux glibc 2.31+ RISC-V 64 Python 3
SHA-256 checksum
How to use checksums
a3ae74b842e4ec3a1ce5189108979b488d161e3f0e8a0b5e4718b9ce28840c63
BLAKE2b-256 checksum
How to use checksums
c7e061d9e5091ae7ec6ab1771df777977853e06b057fbdd648dfb57081cc5afd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL logfire_cli-0.1.5-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 3.7 MB
Tags Linux glibc 2.17+ x86-64 Python 3
SHA-256 checksum
How to use checksums
6a6888c86732f5e1858fdbc8dc2cf57cbffca66d6e852808faf53531d9fa091f
BLAKE2b-256 checksum
How to use checksums
c99b374036e4be76074e5c1740d1c6be6f11d736031a45ff3f4fa5b8014ceefd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl

Download URL logfire_cli-0.1.5-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl
Size 3.4 MB
Tags Linux glibc 2.17+ IBM System/390x Python 3
SHA-256 checksum
How to use checksums
af95fecfbf3f50221d348d9f8b58040431f096192c43a9290b1f16cf02f19228
BLAKE2b-256 checksum
How to use checksums
f9e601c0744df824a7ee65eb94b382367afbe7115c7f2a55bcb1f7ff3edaaf10
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl

Download URL logfire_cli-0.1.5-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Size 3.7 MB
Tags Linux glibc 2.17+ PowerPC 64-le Python 3
SHA-256 checksum
How to use checksums
f08324207e93637f198e25d3b361a7468d409941fbd26c6af4873f68f107493d
BLAKE2b-256 checksum
How to use checksums
4d01044368788d06106d068e8ac312ac9c4d40038bef5688fe655de681ddbdc9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl

Download URL logfire_cli-0.1.5-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl
Size 3.6 MB
Tags Linux glibc 2.17+ x86-32 Python 3
SHA-256 checksum
How to use checksums
307f451dae6a04accdddb734cf7cb2655877b9e95b2d009598952dedac30c631
BLAKE2b-256 checksum
How to use checksums
f3ef2e466abfe209e76e5f1c511e97361f07096e6c74127aaa46ce0f2fac2d6e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl

Download URL logfire_cli-0.1.5-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Size 3.2 MB
Tags Linux glibc 2.17+ ARMv7l Python 3
SHA-256 checksum
How to use checksums
c086c3fd652301e06546557f5a08089deca587afaccf53a9fd0fe31e99e9467f
BLAKE2b-256 checksum
How to use checksums
685d2264044348f39dc03de1898ed50086edc2be0404f42383cfe8d2e3820a19
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL logfire_cli-0.1.5-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 3.5 MB
Tags Linux glibc 2.17+ ARM64 Python 3
SHA-256 checksum
How to use checksums
38610d814c6522183f56f24fbcc4a5288b11bca7898cb8abe9ff218947a13704
BLAKE2b-256 checksum
How to use checksums
e97df579c5fc65b2e84c253e8c584d418fd9ae78ba7e766c4219420d13f323b9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-macosx_11_0_arm64.whl

Download URL logfire_cli-0.1.5-py3-none-macosx_11_0_arm64.whl
Size 2.7 MB
Tags Python 3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
0f452c8b2c22aefdc027dbe242e61198ecc85de8979865b861feee48c691d23b
BLAKE2b-256 checksum
How to use checksums
981c9b8493024e6912ac32697fc2f2b16501c13dfbeb8578e9b94cd952d2423f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-macosx_10_12_x86_64.whl

Download URL logfire_cli-0.1.5-py3-none-macosx_10_12_x86_64.whl
Size 2.9 MB
Tags Python 3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
f2864575865ee1d471c8415a3921375639e949ad76ba420a90a47320bbd52f9f
BLAKE2b-256 checksum
How to use checksums
9fc822a7b2b5759e1e3bd29376badd4f20952c2b358a7d346af96566f915984b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / logfire_cli-0.1.5-py3-none-linux_armv6l.whl

Download URL logfire_cli-0.1.5-py3-none-linux_armv6l.whl
Size 3.3 MB
Tags Python 3 linux armv6l
SHA-256 checksum
How to use checksums
747da3b9ca802a13732e9ffd991fb7b80eeec6ffd657d604c211d206b482a331
BLAKE2b-256 checksum
How to use checksums
9ad08b2824b1c51240f3451255ca5ba267981e1df79a6a7efa7cacd3e30dceee
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release history Release notifications | RSS feed

0.1.8

17 release files

0.1.7

17 release files

0.1.6

17 release files

This release

0.1.5 This release

17 release files

0.1.4

5 release files

0.1.3

5 release files

0.1.2

5 release files

0.1.1

5 release files

0.1.0

4 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page