@naisys/hub-protocol
v3.0.3
Published
[internal] Protocol types and schemas for NAISYS Hub communication
Readme
@naisys/hub-protocol
← Back to packages | ← Back to main README
Shared message types, event names, and Zod schemas for communication between NAISYS runners (clients), the hub server, and the supervisor over WebSocket + REST.
This package is the single source of truth for the wire protocol — both ends of every hub connection compile-check against the same definitions.
What's inside
events.ts/eventMap.ts— typed Socket.IO event names and their payload shapesschemas/agents/— agent state, heartbeat, session messagesschemas/comms/— costs, logs, and mail message envelopesschemas/identity/— Codex auth and user identity payloadsschemas/infra/— config snapshots, connect errors, host registration, model metadata
All schemas are Zod-based and exported alongside their inferred TypeScript types.
Usage
import { type AgentHeartbeat, hubEvents } from "@naisys/hub-protocol";Consumed by naisys (client side), @naisys/hub (server side), and @naisys/supervisor (also a client).
License
MIT
