import type { CrowdyAgentBudgetV1, CrowdyAgentEventV1, CrowdyAgentHeartbeatV1, CrowdyAgentLeaseV1, CrowdyAgentMode, CrowdyAgentPreemptionReason, CrowdyAgentRegisteredToolV1, CrowdyAgentRunV1, CrowdyAgentSessionV1, CrowdyAgentApprovalV1, CrowdyAgentToolCallAckV1, CrowdyAgentToolResultV1 } from './types.js'; export interface CrowdyAgentEdgeV1 { readonly cursor: string; readonly node: T; } export interface CrowdyAgentPageInfoV1 { readonly hasNextPage: boolean; readonly endCursor?: string; } export interface CrowdyAgentConnectionV1 { readonly edges: readonly CrowdyAgentEdgeV1[]; readonly pageInfo: CrowdyAgentPageInfoV1; readonly nodes: readonly T[]; readonly endCursor?: string; readonly hasNextPage: boolean; } export interface CrowdyAgentCreateSessionInputV1 { readonly appId: string; readonly projectId?: string; readonly gridId?: string; readonly mode: CrowdyAgentMode; readonly requestedModel?: string; readonly providerDataConsent?: boolean; readonly idempotencyKey: string; } export interface CrowdyAgentAttachResultV1 { readonly session: CrowdyAgentSessionV1; readonly clientEpoch: string; /** Highest contiguous sequence already persisted for this client cursor. */ readonly replayAfterSeq: string; } export interface CrowdyAgentHistoryPageV1 { readonly edges: readonly CrowdyAgentEdgeV1[]; readonly pageInfo: CrowdyAgentPageInfoV1; readonly events: readonly CrowdyAgentEventV1[]; readonly hasMore: boolean; } export interface CrowdyAgentEventSubscriptionHandlersV1 { next(event: CrowdyAgentEventV1): void; error(error: unknown): void; complete(): void; } export interface CrowdyAgentEventSubscriptionV1 { close(): void; } interface SessionMutationInput { readonly sessionId: string; readonly clientEpoch: string; readonly idempotencyKey: string; } /** * Provider-neutral durable orchestration transport. A generated GraphQL * adapter implements only this interface; tests and other hosts inject fakes. */ export interface CrowdyStudioAgentTransportV1 { getSession(sessionId: string): Promise; listSessions(input: { readonly appId: string; readonly after?: string; readonly first: number; }): Promise>; history(input: { readonly sessionId: string; readonly afterSeq: string; readonly first: number; }): Promise; toolDescriptors(sessionId: string): Promise<{ readonly registryDigest: string; readonly tools: readonly CrowdyAgentRegisteredToolV1[]; }>; budget(sessionId: string): Promise; createSession(input: CrowdyAgentCreateSessionInputV1): Promise; attachClient(input: { readonly sessionId: string; readonly clientInstanceId?: string; readonly idempotencyKey: string; }): Promise; setMode(input: SessionMutationInput & { readonly mode: CrowdyAgentMode; }): Promise; acknowledgeEvents(input: SessionMutationInput & { readonly throughSeq: string; }): Promise<{ readonly throughSeq: string; }>; heartbeat(input: SessionMutationInput): Promise; sendMessage(input: SessionMutationInput & { readonly message: string; }): Promise; approveTool(input: SessionMutationInput & { readonly toolCallId: string; readonly argumentHash: string; }): Promise; rejectTool(input: SessionMutationInput & { readonly toolCallId: string; readonly argumentHash: string; readonly reason?: string; }): Promise; toolResult(input: SessionMutationInput & { readonly result: CrowdyAgentToolResultV1; }): Promise; grantLease(input: SessionMutationInput & { readonly scopes: readonly string[]; readonly durationSeconds: number; readonly controlledEntityId: string; readonly hostCapabilityRevision: string; }): Promise; revokeLease(input: SessionMutationInput & { readonly leaseId: string; readonly reason: CrowdyAgentPreemptionReason; }): Promise; pause(input: SessionMutationInput): Promise; resume(input: SessionMutationInput): Promise; cancelRun(input: SessionMutationInput & { readonly runId: string; }): Promise; closeSession(input: SessionMutationInput): Promise; subscribeEvents(input: { readonly sessionId: string; readonly afterSeq: string; readonly clientEpoch: string; }, handlers: CrowdyAgentEventSubscriptionHandlersV1): CrowdyAgentEventSubscriptionV1 | Promise; } /** * Exact operation mapping implemented by `CrowdyAgentGraphQLTransport`. * This metadata cannot issue a raw GraphQL request. */ export declare const CROWDY_AGENT_GRAPHQL_OPERATIONS_V1: Readonly<{ readonly getSession: "crowdyStudioAgentSession"; readonly listSessions: "crowdyStudioAgentSessions"; readonly history: "crowdyStudioAgentHistory"; readonly toolDescriptors: "crowdyStudioAgentToolDescriptors"; readonly budget: "crowdyStudioAgentBudget"; readonly createSession: "crowdyStudioAgentCreateSession"; readonly attachClient: "crowdyStudioAgentAttachClient"; readonly setMode: "crowdyStudioAgentSetMode"; readonly acknowledgeEvents: "crowdyStudioAgentAcknowledgeEvents"; readonly heartbeat: "crowdyStudioAgentHeartbeat"; readonly sendMessage: "crowdyStudioAgentSendMessage"; readonly approveTool: "crowdyStudioAgentApproveTool"; readonly rejectTool: "crowdyStudioAgentRejectTool"; readonly toolResult: "crowdyStudioAgentToolResult"; readonly grantLease: "crowdyStudioAgentGrantLease"; readonly revokeLease: "crowdyStudioAgentRevokeLease"; readonly pause: "crowdyStudioAgentPause"; readonly resume: "crowdyStudioAgentResume"; readonly cancelRun: "crowdyStudioAgentCancelRun"; readonly closeSession: "crowdyStudioAgentCloseSession"; readonly subscribeEvents: "crowdyStudioAgentEvents"; }>; export {}; //# sourceMappingURL=transport.d.ts.map