import type { PromptOptions, RoolSpaceInfo, SpaceMember, CurrentUser, Conversation, ConversationMeta, ConversationVisibility, RoolUserRole, InviteRole, SpaceInvite, SpaceInviteCreated } from './types.js'; import type { AuthManager } from './auth.js'; import { type RoolClientInfo } from './client-info.js'; export interface GraphQLClientConfig { graphqlUrl: string; authManager: AuthManager; clientInfo?: RoolClientInfo; onRefused?: () => Promise; } /** Space identity, access, and conversation roster returned by openSpace. */ export interface OpenSpaceResult { name: string; role: RoolUserRole; memberCount: number; conversationMeta: ConversationMeta[]; } export declare class GraphQLClient { private config; private _graphqlUrl; constructor(config: GraphQLClientConfig); get graphqlUrl(): string; setGraphqlUrl(url: string): void; setOnRefused(onRefused: () => Promise): void; listSpaces(): Promise; createSpace(name: string): Promise<{ spaceId: string; }>; duplicateSpace(sourceSpaceId: string, name: string): Promise<{ spaceId: string; }>; /** Space identity and conversation roster. Filesystem data comes from WebDAV. */ openSpace(spaceId: string): Promise; /** Fetch a single conversation's full contents (interactions) on demand. */ getConversation(spaceId: string, conversationId: string): Promise; deleteSpace(spaceId: string): Promise; renameSpace(spaceId: string, name: string): Promise; updateConversation(spaceId: string, conversationId: string, options: { name?: string; systemInstruction?: string | null; }): Promise; createConversation(spaceId: string, agent: string, visibility: ConversationVisibility): Promise; deleteConversation(spaceId: string, conversationId: string): Promise; listAgents(spaceId: string): Promise; deleteAgent(spaceId: string, agent: string): Promise; undo(spaceId: string): Promise<{ success: boolean; }>; redo(spaceId: string): Promise<{ success: boolean; }>; checkpointStatus(spaceId: string): Promise<{ canUndo: boolean; canRedo: boolean; }>; prompt(spaceId: string, prompt: string, conversationId: string, options: Omit & { attachmentRefs?: string[]; interactionId: string; }): Promise<{ message: string; modifiedObjectPaths: string[]; creditsUsed: number; }>; stopConversation(spaceId: string, conversationId: string): Promise; getCurrentUser(): Promise; updateCurrentUser(input: { name?: string; slug?: string; marketingOptIn?: boolean; }): Promise; deleteCurrentUser(): Promise; setUserStorage(key: string, value: unknown): Promise; reportEvent(event: string, url?: string): Promise; listSpaceUsers(spaceId: string): Promise; setSpaceUserRole(spaceId: string, userId: string, role: string): Promise; removeSpaceUser(spaceId: string, userId: string): Promise; createSpaceInvite(spaceId: string, role: InviteRole, options?: { email?: string; expiresInDays?: number; maxUses?: number; }): Promise; listSpaceInvites(spaceId: string): Promise; revokeSpaceInvite(spaceId: string, inviteId: string): Promise; /** * Execute an arbitrary GraphQL query or mutation. * Use this for app-specific operations not covered by the typed methods. */ query(query: string, variables?: Record): Promise; private request; } //# sourceMappingURL=graphql.d.ts.map