User Tools

Site Tools


api:iptv:device:list

API : IPTV : Device : List

Introduction

This will list all the devices a customer (with feature IPTVPRIVATE or IPTVBUSINESS) has.

A device can be a set top box (STB), a mobile or tablet app (IOS, ANDROID) or a web browser client (WEB).

Request

URL https://api.telecomx.dk/iptv/device
Method GET
Access level VIEWER, MANAGER or OWNER if customer has feature IPTVBUSINESS or IPTVPRIVATE
RESELLER if customer has IPTVPRIVATE or IPTVBUSINESS
ADMIN
Query offset [optional] Index of the first device to return, default 0.
limit [optional] The number of devices to return, default 100, min 1, max 500.
filter [optional] To filter the devices, this can be used. Mac, name, custom fields, ip addresses, serial number and notes is searched.
full [optional] If true, complete device objects will be returned instead of the condensed version.
customer [optional] Id of the customer to show devices for. Defaults to the users own customer.
type [optional] Type of devices to return:
STB - Set Top boxes
IOS - iPhones and iPads using the app
ANDROID - Android based phones and tablets using the app
WEB - Web browser clients
DRM - all type except STB
ANY - all types (default).
reseller [optional] If true, all devices belonging to the resellers customers will be returned. (RESELLER/ADMIN only).
admin [optional] If true, all devices belonging to any customer will be returned (ADMIN only).
tabletProfile [optional] Filters android tablets on tablet profile ID
heartbeatStatus [optional] Filters devices depending on last communication
showDevelopment  [optional] If true shows devices in development (RESELLERADMIN/ADMIN)
showDisabled [optional] If true also returns disabled devices
packageName [optional] if packageVersion is not set and packageName is set, list of versions and number of devices will be returned. See response further down<DevicesWithPackageName>
ONLY ON TYPE='ANDROID' AND CUSTOMER HAS FEATURE 'FLEXCARE'
packageVersion [optional] Returns devices that has given packageName with given packageVersion
ONLY ON TYPE='ANDROID' AND 'packageName' MUST BE SET AND CUSTOMER HAS FEATURE 'FLEXCARE'

Query examples

https://api.telecomx.dk/iptv/device
https://api.telecomx.dk/iptv/device?offset=25&limit=50&filter=living%20room&full=true&customer=12345678901234567890ABCD&type=STB
https://api.telecomx.dk/iptv/device?reseller=true

Response

