UNPKG

@loopback/docs

Version:
35 lines (22 loc) 963 B
--- lang: en title: 'API docs: rest.restapplication.bodyparser' keywords: LoopBack 4.0, LoopBack 4 sidebar: lb4_sidebar permalink: /doc/en/lb4/apidocs.rest.restapplication.bodyparser.html --- <!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [@loopback/rest](./rest.md) &gt; [RestApplication](./rest.restapplication.md) &gt; [bodyParser](./rest.restapplication.bodyparser.md) ## RestApplication.bodyParser() method Bind a body parser to the server context <b>Signature:</b> ```typescript bodyParser(bodyParserClass: Constructor<BodyParser>, address?: BindingAddress<BodyParser>): Binding<BodyParser>; ``` ## Parameters | Parameter | Type | Description | | --- | --- | --- | | bodyParserClass | <code>Constructor&lt;BodyParser&gt;</code> | | | address | <code>BindingAddress&lt;BodyParser&gt;</code> | Optional binding address | <b>Returns:</b> `Binding<BodyParser>`