bsormagec / wowza-nodejs

A Wowza client for HTTPProviders

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

A very incomplete WowzaMediaServer Client for Node.js

Installation

npm install wowza-control

Usage

var Wowza, client, _cfg;

Wowza = require('wowza-control');

_cfg = {
	"username": 'someUser',
	"password": 'somePassword',
	"host": 'http://some.server:8086'
};

client = new Wowza(_cfg);

//find client connections of first app
client.startStats();

client.on('stats', function(d) {
	console.log(d)
});

//Start recording a stream
// Full option list on client.recordingOptions
start = new Date();

opts = {
  outputPath: '/mnt/s3/recordings',
  outputFile: "" + (start.getUTCFullYear()) + "-" + (start.getUTCMonth() + 1) + "-" + (start.getUTCDate()) + "T" + (start.getUTCHours()) + "." + (start.getUTCMinutes()) + "." + (start.getUTCSeconds()) + ".mp4"
};

client.startRecording('streamName', opts);

setTimeout(function(){
	client.stopRecording('live-1', opts);
}, 5*60);

License

What the fuck Public License

As usual, licensed under the WTFPL.

About

A Wowza client for HTTPProviders

License:Do What The F*ck You Want To Public License


Languages

Language:CoffeeScript 100.0%