/**
 * @fileoverview A TaskStore wrapper that enforces session ownership on top of
 * the SDK's InMemoryTaskStore (which ignores sessionId parameters).
 *
 * This ensures that in HTTP mode, tasks created by one session cannot be
 * accessed by another session, even when using the in-memory store.
 *
 * @experimental These APIs are experimental and may change without notice.
 * @module src/mcp-server/tasks/core/sessionAwareTaskStore
 */
import type { Request, RequestId, Result } from '@modelcontextprotocol/sdk/types.js';
import type { CreateTaskOptions, Task, TaskStore } from './taskTypes.js';
/**
 * Wraps an InMemoryTaskStore to add session ownership enforcement.
 *
 * Tracks which session created each task and rejects access from
 * non-owning sessions. Tasks created without a sessionId are accessible
 * by any session (backwards-compatible with stdio/unauth flows).
 *
 * @experimental
 */
export declare class SessionAwareTaskStore implements TaskStore {
    private readonly inner;
    /** Maps taskId -> sessionId that created it */
    private readonly ownership;
    constructor(inner: TaskStore);
    createTask(taskParams: CreateTaskOptions, requestId: RequestId, request: Request, sessionId?: string): Promise<Task>;
    getTask(taskId: string, sessionId?: string): Promise<Task | null>;
    storeTaskResult(taskId: string, status: 'completed' | 'failed', result: Result, sessionId?: string): Promise<void>;
    getTaskResult(taskId: string, sessionId?: string): Promise<Result>;
    updateTaskStatus(taskId: string, status: Task['status'], statusMessage?: string, sessionId?: string): Promise<void>;
    listTasks(cursor?: string, sessionId?: string): Promise<{
        tasks: Task[];
        nextCursor?: string;
    }>;
    /**
     * Validates that the caller's session matches the task's owner.
     * Tasks created without a sessionId are accessible by any session.
     */
    private assertOwnership;
}
//# sourceMappingURL=sessionAwareTaskStore.d.ts.map