JSON object
offset Index of the first device returned.
limit Number of devices to return. Note that the actual number of devices returned may be lower.
total Number of devices that can be returned when offset and limit is not considered. This is to be used for paging through the data.
devices Array of devices, see definition below.
<DevicesWithPackageName> List of versions and devices with said version
version String  Version defined on 'packageName'
devices Number Number of devices on said version
Device object (JSON)
_id Id Unique id of the device.
type String Type of device:
STB - Set Top Box
IOS - iPhone/iPad using the app
ANDROID - Android based mobile or tablet using the app
WEB - Web browser client
mac String MAC address of device (type STB only).
name String Name of device, e.g. 'Living room' or 'Johns iPhone'.
enabled Boolean True if the device is enabled, false if blocked.
streamOnly Boolean If true, only base channel streams will be served to the STB. DVB and local streams are ignored (type STB only).
developmentMode Boolean True if development mode is enabled for this device.
tabletProfile Id ID of the tablet profile this device uses (Android tablet only)
tabletProfileName String Name of the tablet profile this device uses (Android tablet only)
appsMissing Array List of package ids that should but is not installed on device
appsMissing[] String Package id of application that is missing
appVersionMismatches Array List of package ids where installed version is wrong
appVersionMismatches[] String Package id of application with wrong version
applications Object List of applications that device report to TelecomX
applications._id String Package id of application
applications.name String Name of application
applications.versionCode Number Build version of installed version of application
applications.versionName String Application version
packages Number Number of subscription packages this device has access to (only if reseller!=true).
packages Array List of subscription packages the device has access to (only if reseller=true).
packages[]._id Id Id of the subscription package (only if reseller=true).
packages[].start Date Date and time the package will begin (only if reseller=true).
packages[].end Date Date and time the package expires, null if no expiration (only if reseller=true).
channels Number Number of channels this device has access to.
groups Array List of groups the device belongs to.
groups[]._id Id Id of the group.
groups[].name String Name of the group.
info Object Current readonly data about the device.
info.lastComm Date Date and time of latest communication with the device.
info.lastUiComm Date Date and time of latest STB events request from the device STB
info.lastHbComm Date Date and time of latest request from the device's heartbeat. STB
info.uptime Number Uptime in seconds, 0 if down.
info.vpnUptime Number Uptime in seconds for the vpn tunnel, 0 if down.
info.model String The model of the device, e.g. 'MAG250' or 'iPhone 6S'.
info.channel Id Channel the device is currently showing, Null if none.
info.playback Id EPG id of the program currently being shown on the device from the archive or from a recording. Null if none.
info.offline Boolean True if the device is offline (no communication the last 70 seconds).
info.lanMac String MAC of the LAN network card. (Android tablet only)
info.wifiMac String Mac of the WIFI network card. (Android tablet only)
info.proMic Boolean True if device has got proMic hardware
applications Object Contains info about installed application on Android Tablet
applications.<PACKAGE_NAME>  Object Tablet application object (see definition below)
appVersionMismatches Array<string>  Contains apps that are installed on device but has wrong version
appsMissing  Array<string>  Contains apps that should be installed on device but is missing
Tablet application object
name  String  Name of application
versionCode  Number  Build number of application
versionName  String Version of application ex. “2.0.4”
installed  Boolean  Whether application is installed or not on device
Device object if full=true (JSON)
_id Id Unique id of the device.
type String Type of device:
STB - Set Top Box
IOS - iPhone/iPad using the app
ANDROID - Android based mobile or tablet using the app
WEB - Web browser client
mac String MAC address of device (type STB only).
name String Name of device, e.g. 'Living room' or 'Johns iPhone'.
enabled Boolean True if the device is enabled, false if blocked.
streamOnly Boolean If true, only base channel streams will be served to the STB. DVB and local streams are ignored (type STB only).
developmentMode Boolean True if development mode is enabled for this device.
tabletProfile Id ID of the tablet profile this device uses (Android tablet only)
tabletProfileName String Name of the tablet profile this device uses (Android tablet only)
packages Array List of subscription packages the device has access to. Only if customer has feature IPTVBUSINESS or reseller=true.
For IPTVPRIVATE customer see Subscriptions.
packages[]._id Id Id of the subscription package.
packages[].start Date Date and time the package will begin.
packages[].end Date Date and time the package expires, null if no expiration.
customFields Array List of custom fields values (if used), otherwise null.
customFields[]._id Id Id of the custom field.
customFields[].value String Value of the custom field.
groups Array List of id's of groups the device belongs to.
notes String Notes about the device.
custom Object Custom data, max 4096 bytes.
info Object Current readonly data about the device.
info.created Date Date the device was added to the system.
info.lastComm Date Date and time of latest communication with the device.
info.uptime Number Uptime in seconds, 0 if down.
info.vpnUptime Number Uptime in seconds for the vpn tunnel, 0 if down.
info.net.public String Public IP address the STB is originating from.
info.net.ip String IP address of the STB.
info.net.gateway String Default gateway.
info.net.dns String DNS server(s).
info.model String The model of the device, e.g. 'MAG250' or 'iPhone 6S'.
info.serial String Serial number of the device (type STB only).
info.appVersion String App version as reported by device (not STB).
info.bandwidth Number Current bandwidth usage (type STB only).
info.wifi Boolean True if device is using wifi (type STB only).
info.lan Boolean True if device is using a lan connection (type STB only).
info.channel Id Channel the device is currently showing, Null if none.
info.channelSource String How is the channel served: BASE, DVB or LOCAL.
info.lastchannel Id Last viewed channel on the device.
info.playback Id EPG id of the program currently being shown on the device from the archive or from a recording. Null if none.
info.playbackType String If in playback, then this is the type of media being played: RECORDING or ARCHIVE.
info.channelName String Name of the channel currently showing (live) or program was shown on (playback) or null if none.
info.epgTitle String Name of the program.
info.epgSubTitle String Subtitle of the program.
info.endStart Date Start date/time of the program.
info.epgEnd Date End date/time of the program.
info.epgBaseChannel Number Base channel id of the channel the program is/was on.
info.firmware.name String Name of the current firmware (type STB only).
info.firmware.version String Firmware version (type STB only).
info.firmware.date String Firmware date (type STB only).
info.portalVersion String Portal version number (type STB only).
info.apiVersion String UI API engine version (type STB only).
info.videoOut String Video output mode: HDMI or RCA.
info.videoMode String Video resolution and mode: 480, 576, 720p, 720i, 1080p, 1080i.
info.language String Language for the UI (type STB only).
info.timezone String Timezone for the UI (type STB only).
info.playing Boolean True if currently playing anything (only if type is STB).
info.paused Boolean True if currently paused (only if type is STB).
info.position Number Position in seconds in the media currently playing, live is seconds since midnight (only if type is STB).
info.place String Which section of the STB is currently active, ex. tv, timeshift, radio, epg.simple, epg, vclub, vclub2, settings, main_menu.
info.videoBitrate Number Bitrate of the video currently showing.
info.videoFramerate Number Framerate of the video currently showing.
info.videoWidth Number Width of the video currently showing.
info.videoHeight Number Height of the video currently showing.
info.videoURL String URL of video currently showing (only if type is STB) (ADMIN only).
info.tunnelServer String The tunnel server the device is connected to (only if type is STB) (ADMIN only).
info.offline Boolean True if the device is offline (no communication the last 70 seconds).
info.hdmiState String State of HDMI port: OFF, STANDBY, ON (STB only)
info.commonRoom. Boolean True if the device is placed in a common room (i.e. a waiting room), false if not.
info.proMic Boolean True if device has got proMic hardware
stbRequests Array List of requests waiting for the device to be retrieved and executed (type STB only).
stbRequests[].action String Type of action to perform:
DVB - update DVB configuration and reboot if needed.
CHANNELS - reload the channels list
UI - reload the user interface
SCREENSHOT - take a screenshot
SPEEDTEST - check Internet connection speed
MANAGEMENT - enable debug port for remote service.
REBOOT - reboot the STB.
SCRIPT - download and execute script specified in data
MESSAGE - show the message specified in data.
VIDEO - show the message & video specified in data.
PLAYCHANNEL - show the channel specified in data.
SWITCH_OFF - turn the STB off.
BLOCK - Block the STB.
UBLOCK - Unblock the STB.
JS - run code in the UI.
FIRMWARE - Upgrade firmware.
PLAYRADIOCHANNEL - play a radio channel.
UIDEBUG - enable UI debugger.
VOLUME - set current volume.
EMULATEKEYS - emulate remote control keypresses.
stbRequests[].data String Additional settings for the request, if any.
stbRequests[].date Date Date when request was queued.
stbRequests[].when Date Date/time when request shall be sent to the STB. null if not used = as soon as possible.
stbRequests[].id Id Id of the request.
screenshot Id Id of latest screenshot taken. Null if none (type STB only).
speedtest.date Date Date the speedtest was performed (type STB only).
speedtest.down Number Speedtest downstream average speed (type STB only).
speedtest.up Number Speedtest upstream average speed (type STB only).
favorites Array List of id's of TV channels that are on the favorites list.
listMode String How to list TV channels:
FAV - only those marked as favorite.
NUMBER - By channel number.
ALPHA - By channel name.
volume Number Current volume of device, 0-100% (type STB only).
audioMode Number STB audio mode (type STB only):
0 - Analog only
1 - Analog and SPDIF
2 - Analog and SPDIF with AC3 support
modules Object STB UI modules to enable. (type STB only).
modules.inherit Boolean True to inherit modules settings, false for individual settings.
modules.tv Boolean TV module.
modules.media_browser Boolean Media browser module.
modules.vclub Boolean Archive module.
modules.vclub2 Boolean Recording module.
modules.audioclub Boolean Audio club module.
modules.radio Boolean Radio module.
modules.settings Boolean Settings module.
modules.settingsEx Boolean Sensitive settings module.
modules.internet Boolean Internet browser module.
showAfterLoading String What to show after boot: last_channel or main_menu (type STB only).
playInPreviewByOk Number 1 to play channel in preview, 0 to play channel fullscreen when OK is pressed (type STB only).
theme String Always 'default' (type STB only).
primaryAudioLanguage String Primary audio language: dan, eng, nor, swe, fin (type STB only).
secondaryAudioLanguage String Secondary audio language: dan, eng, nor, swe, fin (type STB only).
primarySubtitleLanguage String Primary subtitle language: dan, eng, nor, swe, fin or blank for none (type STB only).
secondarySubtitleLanguage String secondary subtitle language: dan, eng, nor, swe, fin or blank for none (type STB only).
hdmiReaction Number Automatic standby after this number of seconds, 0 = off (type STB only).
screensaverDelay Number Activate screensaver of this number of seconds of no video playing, 0 = off (type STB only).
playbackBufferBytes Number Playback buffer in bytes, 0 = default (type STB only).
playbackBufferSize Number Playback buffer size, 0 = default (type STB only).
country String Country for language of user interface: DK, EN (type STB only).
sleepTimer Number Amount of minutes before the device goes to sleep. Min value is 0, max is 480.
appRequests Array List of requests waiting for the device to be retrieved and executed. Used by Android tablets only.
appRequests[].action String Type of action to perform:
UI - reload the user interface
REBOOT - reboot the tablet.
MESSAGE - show the message specified in data.
VIDEO - show the message & video specified in data.
*START_APP* - starts the app with the package name specified in app
*UPDATE_APP* - updates the app with the package name specified in app
*UNLOCK* - unlocks the tablet
appRequests[].data String Additional settings for the request, if any.
appRequests[].date Date Date when request was queued.
appRequests[].when Date Date/time when request shall be sent to the tablet. null if not used = as soon as possible.
appRequests[].id Id Id of the request.

