/** * GraphQL HTTP handler for Momentum CMS. * * Provides a framework-agnostic handler that executes GraphQL queries * against the auto-generated schema. Can be used by Express, h3, etc. */ import { type GraphQLSchema } from 'graphql'; import type { UserContext } from '@momentumcms/core'; /** Parsed GraphQL request body. */ export interface GraphQLRequestBody { query: string; variables?: Record; operationName?: string; } /** Result from executeGraphQL. */ export interface GraphQLResult { status: number; body: unknown; } /** * Execute a GraphQL request against the provided schema. */ export declare function executeGraphQL(schema: GraphQLSchema, requestBody: GraphQLRequestBody, context: { user?: UserContext; }, options?: { /** When true, reject mutation operations (e.g. for GET requests). */ readOnly?: boolean; }): Promise;