UNPKG

@omnigraph/json-schema

Version:

This package generates GraphQL Schema from JSON Schema and sample JSON request and responses. You can define your root field endpoints like below in your GraphQL Config for example;

3 lines (2 loc) 273 B
import { GraphQLObjectType, GraphQLTypeResolver } from 'graphql'; export declare function getTypeResolverFromOutputTCs(possibleTypes: readonly GraphQLObjectType[], discriminatorField?: string, statusCodeTypeNameMap?: Record<string, string>): GraphQLTypeResolver<any, any>;