# rtmpdump

> A streamable wrapper around the rtmpdump CLI

Latest version **0.1.1** (published 2014-12-30) · MIT license · 0 weekly downloads

## Install

```sh
npm install rtmpdump
pnpm add rtmpdump
yarn add rtmpdump
bun add rtmpdump
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2014-12-30 |
| First published | 2014-02-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | thibauts |
| Maintainers | thibauts |
| Keywords | rtmp, rtmpdump |

## Links

- npm: https://www.npmjs.com/package/rtmpdump
- Repository: https://github.com/thibauts/node-rtmpdump
- Issues: https://github.com/thibauts/node-rtmpdump/issues
- npm.io page: https://npm.io/package/rtmpdump

## Dependencies (1)

- [split](https://npm.io/package/split.md) ~0.3.0

## Recent versions

- 0.1.1 (latest) — 2014-12-30
- 0.1.0 — 2014-02-13

## README

rtmpdump
=============
### A streamable wrapper around the rtmpdump CLI

This module is a thin wrapper around the `rtmpdump` binary. It provides 
a readable stream you can pipe to your heart's content.

The `rtmpdump` binary must be installed on your system.

The options are those used by `rtmpdump`, both short and long options are supported (see example).
`$ rtmpdump --help` to list them all.

Installation
------------

``` bash
$ npm install rtmpdump
```

Example
-------

``` javascript
var rtmpdump = require('rtmpdump');
var fs = require('fs');

var options = {
  rtmp: 'rtmp://host.tld/app/path',
  playpath: 'mp4:playpath',
  pageUrl: 'http://host.tld/somepage.html',
  swfVfy: 'http://host.tld/player.swf',
  v: null // parameter-less command line switches must have null as a value
};

var stream = rtmpdump.createStream(options);

stream.on('connected', function(info) {
  // info provides various details about the stream
  // duration, resolution, codecs, ...
  console.log(info);
});

stream.on('progress', function(kbytes, elapsed, percent) {
  console.log('%s kbytes read, %s secs elapsed, %s%%', kbytes, elapsed, percent);
});

stream.on('error', function(err) {
  // as usual, unhandled error events will throw
  console.log(err);
  process.exit(1);
});

stream.pipe(fs.createWriteStream('video.mp4'));

```

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