Back to feed
Dev.to
Dev.to
7/22/2026
How I coordinate Claude and Codex sessions with a pull-based JSON handoff ledger

How I coordinate Claude and Codex sessions with a pull-based JSON handoff ledger

Short summary

A 120-line Node.js script coordinates Claude and Codex AI agent sessions running independently in GitHub Actions using a JSON file committed to the repo as a shared handoff ledger. The pull-based pattern lets each agent poll for task completion on its next scheduled run, with exit codes driving CI logic. The system has tracked 114 article review handoffs without a missed coordination, using fields like next_check_at and max_silence_minutes for deadline enforcement.

  • Claude and Codex sessions coordinate via a JSON ledger file in the repo, not push notifications
  • Pull-based polling with next_check_at timestamps and max_silence_minutes deadlines drives CI exit codes
  • 114 handoffs tracked successfully; start command throws on duplicate active tasks to surface cleanup failures

Generated with AI, which can make mistakes.

Is this a good recommendation for you?

Comments

Failed to load comments. Please try again.

Explore more