Roku Direct Publisher

Roku Direct Publisher - the easiest way to create a great TV experience. Learn more about how to create a Roku channel and share your experiences with others.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
atc98092
Community Streaming Expert

Can I use Direct Publisher to connect to an internal server

I want to attempt to build a channel to connect to a Serviio DLNA server. While the Roku Media Player works fine via DLNA, Serviio also offers an API for direct connection. I was thinking something along the lines of a Plex or Emby channel, only Serviio is the media source. I tried walking through the DP setup page, but it seems to want to connect to something that is available on the Internet, rather than a server on my internal network. While it would be possible to make this channel work across the Internet, I want to start with the internal connection first.
.
I've been over the Brightscript documentation, and other docs on the Roku developers site, but can't seem to find where to start. I don't know if Direct Publisher supports what I'm looking for, or if I need to program directly with Brightscript, using Eclipse as the IDE. 
.
I have some programming background, but not with this specific language. Can someone help me out with a starting point? The Serviio API is described as follows: Serviio API

Serviio REST interface is powered by Restlet. It exposes server functionality to the clients via a combination of HTTP and XML or JSON protocols.

Serviio CDS API supports both, XML and JSON languages for the REST protocol via content negotiation mechanism. XML is the default format but the client should still specify Accept HTTP header with value application/xml. JSON format will be used with the header's value of application/json. The same values should be used for Content-Type HTTP header when submitting data in the request body (POST and PUT methods).
Dan

Roku Community Streaming Expert

Help others find this answer and click "Accept as Solution."
If you appreciate my answer, maybe give me a Kudo.

I am not a Roku employee, just another user.
0 Kudos
4 REPLIES 4
tim1607
Visitor

Re: Can I use Direct Publisher to connect to an internal server

I'm no expert, but a JSON or XML has to be generated for Direct Publisher to work no matter what your server is. I'm not familiar with "Serviio DLNA server" but DP only works with JSON and XML files. As long as the server can serve up HTTP protocol you should be good.
What is generating the XML files for your channel?  What does that look like?  If this is just being hosted locally then it should work but the json still has to be there.

I know that's not very helpful, but can you give some additional information about the links that are being provided?  The API is probably not going to be an option for a DP channel. I still haven't figured out Brightscript or the SDK enough to help with getting that up and going.  (If there are anybody who can provide some insight on that it would be AWESOME.)
0 Kudos
atc98092
Community Streaming Expert

Re: Can I use Direct Publisher to connect to an internal server

"tim1607" wrote:
I'm no expert, but a JSON or XML has to be generated for Direct Publisher to work no matter what your server is. I'm not familiar with "Serviio DLNA server" but DP only works with JSON and XML files. As long as the server can serve up HTTP protocol you should be good.
What is generating the XML files for your channel?  What does that look like?  If this is just being hosted locally then it should work but the json still has to be there.

I know that's not very helpful, but can you give some additional information about the links that are being provided?  The API is probably not going to be an option for a DP channel. I still haven't figured out Brightscript or the SDK enough to help with getting that up and going.  (If there are anybody who can provide some insight on that it would be AWESOME.)

Appreciate the reply. From the Serviio API documentation page, it does support an HTTP via JSON or XML. This is the result of the application.xml file from the server:
<application>
[color=#000000][size=100][font=monospace]<version>1.10.1</version>
<edition>PRO</edition>
<license>
<id>license data removed</id>
<type>NORMAL</type>

</license>
<databaseUpdateId>1342370f144244a9b2e8306872265deb</databaseUpdateId>
<cdsAnonymousEnabled>false</cdsAnonymousEnabled>
<serviioId>KwzJibMYKq</serviioId>
[/font][/size][/color]
</application>

The API is server based, so it isn't something the player has to have installed. The API is what generates the XML files. Like I said, I'm a complete newbie when it comes to Brightscript and Roku programming. If I could understand how to make that initial connection (and probably have to build a connection screen for user input for server URL and password), I should be well on the way to get the basic functionality.
Thanks!
Dan

Roku Community Streaming Expert

Help others find this answer and click "Accept as Solution."
If you appreciate my answer, maybe give me a Kudo.

I am not a Roku employee, just another user.
0 Kudos
tim1607
Visitor

Re: Can I use Direct Publisher to connect to an internal server

That's kind of what I was expecting to see.
With DP, I don't believe that will work.
Check out the DP specifications at this webpage
The JSON snippet from my channel that does work with DP looks like:
{
  "providerName": "This can be pretty much anything.",
  "language": "en-US",
  "lastUpdated": "2018-07-27T23:46:13+00:00",
  "shortFormVideos": [
    {
      "id": "1001",
      "title": "Name of videos",
      "shortDescription": "This would be a short description of the video that you want folks to know. ",
      "thumbnail": "http://domainname.com/path_to_thumbnail_image.jpg",     
'If you have an internal address this can also be an IP address.'
      "genres": [
        "comedy"  
'this has to be from the list of genres that roku supports'
      ],
      "tags": [
        "the60s"  
'this is how to identify specific playlists or ways that you want videos to play back'
      ],
      "releaseDate": "1960-07-24",
      "content": {
        "dateAdded": "2018-07-21T14:14:54.431Z",
        "captions": [],
        "duration": 105,  
'this is in seconds'
        "adBreaks": [
          "00:00:00"
        ],
        "videos": [
          {
            "url": "http://ip_address_or_domain_name.com/path_to_video.mp4",
            "quality": "HD",
            "videoType": "MP4"
          }
        ]
      }
    },
  ],
  "categories": [
    {
      "name": "Featured",
      "query": "featured",
      "order": "most_popular"
    },
    {
      "name": "Play them all",
      "query": "pre50 OR the50s OR the60s OR the70s OR pre2000 OR post2000",
      "order": "most_popular"
    },
    {
      "name": "1960 to 1969",
      "query": "the60s",
      "order": "chronological"
    },
  ]
}

That format, at least for a JSON, is pretty much non-negotiable. The order can of course change but all of that has to be there.

XML will of course look pretty different but it is still going to need everything listed in this URL for the XML (MRSS) Feed specs
Rovidx Media.
May the Roku DP be with you.
0 Kudos
atc98092
Community Streaming Expert

Re: Can I use Direct Publisher to connect to an internal server

Thanks. Looking like Direct Publisher isn't going to work. Using Brightscript in the Eclipse IDE is comfortable, as it resembles working with Visual Basic all those years ago. Just have to learn a whole new language. Smiley LOL Fortunately it's similar enough to what I've used in the past, so I can at least follow most of the processes. 
Dan

Roku Community Streaming Expert

Help others find this answer and click "Accept as Solution."
If you appreciate my answer, maybe give me a Kudo.

I am not a Roku employee, just another user.
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.