# url-body-stream

> Takes an array of URLs and creates a stream that emits the bodies retrieved from those URLs.

Latest version **1.2.0** (published 2015-02-27) · MIT license · 0 weekly downloads

## Install

```sh
npm install url-body-stream
pnpm add url-body-stream
yarn add url-body-stream
bun add url-body-stream
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.2.0 |
| Published | 2015-02-27 |
| First published | 2015-02-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 5 |
| Known vulnerabilities | 0 (+7 in 2 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Jim Kang |
| Maintainers | jimkang |

## Links

- npm: https://www.npmjs.com/package/url-body-stream
- Repository: git@github.com:jimkang/url-body-stream
- Homepage: https://github.com/jimkang/url-body-stream
- Issues: https://github.com/jimkang/url-body-stream/issues
- npm.io page: https://npm.io/package/url-body-stream

## Dependencies (5)

- [tape](https://npm.io/package/tape.md) ^3.5.0
- [lodash](https://npm.io/package/lodash.md) ^3.2.0
- [request](https://npm.io/package/request.md) ^2.53.0
- [queue-async](https://npm.io/package/queue-async.md) ^1.0.7
- [conform-async](https://npm.io/package/conform-async.md) ^1.1.1

## Recent versions

- 1.2.0 (latest) — 2015-02-27
- 1.1.0 — 2015-02-22
- 1.0.0 — 2015-02-20

## README

url-body-stream
==================

Takes an array of URLs and creates a stream that emits the bodies retrieved from those URLs.

Installation
------------

    npm install url-body-stream

Usage
-----

    var createURLHeadwaters = require('url-body-stream').create;

    var headwaters = createURLHeadwaters({
      authParams: {
        user: 'basicauth-username',
        pass: 'basicauth-password'
      }
    });

    // You can leave out authParams if you don't need basic http auth.

    var bodyStream = headwaters.createURLBodyStream({
      urls: [
        'http://google.com',
        'http://smidgeo.com/plan',
        'https://api.github.com/repos/jimkang/url-body-stream/commits/"
      ]
    });

    // You can also set maxConcurrentRequests in the createURLBodyStream opts to
    // tell it how many http requests to run at once. Default is 3.

    bodyStream.on('data', function logData(body) {
      console.log('A body I received via http:', body);
    });

    bodyStream.on('end', function onEnd() {
      console.log('Done getting bodies from the URLs.');
    });

Tests
-----

Run tests with `make test`.

License
-------

MIT.

---
_Source: https://npm.io/package/url-body-stream · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
