codecastStream coding agent sessions (Claude Code, Codex, Gemini CLI, etc.) to a Discord channel in real-time via webhook. Use when invoking coding agents and wantin...
Install via ClawdBot CLI:
clawdbot install allanjeng/codecastLive-stream coding agent sessions to Discord. Zero AI tokens burned.
First-time setup: see references/setup.md for webhook creation, unbuffer install, bot token, and smoke test.
Launch with exec background:true. Background exec sessions survive agent turns and OpenClaw fires notifyOnExit automatically when the process ends.
exec background:true command:"{baseDir}/scripts/dev-relay.sh -w ~/projects/myapp -- claude -p --dangerously-skip-permissions --output-format stream-json --verbose 'Your task here'"
Note the session ID from the response ā use it to monitor via process.
| Flag | Description | Default |
|------|------------|---------|
| -w | Working directory | Current dir |
| -t | Timeout | 1800 |
| -h | Hang threshold | 120 |
| -n | Agent display name | Auto-detected |
| -r | Rate limit (posts/60s) | 25 |
| --thread | Post into a Discord thread | Off |
| --skip-reads | Hide Read tool events | Off |
| --review | PR review mode | ā |
| --parallel | Parallel tasks mode | ā |
| --resume | Replay session | ā |
For PR review, parallel tasks, Discord bridge, and Codex structured output: see references/advanced-modes.md.
echo '{"channel":"<invoking-channel-id>","relayDir":"<relay-dir>","pid":<PID>}' > /tmp/codecast-pending-<PID>.json
The breadcrumb file tells the heartbeat precheck where to post results when the session completes. It auto-detects completion by checking if the PID is still alive.
That's it. When the process ends, OpenClaw's notifyOnExit fires a system event + heartbeat request. The heartbeat handler reads the result from the relay dir's stream.jsonl and posts to the invoking channel.
OpenClaw handles this natively:
tools.exec.notifyOnExit: true (default) ā system event + heartbeat on process exit/tmp/dev-relay-sessions/Backup: Append this to the inner agent's prompt for an additional signal:
When completely finished, run: openclaw system event --text "Done: <brief summary>" --mode now
process poll sessionId:<id> # Check status
process log sessionId:<id> # View recent output
process kill sessionId:<id> # Stop session
| Agent | Output Mode | Status |
|-------|------------|--------|
| Claude Code | stream-json | Full support |
| Codex | --json JSONL | Full support |
| Any CLI | Raw ANSI | Basic support |
/tmp/dev-relay-sessions/.json (auto-removed on end)/tmp/dev-relay.XXXXXX/stream.jsonl (7-day auto-cleanup)process submit sessionId: data:"message" Generated Mar 1, 2026
Enables real-time streaming of coding agent outputs like Claude Code to a Discord channel, allowing distributed teams to observe and collaborate on development tasks transparently. This is ideal for code reviews, debugging sessions, or onboarding new developers by making AI-assisted coding visible without burning additional AI tokens. It supports tools like unbuffer for smooth streaming and includes options for timeouts and rate limiting to manage session flow.
Uses the PR review mode to stream AI agent analyses of pull requests directly to Discord, providing instant feedback to development teams. This facilitates continuous integration by making review processes observable and interactive, with features like thread-based discussions and session tracking. It helps in maintaining code quality and speeding up review cycles without manual intervention.
Streams live coding demonstrations from AI agents like Codex to Discord channels for educational purposes, allowing instructors to showcase coding techniques and problem-solving in real-time. Students can follow along, ask questions, and review session logs later, enhancing learning through transparent, interactive sessions. The setup includes options for parallel tasks and replay modes to accommodate different learning paces.
Monitors and logs AI agent sessions for auditing and compliance in regulated industries, streaming outputs to Discord for real-time oversight. This ensures transparency in automated development tasks, with features like event logging and completion detection to track agent activities. It supports various CLI tools and can be integrated into existing workflows for secure, observable AI operations.
Facilitates team collaboration by streaming coding agent sessions to Discord during project sprints, making progress visible and enabling quick feedback loops. Includes options for working directory management and session resumption to handle complex tasks across multiple phases. This helps in coordinating remote teams and maintaining project momentum with minimal setup overhead.
Offers a cloud-based platform with enhanced features like advanced analytics, custom integrations, and priority support for streaming AI agent sessions to Discord. Revenue is generated through monthly or annual subscriptions based on team size and usage tiers, targeting enterprises and mid-sized companies. This model includes value-added services such as setup assistance and dedicated customer success management.
Provides a free version with basic streaming capabilities and limited sessions, while premium add-ons offer advanced modes like PR review, parallel tasks, and extended logging. Revenue comes from one-time purchases or tiered subscriptions for these add-ons, appealing to individual developers and small teams. This model encourages adoption through low entry barriers and scales with user needs.
Targets large organizations with custom deployments, including on-premise solutions, dedicated support, and integration with existing tools like Slack or Jira. Revenue is generated through enterprise licensing fees, consulting services for setup and customization, and ongoing maintenance contracts. This model focuses on security, compliance, and scalability for high-stakes environments.
š¬ Integration Tip
Ensure unbuffer or python3 is installed for smooth streaming, and set up Discord webhooks properly to avoid connection issues during agent sessions.
Guide for creating effective skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends Claude's capabilities with specialized knowledge, workflows, or tool integrations.
Provides a 7-step debugging protocol plus language-specific commands to systematically identify, verify, and fix software bugs across multiple environments.
A comprehensive skill for using the Cursor CLI agent for various software engineering tasks (updated for 2026 features, includes tmux automation guide).
Write, run, and manage unit, integration, and E2E tests across TypeScript, Python, and Swift using recommended frameworks.
Control and operate Opencode via slash commands. Use this skill to manage sessions, select models, switch agents (plan/build), and coordinate coding through Opencode.
Coding style memory that adapts to your preferences, conventions, and patterns for consistent coding.