Bug
When an agent running on a non-delivery channel (e.g. heartbeat, cron, webhook) calls sessions_spawn, the server-side agent param validation rejects the request:
invalid agent params: unknown channel: heartbeat
This happens because isGatewayMessageChannel() only includes deliverable channel IDs + registered plugins + webchat as the internal channel. Heartbeat/cron/webhook sessions are not represented there.
Location
server-methods.ts — agent param validation around the channel hint check:
```
const isKnownGatewayChannel = (value) => isGatewayMessageChannel(value);
const channelHints = [request.channel, request.replyChannel]...
for (const rawChannel of channelHints) {
if (normalized && normalized !== "last" && !isKnownGatewayChannel(normalized)) {
respond(false, ..., invalid agent params: unknown channel: ${normalized});
}
}
```
Suggested fix
Either:
- Skip channel validation when the channel is a known internal/non-delivery source (heartbeat, cron, webhook)
- Add these internal channels to
isGatewayMessageChannel / expand INTERNAL_MESSAGE_CHANNEL
Subagent spawning should be channel-agnostic — the parent channel identity is not relevant to child session creation.
Workaround
Wait for a live invocation (Telegram/webchat) to spawn subagents instead of relying on heartbeat ticks.
Environment
OpenClaw 2026.4.26 (be8c246)
Bug
When an agent running on a non-delivery channel (e.g.
heartbeat,cron,webhook) callssessions_spawn, the server-side agent param validation rejects the request:This happens because
isGatewayMessageChannel()only includes deliverable channel IDs + registered plugins +webchatas the internal channel. Heartbeat/cron/webhook sessions are not represented there.Location
server-methods.ts— agent param validation around the channel hint check:```
const isKnownGatewayChannel = (value) => isGatewayMessageChannel(value);
const channelHints = [request.channel, request.replyChannel]...
for (const rawChannel of channelHints) {
if (normalized && normalized !== "last" && !isKnownGatewayChannel(normalized)) {
respond(false, ...,
invalid agent params: unknown channel: ${normalized});}
}
```
Suggested fix
Either:
isGatewayMessageChannel/ expandINTERNAL_MESSAGE_CHANNELSubagent spawning should be channel-agnostic — the parent channel identity is not relevant to child session creation.
Workaround
Wait for a live invocation (Telegram/webchat) to spawn subagents instead of relying on heartbeat ticks.
Environment
OpenClaw 2026.4.26 (be8c246)