Docs
Bugwatch documentation
Capture exceptions and messages from any stack. Create a project in the app, copy the ingest key from Settings, and point your SDK's DSN at the public API.
Quickstart
Every SDK uses the same DSN format and the same ingest contract. Pick your platform below — or send events with plain curl if you prefer.
Python
pip install bugwatch-sdk-python
import bugwatch_sdk as bugwatch
bugwatch.init(
"https://bw-YOUR_KEY@bugwatch-api.loadmindx.com/api/1",
environment="production",
release="v1.2.3",
)
try:
1 / 0
except ZeroDivisionError:
bugwatch.capture_exception()
bugwatch.flush() # sends are async — flush before exitJavaScript
npm install bugwatch-sdk-js
import Bugwatch from "bugwatch-sdk-js";
Bugwatch.init({
dsn: "https://bw-YOUR_KEY@bugwatch-api.loadmindx.com/api/1",
environment: "production",
});
try {
throw new Error("boom");
} catch (e) {
Bugwatch.captureException(e);
}
await Bugwatch.flush();SDKs
Pythonbugwatch-sdk-python
Stdlib only. Daemon-thread transport, 8 s timeout.
pip install bugwatch-sdk-python
JavaScriptbugwatch-sdk-js
Browser + Node ≥14. fetch keepalive, CJS + ESM + types.
npm install bugwatch-sdk-js
PHProomylabs/bugwatch-php
PHP 8.1+. curl multi, flushes at shutdown.
require __DIR__ . '/Bugwatch.php';
Gogithub.com/roomylabs/bugwatch-go
Go 1.21+. Channel queue + background worker.
go get github.com/roomylabs/bugwatch-go
Shared behaviour
| API | Description |
|---|---|
| DSN | https://{public_key}@{host}/api/{project_id} — HTTPS enforced in every SDK. |
| Auth | Each event is POSTed to {dsn}/store/ with header X-Bugwatch-Key: {public_key}. |
| PII | Email, IP and usernames are stripped unless send_default_pii / sendDefaultPii is enabled. |
| flush() | All SDKs send asynchronously — call flush() (or Flush) before your process exits. |
| Breadcrumbs | PHP and Go keep a rolling trail (last 100) attached to every event. |
