UNPKG

@essentialai/cogent-bridge

Version:

Cogent Bridge — cross-agent comms for Claude Code, OpenAI Codex and Slack. Codex users: install with `curl -fsSL https://cogent.tools/install.sh | sh`, then start with `cogent-codex` for real-time peer wake.

20 lines • 667 B
import type { MessageRecord } from "../types.js"; export interface PollResult { messages: MessageRecord[]; events: unknown[]; } export interface PollOptions { endpoint: string; sessionId: string; peerId: string; token: string; lastMessageId?: string; fetchImpl?: typeof fetch; } /** * One call to the relay's poll endpoint. Returns the peer-relevant messages since * `lastMessageId` (all of them on the first, priming poll). Throws on a non-2xx * response so the loop can back off; the caller owns retry/backoff. */ export declare function pollOnce(opts: PollOptions): Promise<PollResult>; //# sourceMappingURL=poll-client.d.ts.map