export interface InboxCommand { id: string; org_id: string; kind: string; payload: Record; enqueued_at: number; } /** * Enqueue a command for an SDK session to poll. Idempotent on command id. Also * records the id→session ownership (for ack authorization). cmd.org_id is the * owning org; drainCommands only returns commands whose org matches the caller's. */ export declare function enqueueCommand(sessionKey: string, cmd: InboxCommand): void; /** * Drain pending commands for a session (returns + removes them). Evicts stale * first. Only returns commands belonging to `orgId` — a cross-org command (which * should never be enqueued here given the dispatcher's org-first filter) is * dropped, never delivered. */ export declare function drainCommands(sessionKey: string, orgId: string): InboxCommand[]; /** Is this session_key one the inbox is tracking? (has pending commands) */ export declare function hasInbox(sessionKey: string): boolean; /** Store (or replace) the capability token for a session. */ export declare function setSessionToken(sessionKey: string, token: string): void; /** The capability token for a session, or undefined if none is registered. */ export declare function getSessionToken(sessionKey: string): string | undefined; /** Forget a session's token (on 'ended' lifecycle). */ export declare function dropSessionToken(sessionKey: string): void; /** The session_key a command id was enqueued for (for ack authorization). */ export declare function ackOwnerOf(id: string): string | undefined; /** Forget an id→session ownership once the command has been acked/settled. */ export declare function clearAckOwner(id: string): void; /** Total queued commands across all sessions (for /health + tests). */ export declare function inboxDepth(): number; /** Test/shutdown helper — resets inboxes, tokens, and ack-owners. */ export declare function clearInbox(): void; //# sourceMappingURL=agentInbox.d.ts.map