Skip to main content

REST Client for Modern APIs

Lightweight, Dependency-Free, Built with TypeScript. Compatible with Node.js, ESM, CJS, and UMD.


import RestClient from '@bishal-shrestha/rest-client';
const client = new RestClient('https://api.example.com');
const data = await client.getAsync('users');

Lightweight

No runtime dependencies and a minimal footprint. Optimized for fast installs, small bundles, and modern builds without unnecessary bloat.

Multi-Environment Support

Supports ESM, CommonJS, UMD, and TypeScript. Use it in Node.js, modern bundlers, or directly in the browser.

Built with TypeScript

Fully written in TypeScript for a type-safe API, auto-complete, and IntelliSense in modern editors

Retry & Cancel

Includes built-in retry logic with delay/backoff, request timeouts, and cancellation support using AbortController.