getch
TypeScript icon, indicating that this package has built-in type declarations

0.11.1 • Public • Published

getch

Unix Build Status Windows Build Status Coverage Status

Fetch wrapped and using GET with access to text, json, and binary data directly. Raises errors if a response is not a 200. Performs retries using a simple exponential backoff strategy when encountering 500s, and can send monitoring data when configured.

Adaptable using plugins to pre or post process requests and responses.

Install

yarn add getch

Usage

import getch from 'getch';

const text = await getch.text('https://a.text/endpoint');
const json = await getch.json('https://a.json/endpoint');

Readme

Keywords

none

Package Sidebar

Install

npm i getch

Weekly Downloads

1

Version

0.11.1

License

ISC

Unpacked Size

34.8 kB

Total Files

36

Last publish

Collaborators

  • simongregory