Add Error Tracking logo

Add Error Tracking

Organization
gotempsh
add-error-tracking

Add Temps error tracking to applications using the Sentry-compatible SDK. Temps exposes a Sentry-compatible DSN that works with the official Sentry SDK for each language/framework — no code changes beyond initialization are required. Use when the user wants to: (1) Add error tracking to any app (React, Next.js, Vue, Svelte, Angular, Node.js, Python, Go, Rust, Ruby, Java, PHP, .NET, React Native, Flutter), (2) Wire up uncaught exception and unhandled promise rejection capture, (3) Configure session replay for errors, (4) Upload source maps for readable stack traces, (5) Report releases and environments, (6) Capture custom errors/messages. Triggers: "add error tracking", "add sentry", "track exceptions", "report errors", "temps error tracking", "wire up error monitoring".

Overview

Publishergotempsh
Repositorytemps
Skill nameadd-error-tracking
Stars
836
Forks
68
Bundled files
Instructions only
LicenseApache-2.0
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by gotempsh on GitHub. Read the source before you install it.

Installation

Install the Add Error Tracking AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/gotempsh/temps/tree/main/skills/add-error-tracking
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/gotempsh/temps.git /tmp/temps
mkdir -p .claude/skills
cp -r /tmp/temps/skills/add-error-tracking .claude/skills/add-error-tracking
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Add Error Tracking in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Add Error Tracking on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Add Error Tracking is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Add Error Tracking

Integrate Temps error tracking (Sentry-compatible) into an application. The Temps DSN is a drop-in replacement for a Sentry DSN — use the official Sentry SDK for the user's platform and point it at the Temps DSN via an environment variable.

Prefer Sentry's official per-framework skills when available

Temps is Sentry wire-compatible, so every skill Sentry publishes for their SDKs works against a Temps DSN. If the user's CLI already has one of these installed, route them to it and only substitute the DSN:

User's platformSentry skillSource
Next.js/sentry-nextjs-sdkgetsentry/sentry-for-ai
React (Vite, Remix, etc.)/sentry-react-sdkgetsentry/sentry-for-ai
Vanilla browser JS/sentry-browser-sdkgetsentry/sentry-for-ai
Node.js/sentry-node-sdkgetsentry/sentry-for-ai
React Native/sentry-react-native-sdkgetsentry/sentry-for-ai
Generic (language-agnostic)/sentry-sdk-setupgetsentry/sentry-for-ai

For platforms Sentry has no dedicated skill for (Vue, Svelte, Angular, Python, Go, Rust, Ruby, Java, PHP, .NET, Flutter, etc.), follow the setup in this file directly.

Always set the DSN from an environment variable — never hardcode it. The user will point the env var at their Temps DSN instead of a Sentry DSN.

Detect the platform

