1.1.0 • Published 11 years ago
node-rtorrent v1.1.0
node-rtorrent
control rtorrent with your nodejs project !

Install rtorrent
check in config file (/home/user/.rtorrent.rc) that this line exist :
scgi_port = 127.0.0.1:5000now rtorrent is available (only from localhost) with scgi on :
127.0.0.1:5000/set xmlrpc connexion mode
open apache config file and add :
SCGIMount /RPC2 127.0.0.1:5000
<Location "/RPC2">
AuthType Basic
AuthName "Rtorrent"
AuthUserFile /home/www-data/.rtorrent-htpasswd
Require valid-user
</Location>create a password file
htpasswd -cb /home/www-data/.rtorrent-htpasswd user passwordrestart apache
apachectl restartnow rtorrent is available with xmlrpc on
user:password@server:80/RPC2Install
npm install node-rtorrentExample
var Rtorrent = require ('node-rtorrent');
var rtorrent = new Rtorrent({
mode: 'xmlrpc',
host: 'yourserver',
port: 80,
path: '/RPC2'
user: 'bob'
pass: 'marley'
});
rtorrent.getAll(function (err, data) {
if (err) return console.log('err: ', err);
console.log(data);
// data is : {torrents: [{hash: 'XXXXXX', name: 'ubuntu.iso', path: '/xxx', bitfield: ......... }, {...}], up_total: ...}
});
rtorrent.start('XXXXXXXX', function (err, data) {
if (err) return console.log('err: ', err);
console.log(data);
});
rtorrent.loadLink(...
rtorrent.loadFile(...and more : Click here !
use from command line
USAGE: node-rtorrent cmd ...
Exemples:
node-rtorrent get download_list
node-rtorrent get d.multicall main d.name= d.get_base_path
node-rtorrent get t.multicall XXXXXXX t.id= t.url=
node-rtorrent get load "magnet:?xt=urn:xxxx"
node-rtorrent get load "http://xxx/xxx.torrent"
node-rtorrent getAll1.1.0
11 years ago
1.0.4
11 years ago
1.0.3
11 years ago
1.0.2
11 years ago
1.0.1
11 years ago
1.0.0
11 years ago
0.6.0
11 years ago
0.5.4
11 years ago
0.5.3
11 years ago
0.5.2
11 years ago
0.5.1
11 years ago
0.5.0
11 years ago
0.4.4
11 years ago
0.4.3
11 years ago
0.4.2
11 years ago
0.4.1
11 years ago
0.4.0
11 years ago
0.3.2
11 years ago
0.3.1
11 years ago
0.3.0
11 years ago
0.2.0
11 years ago