
Bugsnag Cli
- 9 installs
- 2 repo stars
- Updated February 27, 2026
- yoanbernabeu/bugsnag-cli
Helps with ai & agent building tasks during AI-assisted development.
About
bugsnag-cli is a Claude Code skill for ai & agent building. It helps solo builders move faster with AI-assisted coding.
- bugsnag-cli
- AI & Agent Building
- AI-coding skill
Bugsnag Cli by the numbers
- 9 all-time installs (skills.sh)
- Ranked #12,152 of 16,546 AI & Agent Building skills by installs in the Skillselion catalog
- Data as of Jul 28, 2026 (Skillselion catalog sync)
npx skills add https://github.com/yoanbernabeu/bugsnag-cli --skill bugsnag-cliAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 9 |
|---|---|
| repo stars | ★ 2 |
| Last updated | February 27, 2026 |
| Repository | yoanbernabeu/bugsnag-cli ↗ |
What it does
Helps with ai & agent building tasks during AI-assisted development.
Files
bugsnag-cli
A fast, agent-friendly CLI for the Bugsnag Data Access API. Outputs JSON by default (ideal for agents and scripts), supports --format table for human reading.
When to read which reference
Pick the reference file that matches the user's intent:
| User intent | Reference file |
|---|---|
| Install, configure, authenticate, first steps | references/quickstart.md |
| Investigate a specific error (details, events, trends, comments) | references/investigate-error.md |
| Assess overall project health (error counts, trends, stability, releases) | references/project-health.md |
| Look up exact command syntax, flags, or options | references/command-reference.md |
If unsure, start with references/command-reference.md — it covers every command.
Quick overview
Authentication
Three methods (checked in this priority order):
1. Flag: --api-token TOKEN or -t TOKEN 2. Env var: BUGSNAG_API_TOKEN 3. Config file: ~/.bugsnag-cli.yaml (created via bugsnag configure --api-token TOKEN)
Available commands
| Command | Description |
|---|---|
bugsnag configure | Save auth token and defaults to config file |
bugsnag organizations list | List organizations |
bugsnag projects list/get | List or get project details |
bugsnag errors list/get | List errors with filters, or get error details |
bugsnag events list/get | List event occurrences, or get event details |
bugsnag trends project/error | View error trends over time |
bugsnag collaborators list | List organization collaborators |
bugsnag comments list/create | List or add comments on errors |
bugsnag releases list | List project releases |
bugsnag stability trend | View crash-free session rate |
bugsnag version | Print CLI version |
Global flags
| Flag | Short | Default | Description |
|---|---|---|---|
--api-token | -t | — | Bugsnag API token |
--format | -f | json | Output format: json or table |
--per-page | — | 30 | Results per page (1-100) |
--all-pages | -a | false | Fetch all pages |
--base-url | — | https://api.bugsnag.com | API base URL |
--config | — | ~/.bugsnag-cli.yaml | Config file path |
Output format
JSON lists return: {"data": [...], "total_count": N, "has_more": bool}
Single items return the object directly. Errors go to stderr as {"error": "..."}.
Exit codes
| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | General error |
| 2 | Configuration error (missing token/flag) |
| 3 | API error (401, 403, 404, 500) |
| 4 | Network error (timeout, DNS, connection refused) |
Common workflows
First setup:
bugsnag configure --api-token TOKEN
bugsnag organizations list
bugsnag projects list --org-id ORG_IDInvestigate an error: read references/investigate-error.md
Project health check: read references/project-health.md
Need exact flag syntax: read references/command-reference.md
bugsnag-cli Command Reference
Complete reference for all commands. All flags verified against actual CLI help output (v0.1.0).
Global Flags
| Flag | Short | Default | Env Var | Description |
|---|---|---|---|---|
--api-token | -t | — | BUGSNAG_API_TOKEN | Bugsnag API token |
--format | -f | json | BUGSNAG_FORMAT | Output format: json or table |
--per-page | — | 30 | BUGSNAG_PER_PAGE | Results per page (1-100) |
--all-pages | -a | false | — | Fetch all pages |
--base-url | — | https://api.bugsnag.com | BUGSNAG_BASE_URL | API base URL |
--config | — | ~/.bugsnag-cli.yaml | — | Config file path |
Auth priority: Flag > Env var > Config file.
---
configure
Save configuration to ~/.bugsnag-cli.yaml (permissions 0600).
bugsnag configure --api-token TOKEN [--default-format FORMAT] [--default-per-page N] [--default-base-url URL]| Flag | Required | Description |
|---|---|---|
--api-token, -t | Yes | API token to save |
--default-format | No | Default output format (json or table) |
--default-per-page | No | Default results per page |
--default-base-url | No | Default API base URL |
---
organizations list
List organizations for the authenticated user.
bugsnag organizations listNo additional flags.
---
projects list
bugsnag projects list --org-id ORG_ID| Flag | Required | Description |
|---|---|---|
--org-id | Yes | Organization ID |
projects get
bugsnag projects get --project-id PROJECT_ID| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
---
errors list
bugsnag errors list --project-id ID [--status STATUS] [--severity SEV] [--sort FIELD] [--direction DIR]| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
--status | No | Filter: open, fixed, snoozed, ignored |
--severity | No | Filter: info, warning, error |
--sort | No | Sort by: created_at, last_seen, events, users, unsorted |
--direction | No | Sort direction: asc, desc |
errors get
bugsnag errors get --project-id ID --error-id ERROR_ID| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
--error-id | Yes | Error ID |
---
events list
bugsnag events list --project-id ID [--error-id ERROR_ID]| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
--error-id | No | Scope events to a specific error |
events get
bugsnag events get --project-id ID --event-id EVENT_ID| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
--event-id | Yes | Event ID |
---
trends project
bugsnag trends project --project-id ID [--resolution RES] [--buckets-count N]| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
--resolution | No | Time resolution (e.g., 1h, 1d) |
--buckets-count | No | Number of trend buckets |
trends error
bugsnag trends error --project-id ID --error-id ERROR_ID| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
--error-id | Yes | Error ID |
Important: trends error does NOT accept --resolution or --buckets-count.
---
collaborators list
bugsnag collaborators list --org-id ORG_ID| Flag | Required | Description |
|---|---|---|
--org-id | Yes | Organization ID |
---
comments list
bugsnag comments list --project-id ID --error-id ERROR_ID| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
--error-id | Yes | Error ID |
comments create
bugsnag comments create --project-id ID --error-id ERROR_ID --message "Your comment"| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
--error-id | Yes | Error ID |
--message | Yes | Comment text |
---
releases list
bugsnag releases list --project-id ID| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
---
stability trend
bugsnag stability trend --project-id ID [--release-stage STAGE]| Flag | Required | Description |
|---|---|---|
--project-id | Yes | Project ID |
--release-stage | No | Release stage (e.g., production, staging) |
---
version
bugsnag version---
Output Format
JSON (default)
Lists: {"data": [...], "total_count": N, "has_more": bool}
Single items: object directly (no envelope).
Errors on stderr: {"error": "API error (401): Bad Credentials"}
Table
Use --format table for human-readable columnar output.
---
Exit Codes
| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | General error |
| 2 | Configuration error (missing token, missing required flag) |
| 3 | API error (HTTP 401, 403, 404, 500, etc.) |
| 4 | Network error (timeout, DNS failure, connection refused) |
Investigate a Bugsnag Error
Complete error investigation workflow — from "something is broken" to understanding the error's scope, history, and details.
Prerequisites
- bugsnag-cli configured with a valid API token
- A project ID (run
bugsnag projects list --org-id ORG_IDto find it)
Investigation Workflow
Step 1: Find the Error
List errors with filters to narrow down what you're looking for:
# All open errors, sorted by most recent
bugsnag errors list --project-id PROJECT_ID --status open --sort last_seen --direction desc
# Only critical errors
bugsnag errors list --project-id PROJECT_ID --severity error --status open
# All errors across every page
bugsnag errors list --project-id PROJECT_ID --all-pagesAvailable filters:
--status: open, fixed, snoozed, ignored--severity: info, warning, error--sort: created_at, last_seen, events, users, unsorted--direction: asc, desc
Step 2: Get Error Details
bugsnag errors get --project-id PROJECT_ID --error-id ERROR_IDReturns full error details: class, message, context, severity, status, metadata.
Step 3: Examine Events (Occurrences)
Each error groups multiple event occurrences. Events contain stack traces, request data, device info, and custom metadata — this is where the actual debugging details live.
# List events for this specific error
bugsnag events list --project-id PROJECT_ID --error-id ERROR_ID
# Get full details of a specific event
bugsnag events get --project-id PROJECT_ID --event-id EVENT_IDStep 4: Check Error Trends
bugsnag trends error --project-id PROJECT_ID --error-id ERROR_IDShows event counts bucketed by time period. Look for:
- Spikes — sudden increase, possibly tied to a deploy
- Sustained increases — growing problem
- Drops — a fix is working
Important: trends error does NOT accept --resolution or --buckets-count (only trends project does).
Step 5: Read Existing Comments
bugsnag comments list --project-id PROJECT_ID --error-id ERROR_IDStep 6: Document Your Findings
bugsnag comments create --project-id PROJECT_ID --error-id ERROR_ID \
--message "Investigated: root cause is X. Fix planned in PR #123."Quick Investigation Script
Gather all info at once:
PROJECT_ID="your-project-id"
ERROR_ID="your-error-id"
# Error overview
bugsnag errors get --project-id "$PROJECT_ID" --error-id "$ERROR_ID"
# Recent events (stack traces)
bugsnag events list --project-id "$PROJECT_ID" --error-id "$ERROR_ID"
# Trend
bugsnag trends error --project-id "$PROJECT_ID" --error-id "$ERROR_ID"
# Existing comments
bugsnag comments list --project-id "$PROJECT_ID" --error-id "$ERROR_ID"Tips
- Use
--format tablefor quick human review during investigation - Use JSON (default) when parsing results programmatically
- Event details are the most valuable for debugging — they contain stack traces
--all-pagesis useful when an error has many events to review
Bugsnag Project Health Assessment
Assess the overall health of a project — error counts, trends, stability, and release status.
Prerequisites
- bugsnag-cli configured with a valid API token
- A project ID (run
bugsnag projects list --org-id ORG_IDto find it)
Health Assessment Workflow
Step 1: Project Overview
bugsnag projects get --project-id PROJECT_IDStep 2: Error Summary
# Open errors sorted by impact (most events first)
bugsnag errors list --project-id PROJECT_ID --status open --sort events --direction desc
# Critical errors only
bugsnag errors list --project-id PROJECT_ID --status open --severity error
# All open errors across all pages
bugsnag errors list --project-id PROJECT_ID --status open --all-pagesParse the JSON envelope for total counts:
bugsnag errors list --project-id PROJECT_ID --status open | jq '.total_count'Step 3: Error Trends
# Daily trend — 2 weeks
bugsnag trends project --project-id PROJECT_ID --resolution 1d --buckets-count 14
# Hourly trend — last 24h
bugsnag trends project --project-id PROJECT_ID --resolution 1h --buckets-count 24--resolution and --buckets-count are only available on trends project (not trends error).
Look for:
- Spikes — sudden increase, check recent releases
- Sustained increases — growing problem
- Drops after deployments — fixes working
Step 4: Stability Metrics
# Overall stability
bugsnag stability trend --project-id PROJECT_ID
# Production only
bugsnag stability trend --project-id PROJECT_ID --release-stage production--release-stage is optional and accepts any stage name (production, staging, development, etc.).
Step 5: Recent Releases
bugsnag releases list --project-id PROJECT_IDCompare release timestamps with error trend spikes to identify regressions.
Step 6: Team Activity
bugsnag organizations list
bugsnag collaborators list --org-id ORG_IDQuick Health Check Script
PROJECT_ID="your-project-id"
bugsnag projects get --project-id "$PROJECT_ID"
bugsnag errors list --project-id "$PROJECT_ID" --status open | jq '.total_count'
bugsnag errors list --project-id "$PROJECT_ID" --status open --severity error --format table
bugsnag trends project --project-id "$PROJECT_ID" --resolution 1d --buckets-count 14
bugsnag stability trend --project-id "$PROJECT_ID" --release-stage production
bugsnag releases list --project-id "$PROJECT_ID" --format tableInterpreting Results
- Error count trending up — new bugs introduced, check recent releases
- Stability dropping — critical, likely a regression in a recent deploy
- High event count on a single error — one error dominating, prioritize it
- Many open errors with low event count — noise, consider snoozing old low-impact errors
Bugsnag CLI — Quick Start
Prerequisites
The bugsnag binary must be available in PATH. Installation options:
# Via Go
go install github.com/yoanbernabeu/bugsnag-cli@latest
# Or one-liner install script
curl -fsSL https://raw.githubusercontent.com/yoanbernabeu/bugsnag-cli/main/install.sh | shStep 1: Get an API Token
1. Log in to https://app.bugsnag.com 2. Go to Settings > My account > Auth tokens 3. Generate a new token (shown only once — store it safely)
Step 2: Configure Authentication
Three ways to authenticate (checked in this priority order):
| Priority | Method | How |
|---|---|---|
| 1 | Flag | --api-token TOKEN or -t TOKEN on every command |
| 2 | Env var | export BUGSNAG_API_TOKEN=TOKEN |
| 3 | Config file | bugsnag configure --api-token TOKEN (saves to ~/.bugsnag-cli.yaml) |
The recommended approach for persistent use:
bugsnag configure --api-token YOUR_TOKENOptional: set defaults for format, pagination, and base URL:
bugsnag configure --api-token YOUR_TOKEN \
--default-format table \
--default-per-page 50 \
--default-base-url https://api.bugsnag.comThe config file is written with mode 0600 (readable only by the owner).
Step 3: Verify Setup
# List organizations — confirms auth works
bugsnag organizations list
# List projects for an org
bugsnag projects list --org-id ORG_IDStep 4: Explore Your Data
# List errors for a project (JSON)
bugsnag errors list --project-id PROJECT_ID
# Human-readable output
bugsnag errors list --project-id PROJECT_ID --format table
# Fetch all pages at once
bugsnag errors list --project-id PROJECT_ID --all-pages
# Filter to critical open errors
bugsnag errors list --project-id PROJECT_ID --status open --severity errorTypical First Session
1. bugsnag configure --api-token TOKEN — save credentials 2. bugsnag organizations list — find your org ID 3. bugsnag projects list --org-id ORG_ID — find your project ID 4. bugsnag errors list --project-id PROJECT_ID --format table — see recent errors 5. bugsnag errors list --project-id PROJECT_ID --status open --severity error — filter to critical open errors
Environment Variables
| Env Var | Maps to |
|---|---|
BUGSNAG_API_TOKEN | --api-token |
BUGSNAG_FORMAT | --format |
BUGSNAG_PER_PAGE | --per-page |
BUGSNAG_BASE_URL | --base-url |