import { type SessionRelayInitResult as SdkRelaySessionInitResult } from "@opendatalabs/vana-sdk/session-relay"; import type { SessionRelayConfig, SessionInitParams, SessionPollResult } from "../core/types.js"; /** Raw response from the Session Relay init endpoint. */ export type RelaySessionInitResult = SdkRelaySessionInitResult; /** * Low-level client for the Session Relay service. * * This is a CLI adapter over the Vana SDK Session Relay integration. Session * Relay is a Vana-operated service integration for app handoff flows, not a * protocol-core primitive. * * @see {@link createSessionRelay} to create an instance. */ export interface SessionRelay { /** Creates a new session and returns the raw relay response (sessionId, deepLinkUrl, expiresAt). */ initSession(params: SessionInitParams): Promise; /** Polls the session status once. */ pollSession(sessionId: string): Promise; /** * Polls until the session reaches a terminal state (`approved`, `denied`, or `expired`). * * @param sessionId - The session to poll. * @param opts - Optional polling interval (default 2 s) and timeout (default 15 min). * @throws {@link ConnectError} with code `POLL_TIMEOUT` if the timeout is exceeded. */ pollUntilComplete(sessionId: string, opts?: { interval?: number; timeout?: number; }): Promise; } /** * Creates a low-level Session Relay client. * * Prefer the high-level {@link connect} function for most use cases. * * @param config - Session Relay configuration. * @returns A {@link SessionRelay} instance. */ export declare function createSessionRelay(config: SessionRelayConfig): SessionRelay; //# sourceMappingURL=session-relay.d.ts.map