Roku Registry Persistence - rrirower/DP2SceneGraphWizard GitHub Wiki

Using a backend (BE) server, you can persist the Roku device registry across a user account. This means that a user can begin watching your content on one device, and continue on another. The channel does this by saving and retrieving the user's Roku registry to your BE server. To accomplish this, you need to define REST API functions in your BE server.

Functions you must implement:

  • cloud-get-registry. The wizard code posts a request to your BE server requesting the current Roku registry. It calls the cloud-get-registry function in your BE server with the following syntax: http://yourbeserver/?channelId=xxx&userId=xxx. channelId is your channel ID and userId is the user's Roku email account address. The above parameters should be sufficient to identify the Roku registry that should be returned.

  • cloud-save-registry. The wizard code posts a request to your BE server to save the current contents of the user's Roku registry. It calls the cloud-save-registry function in your BE server with the following syntax: http://yourbeserver/?channelId=xxx&userId=xxx&reg=xxx. channelId and userId are defined above. reg is a string representing the current contents of the user's Roku registry. Your function should save the contents of the reg string so that it can be retrieved when requested.