pkfox wrote: 
> Hi all, I'm trying to run a command against the LMS web server using
> curl from a linux terminal but am not being successful this is what I've
> tried
> 
> > 
Code:
--------------------
  >   > 
  > curl -g -X POST -H "Content-Type: application/json" 
'"{\"id\":1,\"method\":\"slim.request\",\"params\":[null,[\"info total duration 
?\"]]}"' http://10.10.1.11:9000/jsonrpc.js
  > 
--------------------
> > 
> 
> info total duration is a new command Michael added yesterday

our curl looks unknown to me...

i dont know why you want to curl the jsonrpc but if you want...
i didn t update to the newest, but that code is running you had to alter
the request.


Code:
--------------------
    curl 'http://127.0.0.1:9000/jsonrpc.js' --data-binary 
'{"id":1,"method":"slim.request","params":["",["info","total","songs","?"]]}'
--------------------
 

and this should give you only the wanted output.

Code:
--------------------
    curl 'http://127.0.0.1:9000/jsonrpc.js' --data-binary 
'{"id":1,"method":"slim.request","params":["",["info","total","songs","?"]]}'|cut
 -d '_' -f2- |cut -d ':' -f2|cut -d '}' -f1
--------------------



Gruss
Jan
------------------------------------------------------------------------
DJanGo's Profile: http://forums.slimdevices.com/member.php?userid=1516
View this thread: http://forums.slimdevices.com/showthread.php?t=104757

_______________________________________________
discuss mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/discuss

Reply via email to