New adapter type for invoking OpenClaw agents via the gateway protocol. Registers in server, CLI, and UI adapter registries. Adds onboarding wizard support with gateway URL field and e2e smoke test script. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
24 lines
450 B
TypeScript
24 lines
450 B
TypeScript
import pc from "picocolors";
|
|
|
|
export function printOpenClawGatewayStreamEvent(raw: string, debug: boolean): void {
|
|
const line = raw.trim();
|
|
if (!line) return;
|
|
|
|
if (!debug) {
|
|
console.log(line);
|
|
return;
|
|
}
|
|
|
|
if (line.startsWith("[openclaw-gateway:event]")) {
|
|
console.log(pc.cyan(line));
|
|
return;
|
|
}
|
|
|
|
if (line.startsWith("[openclaw-gateway]")) {
|
|
console.log(pc.blue(line));
|
|
return;
|
|
}
|
|
|
|
console.log(pc.gray(line));
|
|
}
|