Home

Awesome

httpstat

Build Status

httpstat is a curl like tool, visualize http/https process and show the duration.

image

Reference from python httpstat and go httpstat .

Install as tool

$ npm install httpstat -g 

Usage as tool

$ httpstat http://example.com/
$ httpstat -X POST -d test http://example.com/

Install as library

$ npm install httpstat -S

Usage as library

const httpstat = require('httpstat');

httpstat('http://example.com', /* option, headers, body */).then((result) => {
  console.log(result); // time property has duration time.
}).catch((e) => {
  console.error(e);
});

API

httpstat(url, [options], [headers], [body]) - return Promise