MCP & Hooks
How the Vibeless local MCP server and hooks connect to your coding agent: the files each one-click installer writes, the default hooks, and the markers Vibeless uses.
Last updated:
On this page
The Vibeless desktop app runs a local MCP server on your own computer, at http://127.0.0.1:<port>/mcp. MCP (the Model Context Protocol) is the standard way a coding agent calls external tools. Hooks are commands the agent runs at set moments, such as the start of a session. Together they hand the project record to your agent.
This page is the technical summary. The full walkthrough, with the install dialog, the hook builder, and troubleshooting, is in Connecting agents.
Supported agents
Vibeless installs into 7 agents, each with one click. Gemini CLI is experimental, and recording from live sessions of GitHub Copilot, Antigravity, and Gemini CLI is not yet verified. Other agents have no manual setup path.
| Agent | Context injection | Recorders | Risky-command gate |
|---|---|---|---|
| Claude Code | Session-start digest; prompt reminder | Prompt, file edits, shell commands, turn end | Yes |
| Codex | Session-start digest; prompt reminder | Prompt, file edits, shell commands, turn end | No |
| Cursor | None; a rules file asks the agent to call the tools | File edits, shell commands, turn end | No |
| OpenCode (1.19.4 or any 2.x) | Instructions file at session start; the plugin adds the reminder to every request | Prompt, file edits, shell commands, turn end, through the plugin | No |
| GitHub Copilot | Session-start digest through a hook; reminder through a block in .github/copilot-instructions.md | Prompt, file edits, shell commands, turn end (.github/hooks/vibeless.json) | No |
| Antigravity | Session-start digest through a hook; reminder through an always-on rules file | Prompt, file writes and edits, shell commands, turn end | No |
| Gemini CLI (experimental) | Session-start digest and prompt reminder, presented to the model as read-only information | Prompt, file writes and edits, shell commands, turn end | No |
Under GitHub Copilot, Antigravity, and Gemini CLI, Vibeless adds no confirmation prompt of its own before a risky command. The risk alert still fires.
GitHub Copilot, Antigravity, and Gemini CLI each have a row in Connected agents and a card in the setup wizard. The Install Vibeless hooks dialog still has a Gemini tab and an Antigravity tab: the Gemini tab installs only your own hooks, and the Antigravity tab writes a Vibeless instructions block to AGENTS.md, not Antigravity hooks.
One-click install
- Open the project, select Dashboard in the sidebar, then the Agents tab.
- On the Connected agents card, find your agent's row. Install is enabled when the row shows Detected, which means the app found the agent's folder (for example
.claude,.codex,.cursor, or.opencode) in the project or your home folder. For Antigravity it looks for.agentsin the project, orantigravity,antigravity-cli,antigravity-ide, orconfigunder~/.gemini. For GitHub Copilot it looks for~/.copilot, or.github/copilot-instructions.mdor.github/hooksin the project. For Gemini CLI, create a.geminifolder or aGEMINI.mdin the project if the row shows Not detected. - Select Install. The Install Vibeless for <agent> dialog lists the main files Vibeless will write or modify.
- Select Confirm.
- Expand Last action on the row to see each file written and any warnings.
- Restart the agent or open a new session so it loads the new configuration.
The setup wizard that opens once after you create a project runs the same install in its last step. Installing, reinstalling, and uninstalling are human-only actions: they need a key that only the Vibeless window holds.
Files written per agent
| Agent | Files Vibeless writes or modifies | Ignored by git |
|---|---|---|
| Claude Code | .mcp.json, .claude/settings.json, envelope files in .vibeless/hooks/ | Yes |
| Codex | .codex/config.toml, .codex/hooks.json, envelope files in .vibeless/hooks/ | Yes |
| Cursor | .cursor/mcp.json, .cursor/rules/vibeless.md, .cursor/hooks.json | mcp.json only; the rules file can be shared with your team |
| OpenCode | .opencode/opencode.json, .opencode/plugins/vibeless.ts, .vibeless/hooks/opencode-session-start.md, and after the first digest build .vibeless/hooks/opencode-user-prompt-submit.json | Yes |
| GitHub Copilot | .mcp.json (the same entry Claude Code uses), .github/hooks/vibeless.json, a managed block in .github/copilot-instructions.md, .vibeless/hooks/copilot-session-start.json | All but the instructions file. Install is refused while git tracks .mcp.json |
| Antigravity | .agents/mcp_config.json, .agents/hooks.json, .agents/rules/vibeless.md, .vibeless/hooks/antigravity-session-start.json | .agents/mcp_config.json and the envelope file only. .agents/hooks.json holds this machine's Vibeless project id: commit it only when the project is shared through team sync. Install is refused while git tracks .agents/mcp_config.json |
| Gemini CLI | .gemini/settings.json, envelope files in .vibeless/hooks/ | Yes. Install is refused while git tracks .gemini/settings.json |
The MCP entry points the agent at http://127.0.0.1:<port>/mcp with an Authorization: Bearer header that carries the project token. No spawned command and no environment variable are written. You never paste a port or a token.
An envelope file is a pre-written JSON file holding the text a hook injects. The hook reads it with a one-line node command. A recorder is also a one-line node command. It reads the app's port and a local token from your home folder when it runs, so no port or token is written into the project for the recorders. OpenCode's plugin reads them the same way.
The OpenCode installer refuses a project that already has .opencode/opencode.jsonc, because OpenCode would load both files. Rename it to opencode.json and install again.
How Vibeless marks what it writes
| File | Marker |
|---|---|
.mcp.json (Claude Code and GitHub Copilot) | A top-level _vibeless_managed key, next to mcpServers. It lists the agents that use the entry |
.claude/settings.json | No key; Vibeless hook entries are recognized by a vibeless-hook marker in their command, or a command that reads from .vibeless/hooks/ |
.codex/config.toml | # vibeless-managed-start and # vibeless-managed-end comments around the Vibeless block |
.codex/hooks.json | A top-level _vibeless_managed key |
.cursor/mcp.json | A _vibeless_managed key under mcpServers |
.cursor/rules/vibeless.md | A marked block |
.opencode/opencode.json | An X-Vibeless-Managed header inside the Vibeless MCP entry, because OpenCode rejects keys it does not know |
.agents/mcp_config.json (Antigravity) | The same X-Vibeless-Managed header |
.agents/hooks.json (Antigravity) | The Vibeless entries sit under one hook named vibeless |
.agents/rules/vibeless.md (Antigravity) | The Vibeless text sits between <!-- vibeless:start --> and <!-- vibeless:end --> |
.gemini/settings.json (Gemini CLI) | The same X-Vibeless-Managed header, and each Vibeless hook entry carries "_vibeless": "system" |
.github/hooks/vibeless.json (GitHub Copilot) | A Vibeless file as a whole |
.github/copilot-instructions.md (GitHub Copilot) | The Vibeless text sits between <!-- vibeless:start --> and <!-- vibeless:end --> |
One vibeless entry in .mcp.json serves both Claude Code and GitHub Copilot. A .mcp.json whose Vibeless marker lists no agent Vibeless knows shows a Retry on the Claude Code and GitHub Copilot rows.
Uninstall on the agent's row uses these marks. It removes only the Vibeless entries and the .gitignore lines Vibeless added, so your own MCP servers, hooks, and rules stay as they are. Reinstall rewrites the Vibeless entries with the current port, token, and hook text.
An uninstall or disconnect that cannot cleanly remove the Vibeless entries is refused with nothing changed: for example when an agent's hooks file is not valid JSON, holds something you added next to the Vibeless recorders, or cannot be written. The row says which file to fix, and Retry runs it again.
Port, manifest, and token
- Port. The MCP server listens on a fixed loopback port that stays the same across restarts. If another program takes it, the app picks a new one and rewrites every installed agent's configuration.
- Manifest. The app writes
~/.vibeless/manifest.json, which lists the app's internal bridge port and every project with its token. The MCP server reads it on every request to work out which project the request belongs to. - Project token. Each project has its own random 64-character token. It tells Vibeless which project the agent works on, so an agent never sees another project's data. To reach a related project, an agent passes that project's id in a tool's
projectargument. See Related projects. - Startup repair. The app re-runs every installer each time it starts, so installed agents pick up changes such as new hooks.
Rotate the token
Rotate the token if you think it has leaked.
- Select Rotate token at the top of the Connected agents card.
- Read the Rotate project MCP token dialog. It names the installed agents the new token affects.
- Select Rotate token.
- When the dialog lists the agents that need rewriting, select Reinstall all.
- In each open agent session, reconnect the MCP server (for example
/mcp reconnectin Claude Code).
The old token stops working at once. A configuration that still holds it gets 401 invalid_project_token on its next call.
Hooks
The system hooks
Vibeless installs these by default. You do not create them on the Hooks card.
| Hook | Event | Agents | What it does |
|---|---|---|---|
| Session start | session_start | Claude Code, Codex; OpenCode through its instructions file | Injects the session digest: project name, goal, tech stack, constraints, related projects, architecture overview, and key decisions, plus a staleness warning when the Agent map may be behind. The active ticket and current phase are not included; agents fetch those through MCP. |
| Prompt submit | user_prompt_submit | Claude Code, Codex; OpenCode through its plugin | Named Governance Reminder in tool output. Adds a short reminder to every prompt and records the prompt. |
| Tool use (recorder) | post_tool_use | Claude Code, Codex, Cursor; OpenCode through its plugin | After each file edit or shell command, posts the file path and tool name, or the command text, to the app. In Claude Code it fires for Edit, Write, MultiEdit, NotebookEdit, and Bash. In Cursor it is installed on afterFileEdit and afterShellExecution. |
| Stop (recorder) | stop | Claude Code, Codex, Cursor; OpenCode through its plugin | Tells the app the agent finished a turn. |
| Risky-command gate | pre_tool_use | Claude Code only | Before a shell command that is a risk action, such as a production deploy, a package publish, a force push, a dropped table, or a recursive delete from / or ~, asks you to approve it. It asks only in the default, accept-edits, and auto permission modes, and only for the main agent. Any error lets the command run. |
For GitHub Copilot, Antigravity, and Gemini CLI, see the table in Supported agents at the top of this page.
The recorders print nothing, never block the agent, and exit without error when the app is closed. In Claude Code, Codex, and Cursor they get 5 seconds and end themselves before the agent's limit; a normal run takes no longer than before. In GitHub Copilot, Antigravity, and Gemini CLI the limit is 2 seconds. They post only to the app on this computer and never send file contents. Their records feed ticket receipts. On a paid plan, Jev checks each receipt built from them, and that check sends parts of the receipt off this computer. See Logs.
Cursor has no hook that injects context. .cursor/rules/vibeless.md tells the agent which Vibeless tools to call at the moments a context hook would fire on Claude Code. Following those rules is up to the agent, so this is less reliable than native hooks.
Your own hooks
The Hooks card on the Dashboard's Agents tab lets you add hooks of your own, with a guided builder or a free-form editor. Hooks you write can use any of 7 events. Vibeless translates each one to the agent's own name for it.
| Event | When it fires |
|---|---|
session_start | A new agent session begins |
user_prompt_submit | You send a prompt |
pre_tool_use | Before the agent uses a tool |
post_tool_use | After the agent uses a tool |
stop | The agent finishes a turn |
pre_compact | Before the agent compacts its context |
pre_shell_execution | Before the agent runs a shell command |
Saving a hook stores it in Vibeless. It reaches an agent only after you install it from the Install Vibeless hooks dialog, which has tabs for Claude Code, Codex, Cursor, Gemini, and Antigravity. Hooks you write cannot be installed into OpenCode. Whether a hook can stop the agent depends on your command and on that agent's own hook rules. See Connecting agents for the builder, the install dialog, and the stale-path banner.
Verifying the connection
After installing, ask your agent:
Call vibeless_get_project_context and tell me what project I have open.
If the answer describes your Vibeless project, the MCP server is connected and the tools are available.
Available tools
The MCP server offers 26 tools, the same set for every project. No tool calls an LLM itself, and calling a tool uses no credits. On a paid plan, though, Jev checks the receipts that vibeless_update_task_status (moving a ticket to review or done) and vibeless_attach_report produce, and each check uses credits. An answer from vibeless_justify_receipt does not start a check. The MCP tool reference has inputs and outputs for each tool, and MCP tools reference explains each one in plain language.
| Group | Tools |
|---|---|
| Orientation | vibeless_declare_intent, vibeless_get_project_context, vibeless_get_adapter_info, vibeless_get_hooks |
| Spec map and code | vibeless_get_node, vibeless_search_specs, vibeless_spec_neighbors, vibeless_get_architecture, vibeless_list_constraints, vibeless_check_constraint, vibeless_topology_summary, vibeless_topology_query |
| Phases and tickets | vibeless_get_phase_spec, vibeless_list_open_tasks, vibeless_get_task_spec, vibeless_create_task, vibeless_update_task_status, vibeless_get_active_ticket, vibeless_set_active_ticket, vibeless_add_task_comment, vibeless_attach_report, vibeless_justify_receipt |
| Decisions and drift | vibeless_log_decision, vibeless_list_decisions, vibeless_run_drift_check, vibeless_get_version_history |