DVBLink Remote API

DVBLink Remote API clients and tools

DVBLink Remote API

Postby Oberon » Wed Apr 11, 2012 1:33 pm

DVBLink Server provides DVBLink Remote API - an Application Programming Interface to build thin PVR clients.

The API is programming language independent and based on open http/xml standards. We at DVBLogic use this API to create all of our clients for different platforms.

DVBLink Remote API provides the following functionality:
- TV channel list retrieval
- EPG information retrieval
- Recording timers management (scheduling, overview and deleting)
- Live TV playback
- DVBLink Server parental control access
- Retrieval and management of TV recordings (aka playback objects)

The full DVBLink Remote API description is available here:
http://www.dvblogic.com/download/dvblink_remote_api.pdf.

Current version is 0.9.4.

If you have any questions regarding DVBLink Remote API usage, do no hesitate to post them in this forum thread.
Oberon
 
Posts: 11746
Joined: Thu Sep 06, 2007 5:04 am


Re: DVBLink Remote API

Postby neil_coggins » Fri Jul 27, 2012 10:11 am

Hi.

I'm having problems with the "search_epg" command on my system (Connect! Server 4.1.0). Getting the list of channels works flawlessly using the "get_channels" command, but my use of "search_epg" appears to ignore the list of channel_ids passed in. Here's an example of a request / response, indicating the problem:

REQUEST:
command=search_epg&xml_param=<?xml version='1.0' encoding='utf-8' ?><epg_searcher xmlns:i='http://www.w3.org/2001/XMLSchema-instance' xmlns='http://www.dvblogic.com'><channel_ids><channel_id>7881299347961893</channel_id></channel_ids><program_id></program_id><keywords></keywords><start_time>-1</start_time><end_time>1343407874</end_time><epg_short>true</epg_short></epg_searcher>

RESPONSE:
<?xml version="1.0" encoding="utf-8"?>
<epg_searcher xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.dvblogic.com">
<channel_epg>
<channel_id>7881299347958988</channel_id>
<dvblink_epg>
<program>
<program_id>5910974510988562</program_id>
<name>Deal or No Deal</name>
<start_time>1343379600</start_time>
<duration>3600</duration>
<is_series>true</is_series>
</program>
<program>
<program_id>5910974510988565</program_id>
<name>Four in a Bed</name>
<start_time>1343383200</start_time>
<duration>1800</duration>
<is_series>true</is_series>
</program>
</dvblink_epg>
</channel_epg>
<channel_epg>
<channel_id>7881299347961879</channel_id>
<dvblink_epg>
<program>
<program_id>5910974510989175</program_id>
<name>Jewellery Channel</name>
<start_time>1343365200</start_time>
<duration>21600</duration>
<is_series>true</is_series>
</program>
</dvblink_epg>
</channel_epg>

etc. As you can see, it is returning programs for channels other than the (single) channel requested... Can someone tell me what I've done wrong in my query?

TIA.

Neil.
Server: Windows 7 Ultimate X64, DigitalDevices Cine S2 V6, TBS 6981, DVBLink TVSource 4.5.1, DVBLink Connect! Server 4.5.1
neil_coggins
 
Posts: 9
Joined: Fri Jun 29, 2012 10:23 pm

Re: DVBLink Remote API

Postby Oberon » Fri Jul 27, 2012 10:26 am

Are you using built-in recorder or Mediacenter as a recorder?
Oberon
 
Posts: 11746
Joined: Thu Sep 06, 2007 5:04 am

Re: DVBLink Remote API

Postby neil_coggins » Fri Jul 27, 2012 11:20 am

Hi,
Media Center on Windows 7 x64.
Server: Windows 7 Ultimate X64, DigitalDevices Cine S2 V6, TBS 6981, DVBLink TVSource 4.5.1, DVBLink Connect! Server 4.5.1
neil_coggins
 
Posts: 9
Joined: Fri Jun 29, 2012 10:23 pm

Re: DVBLink Remote API

Postby zeroniak » Mon Jul 30, 2012 7:18 am

Hi,

