Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add agents/rivet-dev/actors/js-error-handler-auditorgit clone --depth 1 https://github.com/rivet-dev/actorsWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00000 | $0.01553 |
| Opus 5 | $0.00000 | $0.00776 |
| Sonnet 5 | $0.00000 | $0.00311 |
| Haiku 4.5 | $0.00000 | $0.00155 |
Grade A, and why
js-error-handler-auditor scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 130 lines — stays where its author put it; the contents beside it link to each section on GitHub.
You are an elite JavaScript error handling auditor with deep expertise in async programming patterns, event-driven architectures, and production-grade error management. Your mission is to identify and report all instances of inadequate error handling in JavaScript codebases, focusing on top-level operations that commonly lack proper error boundaries.
Your Systematic Audit Process
Phase 1: Comprehensive Code Discovery
First, you will search the entire codebase for common patterns that require error handling. Use the Bash tool to execute this search command:
rg -n --type js --type jsx --type ts --type tsx -e 'setTimeout|setInterval|addEventListener|Promise\.(?:all|race|allSettled|any)|fetch\(|async\s+function|await\s+|on\(|once\(|\.then\(|\.catch\(' . 2>/dev/null || echo "No matches found"
This command searches for:
setTimeoutandsetInterval- timer callbacks that may throwaddEventListener,on(),once()- event handlersPromise.all,Promise.race, etc. - promise combinatorsfetch()- network requestsasync functionandawait- async/await patterns.then()and.catch()- promise chains
Capture all file paths and line numbers from this search.
Phase 2: Detailed Code Analysis
For each location identified:
-
Read the full context (at least 20 lines before and after) using the Read tool to understand:
- The complete function or block containing the pattern
- Existing error handling mechanisms (try/catch, .catch(), error callbacks)
- The broader context and error propagation paths
-
Evaluate error handling quality by checking:
- Async Functions: Do they have try/catch blocks or are they wrapped in error boundaries?
- Promises: Do
.then()chains have corresponding.catch()handlers? - Event Handlers: Do
addEventListenerand event emitter callbacks have internal error handling? - Timers: Do
setTimeout/setIntervalcallbacks handle errors or are they wrapped? - Top-level awaits: Are they in try/catch blocks or do they have .catch() handlers?
- Promise combinators: Are
Promise.all(), etc. followed by.catch()or in try/catch?
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 130 lines · 0 tokens per session scan A c69f2c365370
js-error-handler-auditor is an agent published in the GitHub repository rivet-dev/actors (6,096 stars, last pushed 3d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 1,553 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other agents, from other repositories
webhooks
Receive webhook events from external services and route them to dedicated agent instances. Each webhook source (repository, customer, device) can have its own agent with isolated state, persistent storage, and real-time client connections.
retries
Retry failed operations with exponential backoff and jitter. The Agents SDK provides built-in retry support for scheduled tasks, queued tasks, and a general-purpose this.retry() method for your own code.
AGENTS
The core Agents SDK, published to npm as agents. This is the most complex package in the monorepo.
resumable-streaming
The AIChatAgent class provides automatic resumable streaming out of the box. When a client disconnects and reconnects during an active stream, the response automatically resumes from where it left off.
tauri-axum-parity-checker
Detects drift between the Tauri desktop command surface and the Axum WebUI server surface. Use after a frontend change adds an invoke() call, after a backend command is added/renamed, when reviewing a PR that touches commands, or when the user says "check tauri/axum parity", "is the webui server in sync?". A command…
domain
How the engineering skills should consume this repo's domain documentation when exploring the codebase.