# @heroku/http-call

> make http requests

Latest version **5.6.1** (published 2026-08-20) · ISC license · 0 weekly downloads

## Install

```sh
npm install @heroku/http-call
pnpm add @heroku/http-call
yarn add @heroku/http-call
bun add @heroku/http-call
```

## Health

**Score 70/100 (B)** — status: active.

Positive: has types; no vulnerabilities; has provenance; recently updated; high maintenance score; high quality score.

Warnings: low downloads; no esm support.

## Facts

| | |
|---|---|
| Version | 5.6.1 |
| Published | 2026-08-20 |
| First published | 2024-12-17 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | bundled |
| Module format | CommonJS |
| Node | >=16.0.0 |
| Dependencies | 6 |
| Unpacked size | 55.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 14 |
| Author | Heroku |
| Maintainers | salesforce-releases, heroku-front-end, pritamnaik, akitanaka, ytakamura, jkim-sfdc |
| Keywords | http, request, rest |

## Links

- npm: https://www.npmjs.com/package/@heroku/http-call
- Repository: https://github.com/heroku/http-call
- Issues: https://github.com/heroku/http-call/issues
- npm.io page: https://npm.io/package/@heroku/http-call

## Dependencies (6)

- [chalk](https://npm.io/package/chalk.md) ^4.1.2
- [debug](https://npm.io/package/debug.md) ^4.4.3
- [is-stream](https://npm.io/package/is-stream.md) ^2.0.1
- [content-type](https://npm.io/package/content-type.md) ^1.0.5
- [tunnel-agent](https://npm.io/package/tunnel-agent.md) ^0.6.0
- [is-retry-allowed](https://npm.io/package/is-retry-allowed.md) ^2.2.0

## Alternatives

- [launchdarkly-js-client-sdk](https://npm.io/package/launchdarkly-js-client-sdk.md) — 2.5M weekly downloads
- [@elastic/elasticsearch](https://npm.io/package/@elastic/elasticsearch.md) — 2.1M weekly downloads
- [@c8y/client](https://npm.io/package/@c8y/client.md) — 15.3K weekly downloads
- [@signaldb/maverickjs](https://npm.io/package/@signaldb/maverickjs.md) — 1.7K weekly downloads
- [@bbc/http-transport-cache](https://npm.io/package/@bbc/http-transport-cache.md) — 1.2K weekly downloads

## Recent versions

- 5.6.1 (latest) — 2026-08-20
- 5.6.0-beta.0 (beta) — 2026-07-09
- 5.6.0 — 2026-07-09
- 5.5.3 — 2026-06-11
- 5.5.2 — 2026-06-03
- 5.5.1 — 2026-01-29
- 5.5.0 — 2025-05-19
- 5.4.0 — 2025-01-06
- 5.4.0-beta.1 — 2024-12-19
- 5.4.0-0 — 2024-12-17

## README

http-call
=========

[![Greenkeeper badge](https://badges.greenkeeper.io/heroku/http-call.svg)](https://greenkeeper.io/)

Usage
-----

```js
const {HTTP} = require('http-call')
const {body: user} = await HTTP.get('https://api.github.com/users/me')
// do something with user
// automatically converts from json

// for typescript specify the type of the body with a generic:
const {body: user} = await HTTP.get<{id: string, email: string}>('https://api.github.com/users/me')

// set headers
await HTTP.get('https://api.github.com', {headers: {authorization: 'bearer auth'}})
```

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