OwlMetry
CLI

CLI

Manage OwlMetry from the command line — query events, manage projects, and integrate with AI agents.

The OwlMetry CLI (@owlmetry/cli) lets you manage your OwlMetry instance from the terminal. Use it to query events, create and manage projects and apps, inspect metrics and funnels, and view audit logs. It also ships AI skill files that teach coding agents how to instrument and query OwlMetry.

Key capabilities

  • Query events with flexible filters, date ranges, and output formats
  • Manage resources — projects, apps, metrics, and funnels
  • Inspect metrics — view definitions, query aggregations, and browse raw metric events
  • Analyze funnels — run funnel queries with open/closed modes and experiment segmentation
  • Audit trail — review who did what across your team
  • Multi-team support — authenticate with multiple teams and switch between them
  • AI agent integration — bundled skill files for CLI, Node SDK, and Swift SDK

Global options

Every command accepts these global flags. They can be placed before or after the subcommand.

owlmetry [global options] <command> [command options]
FlagDescriptionDefault
--format <format>Output format: table, json, or logtable
--endpoint <url>OwlMetry API server URLFrom config or https://api.owlmetry.com
--api-key <key>API key (overrides config file)From config or OWLMETRY_API_KEY env var
--ingest-endpoint <url>Ingest endpoint URL (for SDK setup commands)Derived from API endpoint
--team <name-or-id>Use a specific team profile for this commandActive team from config
--versionPrint CLI version
--helpShow help for any command

Configuration resolution

The CLI resolves configuration in this order:

  1. Command-line flags (--endpoint, --api-key, --team)
  2. Environment variables (OWLMETRY_ENDPOINT, OWLMETRY_API_KEY)
  3. Config file (~/.owlmetry/config.json)

See Authentication for details on setting up the config file.

Output formats

The --format flag controls how results are displayed:

  • table (default) — human-readable tables with aligned columns
  • json — raw JSON, suitable for piping to jq or other tools
  • log — chronological log view, used by events and investigate commands
# Default table output
owlmetry events --since 1h

# JSON for scripting
owlmetry events --since 1h --format json

# Log view for event streams
owlmetry events --since 1h --format log

Ready to get started?

Install the CLI and let your agent handle the rest.