2010-10-18, 15:21
slash Wrote:Hi,
I've been porting my tool (XWMM) to JsonRPC for a while now and it works like a charm. You guys did a great job.
As a fan I have few additional requests
- Files.GetSources does not give the USB drives
- How can I use Files.Download to copy files to the XBMC machine ?
- Can ScanForContent take a directory as parameter, to specefy where to start the scan ?
- Would it be possible to add an equivalent to "refresh item" and have JsonRPC reply with the list of possible titles to choose from (don't know how difficult it would be)?
Also, I know that JsonRPC will not support library manipulation, what would be the suggestion to do that. Should I write my own code or python scripts and execute them with the HTTP execBuiltIn function?
Thanks
GetSources probably should give tem, via parameter to aggregate autoadded sources (such as optical and dvd) probably.
Files.Download will just give you direction on how to download based on your current transport. Http will just give you a URL you can access, TCP at some point might give you a port and so on.
ScanForContent won't take a parameter of path since its hard / impossible to make proper (other thread regarding this matter).
Refresh might be interesting, not sure how to code it up but definatly a nice thing if possible. Seems perfect to be able to refresh scanned items via the web interface.
As for library manipulations, I'd say its appropriate to do them via httpapi for the time being. It is planned to be doable via jsonrpc at some point. Probably needs the security addition (mostly to display them in gui, a dialog that asks if client foo can have these permissions etc.).
Please add tickets and cc me so we don't forget them.