Note that properties holding no value may be omitted from the object.

Example - normal

{
  offset: 10,
  limit: 10,
  total: 23,
  devices:
  [
    {
      _id: '1234567890124567890ABCD',
      type: 'STB',
      mac: '00:01:79:12:34:56',
      name: 'Living room',
      enabled: true,
      streamOnly: false,
      developmentMode: false,
      packages: 3,
      channels: 35,
      groups: [
        { _id: '12345678901234567890AAAA', name: 'Building A' },
        { _id: '12345678901234567890BBBB', name: 'VIP customers' }
      ],
      info: {
        lastComm: '2016-02-03T12:34:56.000Z',
        lastUiComm: '2016-02-03T12:34:56.000Z',
        lastHbComm: '2016-02-03T12:34:56.000Z',
        uptime: 45564,
        vpnUptime: 45403,
        model: 'MAG250',
        channel: '12345678901234567890FFFF',
        playback: null,
        offline: false
      }
    },
    {
      ...
    }
  ]
}

Example - full=true

{
  _id: '12345678901234567890ABCD',
  type: 'STB',
  mac: '00:01:79:12:34:56',
  name: 'Living room',
  enabled: true,
  streamOnly: false,
  developmentMode: false,
  packages: [
    {
      _id: '1234567890123457890CCCC',
      start: '2016-01-01T00:00:00.000Z',
      end: '2016-01-01T00:00:00.000Z'
    },
    {
      id: ObjectId('12345678901234567890DDDD')
    }
  ],
  customFields: [
    { _id: 12345678901234567890FFF0', value: 'Standard' }
  ],
  groups: [
    { _id: '12345678901234567890EEE0', name: 'Building A' }
  ],
  notes: 'STB is placed behind the TV with a remote extender',
  custom: null,
  info: {
    created: '2016-01-01T00:00:00.000Z',
    lastComm: 2016-02-03T12:34:56.000Z',
    uptime: 563665,
    vpnUptime: 563602,
    net: {
      public: '213.83.189.234',
      ip: '192.168.0.10',
      gateway: '192.168.0.1',
      dns: '192.168.0.1'
    },
    model: 'MAG275',
    serial: '5635473547256433355',
    bandwidth: 5123,
    wifi: false,
    lan: true,
    channel: null,
    lastChannel: '1234567890124567890FEDC',
    playback: '7_149485867',
    playbackType: 'RECORDING',
    channelName: 'TV2',
    epgBaseChannelId: 7,
    epgTitle: 'Nyhederne',
    epgSubTitle: 'De seneste nyheder fra ind og udland',
    epgStart: '2017-01-01T00:00:00Z',
    epgEnd: '2017-01-01T00:30:00Z',
    firmware: {
      name: 'Playmaker_1.0',
      version: '1.0a',
      date: '2017-01-01 12:23:00'
    },
    portalVersion: '1.0',
    apiVersion: '4.2.3',
    videoOut: 'HDMI',
    videoMode: '1080p',
    language: 'da',
    timezone: 'Europe/Copenhagen',
    offline: false,
    commonRoom: false
  },
  stbRequests: [
    { action: 'DVB', date: '2016-01-01T00:00:00.000Z', when: null, id: '12345678901234567890DDDD' },
    { action: 'REBOOT', date: '2016-01-01T00:00:00.000Z', when: '2019-01-01T00:00:00.000Z', id: '12345678901234567890DDDE' }
  ],
  screenshot: '12345678901234567890BBBB',
  speedtest: { date: '2016-01-01T12:34:56.000Z', down: 8192, up: 512 },
  favorites: [
    '12345678901234567890AABB',
    '12345678901234567890AABD'
  ],
  listMode: 'NUMBER',
  volume: 80,
  audioMode: 1,
  modules: {
    tv: true,
    media_browser: false,
    vclub: true,
    vclub2: true,
    audioclub: false,
    radio: true,
    settings: true,
    settingsEx: false,
    internet: true
  }
}

Errors

Error code Message Description
403 access_denied Insufficient access level
404 not_found Customer does not have IPTV
500 internal_error <Unspecified>
api/iptv/device/list.txt · Last modified: 2024/11/20 09:02 by Mikkel Frederiksen

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki