# restc

> A server-side middleware to visualize REST requests.

Latest version **0.5.0** (published 2020-11-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install restc
pnpm add restc
yarn add restc
bun add restc
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.5.0 |
| Published | 2020-11-03 |
| First published | 2016-11-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 414.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1335 |
| Maintainers | yanagieiichi, lujjjh |

## Links

- npm: https://www.npmjs.com/package/restc
- Repository: https://github.com/ElemeFE/restc
- Homepage: https://github.com/ElemeFE/restc#readme
- Issues: https://github.com/ElemeFE/restc/issues
- npm.io page: https://npm.io/package/restc

## Recent versions

- 0.5.0 (latest) — 2020-11-03
- 0.4.3 — 2020-11-03
- 0.4.2 — 2020-01-08
- 0.4.0 — 2019-05-15
- 0.3.2 — 2018-02-07
- 0.3.1 — 2018-01-26
- 0.3.0 — 2018-01-26
- 0.2.2 — 2017-08-29
- 0.2.1 — 2017-07-18
- 0.1.0 — 2017-06-26
- 0.0.7 — 2017-04-10
- 0.0.6 — 2017-03-09
- 0.0.5 — 2017-03-09
- 0.0.4 — 2016-12-11
- 0.0.3 — 2016-11-28
- … 2 more at https://npm.io/package/restc/versions

## README

<p align="center">
  <img src="/docs/images/logo.svg" alt="restc" width="150" height="150">
</p>

<p align="center">
  <img src="https://img.shields.io/circleci/project/github/ElemeFE/restc.svg" alt="CircleCI (all branches)">
</p>

<p align="center">
  <a href="https://elemefe.github.io/restc/intro/">中文文档</a>
</p>

## Introduction

restc is an HTTP server middleware, aiming to enhance debugging experience on RESTful APIs.

It can be easily integrated with popular HTTP frameworks. You will see:

- formatted JSON responses in the browser
- a debug panel with which you can send GET, POST, PUT, PATCH and DELETE requests directly in the browser

You can even share a request by sharing its URL directly to others and everything will be automatically filled in the panel.

## Getting Started

    npm install --save restc

Use the middleware

```js
const restc = require('restc');
// for express
app.use(restc.express());
// for koa
app.use(restc.koa());
// ...and koa2
app.use(restc.koa2());
// for hapi
server.register(restc.hapi)
// for hapi of legacy version
server.register([{
  register: restc.hapiLegacy
}], (err) => {
  if (err) {
    throw err
  }
})
```

---
_Source: https://npm.io/package/restc · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
