Bugsink API

Use Bugsink’s canonical REST API to query issues and events and manage your projects. The Sentry-compatible API supports Sentry SDKs and tools such as sentry-cli.

Browse the full, generated API reference.

What the API can do

For new integrations, use the Bugsink-specific canonical API at /api/canonical/0/. The /api/0/ and /api/<project-id>/ paths serve Sentry compatibility, including event ingestion and debug-file uploads.

The canonical API provides endpoints for:

  • Teams: list, create, retrieve and update teams.
  • Projects: list, create, retrieve and update projects.
  • Releases: list, create and retrieve releases.
  • Issues: list and retrieve issues; resolve, reopen, mute, unmute or delete them.
  • Events: list events belonging to an issue and retrieve the complete event payload.
  • Comments: add a comment to an issue’s history.

List endpoints use cursor pagination. Follow the next and previous URLs in the response rather than constructing cursors yourself. Lists that belong to another resource require an explicit filter: issues require ?project=<project-id> and events require ?issue=<issue-id>.

Most endpoints exchange JSON. Exact request fields, filters, sort options, response schemas and status codes are in the generated API reference.

Authentication

The API uses bearer tokens. Create one from the “Tokens” menu item in the Bugsink navigation, selecting its capabilities and scope. Store tokens as secrets; revoke them from the token list when they are no longer needed.

Send the token in the Authorization header:

curl --fail \
  --header "Authorization: Bearer $BUGSINK_TOKEN" \
  "$BUGSINK_URL/api/canonical/0/projects/"

Token types and scope

New in Bugsink 2.6.0

Token access depends on three settings:

  • Capabilities select which operations the token can perform. Granting a capability does not grant the user additional permissions.
  • Personal or service: personal tokens follow the creating user’s current permissions. All users can create personal tokens. Superusers can also create service tokens, which operate independently of a user account. To create a service token, clear the “Personal token” checkbox.
  • One project or global: select a project to limit the token to that project’s issues, events, releases and debug files. A global token has no single-project restriction; a personal token still follows its user’s permissions.

The projects:read, projects:manage, teams:read and teams:manage capabilities require a global token. A project-bound token cannot list projects, even its own; configure the project ID directly in integrations that use one.

Tokens created before 2.6.0 keep their full installation-wide access after an upgrade.

OpenAPI documentation

Every Bugsink installation serves its own OpenAPI schema and interactive Swagger UI:

/api/canonical/0/schema/
/api/canonical/0/schema/swagger-ui/

The schema is the authoritative description of the API for your installed Bugsink version. It can also be used to generate a client.

Download the OpenAPI specification for the version documented on this website.

Stacktraces as Markdown

An event’s complete JSON payload is the structured choice for software that needs individual fields. For people and LLMs, Bugsink can also render the stacktrace, source context and local variables as Markdown:

curl --fail \
  --header "Authorization: Bearer $BUGSINK_TOKEN" \
  --header "Accept: text/markdown" \
  "$BUGSINK_URL/api/canonical/0/events/$EVENT_ID/stacktrace/"

The regular JSON event response also includes this rendering in its stacktrace_md field. The Markdown is a presentation format: it may change between Bugsink versions and should not be parsed as a stable interface.

The Bugsink web interface offers related, session-authenticated Markdown views. Event pages have a Markdown link at the bottom. An issue summary, including status, counts, tags, history and its latest stacktrace, is available at:

/issues/issue/<issue-uuid>/md/

Add ?download to download that summary as a .md file.

Stacktraces and local variables can contain credentials, personal data and other sensitive values. Take the destination’s data handling into account before sharing them.

Capabilities

Each endpoint in the generated API reference states its required capability. A token without that capability receives a 403 Forbidden response. These requirements apply to both the canonical and Sentry-compatible APIs; SDK event ingestion continues to use the project’s DSN.

The table below lists all capabilities, their descriptions from the token form, and the REST endpoints they allow. Paths are relative to your Bugsink instance.

Capability Description REST endpoints
issues:read View issues and their details. GET /api/canonical/0/issues/ GET /api/canonical/0/issues/{id}/
events:read View events, including event data and stacktraces. GET /api/canonical/0/events/ GET /api/canonical/0/events/{id}/ GET /api/canonical/0/events/{id}/stacktrace/
issues:comment Add comments to issues. POST /api/canonical/0/issue-comments/
issues:triage Resolve, reopen, mute, and unmute issues. POST /api/canonical/0/issues/{id}/mute/ POST /api/canonical/0/issues/{id}/mute-for/ POST /api/canonical/0/issues/{id}/mute-until/ POST /api/canonical/0/issues/{id}/reopen/ POST /api/canonical/0/issues/{id}/resolve/ POST /api/canonical/0/issues/{id}/resolve-latest/ POST /api/canonical/0/issues/{id}/resolve-next/ POST /api/canonical/0/issues/{id}/unmute/
issues:delete Delete issues. DELETE /api/canonical/0/issues/{id}/
releases:read View releases and their details. GET /api/canonical/0/releases/ GET /api/canonical/0/releases/{id}/
releases:create Create releases. POST /api/canonical/0/releases/
debug-files:upload Upload and assemble debug files and artifact bundles. GET /api/0/ GET /api/0/organizations/{organization_slug}/chunk-upload/ POST /api/0/organizations/{organization_slug}/chunk-upload/ POST /api/0/organizations/{organization_slug}/artifactbundle/assemble/ POST /api/0/projects/{organization_slug}/{project_slug}/files/difs/assemble/
projects:read View projects and their details. GET /api/canonical/0/projects/ GET /api/canonical/0/projects/{id}/
projects:manage Create and update projects. POST /api/canonical/0/projects/ PATCH /api/canonical/0/projects/{id}/
teams:read View teams and their details. GET /api/canonical/0/teams/ GET /api/canonical/0/teams/{id}/
teams:manage Create and update teams. POST /api/canonical/0/teams/ PATCH /api/canonical/0/teams/{id}/

Browse the full, generated API reference.