/** * GitHubGraphQLClient — Resilient GitHub GraphQL API client. * * Features: exponential backoff with jitter, rate limit tracking, * preemptive throttling, cursor-based pagination, variable sanitization. * * Wraps @octokit/graphql as the HTTP transport. */ import type { IGraphQLClient } from '../../../container/interfaces.js'; import type { ILogger } from '../../../shared/logger.js'; import type { ICredentialManager, RateLimitState, RetryConfig, PageInfo, PaginatedQueryOptions } from './types.js'; export declare class GitHubGraphQLClient implements IGraphQLClient { private readonly credentialManager; private readonly logger; private octokitClient; private rateLimitState; private readonly retryConfig; constructor(credentialManager: ICredentialManager, logger: ILogger, config?: Partial); query(queryString: string, variables?: Record): Promise; mutate(mutation: string, variables?: Record): Promise; /** * Execute a query with custom headers (e.g., GraphQL-Features: sub_issues). * Package-internal — not part of IGraphQLClient interface. */ queryWithHeaders(queryString: string, variables?: Record, headers?: Record): Promise; /** * Execute a mutation with custom headers (e.g., GraphQL-Features: sub_issues). * Package-internal — not part of IGraphQLClient interface. */ mutateWithHeaders(mutation: string, variables?: Record, headers?: Record): Promise; /** * Fetch all pages of a paginated query. * Uses cursor-based pagination following GitHub's connection pattern. */ queryAllPages(queryString: string, variables: Record, extractNodes: (data: unknown) => TNode[], extractPageInfo: (data: unknown) => PageInfo, options?: PaginatedQueryOptions): Promise; /** Expose rate limit state for monitoring/testing */ getRateLimitState(): RateLimitState | undefined; private executeWithRetry; private ensureClient; private preemptiveThrottle; private updateRateLimitFromError; private calculateDelay; private sanitizeVariables; /** Overridable sleep for testing */ protected sleep(ms: number): Promise; } //# sourceMappingURL=graphql-client.d.ts.map