Engineering
Coding agent finished a PR — webhook handoff to Grok Bot
Repo work ends in the coding agent; desktop smoke tests and ops never get a clean handoff.
What hurt
Sakan (@sakansokan) wired coding agents (Cursor / ChatGPT / Claude) to a Grok Bot for the next step — desktop smoke test, ops, follow-up — without a public “call my bot” API. Pattern: Grok Bot webhook routine → copy URL/key → PATH helper POSTs JSON → Cursor rule says when to run handoff-to-one. Test with a real webhook payload (Routines → Run now has no payload). Tip with author-quoted Cursor rule.
What to install or create
Webhook is the official doorbell from desktop coding agents to your bot. Keep secrets out of the prompt. One rule per handoff inbox.
Bots
Ops handoff bot
On webhook: read payload, tell you what was handed off, do the next concrete desktop/ops steps — not invent work.
Plugins
None on day one. Follow the first-run steps.
Files
PATH helper (e.g. handoff-to-one) that POSTs JSON to the webhook URL; webhook key / optional Authorization in env.
Routines
Webhook routine named e.g. “Coding agent handoff” — fires only on POST, not empty Run now.
The prompt
Cursor rule — when to hand off
Quoted from @sakansokan thread (2026-09-14).
When I ask to hand off to Grok Bot / One, or desktop/ops follow-up is needed outside the repo, run handoff-to-one "summary…" — only when I asked or gave a standing handoff instruction.
First run
- 1Read https://x.com/sakansokan/status/2099590909713068273 (full 9-beat thread).
- 2Create/pick a Grok Bot and add a webhook routine (e.g. “Coding agent handoff”) that reads the payload, reports what landed, and does concrete next steps only.
- 3Copy Webhook URL, Webhook key, and optional Authorization header exactly; export them on the machine where Cursor/codex/claude runs.
- 4Drop a PATH helper that POSTs JSON to that URL — keep secrets out of the prompt.
- 5Add the author-quoted Cursor rule; test with a real POST payload (not Routines → Run now).
Approval fence
Handoff summary only triggers work you already asked for. No inventing extra ops. Secrets stay in env, never in the prompt.
What to tweak
Steal webhook handoff + Cursor rule. Coding agent does repo; Grok Bot does desktop/ops.
Source
Sakan @sakansokan · Original post
Not affiliated with xAI. We did not write this prompt. Third-party template terms still apply.
Pro pack
PR & deploy watcher: reviews, deploy checks, error triage
Wakes on GitHub, deploy and error events. It reviews each PR, checks the live site after deploys and triages error spikes, and hands small fixes to a cloud coding agent. Nothing merges or deploys without you.