api:iptv:epg:list
Table of Contents
API : IPTV : EPG : List
Introduction
This request will return the Electronic Program Guide for one or more TV channels.
The guide can be returned in both JSON and XMLTV format.
Request
| URL | https://api.telecomx.dk/iptv/epg | |
|---|---|---|
| Method | GET | |
| Access level | VIEWER, MANAGER, OWNER, RESELLER or ADMIN | |
| Query | start | [optional] Date from which to return EPG data, defaults to today. |
| end | [optional] Date until which to return EPG data, defaults to end of today. Max span is 7 days. |
|
| channel | [optional] Id of the TV channel to return EPG for. Multiple channels can be specified by including the parameter multiple times. |
|
| format | [optional] Response format: JSON (default) or XMLTV. If XMLTV and no other properties are specified, full listing for all channels for the next 7 days is returned. |
|
| full | [optional] True to return full EPG data for programs instead of the condensed version. |
|
| filter | [optional] Search criteria - searches title and sub-title. |
|
| genre | [optional] One or more genres to limit the response to. |
|
| credits | [optional] Name of a person that is credited in the programs returned. |
|
Query examples
https://api.telecomx.dk/iptv/epg https://api.telecomx.dk/iptv/epg?start=2016-01-01&channel=7&format=XMLTV&full=true https://api.telecomx.dk/iptv/epg?format=XMLTV
Response (format=JSON)
Array of JSON objects, one item pr. channel listed.
| JSON object | ||
|---|---|---|
| channel | Number | Id of TV channel. |
| name | String | Name of TV channel. |
| logo | String | URL to logo for TV channel. |
| epg | Array | List of programs within the selected time period. |
| epg[]._id | String | Unique ID of the program. |
| epg[].programId | String | Unique program ID |
| epg[].eventId | String | ID of listing from the TV provider (if available) |
| epg[].eventContentId | String | ID of episode/program from the TV provider (if available) |
| epg[].start | Date | Date and time the program starts. |
| epg[].end | Date | Date and time the program ends. |
| epg[].duration | Number | Length of the program in minutes. |
| epg[].title | String | Title of the program. |
| epg[].subTitle | String | Teaser/sub title - short description or episode title for a series episode. |
| epg[].description | String | Long description for the program. |
| epg[].genres | Array | List of genres. |
| epg[].series | Object | Episode data - only available for series. |
| epg[].series.episode | Number | Episode number in the season, if available. |
| epg[].series.episodesInSeason | Number | Number of episodes in the season, if available. |
| epg[].series.season | Number | Season number, if available. |
| epg[].series.id | String | Unique id of the series, if available. |
| epg[].date | Date | Date program/movie/series was released/first shown, if available. |
| epg[].country | string | Country of origin (ISO3166-2 country code). If multiple countries, comma separated string, if available. |
| epg[].credits | Array | List of credited persons for this program. |
| epg[].credits[].type | String | What the person is credited for: ACTOR, DIRECTOR, PRODUCER etc. |
| epg[].credits[].role | String | Name of the role played, if type is ACTOR. |
| epg[].credits[].name | String | Name of person. |
| epg[].images | Array | List of poster images available for the program. |
| epg[].images[].type | String | Image version data, usually WIDTHxHEIGHT. |
| epg[].images[].url | String | URL to retrieve the image. |
| epg[].imageIds | Array | List if id's of images. |
| epg[].restrictions | Array | |
| epg[].restrictions[].nPvr | Boolean | true if nPvr Restricted |
| epg[].restrictions[].archive | Boolean | true if archive is restricted |
| epg[].restrictions[].startOver | Boolean | true if start over is restricted |
Note that properties holding no value may be omitted.
To fetch the images from the imageIds array, use this format:
https://image.powernet.tv/<IMAGE_ID>.<jpg|png|gif|tiff|webp>?property=value...
Jpg format is recommended. A number of optional properties may also be applied to alter the returned image:
| property | Description | Example |
|---|---|---|
| width | Resize image to the given width | width=320 |
| height | Resize image to the given height | height=240 |
| fit | When resizing, how to fit the image: cover: Scale image to cover requested width/height contain: Scale image to be contained within the requested width/height fill: Stretch image to fill width/height inside: Scale image to stay within requested width/height and adjust width/height to image outside: Scale image to minimum width/height and adjust width or height to image | fit=cover (default) |
| gravity | When fit is cover or contain, where is the important part of the image: north, northeast, east, southeast, south, southwest, west, northwest, center | gravity=center (default) |
| crop | Crop image to LxT-WxH | crop=10×10-320×240 |
| quality | Image quality when output is jpeg: 1-100 | quality=80 (default) |
| colors | Image max color when output is png: 1-256-16mill | colors=16 |
Example (format=JSON, full=false)
[ channel: 7, name: 'TV2 (Lorry)', logo: 'https://static.telecomx.dk/channellogos/7.png', epg: [ { _id: '7_1482855900', programId: ''1234567890ABCD1234567890, eventId: '129365718_xx', start: '2016-12-27T16:25:00Z', end: '2016-12-27T16:55:00Z', duration: 30, title: 'Grand Danois', }, { ... } ] ]
Example (format=JSON, full=true)
[ channel: 7, name: 'TV2 (Lorry)', logo: 'https://static.telecomx.dk/channellogos/7.png', epg: [ { _id: '7_1482855900', channelId: 7, start: '2016-12-27T16:25:00Z', end: '2016-12-27T16:55:00Z', duration: 30, title: 'Grand Danois', description: 'Satire. Se eller gense Niels Hausgaard og Anders Grau, når de sammen med en række danske komikere og skuespillere behandler otte emner i dette satiriske sketchshow. Det er alt lige fra danskhed til lov og orden, der kommer under kærlig behandling.', genres: [ 'Komedie' ], series: { episode: 6, season: 2, id: '232174273' }, credits: [ { type: 'ACTOR', name: 'Mick Øgendahl' }, { type: 'ACTOR', name: 'Lars Hjortshøj' }, { type: 'PRODUCER', name: 'Rune Klan' } ], images : [ { type: '95x54', width: 95, height: 54, url: 'https://img.powernet.tv/95x54/30/1490/821800.jpg' }, { type: '177x100', width: 177, height: 100, url: 'https://img.powernet.tv/177x100/30/1490/821800.jpg' }, { type: '250x140', width: 250, height: 140, url: 'https://img.powernet.tv/250x140/30/1490/821800.jpg' }, { type: '270x152', width: 270, height: 152, url: 'https://img.powernet.tv/270x152/30/1490/821800.jpg' }, { type: '360x203', width: 360, height: 203, url: 'https://img.powernet.tv/360x203/30/1490/821800.jpg' }, { type: '400x225', width: 400, height: 225, url: 'https://img.powernet.tv/400x225/30/1490/821800.jpg' }, { type: '460x260', width: 460, height: 260, url: 'https://img.powernet.tv/460x260/30/1490/821800.jpg' }, { type: '750x420', width: 750, height: 420, url: 'https://img.powernet.tv/750x420/30/1490/821800.jpg' }, { type: '900x506', width: 900, height: 506, url: 'https://img.powernet.tv/900x506/30/1490/821800.jpg' }, { type: '1777x1000', width: 1777, height: 1000, url: 'https://img.powernet.tv/1777x1000/30/1490/821800.jpg' } ], imageIds: ['123457890123457890EEEE','123457890123457890FFFF'] }, { ... } ] ]
Example (format=XMLTV, full=false)
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE tv PUBLIC "SYSTEM" "xmltv.dtd"> <tv generator-info-name="TelecomX" source-info-url="https://www.telecomx.dk" source-info-name="TelecomX"> <channel id="7"> <display-name lang="da">TV2 Lorry</display-name> <icon src="https://admin.telecomx.dk/img/tvchannels/7.png"/> </channel> <programme start="20161228013000 +0100" stop="20161228032500 +0100" channel="7"> <title lang="da"><![CDATA[ Dark Tide ]]></title> </programme> .... </tv>
Example (format=XMLTV, full=true)
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE tv PUBLIC "SYSTEM" "xmltv.dtd"> <tv generator-info-name="TelecomX" source-info-url="https://www.telecomx.dk" source-info-name="TelecomX"> <channel id="7"> <display-name lang="da">TV2 Lorry</display-name> <icon src="https://admin.telecomx.dk/img/tvchannels/7.png"/> </channel> <programme start="20161228013000 +0100" stop="20161228032500 +0100" channel="7"> <title lang="da"><![CDATA[ Dark Tide ]]></title> <desc lang="da"><![CDATA[Thriller. Kate er dykkerinstruktør, men har holdt sig væk fra dybt vand i næsten ti år efter et møde med en hvidhaj, hvor hun kun lige slap med livet i behold. Da hun bliver tilbudt en stor sum penge for at vende tilbage til havet, bestemmer hun sig for at takke ja. Snart viser det sig imidlertid, at hendes værste mareridt er i færd med at blive til virkelighed.]]></desc> <credits> <actor role="Kate Mathieson"><![CDATA[ Halle Berry ]]></actor> <actor role="Jeff Mathieson"><![CDATA[ Olivier Martinez ]]></actor> <actor role="Tommy Phillips"><![CDATA[ Mark Elderkin ]]></actor> <actor role="Zukie"><![CDATA[ Thoko Ntshinga ]]></actor> <actor role="Brady Ross"><![CDATA[ Ralph Brown ]]></actor> <actor role="Nate Hadley"><![CDATA[ Luke Tyler ]]></actor> <actor role="Walter"><![CDATA[ Sizwe Msutu ]]></actor> <director><![CDATA[ John Stockwell ]]></director> </credits> <category lang="da">Film</category> <category lang="da">Spændingsfilm</category> </programme> .... </tv>
Errors
| Error code | Message | Description |
|---|---|---|
| 403 | access_denied | Insufficient access level |
| 500 | internal_error | <Unspecified> |
api/iptv/epg/list.txt · Last modified: 2023/03/27 10:48 by Joakim Andersen