Skip to content

SpecSerializerOptions

@tsed/schema

Usage

typescript
import { SpecSerializerOptions } from "@tsed/schema";

See /packages/specs/schema/src/utils/getSpec.ts.

Overview

ts
interface SpecSerializerOptions extends JsonSchemaOptions {
    paths?: Record<string, any>;
    channels?: Record<string, any>;
    rootPath?: string;
    operationIdFormatter?: (name: string, propertyKey: string, path: string) => string;
    operationIdPattern?: string;
}

paths

ts
paths?: Record<string, any>;

Paths

channels

ts
channels?: Record<string, any>;

Channels

rootPath

ts
rootPath?: string;

Root path. This paths will be added to all generated paths Object.

operationIdFormatter:

ts
operationIdFormatter?: (name: string, propertyKey: string, path: string) => string;

A function to generate the operationId.

operationIdPattern

ts
operationIdPattern?: string;

A pattern to generate the operationId.

Released under the MIT License.