# cryptomonitor

> cryptomonitor

Latest version **1.0.0** (published 2018-09-03) · MIT license · 0 weekly downloads

## Install

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

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2018-09-03 |
| First published | 2018-03-22 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 905.7 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| Author | libracredit |
| Maintainers | gongyinan |

## Links

- npm: https://www.npmjs.com/package/cryptomonitor
- npm.io page: https://npm.io/package/cryptomonitor

## Dependencies (3)

- [express](https://npm.io/package/express.md) ^4.16.3
- [request](https://npm.io/package/request.md) ^2.88.0
- [body-parser](https://npm.io/package/body-parser.md) ^1.18.3

## Recent versions

- 1.0.0 (latest) — 2018-09-03
- 0.3.0 — 2018-05-25
- 0.2.0 — 2018-03-28
- 0.1.0 — 2018-03-23
- 0.0.1 — 2018-03-23
- 0.0.0 — 2018-03-22

## README

# cryptomonitor

This is a crypto price monitor support ifttt-like experience, with configurable parameters such as price feed, margin call ratio, etc.

install 
```
npm i cryptomonitor
```

demo
```

const queryCTL = require("cryptomonitor");  

let config = {
    assets: [
        {
            coin: "ethereum",
            sym: "eth",
            count: 0.5
        },
        {
            coin: "bitcoin",
            sym: "btc",
            count: 0.1
        }
    ],
    debt: 400
};


let margincall = 2;
let margincall_callback = (r) => {
    console.log("alert!! " + r);
}

async function test() {
    var rate = await queryCTL(config, margincall, margincall_callback);
    console.log(rate);
}

test();


```

## CTL ifttt extension
Demo code in extension/httpServer.js

You can find margincall service in ifttt.
![Alt text](https://raw.githubusercontent.com/gyn7561/cryptomonitor/master/img/img_20180622183856.jpg)

Set your collateral eth count,lend stable coin count and alert ctl line, if your ctl is lt alert line,you will receive alert.
![Alt text](https://raw.githubusercontent.com/gyn7561/cryptomonitor/master/img/img_20180622183908.jpg)

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