https://github.com/skellla/fastify-status
Returns common info about fastify server. Could be used for healthchecks and status monitoring.
https://github.com/skellla/fastify-status
fastify fastifyjs-plugin healthchecks monitoring
Last synced: about 2 months ago
JSON representation
Returns common info about fastify server. Could be used for healthchecks and status monitoring.
- Host: GitHub
- URL: https://github.com/skellla/fastify-status
- Owner: SkeLLLa
- License: mit
- Created: 2018-08-16T14:55:58.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2023-07-18T22:05:55.000Z (almost 2 years ago)
- Last Synced: 2025-04-25T12:48:13.121Z (2 months ago)
- Topics: fastify, fastifyjs-plugin, healthchecks, monitoring
- Language: JavaScript
- Homepage: https://gitlab.com/m03geek/fastify-status/
- Size: 1.65 MB
- Stars: 2
- Watchers: 1
- Forks: 2
- Open Issues: 29
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# fastify-status
![]()
[](https://www.npmjs.com/package/fastify-status)
[](https://www.npmjs.com/package/fastify-status)
[](https://www.npmjs.com/package/fastify-status)
[](https://github.com/SkeLLLa/fastify-metrics/actions)
[](https://gitlab.com/m03geek/fastify-status/blob/master/LICENSE)
[](https://codecov.io/gh/SkeLLLa/fastify-status)
[](https://lgtm.com/projects/g/SkeLLLa/fastify-status/)
[](https://lgtm.com/projects/g/SkeLLLa/fastify-status/)Returns common info about fastify server. Could be used for healthchecks and status monitoring.
## ToC
- [fastify-status](#fastify-status)
- [ToC](#toc)
- [Installation](#installation)
- [Usage](#usage)
- [Format](#format)## Installation
```sh
npm i fastify-status --save
```[Back to top](#toc)
## Usage
Example with default plugin options.
```js
const fastify = require('fastify');
const statusPlugin = require('fastify-status');const app = fastify();
app.register(statusPlugin, {
info: '/__info__',
alive: '/__alive__',
});
```Use `alive` for healthchecks and `info` to get information and some stats of your server.
If `info` or `alive` is not present in config, then apropriate route will not be added.
[Back to top](#toc)
## Format
```js
{
uptime: '0d 0h 0m 10s',
memory: {
rss: '50Mb',
external: '40Mb',
heapTotal: '30Mb',
heapUsed: '20Mb',
},
start: '2020-05-10T07:41:20.389Z',
env: 'test',
name: 'my-server',
version: '1.0.0',
node: 'v14.0.0'
}
```[Back to top](#toc)
## Changelog
See [changelog](CHANGELOG.md).
[Back to top](#toc)
## See also
- [under-pressure](https://github.com/fastify/under-pressure) - more advanced healthcheck.
## License
Licensed under [MIT](./LICENSE).
[Back to top](#toc)