UNPKG

fetchero

Version:

_A type-safe, proxy-based HTTP & GraphQL client for modern applications._

37 lines (36 loc) 1.09 kB
import { GraphQLProxy, ProxyContext } from '../types'; import { HttpClient } from '../core/http-client'; /** * GraphQL proxy implementation with enhanced error handling */ export declare class GraphQLProxyFactory { private httpClient; private baseUrl; private headers; private static readonly GRAPHQL_OPERATIONS; constructor(httpClient: HttpClient, baseUrl: string, headers: Record<string, string>); /** * Creates GraphQL proxy */ createProxy(ctx: ProxyContext): GraphQLProxy; /** * Optimized GraphQL operation validation */ private isValidGraphQLOperation; /** * Creates operation-specific proxy */ private createOperationProxy; /** * Creates GraphQL query builder with improved caching */ private createQueryBuilder; /** * Builds GraphQL operation with enhanced error handling and validation */ private buildGraphQLOperation; /** * Executes GraphQL query with comprehensive error handling */ private executeGraphQLQuery; }