Guest - Testers are needed for the reworked CDateTime core component. See... https://forum.kodi.tv/showthread.php?tid=378981 (September 29) x
JSON RPC: Important changes
#1
Exclamation 
Tuesday, April 5th 2011:
With commit 774b8868ee59a1778ad5 to XBMC's master our JSON RPC API has undergone a huge transformation. Initially the main reason for this transformation was to make our implementation of JSON RPC compliant with the JSON RPC 2.0 specification (http://groups.google.com/group/json-rpc/...on-rpc-2-0). Our implementation was lacking support for client-side notifications, batch requests and the possibility to provide method parameters by-name (which already existed) OR by-position. The first two features have already been added a while ago but the implementation of by-position and by-name parameters took a bit longer but now it is ready for usage. But we didn't stop at just adding that functionality but we went a step further and are proud to announce that the JSONRPC.Introspect() method now returns a JSON Schema (http://tools.ietf.org/html/draft-zyp-json-schema-03) description of all available methods.

So what does all this mean for people using XBMC's JSON RPC API?
  1. You're current implementations using the JSON RPC API probably won't work anymore (see further below for a list of the most important changes)!
  2. No more need to use custom json rpc implementations as our API is now compliant with JSON RPC 2.0 and therefore you can use standard implementations.
  3. No more uncertainty about what parameters a method expects and what it returns. The JSON Schema returned by JSONRPC.Introspect() contains detailed information about every parameter, it's value range, whether it's optional and about what a method will return.
  4. No more guessing about what an error message means. Based on the JSON Schema, which defines all method parameters, it is possible to return a detailed error message about what exactly is wrong with a received JSON RPC request.
  5. It is now possible to call certain methods using notifications (formerly called announcements). The advantage of call-by-notification is that the caller doesn't get a response at all (over HTTP it will be an empty response) so there's no need to wait for it.
  6. It is now possible to send multiple calls in a single request and receive all the responses in a single response. This can result in less data traffic and faster responses over HTTP.

The following notes are meant for third-party developers using our old JSON RPC API and wish to migrate their applications to the improved JSON RPC API:
  1. Disable compact JSON output from JSON RPC using the advanced settings (see http://wiki.xbmc.org/index.php?title=Adv...jsonrpc.3E)
  2. Call JSONRPC.Introspect() and take a close look at its result. It is a bit overwhelming at first but its structure is pretty much self-explaining. If you don't understand something you can check the JSON Schema specification (http://tools.ietf.org/html/draft-zyp-json-schema-03), the JSON Schema Service Descriptor specification (http://www.simple-is-better.org/json-rpc...iptor.html) or ask us (http://forum.xbmc.org/showthread.php?tid=68263).
  3. Only a few methods have been added and removed:
    • AudioPlayer/VideoPlayer.GetTime() have been merged with AudioPlayer/VideoPlayer.GetTimeMS() to AudioPlayer/VideoPlayer.GetTime()
    • AudioPlayer.Record() has been removed
    • AudioLibrary.GetAlbumDetails() and AudioLibrary.GetSongDetails() have been added (but were already available in all nightly builds since Dharma)
    • VideoLibrary.GetMovieDetails(), VideoLibrary.GetTVShowDetails(), VideoLibrary.GetEpisodeDetails() and VideoLibrary.GetMusicVideoDetails() have been added (but were already available in all nightly builds since Dharma)
  4. A lot of method parameters have changed. The most important change is that it isn't possible anymore to do "params": <some parameter value>. "params" must always be either an object or an array of parameter values. Further changes (no complete list) are:
    • "start" and "end" parameters for methods returning an array of items have been moved into a "limits" object. So now you have to use "params": { "limits": { "start": 5, "end": 15 }, ...}
    • "start", "end" and "total" return values for methods returning an array of items have been moved into a "limits" object
    • parameters used for sorting of items have been moved into a "sort" object. Furthermore "ignorethe" has been renamed to "ignorearticle"
    • AudioPlaylist/VideoPlaylist.GetItems(): "current", "playing" and "paused" have been moved into a "state" object
    • AudioPlayer/VideoPlayer.GetTime(): Returned times are represented as an object containing "hours", "minutes", "seconds" and "millisecond" values
    • AudioLibrary.GetAlbums(): Fields for have been stripped of the "album_" prefix
    • AudioLibrary/VideoLibrary: Several new fields have been added and existing fields (e.g. "set", "showlink" and "cast") have been fixed

These are only the most important changes that affect a lot of methods. If anyone has any particular problems with a certain method, parameter or value and can't make any sense of the received error message they are always welcome to post their questions in our forums (http://forum.xbmc.org/showthread.php?tid=68263).

The next steps concerning XBMC's JSON RPC API will be to update the our wiki with the latest information, write and publish JSON Schema descriptions for notifications sent by XBMC and extend notifications with additional data which belong to the notification (e.g. the current position where movie playback has been stopped).


Monday, April 18th 2011:
Commit: 42298b8e06ffd32eab32
  • Renamed notifications using a naming schema similar to the method names i.e. Player.PlaybackResumed etc
  • Renamed JSONRPC.Notify to JSONRPC.NotifyAll
  • Added a new namespace Input containing the following methods to navigate in the XBMC GUI:
    • Up
    • Down
    • Left
    • Right
    • Select
    • Back
    • Home


Saturday, April 23rd 2011:
Commit: 0c441d98cb24b7bd5473
  • Added GetMovieSets and GetMovieSetDetails to VideoLibrary namespace

Wednesday, June 8th 2011:
Commits: f678c5df079ff3df7d87, cfd17225d55e52da049b, 427599e02e13a5ec36aa, 28743c1647d6cdef84fe
  • Made tvshowid parameter for VideoLibrary.GetEpisodes optional
  • Added GetArtistDetails to AudioLibrary namespace
  • Added GetGenres to VideoLibrary namespace
  • Refactoring and renaming of notifications

Saturday, June 18th 2011:
Commit: 482cb54953c7a450a4ff
  • Added GetRecentlyAddedAlbums and GetRecentlyAddedSongs to AudioLibrary namespace

Wednesday, June 22th 2011:
Commits: 570da530375c22800743, d8e43a2a5399e7fe5ba9, fecb24254184c3b5eaae
  • Added Export and Clean to AudioLibrary and VideoLibrary namespace
  • Renamed ScanForContent to Scan in AudioLibrary and VideoLibrary namespace

Thursday, June 30th 2011:
Commits: 63cba75a76563554d10b
  • Added Swap to AudioPlaylist and VideoPlaylist namespace

Friday, July 8th 2011:
Commits: 6bcd883be85f984308eb, 61bdb057b0149213a081
  • Added Repeat and State to AudioPlaylist and VideoPlaylist namespace
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.
#2
Thursday, September 1th 2011: I'm back after a long holiday trip Smile
Commits: ae691d390c87365087ff, 491764e6aa4f8a96ab7b
  • Added optional parameter "albumartistsonly" to AudioLibrary.GetArtists. If the parameter is not passed or is passed with a value of null the result will consider the GUI setting "Include artists who appear only on compilations" (Settings -> Music -> Library). Providing the parameter with a boolean value (true/false) overrides the GUI setting. If the GUI setting is unchecked or the parameter is passed with a value of false, the returned list will contain an artist named "Various artists". That artist has an "artistid" which cannot be used in AudioLibrary.GetArtistDetails but it can be used in AudioLibrary.GetAlbums and AudioLibrary.GetSongs.
  • Changed the return value of the "set" field, which can be requested for movies. Up until now the return value was a comma-seperated string of set names. It has now been changed into an array of set names which should make parsing the sets a lot easier for clients.
  • The following optional fields have been added to some media objects:
    • "setid" to movies
    • "tvshowid" to episodes
    • "artistid" to albums
    • "artistid" and "albumid" to songs
    This will make it easier to access "parent objects" of a retrieved media objects.

Monday, September 5th 2011: Major cleanup
Commits: 8 commits from 2a33c5f4696d2c079625 to 2968c9b8faf821f70e97
Ok these 8 commits contain all kinds of cleanup in the jsonrpc API to make it more future-proof. From now on everything that resides in the XBMC namespace is either very XBMC-specific or is something that is more of a hack than anything else (like GetInfoLabels and GetInfoBooleans)
  • JSONRPC.GetNotificationFlags and JSONRPC.SetNotificationFlags have been refactored and renamed to JSONRPC.GetConfiguration and JSONRPC.SetConfiguration
  • XBMC.Log has been removed
  • GetProperties has been added to the System namespace. It currently provides the values of the properties "canshutdown", "cansuspend", "canhibernate" and "canreboot".
  • SetVolume, ToggleMute and Quit have been moved from the XBMC to the new Application namespace
  • XBMC.GetVolume has been replaced by Application.GetProperties which currently provides the values of the properties "volume" and "muted".
  • GetInfoLabels and GetInfoBooleans have been moved from the System to the XBMC namespace and are considered deprecated. Please let us know which data you retrieve most using these methods so that we can provide better access to those values.
  • The field album_label for albums has been renamed to albumlabel to match the naming convention
  • The field streamDetails for videos has been renamed to streamdetails to match the naming convention

Tuesday, September 13th 2011:
Commits: 6 commits from 0f12ea73fcef4b65ac89 to c93ea68b5428a9109140
Although there is no change in the functionality and the feature set of the jsonrpc API I finally found the time to further improve xbmc's implementation of JSON schema by covering more parts of the JSON schema specification. The newly added functionality include
  • minLength and maxLength properties for JSON schema definitions of type "string" (no further explanation needed as they are pretty self-explaining)
  • additionalProperties property for JSON schema definitions of type "object". This property can either have the value "false", which means that it is not allowed to provide additional properties (i.e. properties that are not explicitly defined in the types JSON schema definition) as part of the defined JSON object, or it can be a JSON schema definition which must be valid for any property that has not been explicitly defined.
  • extends property for JSON schema definitions of any type. This new functionality is a bit more complicated than the others already present in xbmc's JSON schema implementation. It is similar to inheritance in object-oriented programming languages as it allows one type to extend the JSON schema definition of one or multiple already existing types. The specialty about "extends" is that an actual JSON object must validate both against the extended JSON schema definition(s) and against the extending JSON schema definition. That an extended type should never use "additionalProperties": false because otherwise the extending type cannot provide additional parameters.
    As a simple example let's look at the optimized JSON schema definition of "Player.State" and "Player.State.Extended":
    Code:
    "Player.State": {
        "type": "object",
        "properties": {
          "playing": { "type": "boolean", "required": true, "description": "" },
          "paused": { "type": "boolean", "required": true, "description": "" }
        }
      },
      "Player.State.Extended": {
        "extends": "Player.State",
        "properties": {
          "partymode": { "type": "boolean", "required": true, "description": "" }
        }
      }
    As you can see using the "extends": "Player.State" feature the "Player.State.Extended" definition inherits the "playing" and "paused" properties of "Player.State" and therefore won't have to define them itself (which up until now was necessary so that resulted in quite a bit of duplicate code).
  • union type definitions: Up until now the "type" property of a JSON schema definition could either be a string defining a single type (boolean, integer, number, string, array, object, null) or an array of single types (e.g. [ "integer", "string" ] which means that the type is either an integer or a string). Additionally to that functionality it is now possible to use whole JSON schema definitions as part of the "type" property. To explain this let's look at the definition of "Playlist.Id":
    Code:
    "Playlist.Id": {
        "type": [
          { "type": "object", "properties": { "id": { "type": "string", "minLength": 1, "description": "Identification of a virtual playlist", "required": true } }, "additionalProperties": false },
          { "type": "object", "properties": { "file": { "type": "string", "minLength": 5, "description": "File from which to load a playlist", "required": true } }, "additionalProperties": false }
        ]
      }
    As you can see the definition only consists of the "type" property which is an array of two differing JSON schema definitions. That means that any JSON object which must be a "Playlist.Id" type can now either have a property "id" or a property "file" but a JSON object having both an "id" AND a "file" property is not a valid "Playlist.Id" object. Up until now this kind of definition was not possible and it was possible to provide both an "id" and a "file" property although it doesn't make any sense to provide both. This feature is also used in "Playlist.Item.Video" where (up until now) it was possible to provide an object containing not only a "movieid" property but also a "musicvideoid" property although "VideoPlaylist.Add" (which takes a parameter of type "Playlist.Item.Video") only allows to add a single video to the playlist.
For all those who find my explanations confusing (including myself) you can also take a look at the official JSON schema specification to read up on what those properties really do.

Thursday, September 15th 2011:
Commits: 44b94fac978ef101d442
  • Renamed "shares" to "sources" in the return value of Files.GetSources
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.
#3
Sunday, September 18th 2011:
Commits: c4f161e177f5e079f2ba and 525833acf0b7fa3a9404
OK these two commits (especially the first one) are a huge step in the current jsonrpc API because they completely refactor the handling of players and playlists. First of all there will be no seperate VideoPlayer, AudioPlayer and PicturePlayer anymore but only one Player namespace. The same goes for VideoPlaylist and AudioPlaylist which has been replaced by a refactored Playlist namespace which even offers limited support for picture playlists (aka slideshows). Furthermore a lot of methods have been merged/refactored/moved. From now on the Playlist namespace simply represents a playlist (i.e. a sorted list of playable items) and does not provide any playback controlling functionalities anymore. Those have all been moved into the Player namespace because the players are responsible for playing items and not the playlists. I'm sure there will be quite a few questions about these changes so don't hesitate to post them in the development thread. Here is a more or less complete list of all important changes:
  • Merged AudioPlayer, VideoPlayer and PicturePlayer into Player
  • Merged AudioPlaylist and VideoPlaylist to replace Playlist and provide initial support for picture playlists (aka slideshows)
  • Players/Playlists are no longer accessed by their media type (video, audio, picture) but by a unique ID. Active players/playlists (their ID and media type) can still be retrieved using Player.GetActivePlayers/Playlist.GetPlaylists
  • Replaced Playlist.State with Playlist.GetProperties
  • Replaced Player.State, Player.GetTime and Player.GetPercentage with Player.GetProperties
  • Removed Playlist.SkipPrevious and Playlist.SkipNext (use Player.GoPrevious and Player.GoNext instead)
  • The following methods have been moved from the Playlist to the Player namespace: Play (renamed to Open), Shuffle, UnShuffle, Repeat
  • Refactored notifications for the Player namespace
  • Unified naming of position/item/index parameters in Player and Playlist namespaces
  • Merged XBMC.Play and XBMC.StartSlideshow into Player.Open
  • Make Playlist.Add, Playlist.Clear and Player.Open work for picture playlists
  • Replace Rewind and Forward with SetSpeed in Player namespace
  • Replace "value" parameter in "Player.SeekTime" with time struct parameters
  • Merge SeekTime, SeekPercentage and (Small|Big)Skip(Forward|Backward) into Seek in Player namespace
  • Add Player.SetAudioStream, Player.SetSubtitle and the properties "currentaudiostream", "audiostreams", "subtitleenabled", "currentsubtitle" and "subtitles" to Player.GetProperties

Tuesday, September 20th 2011:
Commits: 5abc022c3a353e206f78, a03c34b37ae64637a9fd, 2a848458dbfd36d87058, 481a6007e899bdba21f2
  • Added "name" and "version" to Application.GetProperties
  • Fixed value of "file" field for videos
  • Renamed "label" field for albums to "albumlabel" for consistency with the name of the returned property
  • Renamed "fields" parameters to "properties" parameters

Wednesday, October 5th 2011:
Commit: 288f4967d954769282fc
  • Added GetItem to the Player namespace to retrieve the currently playing item (also works for items played with Player.Open or from recently added script)

Saturday, October 8th 2011:
Commits: 845288d417d40dea22f6, c2d1e992fdd64f380d67, 6c9af5c7c0ae8075c0f8, c00ff2defb35333206f2, 253dd7e808d1e7a83682
  • renamed "value" parameter of Application.Setvolume to "volume"
  • refactored Application.ToggleMute into Application.SetMute which takes the following parameters: true, false, "toggle"
  • removed optional parameter "albums" from AudioLibrary.GetRecentlyAddedAlbums (use the "limits" parameter to limit the number of returned items (maximum is 25))
  • renamed parameter "albums" from AudioLibrary.GetRecentlyAddedSongs to "albumlimit"
  • refactored (Audio|Video)Library.Export parameters using union types to better distinguish between single and multi file export

Friday, October 14th 2011:
Commit: 53ee2724ede510a8a3a0
  • Refactored Files.Download into Files.PrepareDownload and Files.Download. Using jsonrpc over HTTP Files.PrepareDownload does, what Files.Download did until now. It provides a URL which can be called to download the file (beware the answer format has changed). The idea behind the changes is that some transport layers will support direct download through Files.Download while others (like HTTP) will not and in that case the method name "Download" may be confusing. That's why we split the functionality into Files.PrepareDownload (which will be available over HTTP) and Files.Download (which will not be available over HTTP because it's not supported).
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.
#4
pre-Frodo (pre-12.0)

Sunday, March 25th 2012:
Commit: 4d4eac0b4043c99d9794
Add support for WebSockets. Websockets are accessible using the port of the TCP server (by default 9090) and using version 8 (draft) or 13 (final) of the websocket specification. So the URL to access the websocket would be e.g.
Code:
ws://localhost:9090/jsonrpc
For now websockets are only available for JSON-RPC and support the same features as the TCP Server (i.e. notifications but no file download).

Tuesday, March 27th 2012:
Commit: 32b3b77f9829202e1528
  • added Input.ContextMenu and Input.Info
  • added System.EjectOpticalDrive and a new permission ControlSystem
  • added GUI namespace with the methods ShowNotification, SetFullscreen and GetProperties (current properties are "currentwindow", "currentcontrol", "fullscreen" and "skin")
  • added AudioLibrary.GetRecentlyPlayedAlbums and AudioLibrary.GetRecentlyPlayedSongs
  • added properties "size", "lastmodified" and "mimetype" to Files.GetDirectory
  • added properties "season" and "watchedepisodes" to VideoLibrary.GetTvShows and "watchedepisodes" to VideoLibrary.GetSeasons
  • added notification Application.OnVolumeChanged
  • extended Application.SetVolume to support "increment" and "decrement"
  • added optional "play" parameter to Player.PlayPause
  • added optional "enable" parameter to Player.SetSubtitle
  • added optional "directory" parameter to (Audio|Video)Library.Scan
  • added optional "options" parameter to Player.Open which can have the properties "shuffled", "repeat" and "resume"
  • improved properties returned by Player.GetItem for non-library media being played
  • added sort methods "country", "dateadded", "listeners" and "bitrate"

Tuesday, March 27th 2012:
Commit: adff92756087a50bb116
I just pushed a major refactor of how the webserver works internally. Currently this has only one effect on how it works and that affects JSON-RPC clients using JSON-RPC over HTTP. You need to make sure you set the Content-Type in the HTTP header to "application/json" and not something like "multipart/form-data" because that is plain wrong. The new implementation has the functionality to parse POST data for certain content-types (including application/json, multipart/form-data and application/x-www-form-urlencoded) and will therefore fail if the content-type does not match the actual POST data.

Tuesday, May 1st 2012:
Commit: 5cc59fd88149927ae708
  • added "lastplayed" property for songs

Friday, May 4th 2012:
Commit: 0bd7924d87f00059a9b4
  • added SetArtistDetails, SetAlbumDetails and SetSongDetails to the AudioLibrary namespace
  • added SetMovieDetails, SetTVShowDetails. SetEpisodeDetails and SetMusicVideoDetails to the VideoLibrary namespace
  • added RemoveMovie, RemoveTVShow, RemoveEpisode and RemoveMusicVideo to the VideoLibrary namespace

Monday, May 14th 2012:
Commit: 1e16f6f66c96f70bfdb7
These commits solve the problem of retrieving thumbnails and fanart provided by JSON-RPC after introducing the new texture caching functionality in the video library. With the new cache XBMC uses image://<path-to-real-file> URLs to relate to images. Currently this only is implemented for video artwork, music artwork still uses the old special://<some-path> URLs but they should both work. We used this opportunity to introduce a new image handler in the webserver which is meant to replace the existing VFS handler someday in the near future. This means that images can and should from now on be retrieved using the following HTTP URL: http://<ip>:<port>/image/<url-encoded-image-path> where <url-encoded-image-path> can either be a image://- or a special://-based URL. It is very important that the whole image-URL provided by JSON-RPC is URL-encoded because otherwise it will result in an invalid URL and will not work. If you're not sure what the resulting URL should look like, take a image-URL returned by JSON-RPC and use Files.PrepareDownload to retrieve the actual URL you should call. For the time being you can still use the "old" VFS handler but we plan to remove it because it is a huge security risk/hole.

Sunday, July 1st 2012:
Commit: 64aea4d83de8899e2449
  • added "fanart" and "thumbnail" parameters to VideoLibrary.SetFooDetails

Wednesday, July 11th 2012:
Commit: c924204d75d511489972
  • added SendText, ExecuteAction, ShowOSD and ShowCodec to Input namespace
  • added Input.OnInputRequested and Input.OnInputFinished notifications which are sent when the virtual keyboard (or the numerics/date/time/ip) dialog is activated/deactivated.
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.
#5
Monday, August 6th 2012:
Commits: 8f68fe63bd3c4a1b8b03, 28a085ff623e88084a09

THESE CHANGES BREAK BACKWARDS COMPATIBILITY WITH VERSION 4 OF JSON-RPC API!!!
  • the properties set and setid for movies are no longer arrays but a single string (set) / integer (setid) value because very movie can only belong to one set from now on. This also means that retrieving those two properties does no longer require extra SQL queries and is therefore faster than in the past.
  • a lot of properties which were returned as a concatenated string with a "/" seperator are now returned as arrays of strings instead. This should make parsing the response a lot easier for clients.
  • a tag property (array of strings) has been added for movies
  • the properties productioncode and premiered have been removed from movies because they never belonged there. They are meant for tvshows.
  • a new parameter filter has been added for a lot of (Audio|Video)Library.GetFoos methods. Depending on the method it takes a property like "genreid" or "artistid" etc which were previously available as seperate parameters. Moving them into the "filter" parameter allows more control over the filters because in most cases filters cannot be combined (right now) which was confusing in the past. Furthermore new filters have been added like "genre", "actor", "director", "studio", "artist", "album" etc which do not rely on a database ID but on an actual string/name.

Although some of these changes break backwords compatibility, the move from properties returned as strings to properties returned as arrays can be caught at runtime by checking if a property is a string or an array. If it is a string you interact with an XBMC client using JSON-RPC API v4 (and you need to split the string and extract the seperate items) and if it is an array you interact with an XBMC client using JSON-RPC API v5+ (and you can extract the items directly from the array).

Monday, September 3rd 2012:
Commits: f41b3c5728581ce32c99, 0548adfccfc548e43c97
  • add Files.GetFileDetails
  • advanced filtering in AudioLibrary and VideoLibrary methods based on smartplaylist rules/filters

Monday, October 1st 2012:
Commits: d3d0cfebc02a0c5d2b5c, fee57ef73122697d5c12, a31cdbdba90b973420ce, 79e7c0c205b0fc91ca78, ef7f03ee93acdef40b34
  • cleanup sort methods in List.Sort
  • added GUI.ActivateWindow
  • added partymode property to Player.Open to be able to start the music/video partymode or a specific smartplaylist in partymode
  • added Player.SetPartymode to enable/disable/toggle partymode during playback of a playlist
  • added lastplayed property for tvshows
  • added playcount property for albums
  • added OnScanStarted notification to AudioLibrary/VideoLibrary

Tuesday, October 2nd 2012:
Commits: cf666682e2adcfd22974, 95c748a6d2f8a176b9c4
  • add Player notifications for slideshows
  • add Playlist notifications
  • add Addons namespace with GetAddons, GetAddonDetails, SetAddonEnabled and ExecuteAddon

Thursday, October 4nd 2012:
Commits: 552580d9007b1959c500
  • merge Player.Move(Left|Right|Up|Down) into Player.Move which takes a "direction" parameter which can be "left", "right", "up" or "down"
  • merge Player.Zoom(In|Out) into Player.Zoom which takes a "zoom" parameter which can be "in", "out" or any integer between 1 and 10 (zoom level)
  • merge Player.(Un)Shuffle into Player.SetShuffle with a "shuffle" parameter which can be true, false or "toggle" so this adds the toggle functionality which wasn't possible up until now
  • rename Player.Repeat to Player.SetRepeat to match the naming convention and renames the "state" parameter to "repeat" and add "cycle" to the list of possible values for the "repeat" parameter
  • merge Player.Go(Previous|Next|To) into Player.GoTo with a "to" parameter (not "position") which can be "previous", "next" or any integer number describing a position in the playlist

Wednesday, October 10th 2012:
Commits: 27639ee9759381732b9c
  • added Player.OnPropertyChanged notification whenever "shuffled", "repeat" or "partymode" changes for an active player

Tuesday, October 16th 2012:
Commits: 504e9c41f6720ed6edfc
  • added support to control PVR streams to Player namespace
  • added "channelid" property to Player.Open's "item" parameter
  • added channel-specific properties to Player.GetItem (valid properties for a PVR stream/channel returned by Player.GetItem are "channeltype", "hidden", "locked", "channel", "lastplayed", "channelnumber", "rating", "title", "plotoutline", "plot", "genre", "starttime", "endtime", "runtime", "firstaired")
  • added Player.OnPlay and Player.OnStop notifications when switching a PVR channel
  • added new PVR namespace with the following methods
    • GetProperties with properties "available", "recording", "scanning"
    • GetChannelGroups
    • GetChannelGroupDetails
    • GetChannels
    • GetChannelDetails
    • Record
    • Scan

Tuesday, November 27th 2012:
Commits: 73a9b08f264c859434b8, f00ff50ec98445ac922a
  • changed runtime from a string to an integer. It will now provide the videos duration in seconds which should make it more useful than a string with an arbitrary format.
  • added genreid, artistid and displayartist property for albums
  • added genreid, artistid, albumartistid and displayartist property for songs
  • fixed albumartist property for songs which was always an empty array
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.
#6
pre-Gotham (pre-13.0)
As an FYI, starting with Frodo stable we are using a new versioning system (<major>.<minor>.<bugfix>) for the JSON-RPC API. Frodo stable is version 6.0.0 and from now on with every bugfix the <bugfix> part of the version is increased, with every feature addition to the API, the <minor> version is increased (and the <bugfix> version reset to 0) and with every backwards incompatible change, the <major> version is increased. This should allow third party devs to better rely on the version provided by JSONRPC.Version and to e.g. show a warning or error if the version doesn't match a specific version required by the client. Furthermore it should make debugging easier as I can ask 3rd party devs for the version they are using and will know immediately, which features/fixes are included in that version and which arent.

Version 6.0.1

February 11th 2013:
Commit: 44916b33908f77692d8838446035de3e3bc10ca1
Fix the result of Player.GetProperties with param "currentaudiostream" for video without an audio stream (index = -1).

February 19th 2013:
Commit: 7b9ab8a85fd2b6030e6cf2659ff16380afef3996
Add missing "xbmc.pvrclient" entry to Addon.Types enum

Version 6.0.2

February 24th 2013:
Commit: adc54a9873d213b052f395072c5532781c917648
Correct Player.PlayPause behavior: In current implementation using play parameter as boolean won't force the playerspeed to 1 as it should. This PR correct this so that using a bool parameter act as the toggle and provide the same behavior as GUI or EventServer.

Version 6.0.3

February 27th 2013:
Commit: bee7aeb42812c21655368923ee1047d8ffbc02da
fix passing of paths to builtin methods (fixes #14066)

Version 6.1.0

March 7th 2013:
Commit: ff3611c86b68103abd0cde4142d2b4cdf5b9690c
Add support for limits to Files.GetDirectory

March 7th 2013:
Commit: 16767de3dad0654db94eef04732d9e4f21bd04e9
add compilationartist property to AudioLibrary.GetArtists

Version 6.2.0

April 4th 2013:
Commit: 408ceb032934b3148586500cc3ffd34169118fea
jsonrpc: add support for resume in VideoLibrary.SetFooDetails

Version 6.3.0

April 7th 2013:
Commit: 5c636c0c8517b5f4b5410dbfc279048a84a309f0
Add recursive parameter to Playlist.Item directories

April 8th 2013:
Commit: 08951d3057315e8922ed0a917ae1ae787e3e4e6b
There has been a change in xbmc internal database paths. Old paths like "videodb://1/2/" (for the movie title list) don't work anymore and need to be replaced with something like "videodb://movies/titles/".

Version 6.4.0

April 13th 2013:
Commit: 3098d92aa4c1739fa8baa6102841f73fbc52e95d
Add media parameter to Playlist.Item directory type

Version 6.5.0

May 1st 2013:
Commit: ab74dddc71dcd0b9c18afeb6db4ca7359316014e
Add Favourites namespace

Version 6.5.1

May 3rd 2013:
Commit: 2b458e08378553ff986fe82c5f70059367572c53
fix return value of "volume" property in Application.GetProperties

Version 6.5.2

June 12th 2013:
Commit: d1e3333b5781a2d9b06aee628f9ed179e1350bcd
fix property values returned by Player.GetItem

Commit: 9952d2fa994d99f12193d0905a25d122bf404c70
use "song" as default value for "type" property

Commit: e0ec520d00f61626303a812f1c4dee0517466746
fix "filetype" property being (unexpectedly) returned for Player.GetItem et al.

Version 6.5.3

August 7th 2013:
Commit: 3b07a0205ba498a376214eb5f7e21afda7724e89
fix "mimetype" being empty in Files.GetDirectory

Commit: 0ef065227265d41de6ac7473b8f6f287ccbcefd8
fix "size" property from Files.GetDirectory overflowing and not returning bytes

Version 6.6.0

August 8th 2013:
Commit: 85bfca08835d489877f4fa3bd47b74f1da179e31
Add Profiles namespace

Version 6.6.1

September 13th 2013:
Commit: 97c236ff469da8dc63394754f0e320d1893f0a1b
fix Playlist.Add/Insert not working with "directory"

Version 6.6.2

September 14th 2013:
Commit: f809499d80d93be3ced9c973af116cbdbe83db51
fix "file" property not working in AudioLibrary.GetSongDetails

Version 6.6.3

October 30th 2013:
Commit: 4a57f591e6db57864c888bbc327bb335dd2241ef
fix "limits" for PVR.GetChannels

Version 6.7.0

October 31st 2013:
Commit: 47cbe448c5ca49f7ecbe1fbec6e0d84605825a18
PVR: add GetBroadcasts and GetBroadcastDetails

Version 6.8.0

November 2nd 2013:
Commit: e97d8407d9bc30fe31ada381ca99bf24bf0253a4
GUI: Add SetStereoscopicMode, GetStereoscopicMode and property stereoscopicmode to GetProperties

Version 6.9.0

November 2nd 2013:
Commit: 34984dd19509c21112a22d57edd9584db47dac1d
Add Textures namespace with GetTextures and RemoveTexture

Version 6.9.1

November 3rd 2013:
Commit: e395cac8a376becbd98f4c972fe6ac93e7f4962d
VideoLibrary: add possibility to remove artwork from video items

Version 6.10.0

November 3rd 2013:
Commits: f471af0cc1ee4f250faa5acf06b549e65188c29f, 0f5d486e56e154f0bc627db3dfda390da242b65e
VideoLibrary: add seasonid, GetSeasonDetails and SetSeasonDetails

Version 6.11.0

November 3rd 2013:
Commit: 1b7dbe5b4d13573e90e0dd0a2cf2b16d8bd83c35
add support for multiple items to Playlist.Add/Insert

Version 6.12.0

November 3rd 2013:
Commit: 85bfca08835d489877f4fa3bd47b74f1da179e31
add VideoLibrary.SetMovieSetDetails

Version 6.13.0

November 11th 2013:
Commit: 85bfca08835d489877f4fa3bd47b74f1da179e31
Add Settings namespace with GetSections, GetCategories, GetSettings, GetSettingValue, SetSettingValue and ResetSettingValue
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.

Logout Mark Read Team Forum Stats Members Help
JSON RPC: Important changes1