Can't start/pause a single torrent via RPC ?
Posted: Fri Aug 05, 2016 12:10 pm
Hello
let's use curl to do this
first you need to set the cookies, my password is `deluge`
now you can stop all the torrents (which works) with:
start them all again (which works also) with :
now if you try to stop a single torrent, you need to provide its hash in the `params`, I tried the following:
but it never returns anything. also the `core.resume_torrent` has the same problem, maybe I'm not using them right ?
also, fun fact, if you pause all the torrents via curl, you won't be able to start them via the WebUI, and vise versa, why ? no one knows
let's use curl to do this
first you need to set the cookies, my password is `deluge`
Code: Select all
curl -c cookies.txt --compressed -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d '{"method": "auth.login", "params": ["deluge"], "id": 1}' http://localhost:8112/json
Code: Select all
curl -b cookies.txt --compressed -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d '{"method": "core.pause_all_torrents", "params": [], "id": 2}' http://localhost:8112/json
Code: Select all
curl -b cookies.txt --compressed -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d '{"method": "core.resume_all_torrents", "params": [], "id": 3}' http://localhost:8112/json
Code: Select all
curl -b cookies.txt --compressed -i -H "Content-Type: application/json" -H "Accept: application/json" -X POST -d '{"method": "core.pause_torrent", "params": ["7344bac975ee260aa59bb1b0c1116371b58fa147"], "id": 4}' http://localhost:8112/json
also, fun fact, if you pause all the torrents via curl, you won't be able to start them via the WebUI, and vise versa, why ? no one knows
