openclaw/openclaw · error · Error
Unsupported ClickClack target: ${raw}
Error message
Unsupported ClickClack target: ${raw} What it means
Thrown at the end of parseClickClackTarget (target.ts:28). The input is split on ':'; if a prefix and body both exist but the prefix is not one of the recognized kinds (channel, thread, dm), the target is rejected rather than guessed, to avoid silently misrouting messages.
Source
Thrown at extensions/clickclack/src/target.ts:28
const value = raw.trim();
if (!value) {
throw new Error("ClickClack target is required");
}
const [prefix, ...rest] = value.split(":");
const body = rest.join(":").trim();
if (prefix === "channel" && body) {
return { chatType: "group", kind: "channel", id: body };
}
if (prefix === "thread" && body) {
return { chatType: "group", kind: "thread", id: body };
}
if (prefix === "dm" && body) {
return { chatType: "direct", kind: "dm", id: body };
}
if (!body) {
return { chatType: "group", kind: "channel", id: value };
}
throw new Error(`Unsupported ClickClack target: ${raw}`);
}
/** Formats a parsed ClickClack target back into canonical target syntax. */
export function buildClickClackTarget(target: ClickClackTarget): string {
return `${target.kind}:${target.id}`;
}
/** Normalizes user-entered ClickClack target text for channel routing. */
export function normalizeClickClackTarget(raw: string): string {
return buildClickClackTarget(parseClickClackTarget(raw));
}
/** Reports whether a target string can be offered to the ClickClack parser. */
export function looksLikeClickClackTarget(raw: string): boolean {
return /^(channel|thread|dm):/i.test(raw.trim()) || raw.trim().length > 0;
}
View on GitHub (pinned to 01804a7531)
Solutions
- Use a recognized prefix: 'channel:', 'thread:', or 'dm:'.
- For a plain channel name with no prefix semantics, pass it bare (no colon) so it is treated as a channel.
Example fix
// before
parseClickClackTarget("group:general")
// after
parseClickClackTarget("channel:general") Defensive patterns
Strategy: type-guard
Validate before calling
const KNOWN_PREFIXES = /^(channel|thread|dm):/i;
function isSupportedClickClackTarget(raw: string): boolean {
const v = raw.trim();
if (!v) return false;
return !v.includes(":") || KNOWN_PREFIXES.test(v);
} Type guard
function isSupportedClickClackTarget(raw: string): boolean {
const v = raw.trim();
if (!v) return false;
return !v.includes(":") || /^(channel|thread|dm):/i.test(v);
} Prevention
- Use only channel:, thread:, dm:, or bare channel names.
- Avoid inventing prefixes like group: or user:.
When it happens
Trigger: parseClickClackTarget('user:123'), parseClickClackTarget('group:general'), parseClickClackTarget('email:a@b.com').
Common situations: Using wrong target vocabulary (assuming 'group:' or 'user:' work); a channel name that contains a colon but lacks a known prefix; copy-paste from another tool's target syntax.
Related errors
- ClickClack target is required
- browser action cannot override its run-bound target
- Secret provider "${resolved.ref.provider}" has source "${pro
- Secret provider "${resolved.ref.provider}" is not configured
- ClickClack setup code claim returned invalid v1 contract met
AI-assisted analysis of openclaw/openclaw@01804a7531 (2026-08-12).
Data as JSON: /api/errors/4a985e702157930e.
Report an issue: GitHub.