@omnigraph/raml
Version:
This package generates `GraphQLSchema` instance from **RAML API Document** (`.raml`) file located at a URL or FileSystem by resolving the JSON Schema dependencies. It uses `@omnigraph/json-schema` by generating the necessary configuration.
15 lines (14 loc) • 668 B
text/typescript
import type { MeshFetch } from '@graphql-mesh/types';
import type { JSONSchemaOperationConfig } from '@omnigraph/json-schema';
import type { RAMLLoaderOptions } from './types.cjs';
/**
* Generates the options for JSON Schema Loader
* from RAML Loader options by extracting the JSON Schema references
* from RAML API Document
*/
export declare function getJSONSchemaOptionsFromRAMLOptions({ source, cwd: ramlFileCwd, operations: extraOperations, endpoint: forcedBaseUrl, fetch, schemaHeaders, selectQueryOrMutationField, }: RAMLLoaderOptions): Promise<{
operations: JSONSchemaOperationConfig[];
cwd: string;
endpoint: string;
fetch?: MeshFetch;
}>;