Skip to content

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

Interface: RoutesConfig

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

Properties

authenticationModule?

ts
optional authenticationModule?: string;

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

Authentication module path used by generated routes.


basePath?

ts
optional basePath?: string;

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

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


bodyCoercion?

ts
optional bodyCoercion?: boolean;

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

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:281

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:269

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


middleware?

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

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

Middleware provider.


middlewareTemplate?

ts
optional middlewareTemplate?: string;

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

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


noWriteIfUnchanged?

ts
optional noWriteIfUnchanged?: boolean;

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

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:295

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:239

Directory where generated route files are written.


routesFileName?

ts
optional routesFileName?: string;

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

Filename for the generated route module.

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