Skip to content

tsoa-next / @tsoa-next/runtime / RoutesConfig

Interface: RoutesConfig ​

Defined in: packages/runtime/src/config.ts:236

Properties ​

authenticationModule? ​

ts
optional authenticationModule?: string;

Defined in: packages/runtime/src/config.ts:275

Authentication module path used by generated routes.


basePath? ​

ts
optional basePath?: string;

Defined in: packages/runtime/src/config.ts:255

Base API path; e.g. the '/v1' in https://myapi.com/v1


bodyCoercion? ​

ts
optional bodyCoercion?: boolean;

Defined in: packages/runtime/src/config.ts:289

Whether to implicitly coerce body parameters into an accepted type.

Default ​

ts
true

esm? ​

ts
optional esm?: boolean;

Defined in: packages/runtime/src/config.ts:282

When enabled, generated route imports use .js extensions for ESM output.

Default ​

ts
false

iocModule? ​

ts
optional iocModule?: string;

Defined in: packages/runtime/src/config.ts:270

IoC module path, for example ./inversify/ioc.


middleware? ​

ts
optional middleware?: "express" | "hapi" | "koa";

Defined in: packages/runtime/src/config.ts:260

Middleware provider.


middlewareTemplate? ​

ts
optional middlewareTemplate?: string;

Defined in: packages/runtime/src/config.ts:265

Custom Handlebars template path used instead of the built-in middleware template.


noWriteIfUnchanged? ​

ts
optional noWriteIfUnchanged?: boolean;

Defined in: packages/runtime/src/config.ts:250

Skips writing the route file when the generated content matches the existing file.


rewriteRelativeImportExtensions? ​

ts
optional rewriteRelativeImportExtensions?: boolean;

Defined in: packages/runtime/src/config.ts:296

When enabled, generated route imports keep .ts extensions to support TypeScript 5.7 rewriteRelativeImportExtensions.

Default ​

ts
false

routesDir ​

ts
routesDir: string;

Defined in: packages/runtime/src/config.ts:240

Directory where generated route files are written.


routesFileName? ​

ts
optional routesFileName?: string;

Defined in: packages/runtime/src/config.ts:245

Filename for the generated route module.

TypeScript-first OpenAPI generation, route generation, and runtime validation.