Annotation Type RequestBody
-
@Target({METHOD,PARAMETER,ANNOTATION_TYPE}) @Retention(RUNTIME) @Inherited public @interface RequestBody
The annotation may be used on a method parameter to define it as the Request Body of the operation, and/or to define additional properties for such request body.- See Also:
- Request Body (OpenAPI specification),
Parameter,Content
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description Content[]contentThe content of the request body.StringdescriptionA brief description of the request body.Extension[]extensionsThe list of optional extensionsStringrefA reference to a RequestBody defined in components RequestBodies.booleanrequiredDetermines if the request body is required in the request.booleanuseParameterTypeSchemaSet to true to resolve the request body schema from parameter type
-
-
-
Element Detail
-
description
String description
A brief description of the request body.- Returns:
- description of the request body
- Default:
- ""
-
-
-
content
Content[] content
The content of the request body.- Returns:
- array of content
- Default:
- {}
-
-
-
extensions
Extension[] extensions
The list of optional extensions- Returns:
- an optional array of extensions
- Default:
- {}
-
-
-
ref
String ref
A reference to a RequestBody defined in components RequestBodies.- Returns:
- the reference
- Since:
- 2.0.3
- Default:
- ""
-
-