Skip to content
Docs GitHub

Installation

Installation

Install Script

Install the Sentry CLI using the install script:

Terminal window
curl https://cli.sentry.dev/install -fsS | bash

Package Managers

Install globally with your preferred package manager:

npm install -g sentry

Or run directly without installing:

npx sentry --help

Authentication

The easiest way to authenticate is via OAuth device flow:

Terminal window
sentry auth login

You’ll be given a URL and a code to enter. Once you authorize the application in your browser, the CLI will automatically receive your token.

API Token

Alternatively, you can use an API token directly:

Terminal window
sentry auth login --token YOUR_SENTRY_API_TOKEN

You can create API tokens in your Sentry account settings.

Check Auth Status

Verify your authentication status:

Terminal window
sentry auth status

Logout

To remove stored credentials:

Terminal window
sentry auth logout

Configuration

Credentials are stored in ~/.sentry/config.json with restricted file permissions (mode 600) for security.

Next Steps

Once authenticated, you can start using the CLI: