Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/0xvbetsun/koa-asyncapi
AsyncAPI middleware for koa
https://github.com/0xvbetsun/koa-asyncapi
asyncapi docs koa koa2 middleware
Last synced: 28 days ago
JSON representation
AsyncAPI middleware for koa
- Host: GitHub
- URL: https://github.com/0xvbetsun/koa-asyncapi
- Owner: 0xvbetsun
- License: mit
- Created: 2021-12-06T07:38:33.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2023-11-13T18:07:50.000Z (about 1 year ago)
- Last Synced: 2024-11-14T21:42:16.095Z (about 2 months ago)
- Topics: asyncapi, docs, koa, koa2, middleware
- Language: JavaScript
- Homepage:
- Size: 87.9 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Security: SECURITY.md
Awesome Lists containing this project
README
# Koa AsyncAPI
![CI](https://github.com/VBetsun/koa-asyncapi/workflows/CI/badge.svg)
[![Known Vulnerabilities](https://snyk.io/test/github/VBetsun/koa-asyncapi/badge.svg)](https://snyk.io/test/github/VBetsun/koa-asyncapi)
[![Coverage Status](https://coveralls.io/repos/github/VBetsun/koa-asyncapi/badge.svg?branch=master)](https://coveralls.io/github/VBetsun/koa-asyncapi?branch=master)
[![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat)](http://standardjs.com/)[AsyncAPI](https://www.asyncapi.com/) middleware for [koa](https://koajs.com/)
## Install
```sh
npm i @asyncapi/generator @asyncapi/html-template koa-asyncapi
```## Usage
```javascript
import Koa from 'koa'
import { koaAsyncAPI } from 'koa-asyncapi'const app = new Koa()
app.use(koaAsyncAPI())
app.listen(3000)
```
### Middleware options| Option | Type | Default Value | Description |
| -------- | -------- | ---------------|------------------------------------------------ |
| filePath | string? | 'asyncapi.yaml'| path to the AsyncAPI specification |
| endpoint | string? | '/asyncapi' | endpoint where documentation will be available |