Skip to content

tsoa-next / @tsoa-next/runtime / BodyProp

Function: BodyProp()

ts
function BodyProp(name?): ParameterDecorator;

Defined in: packages/runtime/src/decorators/parameter.ts:15

Binds a single property from the request body to a controller parameter.

Parameters

name?

string

The property name to read from the request body. Defaults to the parameter name.

Returns

ParameterDecorator

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