Trifle CLI

Your metrics, one command away.

Query, push, and aggregate metrics from your terminal. MCP server mode turns your CLI into an AI agent tool.

Everything you need in a single binary

Trifle CLI is a Swiss Army knife for your metrics. Query, push, and analyze data without leaving the terminal.

Query Metrics

Pull time-series data for any key. Filter by granularity, date range, and value path.

Push Data

Track events directly from the terminal or shell scripts. Pipe-friendly for automation.

Aggregate

View aggregated totals across time ranges. Perfect for quick analysis.

Timeline View

See your metrics over time in a clean table format right in your terminal.

Category View

Break down hierarchical data by categories. See country, channel, or any nested dimension.

Multiple Formats

Output as table (human-friendly), JSON (for APIs), or CSV (for spreadsheets). Pipe into jq, awk, or any tool.

Key Feature

AI agents that understand your metrics

Run trifle mcp to start an MCP server. AI coding agents like Claude, Cursor, or Copilot can query your metrics while having full context of your code.

  • Context-aware analysis

    Agents see your code and your metrics at the same time

  • Natural language queries

    Ask "how did orders trend last week?" and get real answers

  • Works with Claude, Cursor, Copilot

    Standard MCP protocol works with any compatible agent

{
  "mcpServers": {
    "trifle": {
      "command": "trifle",
      "args": ["mcp"]
    }
  }
}

Add this to your Claude, Cursor, or Copilot MCP configuration and your AI agent can query Trifle metrics directly.

$ trifle track --key tests \
    --values '{"passed": 42, "failed": 3}'

Tracked successfully.
Driver: sqlite (./trifle.db)
Key:    tests
At:     2026-02-14T10:30:00Z

$ trifle metrics timeline --key tests \
    --format table

at                                passed  failed
--------------------------------  ------  ------
2026-02-14T10:00:00.000000+00:00  42      3

Local SQLite driver, no server needed

Run any Trifle command and it automatically creates a local SQLite database. No configuration files, no server setup, no environment variables. It just works.

Automatic database creation

A trifle.db file is created in your working directory on first use

Perfect for local development

Track metrics during development without setting up infrastructure

CI/CD ready

Track test results, build times, and deploy metrics in your pipelines

Your data, your format

Same data, three output formats. Pick what fits your workflow or pipe it into other tools.

Table --format table
at                  count
------------------  -----
2026-02-09T07:00Z   246
2026-02-09T08:00Z   112
2026-02-09T09:00Z   88
2026-02-09T10:00Z   53
JSON --format json
[
  {
    "at": "2026-02-09T07:00Z",
    "count": 246
  },
  {
    "at": "2026-02-09T08:00Z",
    "count": 112
  }
]
CSV --format csv
at,count
2026-02-09T07:00Z,246
2026-02-09T08:00Z,112
2026-02-09T09:00Z,88
2026-02-09T10:00Z,53

Pipe JSON into jq, CSV into awk, or table straight to your eyes.

Install in seconds

Choose your preferred installation method. Single binary, no dependencies.

# Install via Homebrew
$ brew install trifle-io/tap/trifle
# Install with Go
$ go install github.com/trifle-io/trifle@latest
# Download binary
$ curl -sSL https://get.trifle.io | sh

Trifle App API or standalone local SQLite

Connect to the cloud for team dashboards, or run fully offline with zero configuration.

Cloud

Connect to app.trifle.io for team dashboards, alerts, digests, and AI chat. Your CLI pushes data to the same place your team views it.

$ trifle config set driver api
$ trifle config set api-token $TOKEN

Local

Zero-config SQLite driver. No account, no server, no internet required. Great for development, CI/CD pipelines, and prototyping.

# No config needed. Just run:
$ trifle track --key deploys --values '{"count":1}'

Install in 30 seconds

One command to install. One command to track. Zero config required.

$ brew install trifle-io/tap/trifle
Single binary | Zero dependencies | MIT License