MCPcopy
hub / github.com/FoalTS/foal / ApiDefineExample

Function ApiDefineExample

packages/core/src/core/openapi/decorators.ts:124–128  ·  view source on GitHub ↗
(
  key: string, example: IApiExample | IApiReference | ((controller: any) => IApiExample | IApiReference)
)

Source from the content-addressed store, hash-verified

122}
123
124export function ApiDefineExample(
125 key: string, example: IApiExample | IApiReference | ((controller: any) => IApiExample | IApiReference)
126): OpenApiDecorator {
127 return AddMetadataProperty('api:components:examples', key, example);
128}
129
130export function ApiDefineRequestBody(
131 key: string, requestBody: IApiRequestBody | IApiReference | ((controller: any) => IApiRequestBody | IApiReference)

Callers 2

ControllerClass · 0.90
ControllerClass · 0.90

Calls 1

AddMetadataPropertyFunction · 0.85

Tested by

no test coverage detected