Optionalapq?: GraphqlApqOptionsAPQ (Automatic Persisted Queries) configuration. Absent → APQ disabled.
OptionalbuildContext?: (input: GraphqlContextInput) => unknown | Promise<unknown>Custom context builder. Receives services and request, returns context value.
OptionaldocumentCacheSize?: numberMaximum number of documents to cache. Defaults to 1000. Set to 0 to disable.
OptionalformatError?: (error: unknown) => unknownCustom error formatter applied after masking.
Optionalgraphiql?: booleanEnable GraphiQL UI. Defaults to true.
OptionalgraphqlModule?: GraphqlModuleLikeInjected graphql module to use instead of lazy loading. Required when the application uses its own graphql copy.
Optionalintrospection?: booleanEnable schema introspection. Defaults to true.
OptionalmaskInternalErrors?: booleanMask internal errors. Defaults to true.
OptionalmaxBatchSize?: numberMaximum number of requests in a batch. 0 (default) disables batching;
an array body is still refused with 400. Set above 0 to enable.
OptionalmaxDepth?: numberMaximum query depth. Defaults to 10. Set to 0 to disable.
Bounds NESTING only. A document can be two levels deep and still ask for
a hundred thousand fields, because every alias is a separate field — see
GraphqlPluginOptions.maxNodes, which bounds that dimension.
OptionalmaxNodes?: numberMaximum number of fields a document may resolve, counting every alias separately and expanding each fragment spread at its spread site.
Omitted or 0, unbounded — the released behaviour. The only limit then
standing between an alias bomb and the process is the request-body size,
which one HTTP request can exhaust: 100,000 aliases at depth 2 is a
~2 MB document.
Left off by default because a legitimate large document in an existing application would otherwise start being refused. Pick a budget from the largest query your own clients issue and set it.
Optionalpath?: stringPath for the GraphQL endpoint. Defaults to '/graphql'.
OptionalrootValue?: unknownRoot value passed to execute.
Optionalsubscriptions?: GraphqlSubscriptionsOptionsSubscription transport configuration. Absent → no transport routes are registered (byte-identical to M51 behavior).
OptionalvalidationRules?: unknown[]Additional validation rules to append.
Union of schema construction options — mutually exclusive arms.
Supplying both arms results in a compile error due to the
?: neverfields.