# PUT

## Arguments <a href="#arguments" id="arguments"></a>

| Name       | Type     | Description                                             | Optional |
| ---------- | -------- | ------------------------------------------------------- | -------- |
| handler    | Function | The function to call to handle the route action         | No       |
| middleware | Array    | An array of middleware functions to use for this method | Yes      |

## Usage <a href="#usage" id="usage"></a>

Using the method is simply, passing it within the `route` function like so

```javascript
const { router, methods, response } = require('octoris')

function handler (ctx) {
  return response.send(200, 'OKAY!')
}

router.route(['/'], [methods.PUT(handler)])

```
