2010-11-04, 12:44
ok i'll try it tonight
xbmc@media:~$ curl -u "xbmc:xbmc -i -X POST -d \'\{\"jsonrpc\": \"2.0\", \"method\": \"VideoLibrary.GetTVShows\", \"params\": \{ \"start\": 0, \"fields\": \[\"genre\", \"director\", \"plot\", \"title\", \"originaltitle\", \"runtime\", \"year\", \"rating\"\] \}, \"id\": 1\}" http://127.0.0.1:8080/jsonrpccurl -u "xbmc:xbmc -i -X POST -d \'\{\"jsonrpc\": \"2.0\", \"method\": \"VideoLibrary.GetTVShows\", \"params\": \{ \"start\": 0, \"fields\": \[\"genre\", \"director\", \"plot\", \"title\", \"originaltitle\", \"runtime\", \"year\", \"rating\"\] \}, \"id\": 1\}" http://127.0.0.1:8080/jsonrpc
xbmc@media:~$
xbmc@media:~$ curl -u "xbmc:xbmc -i -X POST -d \'\{\"jsonrpc\": \"2.0\", \"method\": \"VideoLibrary.GetTVShows\", \"params\": \{ \"start\": 0, \"fields\": \[\"genre\", \"director\", \"plot\", \"title\", \"originaltitle\", \"runtime\", \"year\", \"rating\"\] \}, \"id\": 1\}" http://127.0.0.1:8080/jsonrpccurl -u "xbmc:xbmc -i -X POST -d \'\{\"jsonrpc\": \"2.0\", \"method\": \"VideoLibrary.GetTVShows\", \"params\": \{ \"start\": 0, \"fields\": \[\"genre\", \"director\", \"plot\", \"title\", \"originaltitle\", \"runtime\", \"year\", \"rating\"\] \}, \"id\": 1\}" http://127.0.0.1:8080/jsonrpc > test.txt
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
xbmc@media:~$
MKay Wrote:How long does the execution of the command take?
Try to add "--max-time <seconds>" to the command and check if it works (maybe 300 seconds = 5 minutes for testing ).
s1mp3 Wrote:Thank's for this! Could you please add Genre in Music browser?I think genres will not be available via JSON-API before Eden: click me
ppic Wrote:it's instantely ...LoL, now i see that there is a ' missing after "username:password". So the correct command is:
curl -u 'username:password' -i -X POST -d '{"jsonrpc": "2.0", "method": "VideoLibrary.GetTVShows", "params": { "start": 0, "fields": ["genre", "director", "plot", "title", "originaltitle", "runtime", "year", "rating"] }, "id": 1}' http://your_xbmc_host/jsonrpc
Hjord Wrote:I have 2 reqs.I noted it down. But i don't know if and when i will implement it. Especially for playlist i need to find out what is supported by the JSON-API. Moreover i currently have not much time to work on AWX
Search in artist and songs(!).
Open, edit and save playlist thats on XBMC.
MKay Wrote:I think genres will not be available via JSON-API before Eden: click me
But maybe i can use a work around. We will see
LoL, now i see that there is a ' missing after "username:password". So the correct command is:Code:curl -u 'username:password' -i -X POST -d '{"jsonrpc": "2.0", "method": "VideoLibrary.GetTVShows", "params": { "start": 0, "fields": ["genre", "director", "plot", "title", "originaltitle", "runtime", "year", "rating"] }, "id": 1}' http://your_xbmc_host/jsonrpc