JSON-RPC API v5 (pre Frodo)

From XBMC
Jump to: navigation, search

 JSON-RPC API: Overview v2 (Dharma) v4 (Eden) v6 (Frodo) 

Version 5 is a development version of XBMC's JSON-RPC API. It comes with support for WebSockets as an alternative transport for third party clients. Using WebSockets will allow webinterfaces (which are currently restricted to the HTTP transport only) to get access to a bidirectional transport with XBMC's JSON-RPC API and can therefore also profit from additional features like notifications.

A rough and incomplete list of changes compared to version 4 can be found here. A more complete and detailed list can be found in the forum.

Contents

1 JSON-RPC 2.0 compatibility

Version Method calls Notifications
(server-side)
Notifications
(client-side)
Parameters
by-name
Parameters
by-position
Batch requests
Version 5 Yes Yes Yes Yes Yes Yes

2 Documentation (JSON Schema)

2.1 Supported features of JSON Schema

Schema IETF Draft 03
type Yes
properties Yes
patternProperties No
additionalProperties Yes
items Yes
additionalItems Yes
required Yes
dependencies No
minimum Yes
maximum Yes
Schema IETF Draft 03
exclusiveMinimum Yes
exclusiveMaximum Yes
minItems Yes
maxItems Yes
uniqueItems Yes
pattern No
minLength Yes
maxLength Yes
enum Yes
default Yes
Schema IETF Draft 03
title No
description Yes
format No
divisibleBy Yes
disallow No
extends Yes
id Yes
$ref Yes
$schema No
Hyper Schema No

3 Error message

If XBMC detects a bad or missing parameter in a JSON-RPC request it returns an error object. The JSON schema description of that error object is

{
  "type": "object",
  "properties": {
    "code": { "type": "integer", "required": true },
    "message": { "type": "string", "required": true },
    "data": { "type": "object",
      "properties": {
        "method": { "type": "string", "required": true },
        "stack": { "type": "object", "id": "Error.Stack",
          "properties": {
            "name": { "type": "string", "required": true },
            "type": { "type": "string", "required": true },
            "message": { "type": "string", "required": true },
            "property": { "$ref": "Error.Stack" }
          }
        }
      }
    }
  }
}

4 Namespaces

The XBMC JSON-RPC API is split up into namespaces, which contain methods that can be called. These namespaces are:

JSONRPC          A variety of standard JSONRPC calls
Player           Manages all available players
Playlist         Playlist modification
Files            Shares information
AudioLibrary     Audio Library information
VideoLibrary     Video Library information
Input            Allows limited navigation within XBMC
Application      Application information and control
System           System controls and information
XBMC             Dumping ground for very XBMC specific operations

5 Methods

5.1 Application

5.1.1 Application.GetProperties

Retrieves the values of the given properties
Permissions:

Parameters:

  1. Application.Property.Name[] properties

Returns: Application.Property.Value

5.1.2 Application.Quit

Quit application
Permissions:

Parameters: None
Returns: string

5.1.3 Application.SetMute

Toggle mute/unmute
Permissions:

Parameters:

  1. Global.Toggle mute

Returns: boolean

5.1.4 Application.SetVolume

Set the current volume
Permissions:

Parameters:

  1. mixed volume

Returns: integer

5.2 AudioLibrary

5.2.1 AudioLibrary.Clean

Cleans the audio library from non-existent items
Permissions:

Parameters: None
Returns: string

5.2.2 AudioLibrary.Export

Exports all items from the audio library
Permissions:

Parameters:

  1. [ mixed options ]

Returns: string

5.2.3 AudioLibrary.GetAlbumDetails

Retrieve details about a specific album
Permissions:

Parameters:

  1. Library.Id albumid
  2. [ Audio.Fields.Album properties ]

Returns:

Type: object
Properties:

5.2.4 AudioLibrary.GetAlbums

Retrieve all albums from specified artist or genre
Permissions:

Parameters:

  1. [ Library.Id artistid = -1 ]
  2. [ Library.Id genreid = -1 ]
  3. [ Audio.Fields.Album properties ]
  4. [ List.Limits limits ]
  5. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.2.5 AudioLibrary.GetArtistDetails