I'm currently developing a "real" pvr addon for XBMC (Not to be confused with the XBMC add found on the forum, which is "only" a video addon) and thus using the api.

But I have found that I could use some more information currently not presented in the api, but guess it is available in DVBLink. Which I hope would be possible for you to add at some point :D

It would be nice if the get_channels function provided information about the kind of channel : RADIO / TV.

Besides the above I would like to thank you for making this great and fleksible product :D

Best regards,

Palle Ehmsen
zeroniak
 
Posts: 165
Joined: Tue Oct 25, 2011 7:56 pm

Re: DVBLink Remote API

Postby Oberon » Mon Jul 30, 2012 7:38 am

neil_coggins wrote:Hi,
Media Center on Windows 7 x64.

We will look at that and get back to you soon.
Oberon
 
Posts: 11746
Joined: Thu Sep 06, 2007 5:04 am

Re: DVBLink Remote API

Postby Oberon » Mon Jul 30, 2012 7:41 am

zeroniak wrote:Hi,

I'm currently developing a "real" pvr addon for XBMC (Not to be confused with the XBMC add found on the forum, which is "only" a video addon) and thus using the api.

But I have found that I could use some more information currently not presented in the api, but guess it is available in DVBLink. Which I hope would be possible for you to add at some point :D

It would be nice if the get_channels function provided information about the kind of channel : RADIO / TV.

Besides the above I would like to thank you for making this great and fleksible product :D

Best regards,

Palle Ehmsen

Hi and thanks for your interest in DVBLink development.
We will update Remote API description and python library coming days to include the recorded content management functionality.
Also we will put radio/tv on our todo list for the next release.
Oberon
 
Posts: 11746
Joined: Thu Sep 06, 2007 5:04 am

Re: DVBLink Remote API

Postby Oberon » Mon Jul 30, 2012 11:44 am

neil_coggins wrote:Hi,
Media Center on Windows 7 x64.

Here is how the string should look like:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<epg_searcher xmlns="http://www.dvblogic.com"><channels_ids xmlns="http://www.dvblogic.com"><channel_id>7881299348048738</channel_id></channels_ids><program_id/><keywords/><start_time>-1</start_time><end_time>-1</end_time></epg_searcher>

It uses channels_ids instead of channel_ids.
Oberon
 
Posts: 11746
Joined: Thu Sep 06, 2007 5:04 am

Re: DVBLink Remote API

Postby neil_coggins » Mon Jul 30, 2012 12:48 pm

Oberon wrote:
neil_coggins wrote:Hi,
Media Center on Windows 7 x64.

Here is how the string should look like:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<epg_searcher xmlns="http://www.dvblogic.com"><channels_ids xmlns="http://www.dvblogic.com"><channel_id>7881299348048738</channel_id></channels_ids><program_id/><keywords/><start_time>-1</start_time><end_time>-1</end_time></epg_searcher>

It uses channels_ids instead of channel_ids.


DOH! Many thanks and well spotted - works perfectly now!

Neil.
Server: Windows 7 Ultimate X64, DigitalDevices Cine S2 V6, TBS 6981, DVBLink TVSource 4.5.1, DVBLink Connect! Server 4.5.1
neil_coggins
 
Posts: 9
Joined: Fri Jun 29, 2012 10:23 pm

Re: DVBLink Remote API

Postby zeroniak » Thu Aug 02, 2012 4:36 pm

I have noticed that I have problems accessing the API using the local ip : 127.0.0.1. I get a lot of "Connection reset by peer" errors, where as I don't get any when using the local network ip (192.168.0.10).

Is there a know limitation in the connect server / api ?
zeroniak
 
Posts: 165
Joined: Tue Oct 25, 2011 7:56 pm

Re: DVBLink Remote API

Postby Oberon » Mon Sep 10, 2012 3:43 pm

DVBLink Remote API description v0.2 is available:
http://www.dvblogic.com/download/dvblink_remote_api.htm

Updated version includes
- Retrieval of playback objects (e.g. Recorded TV) and management (delete, stop recording)
- Channel type and child lock status to the channel properties
- Get schedules and update schedule functionality
- Get/set recording settings
- Streaming capabilities retrieval
- m3u retrieval for live TV streaming

