An error tracker with email alerts, built by Claude Code on Elements
A paste-in snippet reports uncaught errors, grouped by stack trace into live issues with charts, triage and email alerts.
How it's built
Faultkeep needed an ingest endpoint and a paste-in snippet, grouping by stack trace, live issue lists and charts, triage, and alert emails. Each of those is a part of Elements, so the agent spent its 32 minutes on error tracking itself.
- An ingest endpoint and snippet. One route takes JSON error events authenticated by the project's key, and another serves a snippet any web page can include to report uncaught errors and unhandled rejections.
- Grouping in SQL. A database function fingerprints each event by its stack frames, then updates the issue's counts, affected users, tags and hourly chart in one call. An event on a resolved issue reopens it.
- Live issues and charts. Issues, events, tags and chart buckets are LiveTables, and a database trigger broadcasts every ingest, so the issue list, each issue's chart and its latest events update as errors arrive.
- Triage. Resolving, ignoring and assigning save through the issues LiveTable, which checks the user and the assignee are members of the project.
- Alert emails from a job. A new or reopened issue schedules a job inside the ingest transaction, and it emails every project member from a template.
- Data from SQL files. Migrations define the schema and seed two users, two projects, 15 issues and about 1,860 events over the past week, some resolved, some ignored and one reopened. The project server applied each one as soon as it was saved.
Why Elements
Elements is an integrated full-stack app framework and a project server. The project server checks the agent's work as it builds: it type-checks the server and browser code, analyzes the program, applies migrations and runs the tests, then reports the results to the agent. A security mistake, such as calling a server-only function from the browser, is a compile error. The agent reads the report and fixes its own mistakes before it tells you a feature is done. The same checks run on every feature you ask for next.
Run it yourself
- 1 Sign up
Already have an account? Sign in
- 2 Install and run the demo One prompt to paste into your agent.
The prompt
What Claude was given to build this app.
Build an error tracker named faultkeep for web apps. - Accounts and projects. Each project has a DSN key. - An ingest endpoint that accepts JSON error events (message, stack trace, url, browser, release, user) authenticated by the key, and a small snippet to paste into a web page that reports uncaught errors to it. - Group events into issues by stack trace. Issue list: count, users affected, first and last seen, sorted by last seen or frequency. - Issue detail: the stack trace, a chart of events over time, tags, and the latest events. - Resolve, ignore, or assign an issue. A resolved issue that happens again reopens. - Email when a new issue appears or a resolved one comes back. Seed two users, two projects, and a week of events across about fifteen issues. Show the seeded logins on the sign-in page. New events and issues appear in real time.