dashli-website-status-collector
v0.0.1
Published
[![Build Status](https://travis-ci.org/goodfield/dashli-website-status-collector.svg?branch=master)](https://travis-ci.org/JedWatson/react-select) [![Coverage Status](https://coveralls.io/repos/goodfield/dashli-website-status-collector/badge.svg?branch=ma
Downloads
1
Readme
Website Status Collector for Dashli
Requests a url and returns the status and the response time.
Installation
yarn add dashli-website-status-collector
Usage
import websiteStatus from 'dashli-website-status-collector';
dashli.addCollector(
'google-status',
websiteStatus({ title: 'Google', url: 'https://www.google.com' }),
{ cron: '* * * * *' });
Configuration Options
| Property | Optional | Default | Description :---|:---|:---|:--- | title | no | - | Title | | url | no | - | url to request | | method | yes | GET | http method to use | | headers | yes | - | http headers to use (format {a:'1'} or {b:['1','2','3']}) | | method | yes | GET | http method to use | | timeout | yes | 1000 | timout in milliseconds | | test | yes | - | string to search on the response body | | historySize | yes | 30 | number of values to store in the history |
License
This project is licensed under the MIT License - see the LICENSE file for details