Stratal API Reference
    Preparing search index...

    Interface ApplicationConfig

    interface ApplicationConfig {
        exceptionHandler?: Constructor<ExceptionHandler>;
        logging?: { formatter?: "json" | "pretty"; level?: LogLevel };
        module: DynamicModule | ModuleClass<object>;
        versioning?: VersioningOptions;
    }

    Hierarchy (View Summary)

    Index

    Properties

    exceptionHandler?: Constructor<ExceptionHandler>

    Custom exception handler class.

    Extend ExceptionHandler and override register() to configure custom reporting, rendering, and post-processing of exceptions.

    When not provided, DefaultExceptionHandler is used (standard severity-based logging and JSON error responses).

    new Stratal({
    module: AppModule,
    exceptionHandler: AppExceptionHandler,
    })
    logging?: { formatter?: "json" | "pretty"; level?: LogLevel }

    Logging configuration. Defaults: level=INFO, formatter='json'

    module: DynamicModule | ModuleClass<object>

    Root application module

    versioning?: VersioningOptions

    API versioning configuration. When provided, enables URI-based versioning for controllers.