KosmoKrator

monitoring

Sentry CLI for AI Agents

Use the Sentry CLI from KosmoKrator to call Sentry tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.

7 functions 6 read 1 write API token auth

Sentry CLI Setup

Sentry can be configured headlessly with `kosmokrator integrations:configure sentry`.

# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash

# Configure and verify this integration.
kosmokrator integrations:configure sentry --set auth_token="$SENTRY_AUTH_TOKEN" --enable --read allow --write ask --json
kosmokrator integrations:doctor sentry --json
kosmokrator integrations:status --json

Credentials

Authentication type: API token api_token. Configure credentials once, then use the same stored profile from scripts, coding CLIs, Lua code mode, and the MCP gateway.

KeyEnv varTypeRequiredLabel
auth_token SENTRY_AUTH_TOKEN Secret secret yes Auth Token
url SENTRY_URL URL url no Sentry API URL

Call Sentry Headlessly

Use the generic call form when another coding CLI or script needs a stable universal interface.

kosmo integrations:call sentry.sentry_list_projects '{
  "query": "example_query"
}' --json

Use the provider shortcut form for shorter human-facing commands.

kosmo integrations:sentry sentry_list_projects '{
  "query": "example_query"
}' --json

Agent Discovery Commands

These commands return structured output for coding agents that need to inspect capabilities before choosing a function.

kosmo integrations:docs sentry --json
kosmo integrations:docs sentry.sentry_list_projects --json
kosmo integrations:schema sentry.sentry_list_projects --json
kosmo integrations:search "Sentry" --json
kosmo integrations:list --json

All CLI Functions

Every function below can be called headlessly. The generic form is stable across all integrations; the provider shortcut is shorter but specific to Sentry.

sentry.sentry_list_projects

Read read

List all Sentry projects accessible to the authenticated user. Returns project slugs, organization slugs, and platforms for use in other Sentry tools.

Parameters
query

Generic CLI call

kosmo integrations:call sentry.sentry_list_projects '{"query":"example_query"}' --json

Provider shortcut

kosmo integrations:sentry sentry_list_projects '{"query":"example_query"}' --json

sentry.sentry_get_project

Read read

Get detailed information about a specific Sentry project, including its slug, platform, team assignments, and error statistics.

Parameters
org_slug, project_slug

Generic CLI call

kosmo integrations:call sentry.sentry_get_project '{"org_slug":"example_org_slug","project_slug":"example_project_slug"}' --json

Provider shortcut

kosmo integrations:sentry sentry_get_project '{"org_slug":"example_org_slug","project_slug":"example_project_slug"}' --json

sentry.sentry_list_issues

Read read

List issues (errors) for a specific Sentry project. Supports filtering by status, query, sorting, and time range. Returns issue IDs, titles, counts, and severity.

Parameters
org_slug, project_slug, query, sort, limit

Generic CLI call

kosmo integrations:call sentry.sentry_list_issues '{"org_slug":"example_org_slug","project_slug":"example_project_slug","query":"example_query","sort":"example_sort","limit":1}' --json

Provider shortcut

kosmo integrations:sentry sentry_list_issues '{"org_slug":"example_org_slug","project_slug":"example_project_slug","query":"example_query","sort":"example_sort","limit":1}' --json

sentry.sentry_get_issue

Read read

Get detailed information about a specific Sentry issue, including the error message, stacktrace, tags, event count, and affected users.

Parameters
issue_id

Generic CLI call

kosmo integrations:call sentry.sentry_get_issue '{"issue_id":"example_issue_id"}' --json

Provider shortcut

kosmo integrations:sentry sentry_get_issue '{"issue_id":"example_issue_id"}' --json

sentry.sentry_list_releases

Read read

List releases for a specific Sentry project. Returns version strings, deployment dates, authors, and commit information.

Parameters
org_slug, project_slug, limit

Generic CLI call

kosmo integrations:call sentry.sentry_list_releases '{"org_slug":"example_org_slug","project_slug":"example_project_slug","limit":1}' --json

Provider shortcut

kosmo integrations:sentry sentry_list_releases '{"org_slug":"example_org_slug","project_slug":"example_project_slug","limit":1}' --json

sentry.sentry_create_issue

Write write

Create a new issue (user report or crash report) in a Sentry project. Requires the error message and optional metadata like stacktrace, tags, and user context.

