Context blueprint for request and service contexts.
Gate-less contexts may pass a plain request factory. Contexts with a
gate property must use the blueprint form
{ gate: (ports) => ports.gate, request, service } so the server owns
gate attachment and identity changes can never go stale.
The ports argument includes app ports plus ports provided during server
startup.
OptionalhooksServer hooks that wrap every registered route.
OptionalinstrumentationServer-owned request instrumentation.
The server resolves a request ID and W3C trace context for every request
before user hooks and context creation, writes x-request-id and
traceparent response headers, and records request and error events into
the resolved provider instrumentation port (ports.instrumentation, then
ports.devtools) when one is installed.
Pass false to disable headers and event recording. Context factories
still receive requestId and trace arguments.
OptionalintegrityOptional pure startup check for app workflow registrations.
Runtime integrity compares app-declared workflow artifacts against the registries passed to runtime entrypoints. It performs no filesystem, provider, database, network, worker, or background-loop work, so it is safe to run during serverless cold starts.
OptionalmapGlobal mapper for unexpected errors not handled by app error catalogs.
OptionalonGlobal caught-error observer.
OptionalonHow to handle ports that are still unbound after all providers have started.
Ports declared as deferred in definePorts(...) boot as throwing
placeholders until a provider contributes them. The default "error"
fails startup and lists the unbound port keys. Apps that bind every port
directly are unaffected.
App-owned ports available to context creation, hooks, and handlers.
OptionalproviderProvider config overrides keyed by provider name.
OptionalproviderRuntime env used by providers. Defaults to process.env.
OptionalprovidersProviders installed during server startup.
Provider ports are merged into ports before request handling and are
stopped in reverse setup order when server.stop() runs.
OptionalrequestRequest body parsing limits for JSON/text contract routes.
OptionalroutesRoute list to register up front.
OptionalvalidateWhether route-owned responses are validated against the contract's declared statuses and response schemas before they are sent.
Disable this to trade response guarantees for throughput, mirroring the
client-side validateResponses option.
Options for creating a Beignet server instance.