Skip to content
Merged
Show file tree
Hide file tree
Changes from 9 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/src/content/docs/commands/dashboard.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ List dashboards
| Option | Description |
|--------|-------------|
| `-w, --web` | Open in browser |
| `-n, --limit <limit>` | Maximum number of dashboards to list (default: "30") |
| `-n, --limit <limit>` | Maximum number of dashboards to list (default: "25") |
| `-f, --fresh` | Bypass cache, re-detect projects, and fetch fresh data |
| `-c, --cursor <cursor>` | Navigate pages: "next", "prev", "first" (or raw cursor string) |

Expand Down
23 changes: 22 additions & 1 deletion docs/src/content/docs/commands/event.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ title: event
description: Event commands for the Sentry CLI
---

View Sentry events
View and list Sentry events

## Commands

Expand All @@ -25,6 +25,27 @@ View details of a specific event
| `--spans <spans>` | Span tree depth limit (number, "all" for unlimited, "no" to disable) (default: "3") |
| `-f, --fresh` | Bypass cache, re-detect projects, and fetch fresh data |

### `sentry event list <issue>`

List events for an issue

**Arguments:**

| Argument | Description |
|----------|-------------|
| `<issue>` | Issue: @latest, @most_frequent, &lt;org&gt;/ID, &lt;project&gt;-suffix, ID, or suffix |

**Options:**

| Option | Description |
|--------|-------------|
| `-n, --limit <limit>` | Number of events (1-1000) (default: "25") |
| `-q, --query <query>` | Search query (Sentry search syntax) |
| `--full` | Include full event body (stacktraces) |
| `-t, --period <period>` | Time period (e.g., "1h", "24h", "7d", "30d") (default: "7d") |
| `-f, --fresh` | Bypass cache, re-detect projects, and fetch fresh data |
| `-c, --cursor <cursor>` | Navigate pages: "next", "prev", "first" (or raw cursor string) |

All commands support `--json` for machine-readable output and `--fields` to select specific JSON fields.

<!-- GENERATED:END -->
Expand Down
2 changes: 1 addition & 1 deletion docs/src/content/docs/commands/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ The Sentry CLI provides commands for interacting with various Sentry resources.
| [`repo`](./repo/) | Work with Sentry repositories |
| [`team`](./team/) | Work with Sentry teams |
| [`issue`](./issue/) | Manage Sentry issues |
| [`event`](./event/) | View Sentry events |
| [`event`](./event/) | View and list Sentry events |
| [`log`](./log/) | View Sentry logs |
| [`sourcemap`](./sourcemap/) | Manage sourcemaps |
| [`span`](./span/) | List and view spans in projects or traces |
Expand Down
2 changes: 1 addition & 1 deletion docs/src/content/docs/commands/org.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ List organizations

| Option | Description |
|--------|-------------|
| `-n, --limit <limit>` | Maximum number of organizations to list (default: "30") |
| `-n, --limit <limit>` | Maximum number of organizations to list (default: "25") |
| `-f, --fresh` | Bypass cache, re-detect projects, and fetch fresh data |

### `sentry org view <org>`
Expand Down
2 changes: 1 addition & 1 deletion docs/src/content/docs/commands/project.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ List projects

| Option | Description |
|--------|-------------|
| `-n, --limit <limit>` | Maximum number of projects to list (default: "30") |
| `-n, --limit <limit>` | Maximum number of projects to list (default: "25") |
| `-p, --platform <platform>` | Filter by platform (e.g., javascript, python) |
| `-f, --fresh` | Bypass cache, re-detect projects, and fetch fresh data |
| `-c, --cursor <cursor>` | Navigate pages: "next", "prev", "first" (or raw cursor string) |
Expand Down
2 changes: 1 addition & 1 deletion docs/src/content/docs/commands/release.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ List releases

| Option | Description |
|--------|-------------|
| `-n, --limit <limit>` | Maximum number of releases to list (default: "30") |
| `-n, --limit <limit>` | Maximum number of releases to list (default: "25") |
| `-f, --fresh` | Bypass cache, re-detect projects, and fetch fresh data |
| `-c, --cursor <cursor>` | Navigate pages: "next", "prev", "first" (or raw cursor string) |

Expand Down
2 changes: 1 addition & 1 deletion docs/src/content/docs/commands/repo.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ List repositories

| Option | Description |
|--------|-------------|
| `-n, --limit <limit>` | Maximum number of repositories to list (default: "30") |
| `-n, --limit <limit>` | Maximum number of repositories to list (default: "25") |
| `-f, --fresh` | Bypass cache, re-detect projects, and fetch fresh data |
| `-c, --cursor <cursor>` | Navigate pages: "next", "prev", "first" (or raw cursor string) |

Expand Down
2 changes: 1 addition & 1 deletion docs/src/content/docs/commands/team.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ List teams

| Option | Description |
|--------|-------------|
| `-n, --limit <limit>` | Maximum number of teams to list (default: "30") |
| `-n, --limit <limit>` | Maximum number of teams to list (default: "25") |
| `-f, --fresh` | Bypass cache, re-detect projects, and fetch fresh data |
| `-c, --cursor <cursor>` | Navigate pages: "next", "prev", "first" (or raw cursor string) |

Expand Down
2 changes: 1 addition & 1 deletion docs/src/content/docs/commands/trace.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ List recent traces in a project

| Option | Description |
|--------|-------------|
| `-n, --limit <limit>` | Number of traces (1-1000) (default: "20") |
| `-n, --limit <limit>` | Number of traces (1-1000) (default: "25") |
| `-q, --query <query>` | Search query (Sentry search syntax) |
| `-s, --sort <sort>` | Sort by: date, duration (default: "date") |
| `-t, --period <period>` | Time period (e.g., "1h", "24h", "7d", "30d") (default: "7d") |
Expand Down
3 changes: 2 additions & 1 deletion plugins/sentry-cli/skills/sentry-cli/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -303,9 +303,10 @@ Manage Sentry issues

### Event

View Sentry events
View and list Sentry events

- `sentry event view <org/project/event-id...>` — View details of a specific event
- `sentry event list <issue>` — List events for an issue

→ Full flags and examples: `references/event.md`

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ List dashboards

**Flags:**
- `-w, --web - Open in browser`
- `-n, --limit <value> - Maximum number of dashboards to list - (default: "30")`
- `-n, --limit <value> - Maximum number of dashboards to list - (default: "25")`
- `-f, --fresh - Bypass cache, re-detect projects, and fetch fresh data`
- `-c, --cursor <value> - Navigate pages: "next", "prev", "first" (or raw cursor string)`

Expand Down
36 changes: 34 additions & 2 deletions plugins/sentry-cli/skills/sentry-cli/references/event.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
---
name: sentry-cli-event
version: 0.25.0-dev.0
description: View Sentry events
description: View and list Sentry events
requires:
bins: ["sentry"]
auth: true
---

# Event Commands

View Sentry events
View and list Sentry events

### `sentry event view <org/project/event-id...>`

Expand All @@ -20,6 +20,38 @@ View details of a specific event
- `--spans <value> - Span tree depth limit (number, "all" for unlimited, "no" to disable) - (default: "3")`
- `-f, --fresh - Bypass cache, re-detect projects, and fetch fresh data`

### `sentry event list <issue>`

List events for an issue

**Flags:**
- `-n, --limit <value> - Number of events (1-1000) - (default: "25")`
- `-q, --query <value> - Search query (Sentry search syntax)`
- `--full - Include full event body (stacktraces)`
- `-t, --period <value> - Time period (e.g., "1h", "24h", "7d", "30d") - (default: "7d")`
- `-f, --fresh - Bypass cache, re-detect projects, and fetch fresh data`
- `-c, --cursor <value> - Navigate pages: "next", "prev", "first" (or raw cursor string)`

**JSON Fields** (use `--json --fields` to select specific fields):

| Field | Type | Description |
|-------|------|-------------|
| `id` | string | Internal event ID |
| `event.type` | string | Event type (error, default, transaction) |
| `groupID` | string \| null | Group (issue) ID |
| `eventID` | string | UUID-format event ID |
| `projectID` | string | Project ID |
| `message` | string | Event message |
| `title` | string | Event title |
| `location` | string \| null | Source location (file:line) |
| `culprit` | string \| null | Culprit function/module |
| `user` | object \| null | User context |
| `tags` | array | Event tags |
| `platform` | string \| null | Platform (python, javascript, etc.) |
| `dateCreated` | string | ISO 8601 creation timestamp |
| `crashFile` | string \| null | Crash file URL |
| `metadata` | unknown \| null | Event metadata |

**Examples:**

```bash
Expand Down
2 changes: 1 addition & 1 deletion plugins/sentry-cli/skills/sentry-cli/references/org.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Work with Sentry organizations
List organizations

**Flags:**
- `-n, --limit <value> - Maximum number of organizations to list - (default: "30")`
- `-n, --limit <value> - Maximum number of organizations to list - (default: "25")`
- `-f, --fresh - Bypass cache, re-detect projects, and fetch fresh data`

### `sentry org view <org>`
Expand Down
2 changes: 1 addition & 1 deletion plugins/sentry-cli/skills/sentry-cli/references/project.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ sentry project delete my-org/old-project --yes
List projects

**Flags:**
- `-n, --limit <value> - Maximum number of projects to list - (default: "30")`
- `-n, --limit <value> - Maximum number of projects to list - (default: "25")`
- `-p, --platform <value> - Filter by platform (e.g., javascript, python)`
- `-f, --fresh - Bypass cache, re-detect projects, and fetch fresh data`
- `-c, --cursor <value> - Navigate pages: "next", "prev", "first" (or raw cursor string)`
Expand Down
2 changes: 1 addition & 1 deletion plugins/sentry-cli/skills/sentry-cli/references/release.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Work with Sentry releases
List releases

**Flags:**
- `-n, --limit <value> - Maximum number of releases to list - (default: "30")`
- `-n, --limit <value> - Maximum number of releases to list - (default: "25")`
- `-f, --fresh - Bypass cache, re-detect projects, and fetch fresh data`
- `-c, --cursor <value> - Navigate pages: "next", "prev", "first" (or raw cursor string)`

Expand Down
2 changes: 1 addition & 1 deletion plugins/sentry-cli/skills/sentry-cli/references/repo.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Work with Sentry repositories
List repositories

**Flags:**
- `-n, --limit <value> - Maximum number of repositories to list - (default: "30")`
- `-n, --limit <value> - Maximum number of repositories to list - (default: "25")`
- `-f, --fresh - Bypass cache, re-detect projects, and fetch fresh data`
- `-c, --cursor <value> - Navigate pages: "next", "prev", "first" (or raw cursor string)`

Expand Down
2 changes: 1 addition & 1 deletion plugins/sentry-cli/skills/sentry-cli/references/team.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Work with Sentry teams
List teams

**Flags:**
- `-n, --limit <value> - Maximum number of teams to list - (default: "30")`
- `-n, --limit <value> - Maximum number of teams to list - (default: "25")`
- `-f, --fresh - Bypass cache, re-detect projects, and fetch fresh data`
- `-c, --cursor <value> - Navigate pages: "next", "prev", "first" (or raw cursor string)`

Expand Down
2 changes: 1 addition & 1 deletion plugins/sentry-cli/skills/sentry-cli/references/trace.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ View distributed traces
List recent traces in a project

**Flags:**
- `-n, --limit <value> - Number of traces (1-1000) - (default: "20")`
- `-n, --limit <value> - Number of traces (1-1000) - (default: "25")`
- `-q, --query <value> - Search query (Sentry search syntax)`
- `-s, --sort <value> - Sort by: date, duration - (default: "date")`
- `-t, --period <value> - Time period (e.g., "1h", "24h", "7d", "30d") - (default: "7d")`
Expand Down
3 changes: 2 additions & 1 deletion src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import { cliRoute } from "./commands/cli/index.js";
import { dashboardRoute } from "./commands/dashboard/index.js";
import { listCommand as dashboardListCommand } from "./commands/dashboard/list.js";
import { eventRoute } from "./commands/event/index.js";
import { listCommand as eventListCommand } from "./commands/event/list.js";
import { helpCommand } from "./commands/help.js";
import { initCommand } from "./commands/init.js";
import { issueRoute } from "./commands/issue/index.js";
Expand Down Expand Up @@ -88,7 +89,7 @@ export const routes = buildRouteMap({
team: teamRoute,
issue: issueRoute,
event: eventRoute,
events: eventRoute,
events: eventListCommand,
Comment thread
BYK marked this conversation as resolved.
log: logRoute,
sourcemap: sourcemapRoute,
sourcemaps: sourcemapRoute,
Expand Down
9 changes: 6 additions & 3 deletions src/commands/event/index.ts
Original file line number Diff line number Diff line change
@@ -1,17 +1,20 @@
import { buildRouteMap } from "@stricli/core";
import { listCommand } from "./list.js";
import { viewCommand } from "./view.js";

export const eventRoute = buildRouteMap({
routes: {
view: viewCommand,
list: listCommand,
},
defaultCommand: "view",
aliases: { show: "view" },
docs: {
brief: "View Sentry events",
brief: "View and list Sentry events",
fullDescription:
"View detailed event data from Sentry. " +
"Use 'sentry event view <event-id>' to view a specific event.",
"View and list event data from Sentry.\n\n" +
"Use 'sentry event view <event-id>' to view a specific event.\n" +
"Use 'sentry event list <issue-id>' to list events for an issue.",
hideRoute: {},
},
});
Loading
Loading