•   
  • 1
  • 210
  • 211
  • 212(current)
  • 213
  • 214
  • 226
  •   
JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC
(2014-04-14, 13:42)claymic Wrote: Thanks Montellese, sorry, i was so tired when i wrote this question that i don´t read everything on the commit, now i know how it works, very cool.
Can you tell me if is already possible to request a image with a specific size ? I tried to found any information about this but i don´t found.
Thanks again
Best regards
Clayton

Nope that's not possible yet.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
I am completely new to JSON-RPC. What I want to achieve is to issue the following command form outside XBMC:

Dialog.Close(dialog[,force]) -- Close a dialog. Set force to true to bypass animations. Use (all,true) to close all opened dialogs at once.--

I want to close all open dialogs (actually there will only be one open; but I don't know how to get its name/reference)

Is this possible with JSON-RPC? If not, is there another or better way to do it?

Thanks,

geoff
Reply
(2014-04-25, 11:03)soundgals Wrote: I am completely new to JSON-RPC. What I want to achieve is to issue the following command form outside XBMC:

Dialog.Close(dialog[,force]) -- Close a dialog. Set force to true to bypass animations. Use (all,true) to close all opened dialogs at once.--

I want to close all open dialogs (actually there will only be one open; but I don't know how to get its name/reference)

Is this possible with JSON-RPC? If not, is there another or better way to do it?

Thanks,

geoff

Don't post the same question in different threads.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
is "duration" a deprecated parameter?

If not what is the difference between "duration" and "runtime"

Thanks
Image Lunatixz  Kodi / Beta repository • Twitter
Image PseudoTV • Forum • Website
 
Reply
(2014-05-01, 22:48)Lunatixz Wrote: is "duration" a deprecated parameter?

If not what is the difference between "duration" and "runtime"

Thanks

"duration" is for songs and "runtime" is for videos.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
(2014-04-14, 14:13)Montellese Wrote: Nope that's not possible yet.

Thanks Montellese
I am doing a new add-on and i get a problem with the request bellow :

Code:
def getAddonsPath(path,id):
   print "get addons video",path,id
   directory = "plugin://%s"%id
   json_params  =  '"params": {"properties": ["thumbnail","genre","plot"],"directory" : "%s","media" : "files"}'%directory
   print json_params
   json_request = xbmc.executeJSONRPC('{"jsonrpc": "2.0", "method": "Files.GetDirectory",%s , "id": 1}'% json_params)  
   json_request = unicode(json_request, 'utf-8', errors='ignore')
   json_response = simplejson.loads(json_request)
   if json_response.has_key('result') and json_response['result'] != None and json_response['result'].has_key('files'):
      print "json called directory"
      for myfiles in json_response['result']['files']:
         print "its ok"
This is just a test to see if i can get a data from another add-on. I use the same method on my interface for ipad, but on the add-on after do this request seems that the Xbmc enter in a infinite loop, or something like that.
The add -on that i want to get the data is a video add-on.
Am i doing something wrong ? or what i want is just not possible ?
Thanks in advance
Reply
(2014-05-02, 18:28)claymic Wrote:
(2014-04-14, 14:13)Montellese Wrote: Nope that's not possible yet.

Thanks Montellese
I am doing a new add-on and i get a problem with the request bellow :

Code:
def getAddonsPath(path,id):
   print "get addons video",path,id
   directory = "plugin://%s"%id
   json_params  =  '"params": {"properties": ["thumbnail","genre","plot"],"directory" : "%s","media" : "files"}'%directory
   print json_params
   json_request = xbmc.executeJSONRPC('{"jsonrpc": "2.0", "method": "Files.GetDirectory",%s , "id": 1}'% json_params)  
   json_request = unicode(json_request, 'utf-8', errors='ignore')
   json_response = simplejson.loads(json_request)
   if json_response.has_key('result') and json_response['result'] != None and json_response['result'].has_key('files'):
      print "json called directory"
      for myfiles in json_response['result']['files']:
         print "its ok"
This is just a test to see if i can get a data from another add-on. I use the same method on my interface for ipad, but on the add-on after do this request seems that the Xbmc enter in a infinite loop, or something like that.
The add -on that i want to get the data is a video add-on.
Am i doing something wrong ? or what i want is just not possible ?
Thanks in advance

Please provide a Debug log (wiki) with JSON-RPC logging enabled (in Settings -> System -> Debugging -> Verbose logging).
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
(2014-02-24, 08:57)Montellese Wrote:
(2014-02-24, 07:40)MilhouseVH Wrote: If a VideoLibrary.Clean is initiated using JSON, the GUI in recent Gotham nightlies now prompts to keep or remove missing items. Obviously this is undesirable when the clean has been initiated remotely via JSON and there is no user present to click the GUI button... is there any way to suppress the GUI prompts and always assume "remove" or "keep"? Maybe pass remove/keep/ask as a parameter on the JSON *.Clean request, with the default value being "remove" so as to remain consistent with the old pre-Gotham behaviour?

Otherwise VideoLibrary.Clean (and presumably AudioLibrary.Clean) are now a whole lot less useful (ie. almost unusable) from a JSON perspective if they require user intervention.

Thanks for the report. I'll see what I can get into Gotham. Most likely we will have to hard-code it to do a "keep" action as that's what makes most sense. Yes it differs from the previous behaviour but the previous behaviour was crazy. It's not acceptable to remove all items from a source just because the NAS is offline.

AudioLibrary.Clean is not affected as I've only adjusted the videolibrary cleaning to handle whole sources being offline.

Just a gentle reminder as it looks like this functionality didn't make it into Gotham. Smile
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
@Montellese, I have a feature request. If this pull request to be able to quickly navigate the Channels list and the EPG timeline view by typing in a specific channel number gets accepted into the main development tree can we add functions into the JSON API to take advantage of navigating these windows by passing the desired Channel number to XBMC?
[Image: all-thin-banner.jpg]
Reply
is it possible to get/set watch status of an tv episode? for example if the user is replacing a existing file with something better.. i'd like to fetch the current watched status... hold onto it while we replace the previous file..then set the watch status accordingly (and remove the previous file reference... clean library? or just update old file to new one and keep associated data?)
Reply
(2014-05-03, 23:58)MilhouseVH Wrote:
(2014-02-24, 08:57)Montellese Wrote: Thanks for the report. I'll see what I can get into Gotham. Most likely we will have to hard-code it to do a "keep" action as that's what makes most sense. Yes it differs from the previous behaviour but the previous behaviour was crazy. It's not acceptable to remove all items from a source just because the NAS is offline.

AudioLibrary.Clean is not affected as I've only adjusted the videolibrary cleaning to handle whole sources being offline.

Just a gentle reminder as it looks like this functionality didn't make it into Gotham. Smile
Yeah I've looked into it before Gotham but it was not that easy to fix due to the nature of the video library cleaning implementation so I had to postpone it to after Gotham.

(2014-05-06, 21:37)Talguy Wrote: @Montellese, I have a feature request. If this pull request to be able to quickly navigate the Channels list and the EPG timeline view by typing in a specific channel number gets accepted into the main development tree can we add functions into the JSON API to take advantage of navigating these windows by passing the desired Channel number to XBMC?
I don't have a (working) PVR setup so I'm not really the man for PVR-specific features, sorry.

(2014-05-06, 22:43)thezoggy Wrote: is it possible to get/set watch status of an tv episode? for example if the user is replacing a existing file with something better.. i'd like to fetch the current watched status... hold onto it while we replace the previous file..then set the watch status accordingly (and remove the previous file reference... clean library? or just update old file to new one and keep associated data?)
You can use VideoLibrary.RemoveEpisode and VideoLibrary.SetEpisodeDetails but what you currently can't do is add a new episode. You also can't change the file reference of an episode.
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
Just wondering if anyone has had problems with sorting by date with VideoLibrary.GetMovies? I would have thought that date would reflect when the media was added to the library so if I did something like this:

Code:
{"jsonrpc":"2.0","method":"VideoLibrary.GetMovies","params":{"properties":["title","art"],"sort":{"order":"descending","method":"date"}},"id":"1"}}

I would be getting a similar result to VideoLibrary.GetRecentlyAddedMovies. Instead it seems to give me back reverse alphabetical order.
Reply
Need 'dateadded'. But sometimes the values get messed up specially for TvShows.
Reply
Perfect, Thanks Tolriq!
Works a treat.

Yeah I guess with TV it is listing when the show was added rather than the most recent episodes although even that looks a bit out of whack.
Reply
did GetDirectory change recently?

I'm unable to return xbmc library info from json...

Code:
{"jsonrpc":"2.0","method":"Files.GetDirectory","params":{"directory":"smb://0.0.0.0/TV Shows/White Collar/Season 3/","properties":["duration","runtime"]},"id":19}

Should return duration, but doesn't... Worked in frodo and alpha builds of Gotham.

Tested with regular media (non strm) and strms, same result.

Database is mysql, btw... Thanks ahead of time...
Image Lunatixz  Kodi / Beta repository • Twitter
Image PseudoTV • Forum • Website
 
Reply
  •   
  • 1
  • 210
  • 211
  • 212(current)
  • 213
  • 214
  • 226
  •   
 
Thread Rating:
  • 8 Vote(s) - 5 Average



Logout Mark Read Team Forum Stats Members Help
JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC58