@loopback/docs
Version:
Documentation for LoopBack 4
32 lines (21 loc) • 835 B
Markdown
lang: en
title: 'API docs: rest.baseroute._constructor_'
keywords: LoopBack 4.0, LoopBack 4
sidebar: lb4_sidebar
permalink: /doc/en/lb4/apidocs.rest.baseroute._constructor_.html
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@loopback/rest](./rest.md) > [BaseRoute](./rest.baseroute.md) > [(constructor)](./rest.baseroute._constructor_.md)
## BaseRoute._constructor_
Construct a new route
<b>Signature:</b>
```typescript
constructor(verb: string, path: string, spec: OperationObject);
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| verb | <code>string</code> | http verb |
| path | <code>string</code> | http request path pattern |
| spec | <code>OperationObject</code> | OpenAPI operation spec |