diff --git a/Description.md b/Description.md deleted file mode 100644 index f9620c0..0000000 --- a/Description.md +++ /dev/null @@ -1,65 +0,0 @@ -# API Description -TVHeadend provides the API using the HTTP protocol, by default via port 9981 though this can be changed in the TVH config. Both the GET and POST methods may be used. - -The URL must include a username and password with access permissions to carry out the requested task. If TVHeadend has been started with the '--http_root' qualifier, the HTTP root must be included in the URL, thus eg - -`http://admin:admin@192.168.3.45:9981/myHttpRoot/api/config/capabilities` - -The response from TVH follows the HTTP protocol and includes a status indicating successful completion or the nature of any error. - -Data is usually returned as JSON, without any CR or LF characters - the examples given have been 'prettified' to make them easier to read. Functions which perform an action rather than return data will return an empty JSON object on successful completion. - -## Grid parameters -API calls which end in `/grid`, with the exception of `epg/event/grid`, have a common set of parameters: -- `start` First entry to include. Default is the first. -- `limit` Number of entries to include. **Default is 50** - use a large number to get all. -- `filter` A JSON object describing the filter(s) to be applied. See [Grid Filters](Description.md#grid-filters) below for syntax. -- `sort` Name of the field to sort the records by. A case-sensitive sort is used. -- `dir` if `sort` is specified then `dir=desc` produces a reverse sort. -### Grid filters -A filter can be applied to the output using a JSON object. The syntax is: -``` -filter=[ - { - "field" : "" - "type" : "string|numeric|boolean" - "value" : "" - "comparison" : "gt|lt|eq" - }, ... - ] -``` -The "comparison" field is only used with numeric data; booleans must match exactly while for strings a regular expression match is used. -## Load parameters -API calls which end in `/load` have a common set of parameters: -- `meta` If > 0 a more complex data structure is output, mostly related to the format of the GUI screen where the information is presented. Default is 0. -## Code examples -### curl -Parameters passed to TVH using the GET method must be URI-encoded: - -`curl 'http://user:pass@localhost:9981/api/epg/events/grid?limit=999&channel=BBC%20ONE'` - -Alternatively use the POST Method: - -`curl --data 'limit=999&channel=BBC ONE' 'http://user:pass@localhost:9981/api/epg/events/grid'` - -To make the output more human-readable, pipe it through json_pp (included in the perl package on many distributions). -### PHP -This simple example lists some details about upcoming timers, sorted in date order. To work through a PHP-enabled web server, the PHP.INI setting "allow_url_fopen" must be ON. -``` -$timers = get_timers(); -foreach($timers as $t) { - $start = strftime("%H:%M", $t["start"]); - $stop = strftime("%H:%M", $t["stop"]); - $date = strftime("%a %e/%m", $t["start"]); - echo "Date: $date, Start: $start, End: $stop, Title: {$t['disp_title']}"; -} - -function get_timers() { - $url = "http://admin:admin@localhost:9981/api/dvr/entry/grid_upcoming?sort=start"; - $json = file_get_contents($url); - $j = json_decode($json, true); - $ret = &$j["entries"]; - return $ret; -} -``` -For an example of what can be done with the API in PHP see [https://github.com/dave-p/TVHadmin](https://github.com/dave-p/TVHadmin). diff --git a/access.md b/access.md deleted file mode 100644 index 83564e2..0000000 --- a/access.md +++ /dev/null @@ -1,83 +0,0 @@ -# access -Functions to list and manipulate access controls. With the exception of access/entry/userlist, ADMIN privilege is required to use these functions. -## passwd/entry/class -Lists the text strings, options and defaults used when configuring access controls within TVH (ie Configuration -> Users --> Passwords). It is only likely to be needed for recreating the existing TVH GUI. -## passwd/entry/grid -Lists passwords for users. Note that "password" is in clear-text while "password2" is base64-encoded with a static prefix. -``` -{ - "total" : 1, - "entries" : [ - { - "password" : "XxXxXxXx", - "uuid" : "2fa9ebf7e421a537ac032a6905134137", - "username" : "xxxxxx", - "enabled" : true, - "wizard" : true, - "password2" : "Base64EncodedPassword" -} -``` -## passwd/entry/create -Creates a new password record. -- `conf` The JSON object describing the record. -## ipblock/entry/class -Lists the text strings, options and defaults used when configuring access controls within TVH (ie Configuration -> Users --> IP Blocking Records). It is only likely to be needed for recreating the existing TVH GUI. -## ipblock/entry/grid - -## ipblock/entry/create -Creates a new IP-based access record. -- `conf` The JSON object describing the access record. -## access/entry/class -Lists the text strings, options and defaults used when configuring access controls within TVH (ie Configuration -> Users --> Access Entries). It is only likely to be needed for recreating the existing TVH GUI. -## access/entry/userlist - -## access/entry/grid -Lists users and their privileges. -``` -{ - "total" : 2, - "entries" : [ - { - "change" : [ - "change_rights", - "change_chrange", - "change_chtags", - "change_dvr_configs", - "change_profiles", - "change_conn_limit", - "change_lang", - "change_lang_ui", - "change_theme", - "change_uilevel" - ], - "conn_limit" : 0, - "admin" : false, - "dvr_config" : [], - "dvr" : [], - "htsp_anonymize" : false, - "wizard" : false, - "profile" : [], - "streaming" : [], - "webui" : true, - "channel_min" : 0, - "channel_max" : 0, - "uuid" : "59c300295cbf01e53f096242fd5b8ffc", - "index" : 1, - "lang" : "eng_GB", - "comment" : "New entry", - "channel_tag" : [], - "username" : "*", - "channel_tag_exclude" : false, - "conn_limit_type" : 0, - "uilevel_nochange" : 0, - "prefix" : "192.168.0.0/24", - "enabled" : true, - "uilevel" : 0 - }, ... -``` -## access/entry/create -Creates a new user from a JSON object. -- `conf` The JSON object describing the new user. diff --git a/bouquet.md b/bouquet.md deleted file mode 100644 index 4414732..0000000 --- a/bouquet.md +++ /dev/null @@ -1,55 +0,0 @@ -# bouquet - -## bouquet/list -Lists names and bouquets. The list excerpted below is coded into tvheadend. -``` -{ - "entries" : [ - { - "key" : "e7ddb611669a6a612846415946272f89", - "val" : "Canal Digitaal SD" - }, ... - ] -} -``` -## bouquet/class -Lists the text strings, options and defaults used when configuring bouquets within TVH (ie Configuration -> Channel/EPG -> Bouquets). It is only likely to be needed for recreating the existing TVH GUI. -## bouquet/grid -Lists details of bouquets. For details of the parameters and selection criteria which can be applied, see [Grid Parameters](Description.md#grid-parameters). -``` -{ - "entries" : [ - { - "name" : "Canal Digitaal SD", - "uuid" : "e7ddb611669a6a612846415946272f89", - "lcn_off" : 0, - "services" : {}, - "chtag_ref" : "", - "maptoch" : false, - "source" : "dvb-fastscan://DVB-S,19.2E,12515000,H,22000000,900", - "ext_url_period" : 60, - "chtag" : [], - "services_count" : 0, - "services_seen" : 0, - "ssl_peer_verify" : false, - "mapopt" : [ - "encrypted" - ], - "enabled" : false - }, ... - ] - "total" : 13 -} -``` -## bouquet/create -Create a new bouquet. - -- `conf` Object describing the new bouquet. An element `ext_url` is required; presumably in the format of the `source` element in bouquet/grid. -## bouquet/scan -Scan one or more bouquets to find their channels. - -- `uuid` uuid(s) of bouquet(s) to scan. -## bouquet/detach -Removes the link from a channel to the bouquet that it is part of. - -- `uuid` uuid(s) of channels to detach. diff --git a/caclient.md b/caclient.md deleted file mode 100644 index f18c094..0000000 --- a/caclient.md +++ /dev/null @@ -1,25 +0,0 @@ -# caclient -API calls related to Conditional Access. -## caclient/list -List CA clients -``` -{ - "entries" : [ - { - "title" : "Linux DVB CAM (CI/CI+)", - "status" : "caclientNone", - "uuid" : "7f435a73b190419cc6e69e3956c50549" - } - ] -} -``` -## caclient/class -Lists the text strings, options and defaults used when configuring Conditional Access within TVH (ie Configuration -> CAs). -## caclient/builders -Lists the text strings, options and defaults used when configuring Conditional Access devices within TVH (ie Configuration -> CAs -> Add). -## caclient/create -Create a new CA instance. - -- `class` Name of the class to create, ie one of the classes listed by `caclient/builders`. - -- `conf` A JSON object describing the new device. diff --git a/channel.md b/channel.md deleted file mode 100644 index 3c55992..0000000 --- a/channel.md +++ /dev/null @@ -1,103 +0,0 @@ -# channel -Functions to query and manipulate the list of channels. - -A TVH user can only see via the API those channels which have been enabled and to which access has been allowed. However a user with ADMIN privilege can use the parameter `all=1` to see details of every channel, channeltag and category even if they do not have access to them. - -## channel/class -Lists the text strings, options and defaults used when configuring channels within TVH (ie Configuration -> Channel/EPG -> Channel -> Add). It is only likely to be needed for recreating the existing TVH GUI. -## channel/grid -Lists details of channels. For details of the parameters and selection criteria which can be applied, see [Grid Parameters](Description.md#grid-parameters). -``` -{ - "entries" : [ - { - "dvr_pst_time" : 0, - "enabled" : true, - "epgauto" : true, - "autoname" : true, - "name" : "BBC RB 1", - "number" : 601, - "tags" : [ - "21d5fe751062c4d99997d6cb48f43c55", - "1a2a61c4374cedb1fc29417f1a517446" - ], - "services" : [ - "9b0e2e103a373350f5e99cda6dd3f055" - ], - "epg_running" : -1, - "epggrab" : [], - "uuid" : "ae63d3b40fbfab610f49290abc189472", - "bouquet" : "", - "dvr_pre_time" : 0 - }, ... - ], - "total" : 104 -} -``` -## channel/list -Lists the names and uuids of all known channels. - -These parameters were added at version 4.3-905: - -- `numbers` If non-zero, the LCN appears before the channel name, separated by a space. Default is zero. -- `sources` If non-zero, the source appears after the channel name, in square brackets and separated by a space. Default is zero. -- `sort` Either `name` to sort by channel name, or `numname` to sort by LCN then by name (default). -``` -{ - "entries" : [ - { - "val" : "Channel 5+1", - "key" : "7e7b77801531c803f5ce8f4d5003f44c" - }, ... - ] -} -``` -## channel/create -Creates a new channel. - -- `conf` A JSON object containing details of the new channel. -## channel/rename -Renames a channel. Only available from version 4.3.652. -- `from` The current name of the channel. -- `to` The new name of the channel. -## channeltag/class -Lists the text strings, options and defaults used when configuring channels within TVH (ie Configuration -> Channel/EPG -> Channel Tags -> Add). It is only likely to be needed for recreating the existing TVH GUI. -## channeltag/grid -Lists details of channel tags. For details of the parameters and selection criteria which can be applied, see [Grid Parameters](Description.md#grid-parameters). -``` -{ - "total" : 5, - "entries" : [ - { - "index" : 0, - "private" : false, - "icon_public_url" : "", - "internal" : false, - "name" : "Radio", - "titled_icon" : false, - "enabled" : true, - "uuid" : "3479ac5a48d6680fc37d8b411cf0e2e8", - "icon" : "", - "comment" : "" - }, ... - ] -} -``` -## channeltag/list -Lists the names and uuids of all channel tags. -``` -{ - "entries" : [ - { - "key" : "3479ac5a48d6680fc37d8b411cf0e2e8", - "val" : "Radio" - }, ... - ] -} -``` -## channeltag/create -Creates a new channel tag. - -- `conf` A JSON object containing details of the new channel tag. -## channelcategory/list -?? diff --git a/codec.md b/codec.md deleted file mode 100644 index 2d35ced..0000000 --- a/codec.md +++ /dev/null @@ -1,34 +0,0 @@ -# codec - -## codec/list -Lists available codecs and their properties. This is a very verbose list. -## codec_profile/list -``` -{ - "entries" : [ - { - "uuid" : "d3f76d002a895f5c65dd57715d169399", - "title" : "webtv-vorbis (WEBTV codec Vorbis)", - "status" : "codecEnabled" - }, - { - "status" : "codecEnabled", - "title" : "webtv-aac (WEBTV codec AAC)", - "uuid" : "77e7184d6ade386137f553de0687254d" - }, - { - "title" : "webtv-h264 (WEBTV codec H264)", - "status" : "codecEnabled", - "uuid" : "eb7281ade724c77d23add9223bc2a480" - } - ] -} -``` -## codec_profile/create -Add a new codec profile? - -- `class` The name of the codec profile. - -- `conf` A JSON object describing the codec profile. -## codec_profile/class -Lists the text strings, options and defaults used when configuring codec profiles? diff --git a/config.md b/config.md deleted file mode 100644 index 3a8a22c..0000000 --- a/config.md +++ /dev/null @@ -1,56 +0,0 @@ -# config - -## config/capabilities -(Purpose unknown.) -```[ - "caclient", - "tvadapters", - "imagecache", - "timeshift", - "trace", - "libav" -] -``` -## config/load -Lists the details, descriptions, defaults and current values of the items in the GUI screen Configuration -> General -> Base. -## config/save -**Untested.** Presumably updates the server from an object in the format produced by config/load. -## tvhlog/config/load -Lists the details, descriptions, defaults and current values of the items in the GUI screen Configuration -> Debugging -> Configuration -> Settings. -## tvhlog/config/save -**Untested.** Presumably updates the server from an object in the format produced by tvhlog/config/load. -## memoryinfo/class -Lists the details and descriptions of items in the TVH GUI screen Configuration -> Debugging -> Memory Information Entries. -## memoryinfo/grid -Lists details of in-memory objects. See [Grid Parameters](Description.md#grid-parameters) for details of selection parameters. -``` -{ - "entries" : [ - { - "peak_count" : 17154, - "name" : "EPG Broadcasts", - "uuid" : "a1af1bc4f29ba28104e71a540465f250", - "count" : 17154, - "peak_size" : 6235792, - "size" : 6235792 - }, - { - "peak_count" : 3285, - "peak_size" : 369303, - "count" : 3285, - "size" : 369303, - "name" : "EPG Series Links", - "uuid" : "823a78a3bcd05b688c59871455da6399" - }, - { - "count" : 11514, - "peak_size" : 5015593, - "size" : 5015593, - "name" : "EPG Episodes", - "uuid" : "5c666eea1ec3de4bbb9a11f60116b258", - "peak_count" : 11514 - }, ... - ], - "total" : 19 -} -``` diff --git a/dvr.md b/dvr.md deleted file mode 100644 index ac0f7be..0000000 --- a/dvr.md +++ /dev/null @@ -1,413 +0,0 @@ -# DVR -This section includes functions to manipulate recorder objects; timers, autorecs and recordings. - -## dvr/config/class -Lists the text strings, options and defaults used when configuring the DVR capability within TVH (ie Configuration -> Recording). -## dvr/config/grid -Lists the configuration sets available for the TVH server together with their options. Configurations are identified by their `name` parameter; the default config has the name blank. -``` -{ - "total" : 1, - "entries" : [ - { - "cache" : 2, - "storage-mfree" : 1000, - "autorec-maxsched" : 0, - "whitespace-in-title" : false, - "time-in-title" : false, - "channel-dir" : false, - "epg-running" : true, - "name" : "", - "episode-in-title" : false, - "profile" : "af143f0983fd4e91953fb859c5561984", - "clean-title" : false, - "pre-extra-time" : 0, - "uuid" : "4e3a1e1cacd2d559c129e7b90f6c986e", - "day-dir" : false, - "subtitle-in-title" : false, - "epg-update-window" : 86400, - "title-dir" : false, - "warm-time" : 30, - "windows-compatible-filenames" : false, - "autorec-maxcount" : 0, - "removal-days" : 2147483647, - "storage-mused" : 0, - "tag-files" : true, - "clone" : true, - "omit-title" : false, - "enabled" : true, - "storage" : "/mnt/tvheadend", - "date-in-title" : false, - "channel-in-title" : false, - "post-extra-time" : 0, - "skip-commercials" : false, - "rerecord-errors" : 0, - "file-permissions" : "0664", - "retention-days" : 2147483646, - "charset" : "ASCII", - "pri" : 2, - "directory-permissions" : "0775", - "pathname" : "$t$n.$x" - } - ] -} -``` -## dvr/config/create -Creates a new configuration set. Parameters passed are: -- `name` configuration name -- `conf` parameter set, passed as a JSON object -## dvr/entry/class -Lists the text strings, options and defaults used when editing an upcoming recording. - -## dvr/entry/grid -Lists all of the recordings that TVH knows about, ie it combines the output of `grid_upcoming`, `grid_finished`, `grid_failed` and `grid_removed`. Use the `status` parameter to tell them apart. - -See [Grid Parameters](Description.md#grid-parameters) for parameter details. -## dvr/entry/grid_upcoming -Lists all of the currently-scheduled recordings. See [Grid Parameters](Description.md#grid-parameters) for parameter details. -``` -{ - "total" : 6, - "entries" : [ - { - "comment" : "Auto recording: Created from EPG query", - "creator" : "xxxxxx", - "disp_description" : "Documentary series. A driver raises the alarm when he suspects that his train has hit something on the line, and engineers begin the process of dismantling a Victorian viaduct. (S1 Ep 6)[S]", - "start_extra" : 0, - "noresched" : false, - "stop_extra" : 0, - "enabled" : true, - "description" : { - "eng" : "Documentary series. A driver raises the alarm when he suspects that his train has hit something on the line, and engineers begin the process of dismantling a Victorian viaduct. (S1 Ep 6)[S]" - }, - "title" : { - "eng" : "Paddington Station 24/7" - }, - "subtitle" : { - "eng" : "Documentary series. A driver raises the alarm when he suspects that his train has hit something on the line, and engineers begin the process of dismantling a Victorian viaduct. (S1 Ep 6)[S]" - }, - "start_real" : 1508724570, - "duplicate" : 0, - "removal" : 0, - "dvb_eid" : 29271, - "channel_icon" : "", - "start" : 1508724600, - "channelname" : "Channel 5 HD", - "autorec" : "f2c30b9757e66567bf2d8ec6de60314c", - "config_name" : "4e3a1e13acd2d5a9c129e7b00f6c986e", - "timerec" : "", - "stop_real" : 1508727600, - "content_type" : 8, - "parent" : "", - "disp_subtitle" : "Documentary series. A driver raises the alarm when he suspects that his train has hit something on the line, and engineers begin the process of dismantling a Victorian viaduct. (S1 Ep 6)[S]", - "filename" : "", - "errorcode" : 0, - "duration" : 3000, - "timerec_caption" : "", - "child" : "", - "errors" : 0, - "playcount" : 0, - "norerecord" : false, - "url" : "", - "playposition" : 0, - "data_errors" : 0, - "stop" : 1508727600, - "sched_status" : "scheduled", - "broadcast" : 898373, - "status" : "Scheduled for recording", - "disp_title" : "Paddington Station 24/7", - "filesize" : 0, - "pri" : 6, - "channel" : "a931256950c3f8aa5c5416cd36175e13", - "uuid" : "52f0c81843b3f87ee276bdd02c325d52", - "fileremoved" : 0, - "autorec_caption" : " (Created from EPG query)", - "owner" : "xxxxxx", - "retention" : 0 - } ... - ] -} -``` -## dvr/entry/grid_finished -Lists recordings which have completed and which are still in the TVH logs. See [Grid Parameters](Description.md#grid-parameters) for parameter details. -``` -{ - "total" : 37, - "entries" : [ - { - "enabled" : true, - "disp_subtitle" : "It's Spring and Dick buys a tractor, with plans to tame the walled garden. Angel designs a new boudoir with black walls and mirrors. The couple also consider truffle farming. (S3 Ep2/3) [AD,S]", - "channel_icon" : "", - "errorcode" : 0, - "config_name" : "4e3a1e13acd2d5a9c129e7b00f6c986e", - "broadcast" : 0, - "owner" : "xxxxxx", - "noresched" : true, - "stop_real" : 1506884400, - "filename" : "/video/tvheadend/Escape to the Chateau-1.ts", - "playposition" : 0, - "start_real" : 1506880770, - "duration" : 3600, - "removal" : 0, - "disp_description" : "It's Spring and Dick buys a tractor, with plans to tame the walled garden. Angel designs a new boudoir with black walls and mirrors. The couple also consider truffle farming. (S3 Ep2/3) [AD,S]", - "status" : "Completed OK", - "subtitle" : { - "eng" : "It's Spring and Dick buys a tractor, with plans to tame the walled garden. Angel designs a new boudoir with black walls and mirrors. The couple also consider truffle farming. (S3 Ep2/3) [AD,S]" - }, - "autorec_caption" : "", - "title" : { - "eng" : "Escape to the Chateau" - }, - "autorec" : "", - "sched_status" : "completed", - "duplicate" : 0, - "norerecord" : false, - "channelname" : "Channel 4 HD", - "stop_extra" : 0, - "pri" : 6, - "channel" : "d6727549be8e6a532ff322c389eb3bd4", - "errors" : 0, - "content_type" : 9, - "timerec" : "", - "url" : "dvrfile/7b43663e74e11d9a3efda4bf7baa3548", - "disp_title" : "Escape to the Chateau", - "filesize" : 2338180064, - "retention" : 0, - "description" : { - "eng" : "It's Spring and Dick buys a tractor, with plans to tame the walled garden. Angel designs a new boudoir with black walls and mirrors. The couple also consider truffle farming. (S3 Ep2/3) [AD,S]" - }, - "stop" : 1506884400, - "child" : "", - "comment" : "Auto recording: Created from EPG query", - "playcount" : 0, - "start" : 1506880800, - "data_errors" : 0, - "parent" : "", - "start_extra" : 0, - "uuid" : "7b4366de74e11d9a3ef0a4bf7baa3548", - "timerec_caption" : "", - "fileremoved" : 0, - "dvb_eid" : 0, - "creator" : "xxxxxx" - } ... - ] - } -``` -## dvr/entry/grid_failed -Lists failed recordings. See [Grid Parameters](Description.md#grid-parameters) for parameter details. - -If you merge the 'failed' and 'completed' recordings into a single list, the only way to tell which list the entries originally came from is by using the `status` field. -```{ - "total" : 1, - "entries" : [ - { - "parent" : "", - "channelname" : "BBC Four HD", - "start" : 1513112400, - "stop_real" : 1513116000, - "description" : { - "eng" : "2/3. Series in which Sam Willis reveals stories of invasion in Britain, including the Barbary Corsaire pirates and the tale of King Louis the Lion, who invaded in the 13th century. [HD] [S]" - }, - "comment" : "Auto recording: Created from EPG query", - "disp_title" : "New: Invasion! with Sam Willis", - "child" : "", - "uri" : "crid://fp.bbc.co.uk/247LP4", - "image" : "", - "dvb_eid" : 62795, - "autorec_caption" : " (Created from EPG query)", - "removal" : 0, - "url" : "dvrfile/22d9847b550b8fe9e39e01bda2e41777", - "owner" : "xxxxxx", - "copyright_year" : 0, - "playposition" : 0, - "filename" : "/video/tvheadend/New: Invasion! with Sam Willis.ts", - "start_real" : 1513112355, - "start_extra" : 0, - "duration" : 3600, - "category" : [], - "creator" : "xxxxxx", - "playcount" : 0, - "sched_status" : "completed", - "status" : "Too many data errors", - "autorec" : "5cf012bf5c78e23d3c89c59c172414cb", - "errors" : 0, - "norerecord" : false, - "broadcast" : 0, - "noresched" : true, - "keyword" : [], - "config_name" : "ffb7136480e16dac47c8e71bd7686537", - "disp_subtitle" : "2/3. Series in which Sam Willis reveals stories of invasion in Britain, including the Barbary Corsaire pirates and the tale of King Louis the Lion, who invaded in the 13th century. [HD] [S]", - "enabled" : true, - "stop_extra" : 0, - "pri" : 6, - "retention" : 0, - "subtitle" : { - "eng" : "2/3. Series in which Sam Willis reveals stories of invasion in Britain, including the Barbary Corsaire pirates and the tale of King Louis the Lion, who invaded in the 13th century. [HD] [S]" - }, - "disp_description" : "2/3. Series in which Sam Willis reveals stories of invasion in Britain, including the Barbary Corsaire pirates and the tale of King Louis the Lion, who invaded in the 13th century. [HD] [S]", - "fileremoved" : 0, - "filesize" : 2171129092, - "credits" : {}, - "title" : { - "eng" : "New: Invasion! with Sam Willis" - }, - "content_type" : 2, - "genre" : [], - "errorcode" : 0, - "stop" : 1513116000, - "channel_icon" : "", - "data_errors" : 510410, - "timerec" : "", - "channel" : "7bd448424af369b19f22511b1ece023c", - "uuid" : "22d9847b550b8fe9e39e01bda2e41777", - "timerec_caption" : "", - "first_aired" : 0, - "duplicate" : 0 - } - ] -} -``` -## dvr/entry/grid_removed -Lists removed recordings. See [Grid Parameters](Description.md#grid-parameters) for parameter details. - -If TVH is configured to delete the log record when a recording is deleted this function will always return nothing. -## dvr/entry/create -Creates a new epg-derived timer from a JSON object. - -- `conf` The JSON object describing the timer. Items not specified are derived from the default profile of the user. An example of the minimum useful JSON is shown below. -``` -{ - "start":1509397200, - "stop":1509400800, - "channelname":"Channel 5", - "title":{ - "eng":"Paddington Station 24/7" - }, - "subtitle":{"eng":"More real-life dramas..."} -} -``` -The function returns the uuid of the created timer on success. - -It is also possible using this function to add a file created elsewhere into the TVH database as a completed recording. Items needed in the JSON are: -``` -{ - "enabled": true, - "start": 1509000000, - "stop": 1509003600, - "channelname": "local file", - "title": { - "eng": "my title" - }, - "subtitle": { - "eng": "filename: my video" - }, - "description": { - "eng": "my description" - }, - "comment": "added by tvh_addfile.py", - "files": [ - { - "filename": "/full/path/to/videofile.ts" - } - ] -} -``` -It is important that the start and stop times are in the past, otherwise TVH will try to create a timer to record the event. *(Thanks to "ullix tv" for this information.)* Also note that the ability to add a pre-recorded file is unintended behaviour - see [Caution](Intro.md#caution). -## dvr/entry/create_by_event -Creates a new one-off timer. Input parameters are: -- `config_uuid` this is the `uuid` parameter from the output of `dvr/config/grid` -- `event_id` this is the `eventId` parameter for the event, taken from `epg/events/grid` -## dvr/entry/rerecord/toggle, dvr/entry/rerecord/deny, dvr/entry/rerecord/allow -These functions provide the same capability as the Re-record button in Digital Video Recorder -> Finished Recordings. "Allow" sets the recording to be re-done, "deny" cancels a scheduled rerecording, "toggle" reverses the rerecord state. -- `uuid` the `uuid` of the finished or failed recording, or a JSON object containing an array of uuids. -## dvr/entry/stop -Gracefully stops a running recording. -- `uuid` The `uuid` value from the timer's entry in `dvr/entry/grid`. -## dvr/entry/cancel -Deletes a timer or stops a running recording. -- `uuid` The `uuid` value from the timer's entry in `dvr/entry/grid`. - -**NOTE** To delete a series use `idnode/delete`, passing parameter `uuid` from the entry in `dvr/timerec/grid`. -## dvr/entry/prevrec/toggle, dvr/entry/prevrec/set, dvr/entry/prevrec/unset -These three functions affect the "previously recorded" status of a timer. If set, either directly or via a call to the toggle function, the timer is marked as completed and the file flagged as deleted. If unset, a new timer is created. - -These functions provide the same capability as the Previously Recorded button in Digital Video Recorder -> Upcoming/Current Recordings. It can be used to 'hide' re-runs to prevent them being re-recorded. -## dvr/entry/remove -Removes a completed recording from storage. -- `uuid` The recording's `uuid` value from `dvr/entry/grid_finished`. -## dvr/entry/filemoved -Informs TVH that a recording has been relocated (by external means) within the filesystem. -- `src` The original full path to the file -- `dst` The new full path to the file -## dvr/entry/move/finished -Move a **finished** recording entry to the "Finished Recordings" category, presumably from "Failed Recordings". The actual file is not moved. -- `uuid` The `uuid` of the entry, or an array of entries passed as a JSON object. -## dvr/entry/move/failed -Move a **finished** recording entry to the "Failed Recordings" category, presumably from "Finished Recordings". The actual file is not moved. -- `uuid` The `uuid` of the entry, or an array of entries passed as a JSON object. -## dvr/autorec/class -Lists the text strings, options and defaults used when creating or editing a series timer. -## dvr/autorec/grid -Lists autorecs (series timers). See [Grid Parameters](Description.md#grid-parameters) for parameter details. -``` -{ - "entries" : [ - { - "record" : 0, - "pri" : 6, - "channel" : "a931256950c3f8aa5c5416cd36175e13", - "content_type" : 0, - "retention" : 0, - "fulltext" : false, - "start_window" : "Any", - "serieslink" : "crid://www.five.tv/R5HP0", - "config_name" : "4e3a1e13acd2d5a9c129e7b00f6c986e", - "maxduration" : 0, - "removal" : 0, - "start_extra" : 0, - "stop_extra" : 0, - "maxcount" : 0, - "owner" : "xxxxxx", - "weekdays" : [ - 1, - 2, - 3, - 4, - 5, - 6, - 7 - ], - "uuid" : "f2c30b9757e66567bf2d8ec6de60314c", - "creator" : "xxxxxx", - "tag" : "", - "maxsched" : 0, - "comment" : "Created from EPG query", - "start" : "Any", - "btype" : 0, - "brand" : "", - "enabled" : true, - "season" : "", - "minduration" : 0, - "title" : "New: Paddington Station 24/7" - }, ... - ], - "total" : 9 -} -``` -## dvr/autorec/create -Create a new series timer by specifying search parameters. To create a timer using CRIDs use `dvr/autorec/create_by_series`. -- `conf` A JSON object specifying the selection parameters for the timer. -- `config_uuid` The `uuid` parameter from the output of `dvr/config/grid`. Parameter `config_name` may be passed instead. -## dvr/autorec/create_by_series -Creates a new series timer using CRIDs. Input parameters are: -- `config_uuid` The `uuid` parameter from the output of `dvr/config/grid` -- `event_id` The `eventId` parameter for one event in the series, taken from `epg/events/grid` - -**NOTE** To delete a series use `idnode/delete`, passing parameter `uuid` from the entry in `dvr/timerec/grid`. -## dvr/timerec/class -Lists the text strings, options and defaults used when creating or editing a time-based recording. -## dvr/timerec/grid -Lists time-based recordings. See [Grid Parameters](Description.md#grid-parameters) for parameter details. -## dvr/timerec/create -Create a new time-based timer. -- `conf` A JSON object specifying the selection parameters for the timer. diff --git a/epg.md b/epg.md deleted file mode 100644 index dba93c4..0000000 --- a/epg.md +++ /dev/null @@ -1,119 +0,0 @@ -# epg -Functions to query the Electronic Program(me) Guide. -## epg/events/grid -Query the EPG and optionally apply filters. -- `lang` ? -- `mode` If set to the string `now` then only events currently playing are listed. -- `title` A string which must appear in the title to be listed. -- `fulltext` If set to 1 then the `title` string must match exactly. Default is 0. -- `channel` The channel to show events from, specified either by channel name or uuid. Must be an exact match to the data from `channel/list`, otherwise all channels are returned. -- `channelTag` ? -- `durationMin` Shortest event to be listed (seconds). -- `durationMax` Longest event to be listed (seconds). -- `contentType` Integer representing the genre to be listed - see `epg/content_type/list`. -- `filter` A JSON object describing the filter(s) to be applied. See [Grid Filters](Description.md#grid-filters) for the syntax. -- `sort` The key to be sorted by. Default is to sort by 'start'. -- `dir` If `sort` is specified, setting 'dir' to 'desc' reverses the sort order -- `start` First record to be listed from the database, default is 0. -- `limit` Number of records to list. **Default is 50** - use a very large number to get all. -- `new` If set to 1 then only events marked as 'new' will be included. Default is 0. The EPG source must identify 'new' events for this filter to work. - -EPG sources differ in the information which they provide. Any items which have no data available will be omitted. - -``` -{ - "totalCount" : 18575, - "entries" : [ - { - "serieslinkUri" : "crid://www.channel4.com/M4EI0021031162146302", - "serieslinkId" : 510179, - "episodeId" : 510180, - "episodeUri" : "crid://www.channel4.com/41408/013", - "summary" : "Tony Robinson and the Team descend on the bleak landscape of Bodmin Moor to examine a Bronze Age village and a vast, ancient 300m-long stone structure. [S]", - "genre" : [ - 160 - ], - "channelName" : "More 4", - "title" : "Time Team", - "start" : 1508760600, - "subtitled" : 1, - "channelUuid" : "e1b1de65605dc4e13bac6d4478e66a44", - "eventId" : 510178, - "nextEventId" : 510181, - "widescreen" : 1, - "stop" : 1508764500, - "subtitle" : "Tony Robinson and the Team descend on the bleak landscape of Bodmin Moor to examine a Bronze Age village and a vast, ancient 300m-long stone structure. [S]", - "channelNumber" : "14" - }, ... - ] -} -``` - -## epg/events/alternative -Lists alternative broadcasts of the same event. -- `eventId` Identifier of the event, eg taken from `epg/events/grid`. -The function appears to rely on the EPG provider giving details such as episode number. It does not work on UK DVB-T. - -This function does not work on TVH versions older than 4.2.4-5 or 4.3-589. -## epg/events/related -Lists alternative broadcasts of the same event. -- `eventId` Identifier of the event, eg taken from `epg/events/grid`. -The function appears to rely on the EPG provider giving details such as episode number. It does not work on UK DVB-T. - -This function does not work on TVH versions older than 4.2.4-5 or 4.3-589. -## epg/events/load -Lists details of specific event(s). -- `eventId` Identifier of the event, or a JSON array of event Ids. -``` -{ - "entries" : [ - { - "serieslinkId" : 261067, - "channelUuid" : "e61af00ea8b71683b9a1f41515fa83d3", - "title" : "Take Me Out", - "nextEventId" : 262992, - "widescreen" : 1, - "summary" : "Paddy McGuinness presents the dating show. The likely lads include a chocolate factory worker, a city slicker, an oil rig engineer and a gymnast. [S]", - "channelNumber" : "113", - "channelName" : "ITV2+1", - "serieslinkUri" : "crid://www.itv.com/ebs44033", - "genre" : [ - 48 - ], - "subtitle" : "Paddy McGuinness presents the dating show. The likely lads include a chocolate factory worker, a city slicker, an oil rig engineer and a gymnast. [S]", - "episodeId" : 262718, - "episodeUri" : "crid://www.itv.com/1616462450", - "eventId" : 262991, - "start" : 1515005400, - "stop" : 1515009600, - "subtitled" : 1 - } - ], - "totalCount" : 1 -} - -``` -## epg/brand/list -A 'Brand' is a commonly-available show, eg "Eastenders". What constitutes a 'Brand' is up to the EPG provider. -## epg/content_type/list -Lists the Content Type IDs extracted from ETSI EN 300 468 together with their descriptions. The Content Type ID appears in the output of `epg/grid` as "Genre". IDs described as 'Reserved' or 'User Defined' in the specification are given the description of the previous ID instead. -- `full` If set to 0 (the default) only the broad categories defined by `content_nibble_level_1` in the specification are listed. If set to 1 all categories are listed. - -``` -{ - "entries" : [ - { - "val" : "", - "key" : 0 - }, - { - "val" : "Movie / Drama", - "key" : 16 - }, - { - "key" : 17, - "val" : "Detective / Thriller" - }, ... - ] -} -``` diff --git a/epggrab.md b/epggrab.md deleted file mode 100644 index 4eb850d..0000000 --- a/epggrab.md +++ /dev/null @@ -1,31 +0,0 @@ -# epggrab - -## epggrab/channel/list -**Untested** Lists the EPG grabber channels, ie those appearing in Configuration -> Channel / EPG -> EPG Grabber Channels. -## epggrab/channel/class -Lists the parameters, descriptions, options and defaults for the GUI screen Configuration -> Channel/EPG -> EPG Grabber Channels. -## epggrab/channel/grid -**Untested** Gives details of the EPG grabber channels, ie from Configuration -> Channel / EPG -> EPG Grabber Channels. -## epggrab/module/list -List EPG Grabber Modules, as shown in the GUI screen Configuration -> Channel/EPG -> EPG Grabber Modules. -``` -{ - "entries" : [ - { - "uuid" : "13ba822c654b492183fbd462cd2700f6", - "title" : "External: XMLTV", - "status" : "epggrabmodNone" - }, ... - ] -} -``` -## epggrab/config/load -Lists the parameters, options, defaults and current settings for the EPG grabber, ie Configuration -> Channel / EPG -> EPG Grabber. -## epggrab/config/save -**Untested** Updates the EPG Grabber configuration from an object in the same format as provided by epggrab/config/load. -## epggrab/ota/trigger -Queues a run of the OTA EPG grabber. -- `trigger` Delay in seconds before the run starts. Minimum is one second, maximum is one week. -## epggrab/internal/rerun -Run the internal EPG grabbers immediately. -- `rerun` Not used but must be an integer greater than zero. diff --git a/esfilter.md b/esfilter.md deleted file mode 100644 index f6f6ec3..0000000 --- a/esfilter.md +++ /dev/null @@ -1,11 +0,0 @@ -# esfilter -Functions to report on and control Elementary Stream filters. - -There are separate API functions to operate on the different types of filter, but they all work in the same way. In the descriptions below the `XXX` in the function name can be replaced with `video`, `audio`, `teletext`, `subtit` (subtitle), `ca` or `other` as required. -## esfilter/XXX/class -Lists the descriptions, options and defaults for configuring the chosen type of filter, ie Configuration -> Stream -> Stream Filters -> {chosen type} -> Add. -## esfilter/XXX/grid -Returns the parameters of the defined filters of the chosen type. The usual selection options are available, see [Grid Parameters](Description.md#grid-parameters) -## esfilter/XXX/create -Creates a new filter of the chosen type. -- `conf` A JSON object describing the filter. diff --git a/idnode.md b/idnode.md deleted file mode 100644 index b134f1c..0000000 --- a/idnode.md +++ /dev/null @@ -1,15 +0,0 @@ -# idnode -These function provide direct access to the internal data structures of TVHeadend. Attempting to modify these internal structures may have unwanted effects including loss of data. -## idnode/load - -## idnode/save - -## idnode/tree - -## idnode/class - -## idnode/delete - -## idnode/moveup - -## idnode/movedown diff --git a/imagecache.md b/imagecache.md deleted file mode 100644 index 3d212f2..0000000 --- a/imagecache.md +++ /dev/null @@ -1,14 +0,0 @@ -# imagecache -Functions controlling the configuration of the Image Cache. - -These functions are only available if Image Cache support was included at compile time. -## imagecache/config/load -TODO -## imagecache/config/save -TODO -## imagecache/config/clean -Delete all files from the image cache and re-load, in the same way as Configuration -> General -> Image Cache -> Clean Image (icon) Cache in the GUI. -- `clean` Required parameter, must be 1 - the value is not used. -## imagecache/config/trigger -Trigger a re-load of the image cache, in the same way as Configuration -> General -> Image Cache -> Re-fetch Images in the GUI. -- `trigger` Required parameter, must be 1 - the value is not used. diff --git a/input.md b/input.md deleted file mode 100644 index c34c3ef..0000000 --- a/input.md +++ /dev/null @@ -1,7 +0,0 @@ -# input -List details of input devices. -## hardware/tree -??? -- `uuid` Unknown. -## hardware/satip/discover -Triggers a discovery process for SAT>IP servers. This function is only available if SAT>IP client functionality has been compiled into TVHeadend. diff --git a/intlconv.md b/intlconv.md deleted file mode 100644 index 9ddde6d..0000000 --- a/intlconv.md +++ /dev/null @@ -1,3 +0,0 @@ -# intlconv -## intlconv/charsets -Lists the available character sets. diff --git a/language.md b/language.md deleted file mode 100644 index 1f02587..0000000 --- a/language.md +++ /dev/null @@ -1,25 +0,0 @@ -# language -## language/list -Produces a list of all known languages (hard-coded within the TVH source) -``` -{ - "entries" : [ - { - "val" : "Undetermined", - "key" : "und" - }, - { - "key" : "aar", - "val" : "Afar" - }, - { - "val" : "Abkhazian", - "key" : "abk" - }, ... - ] -} -``` -## language/locale -Produces a similar list to language/list. -## language/ui_locale -Produces a list in the same format as the other functions but containing only those languages which are supported by TVHeadend. diff --git a/mpegts.md b/mpegts.md deleted file mode 100644 index 91e9478..0000000 --- a/mpegts.md +++ /dev/null @@ -1,153 +0,0 @@ -# mpegts - -## mpegts/input/network_list - -## mpegts/network/grid -Lists available networks. The standard parameters listed in [Grid Parameters](Description.md#grid-parameters) may be used. -``` -{ - "entries" : [ - { - "localtime" : 0, - "num_mux" : 9, - "wizard" : false, - "ignore_chnum" : false, - "num_svc" : 145, - "autodiscovery" : 2, - "skipinitscan" : false, - "bouquet" : false, - "sid_chnum" : false, - "scanq_length" : 0, - "networkname" : "Sandy", - "uuid" : "c70bb0e55db15cf44c72a8acb49d5ed7", - "charset" : "AUTO", - "pnetworkname" : "", - "num_chn" : 105, - "nid" : 0, - "idlescan" : false - } - ], - "total" : 1 -} -``` -## mpegts/network/class -Lists the text strings, options and defaults used when configuring the DVB capability within TVH (ie Configuration -> DVB Inputs -> Networks). It is only likely to be needed for recreating the existing TVH GUI. -## mpegts/network/builders -Lists the text strings, options and defaults used when configuring the DVB capability within TVH (ie Configuration -> DVB Inputs -> Network -> Add). It is only likely to be needed for recreating the existing TVH GUI. -## mpegts/network/create - -## mpegts/network/mux_class - -## mpegts/network/mux_create - -## mpegts/network/scan -Triggers a scan of the requested network(s). -- `uuid` uuid(s) of the network(s) to scan. More than one may be given; they will be scanned in sequence. -## mpegts/mux/grid -Lists available multiplexes. The standard parameters listed in [Grid Parameters](Description.md#grid-parameters) may be used. -- `hidemode` If set to `all`, only enabled multiplexes are listed. The default is to show all multiplexes. -``` -{ - "total" : 9, - "entries" : [ - { - "created" : 1508497835, - "delsys" : "DVB-T", - "scan_state" : 0, - "tsid" : 24640, - "scan_first" : 1508761027, - "name" : "690MHz", - "pnetwork_name" : "Cambs & Beds", - "transmission_mode" : "8k", - "sid_filter" : 0, - "network_uuid" : "c70bb0e55db15cf44c72a8acb49d5ed7", - "onid" : 9018, - "num_svc" : 35, - "eit_tsid_nocheck" : false, - "num_chn" : 29, - "hierarchy" : "NONE", - "tsid_zero" : false, - "pmt_06_ac3" : 0, - "network" : "Sandy", - "scan_last" : 1509267382, - "bandwidth" : "8MHz", - "fec_lo" : "NONE", - "frequency" : 690000000, - "constellation" : "QAM/64", - "fec_hi" : "3/4", - "epg" : 1, - "guard_interval" : "1/32", - "scan_result" : 1, - "enabled" : 1, - "uuid" : "0245c791efc3fa448c19db2f000d0d8f", - "plp_id" : -1 - }, ... - ] -} -``` -## mpegts/mux/class -Lists the text strings, options and defaults used when configuring the DVB capability within TVH (ie Configuration -> DVB Inputs -> Muxes). It is only likely to be needed for recreating the existing TVH GUI. -## mpegts/service/grid -Lists available mpegts services. The standard parameters listed in [Grid Parameters](Description.md#grid-parameters) may be used. -- `hidemode` The default is to show only services where the multiplex is enabled and the service has been verified. Setting this parameter to `all` also hides services which are not enabled, setting it to `none` shows all services. -``` -{ - "total" : 137, - "entries" : [ - { - "prefcapid_lock" : 0, - "s_type_user" : -1, - "prefcapid" : 0, - "lcn_minor" : 0, - "lcn2" : 0, - "uuid" : "c5206e5a69625ee60c1c3d23e56b6d22", - "lcn" : 698, - "auto" : 0, - "svcname" : "698", - "dvb_servicetype" : 1, - "created" : 1499259842, - "force_caid" : 0, - "enabled" : true, - "channel" : [], - "priority" : 0, - "pts_shift" : 0, - "last_seen" : 1509329042, - "multiplex_uuid" : "0245c791efc3fa448c19db2f000d0d8f", - "encrypted" : false, - "caid" : "", - "srcid" : 0, - "dvb_ignore_eit" : false, - "multiplex" : "690MHz", - "sid" : 28520, - "network" : "Sandy" - }, ... - ] -} -``` -`dvb_servicetype` can be used to determine what kind of service is being broadcast. The possibilities are: - -- Radio: 0x02 -- SD TV: 0x01, 0x16, 0x17, 0x18, 0x80, 0x96, 0xa8, 0xd3 -- HD TV: 0x11, 0x19 - 0x1e, 0x91, 0xa0, 0xa4, 0xa6 -- UHDTV: 0x1f -## mpegts/service/class -Lists the text strings, options and defaults used when configuring the DVB capability within TVH (ie Configuration -> DVB Inputs -> Services). It is only likely to be needed for recreating the existing TVH GUI. -## mpegts/mux_sched/class -Lists the text strings, options and defaults used when configuring the DVB capability within TVH (ie Configuration -> DVB Inputs -> Mux Schedulers). It is only likely to be needed for recreating the existing TVH GUI. -## mpegts/mux_sched/grid - -## mpegts/mux_sched/create - -## dvb/orbitalpos/list -Lists orbital positions and the satellites occupying them. The list is distributed with tvheadend; satellite reception is not necessary to use this API. -``` -{ - "entries" : [ - { - "key" : "177W", - "val" : "177W : NSS 9" - }, ... - ] -} -``` -## dvb/scanfile/list diff --git a/profile.md b/profile.md deleted file mode 100644 index af40d55..0000000 --- a/profile.md +++ /dev/null @@ -1,48 +0,0 @@ -# profile - -## profile/list -Lists the available stream profiles (visible in the GUI at Configuration -> Stream -> Stream Profiles) together with their uuids. -- `all` A user with ADMIN privilege can use this parameter to see details of every profile even if they do not have access to them. -- `htsp` If set to 1, list only HTSP profiles. Default is 0 (list all). -``` -{ - "entries" : [ - { - "val" : "webtv-h264-vorbis-mp4", - "key" : "1c1f404622fbe9e6133eec69b7c7da6e" - }, - { - "val" : "matroska", - "key" : "03663b00383b34a6ce2a621733388bf5" - }, - { - "val" : "webtv-h264-aac-mpegts", - "key" : "b90da9e0bc0633515b261714a966910d" - }, - { - "val" : "webtv-vp8-vorbis-webm", - "key" : "b171e3a1d2b576e61b8df418e13c5f4a" - }, - { - "key" : "8405e0911b97b795d4cd2cddc322dd7f", - "val" : "webtv-h264-aac-matroska" - }, - { - "key" : "b436b4d6bf606fc9954a1fd3dcebe6a8", - "val" : "audio" - }, - { - "val" : "pass", - "key" : "af143f0b83fd4e919e3fbf05c5561984" - } - ] -} -``` -## profile/class -Lists the options, defaults and descriptions of configuration parameters (Configuration -> Stream -> Stream Profiles in the GUI). -## profile/builders -TODO -## profile/create -Create a new stream profile. -- `class` -- `conf` A JSON object containing detaiols of the new profile. diff --git a/raw.md b/raw.md deleted file mode 100644 index f5d4463..0000000 --- a/raw.md +++ /dev/null @@ -1,23 +0,0 @@ -# raw -## classes -?? Returns a list of all data classes together with readable titles. -``` -{ - "linuxdvb_rotor_gotox" : "TV Adapters - SatConfig - GOTOX Rotor", - "dvb_mux" : "DVB multiplex", - "profile-libav-mpegts" : "MPEG-TS/av-lib", - "epggrab_mod" : "EPG Grabber", - "esfilter" : "Elementary stream filter", - "mpegts_network" : "DVB Inputs - Networks", - "caclient_capmt" : "CAPMT (Linux Network DVBAPI)", - "channeltag" : "Channel Tags", - "codec_profile_libopus" : "libopus", - "linuxdvb_frontend_isdb_t" : "TV Adapters - Linux ISDB-T Frontend", - ... -} -``` -## raw/export -- `class` -## raw/import -- `node` -- `uuid` diff --git a/satip.md b/satip.md deleted file mode 100644 index 0a3724c..0000000 --- a/satip.md +++ /dev/null @@ -1,4 +0,0 @@ -# satip -## satips/config/load - -## satips/config/save diff --git a/service.md b/service.md deleted file mode 100644 index 3949f4b..0000000 --- a/service.md +++ /dev/null @@ -1,117 +0,0 @@ -# service -## service/mapper/load - -## service/mapper/save - -## service/mapper/stop -Stops a running service mapper operation. -## service/mapper/status -Provides the same output as Status -> Service Mapper in the TVH GUI. -``` -{ - "ignore" : 0, - "ok" : 0, - "fail" : 0, - "total" : 0 -} -``` -## service/list -Lists available services. -- `enum` If set to 1 (as an integer without quotes) a short-form list is output containing each service's uuid and name. If set to 0 (the default) a verbose list is generated. -- `list` If `enum` is not 1 this parameter selects which items are to be output (details to follow). -## service/streams -Lists the streams comprising the service. -- `uuid` uuid of the service. This parameter is mandatory; it is not possible to list all services. -``` -{ - "streams" : [ - { - "pid" : 1101, - "type" : "PCR" - }, - { - "pid" : 1100, - "type" : "PMT" - }, - { - "aspect_num" : 0, - "index" : 1, - "pid" : 1101, - "type" : "MPEG2VIDEO", - "aspect_den" : 0, - "width" : 0, - "language" : "", - "height" : 0, - "duration" : 0 - }, - { - "audio_type" : 0, - "type" : "MPEG2AUDIO", - "audio_version" : 2, - "language" : "eng", - "index" : 2, - "pid" : 1102 - }, - { - "language" : "eng", - "audio_version" : 2, - "index" : 3, - "pid" : 1103, - "type" : "MPEG2AUDIO", - "audio_type" : 3 - }, - { - "index" : 4, - "language" : "eng", - "pid" : 1131, - "ancillary_id" : 2, - "type" : "DVBSUB", - "composition_id" : 2 - } - ], - "name" : "Sandy/498MHz/Channel 4", - "fstreams" : [ - { - "pid" : 1101, - "index" : 1, - "aspect_num" : 0, - "width" : 0, - "aspect_den" : 0, - "type" : "MPEG2VIDEO", - "height" : 0, - "language" : "", - "duration" : 0 - }, - { - "audio_type" : 0, - "type" : "MPEG2AUDIO", - "language" : "eng", - "audio_version" : 2, - "index" : 2, - "pid" : 1102 - }, - { - "type" : "MPEG2AUDIO", - "audio_type" : 3, - "pid" : 1103, - "audio_version" : 2, - "language" : "eng", - "index" : 3 - }, - { - "language" : "eng", - "pid" : 1131, - "index" : 4, - "ancillary_id" : 2, - "type" : "DVBSUB", - "composition_id" : 2 - } - ] -} -``` -## service/removeunseen -Remove services which have not been seen recently. This call carries out the same action as Configuration -> DVB Inputs -> Services -> Maintenance in the TVH GUI. -- `days` The number of unseen days before deletion. The default is 7 days, the minimum is 5 days. -- `type` If set to `pat` the action is the same as "Remove unseen services (PAT/SDT)" in the GUI. Otherwise the action is the same as "Remove all unseen services". - -An empty JSON object is always returned. diff --git a/status.md b/status.md deleted file mode 100644 index cc0b164..0000000 --- a/status.md +++ /dev/null @@ -1,95 +0,0 @@ -# status -Lists statistics of input sources and connections. -## status/connections -Lists currently-connected client devices. -``` -{ - "totalCount" : 1, - "entries" : [ - { - "id" : 1, - "started" : 1508668447, - "server_port" : 9982, - "server" : "x.x.x.x", - "type" : "HTSP", - "peer" : "x.x.x.y", - "user" : "xxxxxx", - "peer_port" : 57496 - } - ] -} -``` -## status/subscriptions -Lists currently-active subscriptions. -``` -{ - "entries" : [ - { - "errors" : 0, - "title" : "epggrab", - "in" : 85222, - "total_in" : 25162474, - "total_out" : 25162474, - "id" : 75, - "out" : 85222, - "service" : "Silicon Labs Si2168 : DVB-T #0/Sandy/690MHz/Raw PID Subscription", - "state" : "Running", - "start" : 1508763840 - } - ], - "totalCount" : 1 -} -``` -## status/inputs -Lists statistics of input devices. - -For DVB-T tuners at least, the signal and SNR values are only non-zero while TVH is actively using the device. -``` -{ - "totalCount" : 1, - "entries" : [ - { - "snr" : 0, - "input" : "Siano Mobile Digital MDTV Receiver #0 : DVB-T #0", - "snr_scale" : 0, - "tc_block" : 0, - "ec_block" : 0, - "signal" : 0, - "signal_scale" : 0, - "te" : 0, - "tc_bit" : 0, - "ber" : 0, - "cc" : 0, - "subs" : 0, - "weight" : 0, - "unc" : 0, - "bps" : 0, - "uuid" : "2700b3116072cf41e59b13bf77d29781", - "ec_bit" : 0 - } - ] -} -``` -The meaning of the statistics is below. Not all input sources provide all of the values. -``` -subs => Subscribers -weight => Weight -bps => Bandwidth (bits/second) -ber => Bit Error Rate -unc => Uncorrected Blocks -te => Transport Errors -cc => Continuity Errors -signal => Signal Strength (dBm) -snr => Signal/Noise Ratio (dB0 -stream => Stream -ec_block => Block Error Count -tc_bit => Total Bit Error Count -tc_block => Total Block Error Count -ec_bit => Bit Error Count -``` -## status/inputclrstats -Resets the input counters to zero. -- `uuid` The uuid of the input device from `status/inputs`. More than one uuid can be specified - syntax? -## connections/cancel -Disconnects one or more clients. -- `id` ids of the connections, obtained from status/connections. How are multiple connections specified?? diff --git a/timeshift.md b/timeshift.md deleted file mode 100644 index af9402e..0000000 --- a/timeshift.md +++ /dev/null @@ -1,4 +0,0 @@ -# timeshift -## timeshift/config/load - -## timeshift/config/save