Parameters
org_slug, project_slug, title, message, level, tags, extra

Generic CLI call

kosmo integrations:call sentry.sentry_create_issue '{"org_slug":"example_org_slug","project_slug":"example_project_slug","title":"example_title","message":"example_message","level":"example_level","tags":"example_tags","extra":"example_extra"}' --json

Provider shortcut

kosmo integrations:sentry sentry_create_issue '{"org_slug":"example_org_slug","project_slug":"example_project_slug","title":"example_title","message":"example_message","level":"example_level","tags":"example_tags","extra":"example_extra"}' --json

sentry.sentry_get_current_user

Read read

Get the currently authenticated Sentry user. Returns user name, email, and organization memberships. Useful for verifying the connection and identifying which Sentry account is being used.

Parameters
none

Generic CLI call

kosmo integrations:call sentry.sentry_get_current_user '{}' --json

Provider shortcut

kosmo integrations:sentry sentry_get_current_user '{}' --json

Function Schemas

Use these parameter tables when building CLI payloads without calling integrations:schema first.

sentry.sentry_list_projects

List all Sentry projects accessible to the authenticated user. Returns project slugs, organization slugs, and platforms for use in other Sentry tools.

Operation
Read read
Schema command
kosmo integrations:schema sentry.sentry_list_projects --json
ParameterTypeRequiredDescription
query string no Filter projects by name or slug.

sentry.sentry_get_project

Get detailed information about a specific Sentry project, including its slug, platform, team assignments, and error statistics.

Operation
Read read
Schema command
kosmo integrations:schema sentry.sentry_get_project --json
ParameterTypeRequiredDescription
org_slug string yes The organization slug (e.g., "my-org").
project_slug string yes The project slug (e.g., "my-project").

sentry.sentry_list_issues

List issues (errors) for a specific Sentry project. Supports filtering by status, query, sorting, and time range. Returns issue IDs, titles, counts, and severity.

Operation
Read read
Schema command
kosmo integrations:schema sentry.sentry_list_issues --json
ParameterTypeRequiredDescription
org_slug string yes The organization slug (e.g., "my-org").
project_slug string yes The project slug (e.g., "my-project").
query string no Search query to filter issues (e.g., "is:unresolved level:error").
sort string no Sort order: "date" (default), "freq", "new", "priority".
limit integer no Maximum number of issues to return (default: 25, max: 100).

sentry.sentry_get_issue

Get detailed information about a specific Sentry issue, including the error message, stacktrace, tags, event count, and affected users.

Operation
Read read
Schema command
kosmo integrations:schema sentry.sentry_get_issue --json
ParameterTypeRequiredDescription
issue_id string yes The Sentry issue ID (e.g., "1234567890").

sentry.sentry_list_releases

List releases for a specific Sentry project. Returns version strings, deployment dates, authors, and commit information.

Operation
Read read
Schema command
kosmo integrations:schema sentry.sentry_list_releases --json
ParameterTypeRequiredDescription
org_slug string yes The organization slug (e.g., "my-org").
project_slug string yes The project slug (e.g., "my-project").
limit integer no Maximum number of releases to return (default: 25, max: 100).

sentry.sentry_create_issue

Create a new issue (user report or crash report) in a Sentry project. Requires the error message and optional metadata like stacktrace, tags, and user context.

Operation
Write write
Schema command
kosmo integrations:schema sentry.sentry_create_issue --json
ParameterTypeRequiredDescription
org_slug string yes The organization slug (e.g., "my-org").
project_slug string yes The project slug (e.g., "my-project").
title string yes Short description of the issue (the error message or title).
message string no Full error message or stacktrace.
level string no Severity level: "fatal", "error", "warning", "info", or "debug". Defaults to "error".
tags object no Key-value tags to attach to the issue (e.g., {"environment": "production", "version": "1.0.0"}).
extra object no Additional context data as key-value pairs.

sentry.sentry_get_current_user

Get the currently authenticated Sentry user. Returns user name, email, and organization memberships. Useful for verifying the connection and identifying which Sentry account is being used.

Operation
Read read
Schema command
kosmo integrations:schema sentry.sentry_get_current_user --json
ParameterTypeRequiredDescription
No parameters.

Permissions

Headless calls still follow the integration read/write permission policy. Configure read/write defaults with integrations:configure. Add --force only for trusted automation that should bypass that policy.