import type { PtyHandle, Role, Channel } from './types.js';
export interface StoredSession {
    /** Intrinsic Claude session id (UUID). Stable for the row's lifetime.
     *  For `/resume` spawns this is the prior canonical id the operator
     *  pressed Resume on. After Task 258's archive-restore at /resume,
     *  claude --resume appends to the same canonical jsonl, so the
     *  StoredSession.sessionId and the on-disk jsonl basename match by
     *  construction. */
    sessionId: string;
    /** "session_<suffix>" form from the PID file. Stable, never null after
     *  /spawn returns (the spawn promise resolves on PID-file event). */
    bridgeSessionId: string;
    /** Suffix-only convenience field (no "session_" prefix). */
    bridgeSuffix: string;
    pid: number;
    /** URL from the `/remote-control` banner. Null until url-capture fires;
     *  may stay null forever if the banner never lands. The UI tolerates
     *  null. */
    url: string | null;
    startedAt: string;
    senderId: string;
    role: Role;
    channel: Channel;
    pty: PtyHandle;
    exited: boolean;
    /** Task 176 — flipped true when `releasePtyMasterFd` returns
     *  `master-fd=closed` for this session. Both exit branches set this so
     *  the second branch (whichever loses the race) can skip a redundant
     *  `pty.destroy()` that would otherwise throw "socket already
     *  destroyed" on real node-pty and turn the operator-request log
     *  line's `master-fd=closed` into a false `master-fd=close-failed`.
     *  When the first branch's destroy throws (rescued), this stays false
     *  so the second branch retries — defense in depth. */
    fdReleased: boolean;
    hidden: boolean;
    specialist: string | null;
}
export declare class SessionStore {
    private readonly bySessionId;
    add(s: StoredSession): void;
    get(sessionId: string): StoredSession | undefined;
    remove(sessionId: string): StoredSession | undefined;
    listBySender(senderId: string, opts?: {
        includeHidden?: boolean;
    }): StoredSession[];
    all(): StoredSession[];
    size(): number;
}
//# sourceMappingURL=session-store.d.ts.map