Serveur MCP AgentSensor
Commit 20 oct. 2026Fournit aux agents de codage IA un accès en temps réel aux erreurs d'exécution du serveur et du navigateur, avec un mappage précis vers les fichiers sources et les numéros de ligne.
Aussi connu sous arif-js/agentsensor, agentsensor-mcp
- Étoiles
- 0
- Outils
- 4
- Téléchargements, 30 jours
- —
- Dernière version
- —
- Dernier commit
- 20 oct. 2026
- Licence
- MIT
Qu'est-ce que AgentSensor MCP ?
AgentSensor est un serveur MCP. Fournit aux agents de codage IA un accès en temps réel aux erreurs d'exécution du serveur et du navigateur, avec un mappage précis vers les fichiers sources et les numéros de ligne. Il expose 4 outils, comme get_runtime_errors, get_error_detail, check_fix.
Résumé généré à partir du README du projet
À propos du MCP server AgentSensor
agentsensor permet aux développants travaillant dans les écosystèmes Node.js, JavaScript et TypeScript d'offrir aux agents de codage IA une visibilité directe sur les plantages d'exécution. En enveloppant une commande de développement, cet outil capture les exceptions backend, les erreurs de compilation du bundler et les plantages du navigateur frontend provenant de frameworks comme Next.js, Vite et Remix. Il mappe ces erreurs vers les fichiers sources et les numéros de ligne exacts, éliminant ainsi le besoin de copier-coller manuellement entre un terminal et un client IA.
Les utilisateurs connectent ce serveur à des clients tels que Claude Code, Cursor, Codex ou Antigravity via une configuration MCP standard. L'installation est entièrement locale et ne nécessite ni compte cloud ni télémétrie. Il gère les états d'erreur via un tableau de bord de statut local, permettant aux agents de suivre si un bug est ouvert ou résolu. Grâce à des outils spécifiques comme get_runtime_errors et get_error_detail, un agent peut inspecter les stack traces et les trente lignes de log précédant un plantage pour implémenter des correctifs précis.
Ce que vous pouvez faire avec
- 1Vérification des correctifs de bugsUn développeur peut demander à un agent IA de confirmer si une modification de code a réellement résolu une erreur signalée précédemment.
- 2Débogage d'erreurs de composants frontendL'outil capture les erreurs de composants React et les exceptions du navigateur pour aider les agents à déboguer les problèmes côté client.
Extrait du README du projet. Chaque cas d'utilisation est vérifié par rapport à une citation du document.
Comment installer AgentSensor MCP
Formats vérifiés le 10 nov. 2026Ajouter à CursorAjouter à GooseInstaller AgentSensor MCP dans Claude Code
$ claude mcp add agentsensor -- npx -y agentsensor-mcpInstaller AgentSensor MCP dans Cursor
~/.cursor/mcp.json
{
"mcpServers": {
"agentsensor": {
"command": "npx",
"args": [
"-y",
"agentsensor-mcp"
]
}
}
}Installer AgentSensor MCP dans VS Code
.vscode/mcp.json
{
"servers": {
"agentsensor": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"agentsensor-mcp"
]
}
}
}Installer AgentSensor MCP dans VS Code CLI
$ code --add-mcp '{"name":"agentsensor","type":"stdio","command":"npx","args":["-y","agentsensor-mcp"]}'Installer AgentSensor MCP dans Claude Desktop
claude_desktop_config.json
{
"mcpServers": {
"agentsensor": {
"command": "npx",
"args": [
"-y",
"agentsensor-mcp"
]
}
}
}Installer AgentSensor MCP dans Codex
$ codex mcp add agentsensor -- npx -y agentsensor-mcpInstaller AgentSensor MCP dans Codex config.toml
~/.codex/config.toml
[mcp_servers.agentsensor] command = "npx" args = ["-y", "agentsensor-mcp"]
Installer AgentSensor MCP dans Gemini CLI
$ gemini mcp add -s user agentsensor npx -- -y agentsensor-mcpInstaller AgentSensor MCP dans Gemini settings.json
~/.gemini/settings.json
{
"mcpServers": {
"agentsensor": {
"command": "npx",
"args": [
"-y",
"agentsensor-mcp"
]
}
}
}Outils MCP AgentSensor 4
Détectés depuis le READMEget_runtime_errorsget_error_detailcheck_fixresolve_error
| get_runtime_errors | — | |
| get_error_detail | — | |
| check_fix | — | |
| resolve_error | — |
Configuration
AUTO_TRIGGER
| Nom | Description | Type |
|---|---|---|
| AUTO_TRIGGER | — |
Vérifications automatisées
Exécuté le 14 nov. 2026Rapport complet →Pas encore vérifié. Un serveur nécessite un score de 80, aucune faille sérieuse et suffisamment de données pour que nous puissions effectuer les vérifications. Fonctionnement des vérifications · Ce qu'il faut corriger pour gagner des points
- Dépôt source lié et accessiblearif-js/agentsensor is public and reachablegithub.com/arif-js/agentsensor ↗Réussi
- Le nom du package correspond au dépôt sourceagentsensor-mcp names arif-js/agentsensor as sourcenpmjs.com/package/agentsensor-mcp ↗Réussi
- Provenance du build (attestation Sigstore)No build attestation published for this releaseNon vérifié
- Licence open source (OSI)MITspdx.org/licenses/MIT.html ↗Réussi
- Commit ou version publiée au cours de l'année écouléeLast commit or release 2026-10-20github.com/arif-js/agentsensor ↗Réussi
- OpenSSF ScorecardNon vérifié
- Nom du package non proche d'un package populaireNo popular package one edit away from agentsensor-mcpRéussi
- Aucun avis critique dans le package ou ses dépendancesNon vérifié
- Aucune instruction cachée destinée au modèle4 tool descriptions and the README read; no override phrases, credential paths or hidden charactersRéussi
- Les outils destructifs sont étiquetésNo tool named like delete, drop or execRéussi
- Le point de terminaison distant répond à la poignée de main MCPNon vérifié
README
Voir sur GitHubAgentSensor
Zero-config runtime & browser error sensor for AI coding agents.
Wrap your dev server with one command, then let Claude Code, Codex, Cursor, Antigravity, or any MCP client see the real crashes from your terminal and browser — mapped to the exact file and line, with zero copy-paste.
What it does · Supported stack · Demo · Quick start · MCP tools · How it works · Contributing
Status: pre-release (0.1). Expect rapid improvements before 1.0.
What it does
- ⚡ Zero code changes: wrap your existing dev script (
agentsensor run -- npm run dev). No SDK imports, no middleware, no config files. - 🌐 Captures both server and browser crashes: intercepts backend runtime exceptions, bundler compilation errors, and in-browser exceptions (
window.onerror,unhandledrejection, React component errors). - 🎯 Source-mapped to your real code: automatically enables
--enable-source-maps, strips monorepo runner prefixes, collapsesnode_modulesnoise, and maps browser URLs back to exact workspace files. - 📋 Live
openvsresolvedstatus board: maintains.agentsensor/status.jsonso fixed errors from earlier sessions never confuse the agent — while automatically reopening an error if it ever happens again. - 🤖 Automatic agent triggering: sends MCP server instructions so connected agents check
get_runtime_errorsfirst whenever you report a bug or crash. - 🔒 100% local: no accounts, no cloud, no telemetry, no background daemons.
AgentSensor doesn't guess fixes — it gives your coding agent the exact runtime reality (error type, message, source-mapped file:line:column, and the 30 log lines leading up to the crash) so the agent fixes the real bug on the first try.
Supported stack
AgentSensor currently supports the Node.js, JavaScript, and TypeScript ecosystem:
| Layer | Supported | Details |
|---|---|---|
| Runtimes | Node.js (>=18.17) | JavaScript & TypeScript |
| Frontend & SSR | Next.js, Vite, Remix, Storybook | Dev server builds & browser crashes (window.onerror, unhandledrejection, React console.error) |
| Backend | Express, Fastify, NestJS, Koa, Node CLI scripts | V8 exceptions, unhandled promise rejections, source-mapped stack traces |
| Compilers & Bundlers | tsc, Turbopack, Webpack, esbuild, Babel |
Build-time errors, type errors, syntax crashes |
| Monorepos | pnpm, Turborepo, Nx |
Strips runner prefixes, maps local package paths |
[!NOTE] Non-Node runtimes (Python, Go, Rust): Not supported yet. Dedicated runtime hooks and stack trace parsers for these languages are planned for upcoming releases.
Demo
Run your dev server through agentsensor:
npx -y agentsensor-mcp run -- npm run dev
When your app or browser throws an error, just talk to your assistant naturally:
You: The checkout page just crashed — fix it.
Claude: (calls
get_runtime_errors→get_error_detail) FoundOPENerror[9e84385bb1]:TypeError: Cannot read properties of undefined (reading 'code')atsrc/checkout/total.ts:17:38. I added a guard for optionalcouponincalculateTotalCentsand calledcheck_fix— error[9e84385bb1]is now markedresolvedin.agentsensor/status.json.
Who it's for
- Developers using AI coding agents: stop acting as the manual copy-paste bridge between terminal errors, Chrome DevTools, and chat windows (Claude Code, Codex, Antigravity, Cursor, Windsurf, Copilot).
- Full-stack teams: catch backend route crashes and frontend React component render errors in one unified stream.
- Monorepo teams: automatic workspace root detection and sub-package path resolution out of the box.
Quick start
1. Run your dev server with agentsensor
Prefix your normal dev command with npx -y agentsensor-mcp run -- (or install globally with npm i -g agentsensor-mcp and use agentsensor run --):
npx -y agentsensor-mcp run -- npm run dev
Your terminal output and colors stay completely unchanged, and .agentsensor/ is automatically added to .gitignore.
2. Connect your AI coding agent (one-time setup)
Claude Code
claude mcp add agentsensor -- npx -y agentsensor-mcp
OpenAI Codex (~/.codex/config.toml)
[mcp_servers.agentsensor]
command = "npx"
args = ["-y", "agentsensor-mcp"]
Antigravity / Cursor / Windsurf / GitHub Copilot (mcp_config.json)
{
"mcpServers": {
"agentsensor": {
"command": "npx",
"args": ["-y", "agentsensor-mcp"]
}
}
}
3. Trigger a bug and ask your agent
Ask your agent:
"Fix the error I just hit."
MCP tools
| Tool | Parameters | Description |
|---|---|---|
get_runtime_errors |
since_minutes?, limit? (default 10), all_sessions?, include_resolved?, project? |
Returns active OPEN errors from the current dev session (or last 24h), grouped by stack signature with error_id, file:line:column, occurrence count, and timestamps. |
get_error_detail |
error_id, project? |
Returns the full source-mapped stack trace (user [app] frames highlighted, node_modules frames collapsed), the ~30 log lines before the crash, and the command/browser URL. |
check_fix |
error_id, since?, project? |
Checks whether error_id recurred after a code edit. Reports still_failing or not_seen (and moves the error from open to resolved in .agentsensor/status.json). |
resolve_error |
error_id?, project? |
Explicitly marks a specific error_id (or all currently open errors) as resolved in .agentsensor/status.json. Automatically reopens if triggered again. |
How it works
flowchart LR
Dev["agentsensor run -- npm run dev"] -->|"Terminal stream + Browser hook"| Parser["Stack Trace & Bundler Parser"]
Parser -->|"Dedupe & sync"| Store[".agentsensor/status.json + errors.jsonl"]
Store -->|"Read"| MCP["agentsensor-mcp (stdio)"]
MCP <-->|"MCP Tools"| Agent["Claude Code / Codex / Antigravity / Cursor"]
- Terminal + Browser Capture:
agentsensor runspawns your dev command with--enable-source-mapsand a lightweight preload hook (agentsensor-mcp/register). It watchesstdout/stderrfor server/bundler errors and automatically injects a tiny listener into/@vite/clientand Next.js dev chunks to catch browser crashes (window.onerror,unhandledrejection, Reactconsole.error) viaPOST /__agentsensoron the same dev server port. - Line-Number-Independent Fingerprinting: Errors are hashed by error type, normalized message, and top app file/function (excluding line numbers so signatures stay stable even after the agent edits the file).
- Live Status Board (
.agentsensor/status.json): Every error starts inopen. When the agent fixes the code and runscheck_fix(orresolve_error), the error moves toresolved. If that error ever fires again later, it automatically moves back toopen. - Multi-Project Root Resolution:
agentsensor-mcplocates the right.agentsensor/directory using MCP client workspaceroots, the--projectflag /AGENTSENSOR_PROJECTenv var, or by walking up from the current working directory.
Try the included broken app
Clone the repo and run the planted-bug demo server:
git clone https://github.com/arif-js/agentsensor.git
cd agentsensor
npm install && npm run build
AUTO_TRIGGER=1 node dist/cli.js run -- npx tsx examples/broken-app/server.ts
Then ask your MCP-connected agent: "Check runtime errors and fix the bug in examples/broken-app/server.ts."
Contributing
Issues and pull requests are welcome! Before submitting a PR:
npm run lint
npm run typecheck
npm test
npm run build
License
Questions sur AgentSensor MCP
Comment ajouter AgentSensor MCP à Claude Code ?
Exécutez claude mcp add agentsensor -- npx -y agentsensor-mcp dans votre terminal. Ajoutez --scope user pour le rendre disponible dans tous les projets.
Comment ajouter AgentSensor MCP à Cursor ?
Ouvrez ~/.cursor/mcp.json et ajoutez le serveur sous mcpServers, avec la configuration Cursor indiquée dans la section d'installation ci-dessus.
Quels outils AgentSensor MCP fournit-il ?
Il expose 4 outils, dont get_runtime_errors, get_error_detail, check_fix, resolve_error.
Nécessite-t-il des modifications de code pour fonctionner ?
Non, il fonctionne sans aucune modification de code en enveloppant votre script de développement existant.
Quels runtimes sont pris en charge ?
Il prend actuellement en charge l'écosystème Node.js, JavaScript et TypeScript, incluant des frameworks comme Next.js, Vite et Remix.
Prend-il en charge Python ou Go ?
Non, les runtimes autres que Node comme Python, Go et Rust ne sont pas encore pris en charge, bien qu'ils soient prévus pour de futures versions.
Mes données sont-elles envoyées dans le cloud ?
Non, l'outil est 100 % local, sans compte, sans cloud et sans télémétrie.