/** * Claude Code Remote HTTP API client. * * REST endpoints: * - GET /v1/sessions → list sessions * - POST /v1/sessions → create session * - GET /v1/sessions/{id} → get session * - PATCH /v1/sessions/{id} → update session (title, status) * - GET /v1/sessions/{id}/events → list events (paginated) * - POST /v1/sessions/{id}/events → post events (send message, control) * - GET /v1/sessions/{id}/share-status → get share status * - GET /v1/environment_providers/private/organizations/{orgId}/environments → list environments * - GET /v1/environment_providers/private/organizations/{orgId}/environments/{envId} → get environment */ import type { ClaudeRemoteOptions, Session, SessionListResponse, CreateSessionParams, EventsListResponse, SessionEvent, EventMessage, FileAttachment, EnvironmentListResponse } from "./types"; /** Build cookie string from options */ export declare function buildCookie(options: ClaudeRemoteOptions): string; export declare class ClaudeApi { private baseUrl; private orgUuid; private cookie; private userAgent; constructor(options: ClaudeRemoteOptions); private headers; private request; listSessions(): Promise; getSession(sessionId: string): Promise; createSession(params: CreateSessionParams): Promise; updateSession(sessionId: string, update: { title?: string; session_status?: string; }): Promise; listEvents(sessionId: string, afterId?: string): Promise; postEvents(sessionId: string, events: SessionEvent[]): Promise; /** * Send a user message to a session via the events API. */ sendMessage(params: { sessionId: string; uuid: string; message: EventMessage; parentToolUseId?: string | null; fileAttachments?: FileAttachment[]; }): Promise; getShareStatus(sessionId: string): Promise; getEnvironment(envId: string): Promise; /** * Send an interrupt control request via the events API. */ interrupt(sessionId: string): Promise; /** * Send a tool permission response via the events API. */ respondToolPermission(params: { sessionId: string; requestId: string; toolName: string; toolUseId?: string; decision: "allow" | "deny"; input?: Record; suggestions?: unknown[]; }): Promise; /** * Set permission mode for a session via the events API. */ setPermissionMode(sessionId: string, mode: string): Promise; listEnvironments(): Promise; } export declare class ApiError extends Error { status: number; body: string; url: string; constructor(status: number, body: string, url: string); } //# sourceMappingURL=api.d.ts.map