Files
Lyon ecddd9a630 feat: add code agent M3 skill control path
Adds the Code Agent -> Skill CLI -> HWLAB API /v1/m3/io controlled M3 IO path with route/audit/evidence/blocker payloads and tests proving no direct gateway/box/patch-panel or OpenAI fallback hardware control.
2026-05-23 20:52:40 +08:00

18 lines
564 B
JavaScript

#!/usr/bin/env node
import { runM3IoSkillCommand } from "./src/m3-io-skill-client.mjs";
try {
const result = await runM3IoSkillCommand(process.argv.slice(2));
const pretty = process.argv.includes("--pretty");
process.stdout.write(`${JSON.stringify(result, null, pretty ? 2 : 0)}\n`);
process.exitCode = result.ok ? 0 : 2;
} catch (error) {
process.stdout.write(`${JSON.stringify({
ok: false,
status: "failed",
code: "skill_cli_failed",
message: error instanceof Error ? error.message : String(error)
})}\n`);
process.exitCode = 1;
}