Docs · Quickstart

Five minutes to first event.

Install the SDK, set the DSN, run your app, watch the event arrive in the live feed. Then add an alert rule and you're done.

0. Sign in

Go to app.coderadar.app/sign-in. Sign in with the Goodventures Clerk session. You should see the project picker. If your project doesn't exist yet, create it from Settings → Projects → New project. The wizard hands you the DSN.

1. Install the SDK

Pick your runtime.

Node.js

pnpm add @coderadar/sdk
# or: npm install @coderadar/sdk
# or: yarn add @coderadar/sdk

Browser

pnpm add @coderadar/browser
# or paste the script tag in the browser tab below

Python

pip install coderadar
# or: poetry add coderadar
# or: uv add coderadar

Go

go get github.com/RelayOne/coderadar/sdks/go/coderadar

2. Init at boot

Earlier is better. The SDK needs to be initialized before any code that might throw.

Node — Express, Hono, plain Node

// instrumentation.ts (Next.js) or src/init.ts (others)
import { init } from "@coderadar/sdk";

init({
  dsn:         process.env.CODERADAR_DSN,
  project:     "truecom",
  environment: process.env.NODE_ENV,
  release:     process.env.RELEASE_SHA,
  tracesSampleRate: 0.2,
});

Browser — script tag

<script
  src="https://cdn.coderadar.app/v1/sdk.js"
  data-project="truecom"
  data-env="production"
  data-release="[email protected]">
</script>

Python — FastAPI

import os
import coderadar
from coderadar.fastapi import CodeRadarMiddleware

coderadar.init(
    dsn=os.environ["CODERADAR_DSN"],
    project="veritize",
    environment=os.environ.get("ENV"),
    release=os.environ.get("RELEASE_SHA"),
    traces_sample_rate=0.2,
)
app = FastAPI()
app.add_middleware(CodeRadarMiddleware)

Go — net/http

import "github.com/RelayOne/coderadar/sdks/go/coderadar"

cr, _ := coderadar.NewClient(coderadar.Config{
    DSN:         os.Getenv("CODERADAR_DSN"),
    Project:     "relaygate",
    Environment: os.Getenv("ENV"),
    Release:     os.Getenv("RELEASE_SHA"),
    SampleRate:        1.0,
    TracesSampleRate:  0.2,
})
defer cr.Flush()
http.ListenAndServe(":8080", coderadar.WrapHandler(mux))

3. Set the DSN

Get the DSN from the project's Settings → Keys page. Paste it into your environment.

export CODERADAR_DSN="https://[email protected]/12"

The public part of the DSN is safe to expose in browser bundles. For stricter setups use the server-only DSN with a Bearer token; see Concepts.

4. Trigger a test event

Throw something. The SDK will catch it.

// Node / Browser
import { captureException } from "@coderadar/sdk";
captureException(new Error("hello from quickstart"));

// Python
import coderadar
coderadar.capture_exception(Exception("hello from quickstart"))

// Go
cr.CaptureException(errors.New("hello from quickstart"))

5. See it in the live feed

Open app.coderadar.app and pick your project. Within a second, the test event should appear in the live feed at the top. Click it to see breadcrumbs, runtime info, the user object (if you set one), tags, and the trace it was part of (if there was one).

Not seeing it?

Run the SDK in debug mode (CODERADAR_DEBUG=1) and check stderr for SDK self-logs. Common causes: wrong DSN format, network egress blocked, sample rate set to 0, or the SDK's flush hasn't fired yet (give it 5 seconds).

6. Add a release tag

Releases let CodeRadar associate errors with a specific deploy. Two ways:

  • Via init — pass release in the SDK init options (recommended).
  • Via CLIcoderadar releases create --project=truecom --release=truecom@$SHORT_SHA --commit=$COMMIT_SHA in CI.

7. Upload source maps (browser only)

Without source maps, browser stack traces are minified gibberish. Upload them as part of your release pipeline.

pnpm dlx @coderadar/cli sourcemaps upload \
  --project=truecom \
  --release=truecom@$SHORT_SHA \
  --rewrite \
  --strip-common-prefix \
  dist/static/js/

8. Add your first alert rule

Either click Alerts → New rule in the dashboard, or check this YAML into .coderadar/alerts.yaml in your repo:

version: 1
project: truecom
rules:
  - name: fatal_in_production
    when: "level:fatal env:production"
    threshold: "count > 0 in 1m"
    channels: [slack-prod]
    cooldown: 5m
channels:
  - id: slack-prod
    type: slack
    webhook: ${SLACK_WEBHOOK_URL}

Apply with coderadar alerts apply --file=.coderadar/alerts.yaml. The next time a fatal-level event lands in production, your Slack channel gets pinged.

That's it

You have errors flowing in, traces being captured, and one alert wired up. Read the Concepts guide for the full mental model, or jump to the Node / Browser / Python / Go SDK reference.