Composes and mounts a full EndpointHandler block at a specific root.
The endpoint initialization logic.
The base URI.
Middlewares and operational options.
Injects a Quatrain-compatible API middleware into the flow.
The Quatrain ApiMiddleware function.
Spawns an isolated routing scope (sub-router).
The prefix path for the router.
A new ExpressAdapter instance controlling the sub-router.
Registers a DELETE endpoint.
The URI path.
Standard Quatrain ApiHandlers or native Express middlewares.
Registers a GET endpoint.
The URI path.
Standard Quatrain ApiHandlers or native Express middlewares.
Retrieves the underlying native framework instance.
The raw Express Application or Router instance.
Registers a PATCH endpoint.
The URI path.
Standard Quatrain ApiHandlers or native Express middlewares.
Registers a POST endpoint.
The URI path.
Standard Quatrain ApiHandlers or native Express middlewares.
Registers a PUT endpoint.
The URI path.
Standard Quatrain ApiHandlers or native Express middlewares.
Configures the server to serve static files from a specified folder. It also sets up a fallback route for SPA (Single Page Application) navigation, ensuring that non-API routes return the main index.html file.
The absolute path to the directory containing static files (e.g. built frontend).
The prefix used for API routes, which will be ignored by the SPA fallback. Defaults to '/api'.
Binds the server to the network and starts listening.
The network port.
Optionalcallback: () => voidOptional completion callback.
Attaches a native Express middleware, path prefix, or sub-router.
Arguments forwarded directly to express.use (e.g. path and RequestHandlers).
Api Server adapter wrapping the
expressframework. Maps Quatrain's standardizedServerAdapterinterfaces to native Express mechanisms.