Infer the platform from the codebase:

  • package.json with "next" → Next.js → @sentry/nextjs
  • package.json with "react" and Vite/Remix/CRA → React → @sentry/react
  • package.json with "vue" or "nuxt" → Vue → @sentry/vue
  • package.json with "svelte" or "@sveltejs/kit" → Svelte → @sentry/sveltekit
  • package.json with "@angular/core" → Angular → @sentry/angular
  • package.json with "express", "fastify", "@nestjs/core" → Node.js → @sentry/node
  • package.json with "react-native" or "expo" → React Native → @sentry/react-native
  • requirements.txt/pyproject.toml with Flask, Django, FastAPI → Python → sentry-sdk
  • go.mod → Go → github.com/getsentry/sentry-go
  • Cargo.toml → Rust → sentry
  • Gemfile with rails → Ruby → sentry-ruby + sentry-rails
  • pom.xml/build.gradle with Spring → Java → sentry-spring-boot-starter-jakarta
  • composer.json with laravel/framework or symfony/* → PHP → sentry/sentry
  • .csproj with Microsoft.AspNetCore.* → .NET → Sentry.AspNetCore
  • pubspec.yaml with flutter → Flutter → sentry_flutter

Get the DSN

The user's Temps project exposes a DSN at Error Tracking → DSN & Setup. It looks like:

https://<public_key>@<temps-host>/<project_id>

If the user has not provided a DSN, tell them to:

  1. Open their project in the Temps dashboard
  2. Go to Error Tracking → DSN & Setup
  3. Copy the DSN for the target environment

Always store the DSN in an environment variable. The exact variable name depends on the platform (browser bundlers often require a prefix to expose vars to the client):

PlatformEnv var name
Next.jsNEXT_PUBLIC_SENTRY_DSN
Vite / React / VueVITE_SENTRY_DSN
SvelteKitPUBLIC_SENTRY_DSN
AngularSENTRY_DSN (injected via environment.ts)
Everything else (Node, Python, Go, Rust, Ruby, Java, PHP, .NET, Flutter)SENTRY_DSN
bash
# .env
SENTRY_DSN=https://<public_key>@<temps-host>/<project_id>

Browser SDKs: also pass tunnel

For every browser platform (Next.js client config, React, Vue, Svelte, vanilla JS — not server-side SDKs, not React Native/Flutter), also pass tunnel in the same Sentry.init call:

ts
Sentry.init({
  dsn: process.env.NEXT_PUBLIC_SENTRY_DSN,
  tunnel: process.env.NEXT_PUBLIC_SENTRY_TUNNEL,
});

Why: without tunnel, the SDK POSTs straight to the DSN's host (the Temps console), which is a third-party, cross-origin request from the app's own domain — ad blockers commonly block it, and it costs a CORS preflight on every event. With tunnel set to a same-origin path, the browser posts to the app's own domain instead; Temps' proxy forwards anything under /api/_temps to the console regardless of which project domain it arrived on, so this works unmodified on custom domains and preview URLs.

The value is a fixed path, not a secret — Temps injects it automatically as an env var alongside the DSN, under the same bundler-specific public prefix (so if the DSN reaches the client bundle, the tunnel path does too):

PlatformDSN env varTunnel env var
Next.jsNEXT_PUBLIC_SENTRY_DSNNEXT_PUBLIC_SENTRY_TUNNEL
Vite / React / VueVITE_SENTRY_DSNVITE_SENTRY_TUNNEL
SvelteKitPUBLIC_SENTRY_DSNPUBLIC_SENTRY_TUNNEL
AngularSENTRY_DSN (via environment.ts)(none — no public-prefix convention; skip tunnel)

If deploying outside Temps (or the tunnel var isn't set for some other reason), you have two options. Omit tunnel — the SDK falls back to posting straight to the DSN host, which still works, just cross-origin. Or point tunnel at the absolute tunnel URL of the Temps instance, e.g. tunnel: "https://your-temps-instance.example.com/api/_temps/sentry/envelope": the endpoint resolves the project from the DSN the SDK embeds in the envelope, so it does not need the app to be served by Temps. That keeps the tunnel's ad-blocker resistance for an app Temps does not host, at the cost of the cross-origin request the same-origin variant avoids.

Leave out Sentry.replayIntegration() and tracesSampleRate for browser projects unless you specifically want them — Temps doesn't yet ingest Sentry session replay or performance transactions, so that traffic would be uploaded (through the tunnel, using the visitor's bandwidth) and discarded server-side. Use Temps' own session replay and analytics SDKs for those instead (see the add-session-recording and add-react-analytics skills).

Platform setup

Every snippet below reads the DSN from an env var — do not hardcode it.

Next.js

bash
npx @sentry/wizard@latest -i nextjs

Or manually:

bash
npm install @sentry/nextjs
ts
// sentry.client.config.ts (or instrumentation-client.ts on newer @sentry/nextjs)
import * as Sentry from '@sentry/nextjs';

Sentry.init({
  dsn: process.env.NEXT_PUBLIC_SENTRY_DSN,
  tunnel: process.env.NEXT_PUBLIC_SENTRY_TUNNEL,
});

Mirror the dsn (no tunnel, no replay) in sentry.server.config.ts and sentry.edge.config.ts — those run server-side and post directly to the console.

Do not set tunnelRoute in withSentryConfig — it's a different mechanism (forwards through a Next.js server route) and its own docs state it doesn't work with self-hosted Sentry, which is what Temps' DSN compatibility layer is. Use the tunnel option shown above instead.

React (Vite, Remix, CRA)

bash
npm install @sentry/react
tsx
// src/sentry.ts — import this first in main.tsx / root.tsx
import * as Sentry from '@sentry/react';

Sentry.init({
  dsn: import.meta.env.VITE_SENTRY_DSN,
  tunnel: import.meta.env.VITE_SENTRY_TUNNEL,
  environment: import.meta.env.MODE,
});

Wrap the app root with <Sentry.ErrorBoundary> for React render errors.

Vue (Vue 3 / Nuxt)

bash
npm install @sentry/vue
ts
// src/main.ts
import { createApp } from 'vue';
import * as Sentry from '@sentry/vue';
import App from './App.vue';

const app = createApp(App);

Sentry.init({
  app,
  dsn: import.meta.env.VITE_SENTRY_DSN,
  tunnel: import.meta.env.VITE_SENTRY_TUNNEL,
});

app.mount('#app');

Svelte / SvelteKit

bash
npx @sentry/wizard@latest -i sveltekit
ts
// src/hooks.client.ts
import * as Sentry from '@sentry/sveltekit';
import { PUBLIC_SENTRY_DSN, PUBLIC_SENTRY_TUNNEL } from '$env/static/public';

Sentry.init({
  dsn: PUBLIC_SENTRY_DSN,
  tunnel: PUBLIC_SENTRY_TUNNEL,
});

export const handleError = Sentry.handleErrorWithSentry();

Mirror in src/hooks.server.ts using $env/dynamic/private for the server DSN.

Angular

bash
npm install @sentry/angular
ts
// src/main.ts
import * as Sentry from '@sentry/angular';
import { environment } from './environments/environment';

Sentry.init({
  dsn: environment.sentryDsn,
  tracesSampleRate: 1.0,
});

Populate environment.sentryDsn from process.env.SENTRY_DSN at build time. No public-prefix tunnel var is injected for Angular (no bundler convention to mirror) — skip tunnel here; the SDK posts directly to the DSN host.

Vanilla JavaScript (browser)

bash
npm install @sentry/browser
ts
import * as Sentry from '@sentry/browser';

Sentry.init({
  dsn: import.meta.env.VITE_SENTRY_DSN,
  tunnel: import.meta.env.VITE_SENTRY_TUNNEL,
});

Node.js

bash
npm install @sentry/node
ts
// Must be the first import in your entrypoint.
import * as Sentry from '@sentry/node';

Sentry.init({
  dsn: process.env.SENTRY_DSN,
  environment: process.env.NODE_ENV,
  tracesSampleRate: 1.0,
});

For Express:

ts
import express from 'express';
import * as Sentry from '@sentry/node';

const app = express();
Sentry.setupExpressErrorHandler(app);

React Native

bash
npx @sentry/wizard@latest -s -i reactNative
ts
import * as Sentry from '@sentry/react-native';

Sentry.init({
  dsn: process.env.SENTRY_DSN,
  tracesSampleRate: 1.0,
  replaysSessionSampleRate: 0.1,
  replaysOnErrorSampleRate: 1.0,
});

export default Sentry.wrap(App);

Python

bash
pip install sentry-sdk
python
import os
import sentry_sdk

sentry_sdk.init(
    dsn=os.environ["SENTRY_DSN"],
    environment=os.environ.get("ENV", "development"),
    traces_sample_rate=1.0,
    profiles_sample_rate=1.0,
)

Framework integrations:

python
# Flask
from sentry_sdk.integrations.flask import FlaskIntegration
sentry_sdk.init(dsn=os.environ["SENTRY_DSN"], integrations=[FlaskIntegration()])

# Django
from sentry_sdk.integrations.django import DjangoIntegration
sentry_sdk.init(dsn=os.environ["SENTRY_DSN"], integrations=[DjangoIntegration()])

# FastAPI
from sentry_sdk.integrations.starlette import StarletteIntegration
from sentry_sdk.integrations.fastapi import FastApiIntegration
sentry_sdk.init(
    dsn=os.environ["SENTRY_DSN"],
    integrations=[StarletteIntegration(), FastApiIntegration()],
)

Go

bash
go get github.com/getsentry/sentry-go
go
package main

import (
    "log"
    "os"
    "time"

    "github.com/getsentry/sentry-go"
)

func main() {
    err := sentry.Init(sentry.ClientOptions{
        Dsn:              os.Getenv("SENTRY_DSN"),
        TracesSampleRate: 1.0,
        Environment:      os.Getenv("ENV"),
    })
    if err != nil {
        log.Fatalf("sentry.Init: %s", err)
    }
    defer sentry.Flush(2 * time.Second)
}

Rust

bash
cargo add sentry sentry-tracing
rust
use std::env;

fn main() {
    let _guard = sentry::init((
        env::var("SENTRY_DSN").expect("SENTRY_DSN must be set"),
        sentry::ClientOptions {
            release: sentry::release_name!(),
            traces_sample_rate: 1.0,
            environment: env::var("ENV").ok().map(Into::into),
            ..Default::default()
        },
    ));

    // Your app entrypoint
}

Ruby (Rails)

bash
bundle add sentry-ruby sentry-rails
ruby
# config/initializers/sentry.rb
require "sentry-ruby"
require "sentry-rails"

Sentry.init do |config|
  config.dsn = ENV["SENTRY_DSN"]
  config.environment = ENV.fetch("RAILS_ENV", "development")
  config.traces_sample_rate = 1.0
end

Java (Spring Boot)

xml
<!-- pom.xml -->
<dependency>
  <groupId>io.sentry</groupId>
  <artifactId>sentry-spring-boot-starter-jakarta</artifactId>
  <version>7.14.0</version>
</dependency>
properties
# application.properties — Spring reads ${SENTRY_DSN} from the environment
sentry.dsn=${SENTRY_DSN}
sentry.environment=${ENV:development}
sentry.traces-sample-rate=1.0

PHP

bash
composer require sentry/sentry
php
<?php
\Sentry\init([
    'dsn' => $_ENV['SENTRY_DSN'],
    'environment' => $_ENV['APP_ENV'] ?? 'development',
    'traces_sample_rate' => 1.0,
]);

For Laravel, use sentry/sentry-laravel and configure via config/sentry.php reading env('SENTRY_DSN').

.NET (ASP.NET Core)

bash
dotnet add package Sentry.AspNetCore
csharp
// Program.cs
builder.WebHost.UseSentry(options =>
{
    options.Dsn = Environment.GetEnvironmentVariable("SENTRY_DSN");
    options.Environment = builder.Environment.EnvironmentName;
    options.TracesSampleRate = 1.0;
});

Flutter

bash
flutter pub add sentry_flutter
dart
import 'package:flutter/widgets.dart';
import 'package:sentry_flutter/sentry_flutter.dart';

Future<void> main() async {
  await SentryFlutter.init(
    (options) {
      options.dsn = const String.fromEnvironment('SENTRY_DSN');
      options.tracesSampleRate = 1.0;
    },
    appRunner: () => runApp(const MyApp()),
  );
}

Pass the DSN at build time: flutter run --dart-define=SENTRY_DSN=$SENTRY_DSN.

Capture custom errors

JavaScript / TypeScript

ts
import * as Sentry from '@sentry/react'; // or /browser, /node, /nextjs, etc.

try {
  doRiskyThing();
} catch (err) {
  Sentry.captureException(err);
}

Sentry.captureMessage('Something notable happened', 'warning');

Python

python
try:
    do_risky_thing()
except Exception as exc:
    sentry_sdk.capture_exception(exc)

sentry_sdk.capture_message("Something notable happened", level="warning")

Go

go
sentry.CaptureException(err)
sentry.CaptureMessage("Something notable happened")

Rust

rust
sentry::capture_error(&err);
sentry::capture_message("Something notable happened", sentry::Level::Warning);

Source maps (JS/TS only)

Upload source maps during CI so the Temps dashboard shows original source in stack traces.

bash
npm install --save-dev @sentry/cli
bash
sentry-cli sourcemaps inject ./dist
sentry-cli sourcemaps upload \
  --url-prefix '~/' \
  --release "$GIT_SHA" \
  ./dist

The Temps dashboard also accepts source map uploads via Error Tracking → Source Maps in the UI.

Verification

After wiring up:

  1. Throw a deliberate error from the app:
    • JS / TS: throw new Error('Temps error tracking test');
    • Python: raise Exception('Temps error tracking test')
    • Go: sentry.CaptureException(errors.New("Temps test"))
    • Rust: panic!("Temps test") (inside a handler caught by the Sentry integration)
  2. Run the app and trigger the path that throws.
  3. Open Error Tracking → Error Groups in the Temps dashboard — the error should appear within a few seconds.
  4. Confirm the stack trace and environment are populated.

Common issues

  • Nothing shows up: Verify the DSN env var is loaded and the SDK is initialized before any code that might throw. For Node, Sentry.init must be the very first import.
  • Minified stack traces: Upload source maps (see above).
  • Browser apps not reporting: Make sure the env var uses the bundler's public prefix (NEXT_PUBLIC_, VITE_, PUBLIC_) so it reaches the client bundle.
  • Events missing in production: Confirm the deployment environment sets the DSN env var — local .env files are not copied automatically.
  • Tunneled requests get 403: the tunnel endpoint checks that the request's Origin (or Referer) matches the domain it arrived on — this rejects a script sending forged events to someone else's project, but also anything proxying/rewriting the request in a way that drops or rewrites Origin. Confirm nothing between the browser and the app strips that header.
  • Tunneled requests get 404: the tunnel resolves the project from the Host header via Temps' routing table — this only works for the domain(s) actually deployed on Temps. A tunnel env var used on a domain temps doesn't serve (e.g. testing against a different environment's URL) has nowhere to resolve to.

Frequently asked questions

What does the Add Error Tracking AI skill do?

Add Temps error tracking to applications using the Sentry-compatible SDK. Temps exposes a Sentry-compatible DSN that works with the official Sentry SDK for each language/framework — no code changes beyond initialization are required. Use when the user wants to: (1) Add error tracking to any app (React, Next.js, Vue, Svelte, Angular, Node.js, Python, Go, Rust, Ruby, Java, PHP, .NET, React Native, Flutter), (2) Wire up uncaught exception and unhandled promise rejection capture, (3) Configure session replay for errors, (4) Upload source maps for readable stack traces, (5) Report releases and e...

Why use Add Error Tracking on TypingMind?

Because you install it once and use it with any model. Add Error Tracking is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Add Error Tracking in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/gotempsh/temps/tree/main/skills/add-error-tracking. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Add Error Tracking?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Add Error Tracking?

As many as you like. As long as a model supports skills, you can use Add Error Tracking with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Add Error Tracking AI skill free?

Yes. It is published on GitHub by gotempsh under the Apache-2.0 license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