# node-faultline-proto

> faultline用nodejsライブラリ(プロト)

Latest version **0.1.6** (published 2017-08-29) · MIT license · 0 weekly downloads

## Install

```sh
npm install node-faultline-proto
pnpm add node-faultline-proto
yarn add node-faultline-proto
bun add node-faultline-proto
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.6 |
| Published | 2017-08-29 |
| First published | 2017-06-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 4 |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | sinofseven |
| Maintainers | sinofseven |

## Links

- npm: https://www.npmjs.com/package/node-faultline-proto
- Repository: https://github.com/sinofseven/node-faultline-proto
- Homepage: https://github.com/sinofseven/node-faultline-proto#readme
- Issues: https://github.com/sinofseven/node-faultline-proto/issues
- npm.io page: https://npm.io/package/node-faultline-proto

## Dependencies (4)

- [request](https://npm.io/package/request.md) ^2.81.0
- [airbrake](https://npm.io/package/airbrake.md) 2.0.1
- [stack-trace](https://npm.io/package/stack-trace.md) ^0.0.10
- [lodash.merge](https://npm.io/package/lodash.merge.md) ^4.6.0

## Recent versions

- 0.1.6 (latest) — 2017-08-29
- 0.1.8 — 2017-07-24
- 0.1.5 — 2017-06-20
- 0.1.4 — 2017-06-20
- 0.1.2 — 2017-06-20
- 0.1.1 — 2017-06-20
- 0.1.0 — 2017-06-20

## README

[![NPM](https://nodei.co/npm/node-faultline-proto.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/node-faultline-proto/)
[![NPM](https://nodei.co/npm-dl/node-faultline-proto.png?height=2)](https://nodei.co/npm/node-faultline-proto/)

# node-faultline-proto 

> [faultline](https://github.com/faultline/faultline) exception and error notifier for JavaScript.

## About
unofficial faultline library for nodejs.  
I made this becase I want this.

## Installation

Using npm:

```sh
npm install node-faultline-proto
```

## Usage

```js
var faultlineJs = require('node-faultline-proto');
var faultline = faultlineJs.createClient({
                  project: 'faultline-js', 
                  apiKey: 'xxxxXXXXXxXxXXxxXXXXXXXxxxxXXXXXX',
                  endpoint: 'https://xxxxxxxxx.execute-api.ap-northeast-1.amazonaws.com/v0',
                  notifications: [
                    {
                      type: 'slack',
                      endpoint: 'https://hooks.slack.com/services/XXXXXXXXXX/B2RAD9423/WC2uTs3MyGldZvieAtAA7gQq',
                      channel: '#random',
                      username: 'faultline-notify',
                      notifyInterval: 1,
                      threshold: 1,
                      timezone: 'Asia/Tokyo'
                    }
                  ]
                });
faultline.notify(new Error("test"));
```

## Integration

### handle excptions

The common use case for this module is to catch all 'uncaughtException' events on the process object and send them to Faultline.

```js
var faultlineJs = require('node-faultline-proto');
var faultline = faultlineJs.createClient({
                  project: 'faultline-js', 
                  apiKey: 'xxxxXXXXXxXxXXxxXXXXXXXxxxxXXXXXX',
                  endpoint: 'https://xxxxxxxxx.execute-api.ap-northeast-1.amazonaws.com/v0',
                  notifications: [
                    {
                      type: 'slack',
                      endpoint: 'https://hooks.slack.com/services/XXXXXXXXXX/B2RAD9423/WC2uTs3MyGldZvieAtAA7gQq',
                      channel: '#random',
                      username: 'faultline-notify',
                      notifyInterval: 1,
                      threshold: 1,
                      timezone: 'Asia/Tokyo'
                    }
                  ]
                });
faultline.handleExceptions();
throw new Error("test");
```

## References

- faultline-js is based on [airbrake/node-airbrake](https://github.com/airbrake/node-airbrake)
    - Node Airbrake is licensed under [The MIT License (MIT)](https://github.com/airbrake/node-airbrake/blob/master/LICENSE.md).

## License

MIT © Yuta Natsume

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