![]() A channel per session β one per Cursor conversation |
![]() Reply from your phone β the agent picks up where it left off |
BRIDGE_PLATFORM | `activeAdapter` | `github` \| `telegram` \| `discord` |
| BRIDGE_POLL_INTERVAL | poll interval (**seconds**) | `30` |
| BRIDGE_STOP_BUDGET_MIN | wait budget, mins; resets on reply ΒΉ | `60` |
| BRIDGE_STOP_WINDOW_MIN | mins per blocking window Β² | `60` |
| BRIDGE_CA_CERT | `caCertPath` | `/path/to/ca.pem` |
| BRIDGE_GITHUB_REPO | github `owner/repo` | `you/inbox` |
| BRIDGE_GITHUB_TOKEN | github token | `gho_β¦` |
| BRIDGE_TELEGRAM_BOT_TOKEN | telegram bot token | β |
| BRIDGE_TELEGRAM_CHAT_ID | telegram forum group id | β |
| BRIDGE_TELEGRAM_ALLOWED_USER_IDS | whitelist (csv) | `123,456` |
| BRIDGE_DISCORD_BOT_TOKEN | discord bot token | β |
| BRIDGE_DISCORD_CHANNEL_ID | discord **channel** id Β³ | β |
| BRIDGE_DISCORD_ALLOWED_USER_IDS | whitelist (csv) | `123,456` |
| BRIDGE_WORKSPACE | per-window session key | `${workspaceFolder}` |
| BRIDGE_NTFY_TOPIC | enable ntfy + set topic | `cursor-bridge-β¦` |
| BRIDGE_NTFY_PRIORITY | push priority 0β5 (0 = off) | `2` |
| BRIDGE_NTFY_SERVER | ntfy server base URL | `https://ntfy.sh` |
ΒΉ Also `stopBudgetMin` in `config.json` β the reliable knob, since the hook doesn't inherit the MCP entry's env.
Β² Also `stopWindowMin` in `config.json`. Keep below the `stop` hook `timeout` in `~/.cursor/hooks.json`.
Β³ Any existing text channel in your server; used to locate the server + category β a fresh channel is created per session alongside it (For example #General).
Per-conversation platform can also be chosen at runtime: say _"start remote chat in Telegram"_ and
the agent passes `bridge_start(adapter: "telegram")` for that conversation only.
## The wait loop (stop hook)
While remote mode is active, the `stop` hook blocks at the end of each turn waiting for your reply.
Two knobs control it:
- **`stopWindowMin`** (default **60**) β how long a single hook invocation blocks before it returns
a silent keep-alive and re-arms. Cursor caps `stop`-hook runtime at the `timeout` in
`~/.cursor/hooks.json` (default **3660s / 61 min**); probing showed no hidden cap below that, so
one ~60-min window means just **one paid keep-alive turn per hour** while you're away.
- **`stopBudgetMin`** (default **60**) β the total time to keep waiting across re-arms. It **resets
on every reply**, so it's really "keep waiting up to N minutes since your last message."
The loop ends when you reply, type in Cursor, send `stop` in the thread, or call `bridge_stop`.
## Push notifications (ntfy)
GitHub never notifies you about your **own** activity β and the agent posts as _you_ (self-mentions
and self-assignment don't notify either). So to get a phone alert on the GitHub channel without a
second account, cursor-chat-bridge can fire an out-of-band push via [ntfy](https://ntfy.sh) on
every summary. It's free, account-less, open-source, self-hostable, and deep-links to the issue.
It's **off by default**. Enable it via env on the MCP entry:
1. Install the **ntfy** app (iOS/Android) or use the web app.
2. Pick a long, unguessable topic (topics are public-by-obscurity) and **subscribe** to it.
3. Set `BRIDGE_NTFY_TOPIC=cursor-bridge-