/**
 * Session Registry Types for Awake Lambda Development
 *
 * Defines the data structures for managing developer sessions
 * in the Live Dev infrastructure.
 *
 * @module runtime-awake/session-registry
 */
/**
 * Represents an active developer session for Awake Lambda Development.
 *
 * A DevSession tracks a developer's connection to the Live Dev infrastructure,
 * enabling the Proxy Lambda to route requests to the correct local CLI instance.
 *
 * @see Requirements 6.1, 6.2
 */
export interface DevSession {
    /** Partition key: unique developer identifier */
    readonly devId: string;
    /** Sort key: function name or '*' for all functions */
    readonly functionName: string;
    /** Unix timestamp (seconds) of last heartbeat */
    readonly lastHeartbeat: number;
    /** TTL for DynamoDB auto-expiry (lastHeartbeat + timeout) */
    readonly ttl: number;
    /** Developer's machine hostname for identification */
    readonly hostname: string;
    /** Application name from configuration */
    readonly appName: string;
    /** Deployment stage (dev, staging, prod) */
    readonly stage: string;
    /** CLI version for compatibility checking */
    readonly cliVersion: string;
    /** IoT client ID for this session */
    readonly iotClientId: string;
}
/**
 * Input for registering a new session.
 * Excludes computed fields (lastHeartbeat, ttl) which are set by the registry.
 */
export interface RegisterSessionInput {
    /** Unique developer identifier */
    readonly devId: string;
    /** Function name or '*' for all functions */
    readonly functionName: string;
    /** Developer's machine hostname */
    readonly hostname: string;
    /** Application name */
    readonly appName: string;
    /** Deployment stage */
    readonly stage: string;
    /** CLI version */
    readonly cliVersion: string;
    /** IoT client ID */
    readonly iotClientId: string;
}
/**
 * Configuration for the Session Registry.
 */
export interface SessionRegistryConfig {
    /** DynamoDB table name for session storage */
    readonly tableName: string;
    /** AWS region */
    readonly region: string;
    /** Session timeout in seconds (default: 120) */
    readonly timeoutSeconds?: number;
}
/**
 * Interface for the Session Registry service.
 *
 * Provides methods for managing developer sessions in the Live Dev infrastructure.
 *
 * @see Requirements 6.1, 6.2, 6.4, 6.5
 */
export interface ISessionRegistry {
    /**
     * Register or update a developer session.
     *
     * Creates a new session or updates an existing one with fresh heartbeat.
     *
     * @param input - Session registration data
     * @returns The registered session with computed fields
     *
     * @see Requirements 6.1, 6.2
     */
    registerSession(input: RegisterSessionInput): Promise<DevSession>;
    /**
     * Get an active session for a developer and function.
     *
     * Returns the session if it exists and is not stale (within TTL window).
     *
     * @param devId - Developer identifier
     * @param functionName - Function name or '*' for wildcard
     * @returns The active session or null if not found/stale
     *
     * @see Requirements 1.1, 6.3
     */
    getActiveSession(devId: string, functionName: string): Promise<DevSession | null>;
    /**
     * Mark a session as offline (deregister).
     *
     * Called during graceful shutdown (Ctrl+C) to immediately mark session as inactive.
     *
     * @param devId - Developer identifier
     * @param functionName - Function name or '*' for wildcard
     *
     * @see Requirements 6.4
     */
    deregisterSession(devId: string, functionName: string): Promise<void>;
    /**
     * Update the heartbeat timestamp for a session.
     *
     * Extends the session TTL to prevent expiry during active development.
     *
     * @param devId - Developer identifier
     * @param functionName - Function name or '*' for wildcard
     *
     * @see Requirements 6.5
     */
    heartbeat(devId: string, functionName: string): Promise<void>;
}
/**
 * Checks if a session is stale based on its lastHeartbeat and TTL.
 *
 * A session is considered stale if the current time exceeds the TTL.
 *
 * @param session - The session to check
 * @param currentTimeSeconds - Current time in Unix seconds (defaults to now)
 * @returns True if the session is stale
 *
 * @see Requirements 6.5
 */
export declare function isSessionStale(session: DevSession, currentTimeSeconds?: number): boolean;
/**
 * Validates that a DevSession has all required fields with non-null, non-empty values.
 *
 * @param session - The session to validate
 * @returns True if all required fields are present and valid
 *
 * @see Requirements 6.2
 */
export declare function isValidSession(session: DevSession): boolean;
