@omnigraph/thrift
Version:
25 lines (24 loc) • 1.09 kB
text/typescript
import { GraphQLSchema } from 'graphql';
import { ThriftDocument } from '@creditkarma/thrift-parser';
import { ImportFn, Logger } from '@graphql-mesh/types';
export interface GraphQLThriftLoaderOptions {
subgraphName: string;
source: string;
endpoint: string;
operationHeaders?: Record<string, string>;
serviceName: string;
baseDir?: string;
schemaHeaders?: Record<string, string>;
fetchFn?: typeof fetch;
logger?: Logger;
importFn?: ImportFn;
}
export declare function loadNonExecutableGraphQLSchemaFromIDL({ subgraphName, source, endpoint, operationHeaders, serviceName, baseDir, schemaHeaders, fetchFn, logger, importFn, }: GraphQLThriftLoaderOptions): Promise<GraphQLSchema>;
export declare function loadNonExecutableGraphQLSchemaFromThriftDocument({ subgraphName, baseNamespace, namespaceASTMap, location, headers, serviceName, }: {
subgraphName: string;
baseNamespace: string;
namespaceASTMap: Record<string, ThriftDocument>;
location: string;
headers: Record<string, string>;
serviceName: string;
}): GraphQLSchema;