loading…
Search for a command to run...
loading…
An MCP server that bridges VS Code Copilot to your mobile device, allowing you to monitor task progress and respond to decision prompts while away from your des
An MCP server that bridges VS Code Copilot to your mobile device, allowing you to monitor task progress and respond to decision prompts while away from your desk. It features real-time push notifications, a web-based dashboard, and interactive tools for remote code review and approval.
Monitor and respond to VS Code Copilot from your phone.
When Copilot's agent mode runs long tasks, it frequently pauses for user input. If you step away, the session stalls. AFK Mode bridges Copilot and your phone through an MCP server — so you can watch progress, get notifications, and respond to prompts without being at your desk.
Run this in your project folder:
npx afk-mode-mcp --setup
This creates .vscode/mcp.json and .github/prompts/afk-workflow.prompt.md — done. Copilot will start AFK Mode automatically when it needs it.
/afk-workflow — Copilot routes all progress and decisions to your phonePush notifications work automatically — no extra setup needed.
If you prefer to configure manually, add this to .vscode/mcp.json in your workspace:
{
"servers": {
"afk-mode-mcp": {
"type": "stdio",
"command": "npx",
"args": ["-y", "afk-mode-mcp"],
"env": {
"AFK_PORT": "7842"
}
}
}
}
AFK Mode is a single Node.js process that serves two roles simultaneously:
┌──────────────┐ stdio ┌──────────────────────┐ WebSocket ┌──────────────┐
│ VS Code │◄──────────────►│ MCP + Web Server │◄────────────────►│ Mobile Web │
│ Copilot │ │ (single process) │ HTTP (static) │ App (PWA) │
│ Agent Mode │ │ │◄────────────────►│ │
└──────────────┘ └──────────────────────┘ └──────────────┘
get_current_web_app_url and renders a QR codeThe server exposes 4 tools to Copilot:
| Tool | Purpose |
|---|---|
get_current_web_app_url |
Returns the connection URL + QR code for pairing your phone |
get_afk_status |
Checks if AFK mode is on and a client is connected |
notify_session_progress |
Sends a progress update to the phone (info, warning, error, success, milestone) |
get_user_decision |
Asks the user a question and blocks until they respond (confirm, choice, text, or diff review) |
notify_session_progressSends real-time progress to the phone. Categories control the icon and urgency:
Supports optional progress bars ({ current, total, label }) and file change lists.
get_user_decisionBlocks Copilot until the user responds on their phone. Decision types:
Includes a configurable timeout (default 5 minutes) with an optional default value.
Push notifications alert you on your phone even when the browser tab is in the background (e.g., for errors or pending decisions). They work out of the box — no configuration required.
Push uses the Web Push standard with VAPID (Voluntary Application Server Identification). VAPID is an open W3C standard — no Google account, Firebase setup, or API keys required.
/api/vapid-key and subscribes via the Push APISince VAPID keys are generated per session (and push subscriptions are in-memory), each developer runs an isolated instance — no shared secrets, no cross-talk between team members.
| Variable | Default | Description |
|---|---|---|
AFK_PORT |
7842 |
HTTP/WebSocket server port |
git clone <repo-url> && cd afk-mode-mcp
pnpm install
# Run server with hot reload
pnpm dev:server
# Run webapp dev server (Vite, port 5173)
pnpm dev:webapp
# Build everything
pnpm build
# Start production server
pnpm start
# Lint and format
pnpm lint # Check for lint errors
pnpm lint:fix # Auto-fix lint errors
pnpm format # Format all source files
pnpm format:check # Check formatting without writing
ws), @modelcontextprotocol/sdktypescript-eslint + React Hooks pluginweb-push with VAPIDqrcode (data-URI PNG)Добавь это в claude_desktop_config.json и перезапусти Claude Desktop.
{
"mcpServers": {
"afk-mode": {
"command": "npx",
"args": []
}
}
}PRs, issues, code search, CI status
Database, auth and storage
Reference / test server with prompts, resources, and tools.
Secure file operations with configurable access controls.