Retrieve details about a specific artist
Permissions:

Parameters:

  1. Library.Id artistid
  2. [ Audio.Fields.Artist properties ]

Returns:

Type: object
Properties:

5.2.6 AudioLibrary.GetArtists

Retrieve all artists
Permissions:

Parameters:

  1. [ Optional.Boolean albumartistsonly = null ]
  2. [ Library.Id genreid = -1 ]
  3. [ Audio.Fields.Artist properties ]
  4. [ List.Limits limits ]
  5. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.2.7 AudioLibrary.GetGenres

Retrieve all genres
Permissions:

Parameters:

  1. [ Library.Fields.Genre properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.2.8 AudioLibrary.GetRecentlyAddedAlbums

Retrieve recently added albums
Permissions:

Parameters:

  1. [ Audio.Fields.Album properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.2.9 AudioLibrary.GetRecentlyAddedSongs

Retrieve recently added songs
Permissions:

Parameters:

  1. [ List.Amount albumlimit = -1 ]
  2. [ Audio.Fields.Song properties ]
  3. [ List.Limits limits ]
  4. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.2.10 AudioLibrary.GetRecentlyPlayedAlbums

Retrieve recently played albums
Permissions:

Parameters:

  1. [ Audio.Fields.Album properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.2.11 AudioLibrary.GetRecentlyPlayedSongs

Retrieve recently played songs
Permissions:

Parameters:

  1. [ Audio.Fields.Song properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.2.12 AudioLibrary.GetSongDetails

Retrieve details about a specific song
Permissions:

Parameters:

  1. Library.Id songid
  2. [ Audio.Fields.Song properties ]

Returns:

Type: object
Properties:

5.2.13 AudioLibrary.GetSongs

Retrieve all songs from specified album, artist or genre
Permissions:

Parameters:

  1. [ Library.Id artistid = -1 ]
  2. [ Library.Id albumid = -1 ]
  3. [ Library.Id genreid = -1 ]
  4. [ Audio.Fields.Song properties ]
  5. [ List.Limits limits ]
  6. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.2.14 AudioLibrary.Scan

Scans the audio sources for new library items
Permissions:

Parameters:

  1. [ string directory = "" ]

Returns: string

5.2.15 AudioLibrary.SetAlbumDetails

Update the given album with the given details
Permissions:

Parameters:

  1. Library.Id albumid
  2. [ Optional.String title = null ]
  3. [ mixed artist = null ]
  4. [ Optional.String description = null ]
  5. [ mixed genre = null ]
  6. [ mixed theme = null ]
  7. [ mixed mood = null ]
  8. [ mixed style = null ]
  9. [ Optional.String type = null ]
  10. [ Optional.String albumlabel = null ]
  11. [ Optional.Integer rating = null ]
  12. [ Optional.Integer year = null ]

Returns: string

5.2.16 AudioLibrary.SetArtistDetails

Update the given artist with the given details
Permissions:

Parameters:

  1. Library.Id artistid
  2. [ Optional.String artist = null ]
  3. [ mixed instrument = null ]
  4. [ mixed style = null ]
  5. [ mixed mood = null ]
  6. [ Optional.String born = null ]
  7. [ Optional.String formed = null ]
  8. [ Optional.String description = null ]
  9. [ mixed genre = null ]
  10. [ Optional.String died = null ]
  11. [ Optional.String disbanded = null ]
  12. [ mixed yearsactive = null ]

Returns: string

5.2.17 AudioLibrary.SetSongDetails

Update the given song with the given details
Permissions:

Parameters:

  1. Library.Id songid
  2. [ Optional.String title = null ]
  3. [ mixed artist = null ]
  4. [ mixed albumartist = null ]
  5. [ mixed genre = null ]
  6. [ Optional.Integer year = null ]
  7. [ Optional.Integer rating = null ]
  8. [ Optional.String album = null ]
  9. [ Optional.Integer track = null ]
  10. [ Optional.Integer duration = null ]
  11. [ Optional.String comment = null ]
  12. [ Optional.String musicbrainztrackid = null ]
  13. [ Optional.String musicbrainzartistid = null ]
  14. [ Optional.String musicbrainzalbumid = null ]
  15. [ Optional.String musicbrainzalbumartistid = null ]

Returns: string

5.3 Files

5.3.1 Files.GetDirectory

Get the directories and files in the given directory
Permissions:

Parameters:

  1. string directory
  2. [ Files.Media media = "files" ]
  3. [ List.Fields.Files properties ]
  4. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.3.2 Files.GetSources

Get the sources of the media windows
Permissions:

Parameters:

  1. Files.Media media
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.3.3 Files.PrepareDownload

Provides a way to download a given file (e.g. providing an URL to the real file location)
Permissions:

Parameters:

  1. string path

Returns:

Type: object
Properties:

  • string protocol
  • any details
  • string mode

5.4 GUI

5.4.1 GUI.GetProperties

Retrieves the values of the given properties
Permissions:

Parameters:

  1. GUI.Property.Name[] properties

Returns: GUI.Property.Value

5.4.2 GUI.SetFullscreen

Toggle fullscreen/GUI
Permissions:

Parameters:

  1. Global.Toggle fullscreen

Returns: boolean

5.4.3 GUI.ShowNotification

Shows a GUI notification
Permissions:

Parameters:

  1. string title
  2. string message
  3. [ mixed image = "" ]
  4. [ integer displaytime = 5000 ]

Returns: System.Property.Value

5.5 Input

5.5.1 Input.Back

Goes back in GUI
Permissions:

Parameters: None
Returns: string

5.5.2 Input.ContextMenu

Shows the context menu
Permissions:

Parameters: None
Returns: string

5.5.3 Input.Down

Navigate down in GUI
Permissions:

Parameters: None
Returns: string

5.5.4 Input.Home

Goes to home window in GUI
Permissions:

Parameters: None
Returns: string

5.5.5 Input.Info

Shows the information dialog
Permissions:

Parameters: None
Returns: string

5.5.6 Input.Left

Navigate left in GUI
Permissions:

Parameters: None
Returns: string

5.5.7 Input.Right

Navigate right in GUI
Permissions:

Parameters: None
Returns: string

5.5.8 Input.Select

Select current item in GUI
Permissions:

Parameters: None
Returns: string

5.5.9 Input.Up

Navigate up in GUI
Permissions:

Parameters: None
Returns: string

5.6 JSONRPC

5.6.1 JSONRPC.Introspect

Enumerates all actions and descriptions
Permissions:

Parameters:

  1. [ boolean getdescriptions = True ]
  2. [ boolean getmetadata = False ]
  3. [ boolean filterbytransport = True ]
  4. [ object filter ]

Properties:

  • string type
  • string id
  • [ boolean getreferences = True ]

Returns:

Type: object

5.6.2 JSONRPC.NotifyAll

Notify all other connected clients
Permissions:

Parameters:

  1. string sender
  2. string message
  3. [ any data = null ]

Returns: any

5.6.3 JSONRPC.Permission

Retrieve the clients permissions
Permissions:

Parameters: None
Returns:

Type: object
Properties:

  • boolean navigate
  • boolean controlgui
  • boolean controlplayback
  • boolean readdata
  • boolean updatedata
  • boolean writefile
  • boolean controlsystem
  • boolean controlnotify
  • boolean removedata
  • boolean controlpower

5.6.4 JSONRPC.Ping

Ping responder
Permissions:

Parameters: None
Returns: string

5.6.5 JSONRPC.Version

Retrieve the jsonrpc protocol version
Permissions:

Parameters: None
Returns: string

5.7 Player

5.7.1 Player.GetActivePlayers

Returns all active players
Permissions:

Parameters: None
Returns:

Type: array

5.7.2 Player.GetItem

Retrieves the currently played item
Permissions:

Parameters:

  1. Player.Id playerid
  2. [ List.Fields.All properties ]

Returns:

Type: object
Properties:

5.7.3 Player.GetProperties

Retrieves the values of the given properties
Permissions:

Parameters:

  1. Player.Id playerid
  2. Player.Property.Name[] properties

Returns: Player.Property.Value

5.7.4 Player.GoNext

Go to next item on the playlist
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.5 Player.GoPrevious

Go to previous item on the playlist
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.6 Player.GoTo

Go to item at the given position in the playlist
Permissions:

Parameters:

  1. Player.Id playerid
  2. Playlist.Position position

Returns: string

5.7.7 Player.MoveDown

If picture is zoomed move viewport down
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.8 Player.MoveLeft

If picture is zoomed move viewport left otherwise skip previous
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.9 Player.MoveRight

If picture is zoomed move viewport right otherwise skip next
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.10 Player.MoveUp

If picture is zoomed move viewport up
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.11 Player.Open

Start playback of either the playlist with the given ID, a slideshow with the pictures from the given directory or a single file or an item from the database.
Permissions:

Parameters:

  1. [ mixed item ]
  2. [ object options ]

Properties:

  • [ mixed repeat = null ]
  • [ Optional.Boolean shuffled = null ]
  • [ mixed resume = False ]

Returns: string

5.7.12 Player.PlayPause

Pauses or unpause playback and returns the new state
Permissions:

Parameters:

  1. Player.Id playerid
  2. [ Global.Toggle play = "toggle" ]

Returns: Player.Speed

5.7.13 Player.Repeat

Set the repeat mode of the player
Permissions:

Parameters:

  1. Player.Id playerid
  2. Player.Repeat state

Returns: string

5.7.14 Player.Rotate

Rotates current picture
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.15 Player.Seek

Seek through the playing item
Permissions:

Parameters:

  1. Player.Id playerid
  2. mixed value

Returns:

Type: object
Properties:

5.7.16 Player.SetAudioStream

Set the audio stream played by the player
Permissions:

Parameters:

  1. Player.Id playerid
  2. mixed stream

Returns: string

5.7.17 Player.SetSpeed

Set the speed of the current playback
Permissions:

Parameters:

  1. Player.Id playerid
  2. mixed speed

Returns: Player.Speed

5.7.18 Player.SetSubtitle

Set the subtitle displayed by the player
Permissions:

Parameters:

  1. Player.Id playerid
  2. mixed subtitle
  3. [ boolean enable = False ]

Returns: string

5.7.19 Player.Shuffle

Shuffle items in the player
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.20 Player.Stop

Stops playback
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.21 Player.UnShuffle

Unshuffle items in the player
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.22 Player.Zoom

Zooms current picture
Permissions:

Parameters:

  1. Player.Id playerid
  2. integer value

Returns: string

5.7.23 Player.ZoomIn

Zoom in once
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.7.24 Player.ZoomOut

Zoom out once
Permissions:

Parameters:

  1. Player.Id playerid

Returns: string

5.8 Playlist

5.8.1 Playlist.Add

Add item(s) to playlist
Permissions:

Parameters:

  1. Playlist.Id playlistid
  2. Playlist.Item item

Returns: string

5.8.2 Playlist.Clear

Clear playlist
Permissions:

Parameters:

  1. Playlist.Id playlistid

Returns: string

5.8.3 Playlist.GetItems

Get all items from playlist
Permissions:

Parameters:

  1. Playlist.Id playlistid
  2. [ List.Fields.All properties ]
  3. [ List.Limits limits ]
  4. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.8.4 Playlist.GetPlaylists

Returns all existing playlists
Permissions:

Parameters: None
Returns:

Type: array

5.8.5 Playlist.GetProperties

Retrieves the values of the given properties
Permissions:

Parameters:

  1. Playlist.Id playlistid
  2. Playlist.Property.Name[] properties

Returns: Playlist.Property.Value

5.8.6 Playlist.Insert

Insert item(s) into playlist. Does not work for picture playlists (aka slideshows).
Permissions:

Parameters:

  1. Playlist.Id playlistid
  2. Playlist.Position position
  3. Playlist.Item item

Returns: string

5.8.7 Playlist.Remove

Remove item from playlist. Does not work for picture playlists (aka slideshows).
Permissions:

Parameters:

  1. Playlist.Id playlistid
  2. Playlist.Position position

Returns: string

5.8.8 Playlist.Swap

Swap items in the playlist. Does not work for picture playlists (aka slideshows).
Permissions:

Parameters:

  1. Playlist.Id playlistid
  2. Playlist.Position position1
  3. Playlist.Position position2

Returns: string

5.9 System

5.9.1 System.EjectOpticalDrive

Ejects or closes the optical disc drive (if available)
Permissions:

Parameters: None
Returns: string

5.9.2 System.GetProperties

Retrieves the values of the given properties
Permissions:

Parameters:

  1. System.Property.Name[] properties

Returns: System.Property.Value

5.9.3 System.Hibernate

Puts the system running XBMC into hibernate mode
Permissions:

Parameters: None
Returns: string

5.9.4 System.Reboot

Reboots the system running XBMC
Permissions:

Parameters: None
Returns: string

5.9.5 System.Shutdown

Shuts the system running XBMC down
Permissions:

Parameters: None
Returns: string

5.9.6 System.Suspend

Suspends the system running XBMC
Permissions:

Parameters: None
Returns: string

5.10 VideoLibrary

5.10.1 VideoLibrary.Clean

Cleans the video library from non-existent items
Permissions:

Parameters: None
Returns: string

5.10.2 VideoLibrary.Export

Exports all items from the video library
Permissions:

Parameters:

  1. [ mixed options ]

Returns: string

5.10.3 VideoLibrary.GetEpisodeDetails

Retrieve details about a specific tv show episode
Permissions:

Parameters:

  1. Library.Id episodeid
  2. [ Video.Fields.Episode properties ]

Returns:

Type: object
Properties:

5.10.4 VideoLibrary.GetEpisodes

Retrieve all tv show episodes
Permissions:

Parameters:

  1. [ Library.Id tvshowid = -1 ]
  2. [ integer season = -1 ]
  3. [ Video.Fields.Episode properties ]
  4. [ List.Limits limits ]
  5. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.5 VideoLibrary.GetGenres

Retrieve all genres
Permissions:

Parameters:

  1. string type
  2. [ Library.Fields.Genre properties ]
  3. [ List.Limits limits ]
  4. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.6 VideoLibrary.GetMovieDetails

Retrieve details about a specific movie
Permissions:

Parameters:

  1. Library.Id movieid
  2. [ Video.Fields.Movie properties ]

Returns:

Type: object
Properties:

5.10.7 VideoLibrary.GetMovieSetDetails

Retrieve details about a specific movie set
Permissions:

Parameters:

  1. Library.Id setid
  2. [ Video.Fields.MovieSet properties ]
  3. [ object movies ]

Properties:

Returns:

Type: object
Properties:

5.10.8 VideoLibrary.GetMovieSets

Retrieve all movie sets
Permissions:

Parameters:

  1. [ Video.Fields.MovieSet properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.9 VideoLibrary.GetMovies

Retrieve all movies
Permissions:

Parameters:

  1. [ Video.Fields.Movie properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.10 VideoLibrary.GetMusicVideoDetails

Retrieve details about a specific music video
Permissions:

Parameters:

  1. Library.Id musicvideoid
  2. [ Video.Fields.MusicVideo properties ]

Returns:

Type: object
Properties:

5.10.11 VideoLibrary.GetMusicVideos

Retrieve all music videos
Permissions:

Parameters:

  1. [ Library.Id artistid = -1 ]
  2. [ Library.Id albumid = -1 ]
  3. [ Video.Fields.MusicVideo properties ]
  4. [ List.Limits limits ]
  5. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.12 VideoLibrary.GetRecentlyAddedEpisodes

Retrieve all recently added tv episodes
Permissions:

Parameters:

  1. [ Video.Fields.Episode properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.13 VideoLibrary.GetRecentlyAddedMovies

Retrieve all recently added movies
Permissions:

Parameters:

  1. [ Video.Fields.Movie properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.14 VideoLibrary.GetRecentlyAddedMusicVideos

Retrieve all recently added music videos
Permissions:

Parameters:

  1. [ Video.Fields.MusicVideo properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.15 VideoLibrary.GetSeasons

Retrieve all tv seasons
Permissions:

Parameters:

  1. Library.Id tvshowid
  2. [ Video.Fields.Season properties ]
  3. [ List.Limits limits ]
  4. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.16 VideoLibrary.GetTVShowDetails

Retrieve details about a specific tv show
Permissions:

Parameters:

  1. Library.Id tvshowid
  2. [ Video.Fields.TVShow properties ]

Returns:

Type: object
Properties:

5.10.17 VideoLibrary.GetTVShows

Retrieve all tv shows
Permissions:

Parameters:

  1. [ Video.Fields.TVShow properties ]
  2. [ List.Limits limits ]
  3. [ List.Sort sort ]

Returns:

Type: object
Properties:

5.10.18 VideoLibrary.RemoveEpisode

Removes the given episode from the library
Permissions:

Parameters:

  1. Library.Id episodeid

Returns: string

5.10.19 VideoLibrary.RemoveMovie

Removes the given movie from the library
Permissions:

Parameters:

  1. Library.Id movieid

Returns: string

5.10.20 VideoLibrary.RemoveMusicVideo

Removes the given music video from the library
Permissions:

Parameters:

  1. Library.Id musicvideoid

Returns: string

5.10.21 VideoLibrary.RemoveTVShow

Removes the given tv show from the library
Permissions:

Parameters:

  1. Library.Id tvshowid

Returns: string

5.10.22 VideoLibrary.Scan

Scans the video sources for new library items
Permissions:

Parameters:

  1. [ string directory = "" ]

Returns: string

5.10.23 VideoLibrary.SetEpisodeDetails

Update the given episode with the given details
Permissions:

Parameters:

  1. Library.Id episodeid
  2. [ Optional.String title = null ]
  3. [ Optional.Integer playcount = null ]
  4. [ Optional.String runtime = null ]
  5. [ mixed director = null ]
  6. [ Optional.String plot = null ]
  7. [ Optional.Number rating = null ]
  8. [ Optional.String votes = null ]
  9. [ Optional.String lastplayed = null ]
  10. [ mixed writer = null ]
  11. [ Optional.String firstaired = null ]
  12. [ Optional.String productioncode = null ]
  13. [ Optional.Integer season = null ]
  14. [ Optional.Integer episode = null ]
  15. [ Optional.String originaltitle = null ]

Returns: string

5.10.24 VideoLibrary.SetMovieDetails

Update the given movie with the given details
Permissions:

Parameters:

  1. Library.Id movieid
  2. [ Optional.String title = null ]
  3. [ Optional.Integer playcount = null ]
  4. [ Optional.String runtime = null ]
  5. [ mixed director = null ]
  6. [ mixed studio = null ]
  7. [ Optional.Integer year = null ]
  8. [ Optional.String plot = null ]
  9. [ mixed genre = null ]
  10. [ Optional.Number rating = null ]
  11. [ Optional.String mpaa = null ]
  12. [ Optional.String imdbnumber = null ]
  13. [ Optional.String votes = null ]
  14. [ Optional.String lastplayed = null ]
  15. [ Optional.String originaltitle = null ]
  16. [ Optional.String trailer = null ]
  17. [ Optional.String tagline = null ]
  18. [ Optional.String plotoutline = null ]
  19. [ mixed writer = null ]
  20. [ mixed country = null ]
  21. [ Optional.Integer top250 = null ]
  22. [ Optional.String sorttitle = null ]
  23. [ mixed set = null ]
  24. [ mixed showlink = null ]

Returns: string

5.10.25 VideoLibrary.SetMusicVideoDetails

Update the given music video with the given details
Permissions:

Parameters:

  1. Library.Id musicvideoid
  2. [ Optional.String title = null ]
  3. [ Optional.Integer playcount = null ]
  4. [ Optional.String runtime = null ]
  5. [ mixed director = null ]
  6. [ mixed studio = null ]
  7. [ Optional.Integer year = null ]
  8. [ Optional.String plot = null ]
  9. [ Optional.String album = null ]
  10. [ mixed artist = null ]
  11. [ mixed genre = null ]
  12. [ Optional.Integer track = null ]
  13. [ Optional.String lastplayed = null ]

Returns: string

5.10.26 VideoLibrary.SetTVShowDetails

Update the given tvshow with the given details
Permissions:

Parameters:

  1. Library.Id tvshowid
  2. [ Optional.String title = null ]
  3. [ Optional.Integer playcount = null ]
  4. [ mixed studio = null ]
  5. [ Optional.Integer year = null ]
  6. [ Optional.String plot = null ]
  7. [ mixed genre = null ]
  8. [ Optional.Number rating = null ]
  9. [ Optional.String mpaa = null ]
  10. [ Optional.String imdbnumber = null ]
  11. [ Optional.String premiered = null ]
  12. [ Optional.String votes = null ]
  13. [ Optional.String lastplayed = null ]
  14. [ Optional.String originaltitle = null ]
  15. [ Optional.String sorttitle = null ]
  16. [ Optional.String episodeguide = null ]

Returns: string

5.11 XBMC

5.11.1 XBMC.GetInfoBooleans

Retrieve info booleans about XBMC and the system
Permissions:

Parameters:

  1. array[1..X] booleans

Returns:

Type: object

5.11.2 XBMC.GetInfoLabels

Retrieve info labels about XBMC and the system
Permissions:

Parameters:

  1. array[1..X] labels

Returns:

Type: object

6 Global types

6.1 Application

6.1.1 Application.Property.Name

Type: string

6.1.2 Application.Property.Value

Type: object
Properties:

Properties:

6.2 Array

6.2.1 Array.Integer

Type: array

6.2.2 Array.String

Type: array

6.3 Audio

6.3.1 Audio.Details.Album

Extends:


Properties:

6.3.2 Audio.Details.Artist

Extends:


Properties:

6.3.3 Audio.Details.Base

Extends:


Properties:

6.3.4 Audio.Details.Media

Extends:


Properties:

6.3.5 Audio.Details.Song

Extends:


Properties:

6.3.6 Audio.Fields.Album

Extends:

6.3.7 Audio.Fields.Artist

Extends:

6.3.8 Audio.Fields.Song

Extends:

6.4 Configuration

6.4.1 Configuration

Type: object
Properties:

6.4.2 Configuration.Notifications

Type: object
Properties:

6.5 Files

6.5.1 Files.Media

Type: string

6.6 Global

6.6.1 Global.Time

Type: object
Properties:

6.7 Item

6.7.1 Item.Details.Base

Type: object
Properties:

6.7.2 Item.Fields.Base

Type: array

6.8 Library

6.8.1 Library.Details.Genre

Extends:


Properties:

6.8.2 Library.Fields.Genre

Extends:

6.8.3 Library.Id

Type: integer

6.9 List

6.9.1 List.Amount

Type: integer

6.9.2 List.Fields.All

Extends:

6.9.3 List.Item.All

Extends:


Properties:

6.9.4 List.Item.File

Extends:


Properties:

6.9.5 List.Items.Sources

Type: array

6.9.6 List.Limits

Type: object
Properties:

6.9.7 List.LimitsReturned

Type: object
Properties:

6.9.8 List.Sort

Type: object
Properties:

6.10 Media

6.10.1 Media.Details.Base

Extends:


Properties:

6.11 Optional

6.11.1 Optional.Boolean

Type: mixed

6.12 Player

6.12.1 Player.Audio.Stream

Type: object
Properties:

6.12.2 Player.Audio.Stream.Extended

Extends:


Properties:

6.12.3 Player.Id

Type: integer

6.12.4 Player.Notifications.Data

Type: object
Properties:

6.12.5 Player.Notifications.Item

Type: mixed

6.12.6 Player.Notifications.Item.Type

Type: string

6.12.7 Player.Notifications.Player

Type: object
Properties:

6.12.8 Player.Notifications.Player.Seek

Extends:


Properties:

6.12.9 Player.Position.Percentage

Type: number

6.12.10 Player.Property.Name

Type: string

6.12.11 Player.Property.Value

Type: object
Properties:

6.12.12 Player.Repeat

Type: string

6.12.13 Player.Speed

Type: object
Properties:

6.12.14 Player.Subtitle

Type: object
Properties:

6.12.15 Player.Type

Type: string

6.13 Playlist

6.13.1 Playlist.Id

Type: integer

6.13.2 Playlist.Item

Type: mixed

6.13.3 Playlist.Position

Type: integer

6.13.4 Playlist.Property.Name

Type: string

6.13.5 Playlist.Property.Value

Type: object
Properties:

6.13.6 Playlist.Type

Type: string

6.14 System

6.14.1 System.Property.Name

Type: string

6.14.2 System.Property.Value

Type: object
Properties:

6.15 Video

6.15.1 Video.Cast

Type: array

6.15.2 Video.Details.Base

Extends:


Properties:

6.15.3 Video.Details.Episode

Extends:


Properties:

6.15.4 Video.Details.File

Extends:


Properties:

6.15.5 Video.Details.Item

Extends:


Properties:

6.15.6 Video.Details.Media

Extends:


Properties:

6.15.7 Video.Details.Movie

Extends:


Properties:

6.15.8 Video.Details.MovieSet

Extends:


Properties:

6.15.9 Video.Details.MovieSet.Extended

Extends:


Properties:

6.15.10 Video.Details.MusicVideo

Extends:


Properties:

6.15.11 Video.Details.Season

Extends:


Properties:

6.15.12 Video.Details.TVShow

Extends:


Properties:

6.15.13 Video.Fields.Episode

Extends:

6.15.14 Video.Fields.Movie

Extends:

6.15.15 Video.Fields.MovieSet

Extends:

6.15.16 Video.Fields.MusicVideo

Extends:

6.15.17 Video.Fields.Season

Extends:

6.15.18 Video.Fields.TVShow

Extends:

6.15.19 Video.Resume

Type: object
Properties:

6.15.20 Video.Streams

Type: object
Properties:


7 Notifications

7.1 AudioLibrary

7.1.1 AudioLibrary.OnRemove

An audio item has been removed.
Parameters:

  1. string sender
  2. object data

Properties:

7.1.2 AudioLibrary.OnUpdate

An audio item has been updated.
Parameters:

  1. string sender
  2. object data

Properties:

7.2 Player

7.2.1 Player.OnPause

Playback of a media item has been paused. If there is no ID available extra information will be provided.
Parameters:

  1. string sender
  2. Player.Notifications.Data data

7.2.2 Player.OnPlay

Playback of a media item has been started or the playback speed has changed. If there is no ID available extra information will be provided.
Parameters:

  1. string sender
  2. Player.Notifications.Data data

7.2.3 Player.OnSeek

The playback position has been changed. If there is no ID available extra information will be provided.
Parameters:

  1. string sender
  2. object data

Properties:

7.2.4 Player.OnSpeedChanged

Speed of the playback of a media item has been changed. If there is no ID available extra information will be provided.
Parameters:

  1. string sender
  2. Player.Notifications.Data data

7.2.5 Player.OnStop

Playback of a media item has been stopped. If there is no ID available extra information will be provided.
Parameters:

  1. string sender
  2. object data

Properties:

7.3 System

7.3.1 System.OnLowBattery

The system is on low battery.
Parameters:

  1. string sender
  2. null data

7.3.2 System.OnQuit

XBMC will be closed.
Parameters:

  1. string sender
  2. null data

7.3.3 System.OnRestart

The system will be restarted.
Parameters:

  1. string sender
  2. null data

7.3.4 System.OnSleep

The system will be suspended.
Parameters:

  1. string sender
  2. null data

7.3.5 System.OnWake

The system woke up from suspension.
Parameters:

  1. string sender
  2. null data

7.4 VideoLibrary

7.4.1 VideoLibrary.OnRemove

A video item has been removed.
Parameters:

  1. string sender
  2. object data

Properties:

7.4.2 VideoLibrary.OnUpdate

A video item has been updated.
Parameters:

  1. string sender
  2. object data

Properties:

  • [ integer playcount = -1 ]
  • string type
  • Library.Id id

8 See also

9 External links

Personal tools
Namespaces
Variants
Actions
Navigation
Wiki help
Google Search
Toolbox