Please note that DVBLink Connect! Server v 4.5.1 is required.
Oberon
 
Posts: 11746
Joined: Thu Sep 06, 2007 5:04 am

Re: DVBLink Remote API

Postby azebro » Wed Oct 31, 2012 11:06 pm

Hello,

I'm trying to retrieve the list of recordings using the remote API.
I invoke the get_recordings function, but can receive only active recordings. Is that correct?
Tried to access the get_object, but stuck on the DVBLInk Server container, as no children are retrieved.
Please help...

Thanks,
Adam
azebro
 
Posts: 16
Joined: Fri Sep 25, 2009 2:36 pm

Re: DVBLink Remote API

Postby azebro » Thu Nov 01, 2012 2:46 pm

Hi Oberon,

I've got a bit further but still stuck on the get_object, as the children object are not returned despite setting children_request to true i.e.:

Code: Select all
<?xml version="1.0" encoding="utf-8" ?>
- <object_requester xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://www.dvblogic.com">
  <object_type>-1</object_type>
  <item_type>-1</item_type>
  <start_position>0</start_position>
  <requested_count>-1</requested_count>
  <children_request>true</children_request>
  <server_address>192.168.0.192</server_address>
  </object_requester>


the reply is:

Code: Select all
  <?xml version="1.0" encoding="UTF-8" ?>
- <response xmlns="http://www.dvblogic.com">
  <status_code>0</status_code>
  <xml_result><?xml version="1.0" encoding="UTF-8"?> <object xmlns="http://www.dvblogic.com"><containers xmlns="http://www.dvblogic.com"><container xmlns="http://www.dvblogic.com"><object_id>fcc65d92-5dc5-49ee-bf64-7e19dffbff89:</object_id><parent_id/><name>Recorded TV</name><description>Your favorite recorded shows and programs</description><logo>http://192.168.0.192:8081/dvblink/playback?object=fcc65d92-5dc5-49ee-bf64-7e19dffbff89%3aDA5F661E-540E-47B1-9DCC-3F40F5CB85CA%2fB86A430E-A1D8-4f27-9015-F5CBF0B900F2</logo><source_id>8F94B459-EFC0-4D91-9B29-EC3D72E92677</source_id><container_type>0</container_type><content_type>-1</content_type><total_count>2</total_count></container></containers><items xmlns="http://www.dvblogic.com"/><actual_count>1</actual_count><total_count>1</total_count></object></xml_result>
  </response>


Could you please advise?

Thanks,

Adam
azebro
 
Posts: 16
Joined: Fri Sep 25, 2009 2:36 pm

Re: DVBLink Remote API

Postby Oberon » Thu Nov 01, 2012 2:56 pm

azebro wrote:Hello,

I'm trying to retrieve the list of recordings using the remote API.
I invoke the get_recordings function, but can receive only active recordings. Is that correct?
Tried to access the get_object, but stuck on the DVBLInk Server container, as no children are retrieved.
Please help...

Thanks,
Adam

The general process to obtain recordings list is the following:
- Ask server (root container) for the list of available sources (containers of the first level)
- Parse a response to find a container with <source_id>8F94B459-EFC0-4D91-9B29-EC3D72E92677</source_id> - this is fixed source id of dvblink recorder
- use the object id of the dvblink recorder to get its children - there will be two containers (by date and by name)
- use object id of one of the containers to get its children - recordings

In your particular example your request misses an important field - object_id for which you ask its children. By default it is a root request - that's why you always get the first level container(s).
Oberon
 
Posts: 11746
Joined: Thu Sep 06, 2007 5:04 am

Re: DVBLink Remote API

Postby azebro » Thu Nov 01, 2012 3:16 pm

Thanks Oberon,

It appeared that there was a serialization issue with the request, I can get the response now.
Could you please look at the post above re the children objects included in the reply?

Thanks,

Adam
azebro
 
Posts: 16
Joined: Fri Sep 25, 2009 2:36 pm

Next

Return to Development corner

Who is online

Users browsing this forum: No registered users and 1 guest