Roku Developer Program

Developers and content creators—a complete solution for growing an audience directly.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
ionatan
Level 8

getPurchases returns HTTP Error/Timeout for Dev Apps

Hello,

 

Function getPurchases https://developer.roku.com/docs/references/scenegraph/control-nodes/channelstore.md#getpurchases returns "-1: HTTP Error/Timeout" if the app is installed as a Dev app (zip archive) on device.

The app works properly if it is published as a Channel, but local tests fails due function getPurchases not working for dev app.

Did anyone experienced similar behaviors?

 

Thanks!

0 Kudos
3 REPLIES 3
renojim
Community Streaming Expert

Re: getPurchases returns HTTP Error/Timeout for Dev Apps

I don't know if it would cause that error, but do you have the channel you're developing set to "Use for billing testing"?

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.
0 Kudos
ionatan
Level 8

Re: getPurchases returns HTTP Error/Timeout for Dev Apps

This occurs when I upload a zip to my local Roku devices, so the Channel is identified as a "dev" Channel not as a Channel from Roku account.

From what I am aware there is no way to set such a dev Channel as "use for billing" testing.

0 Kudos
renojim
Community Streaming Expert

Re: getPurchases returns HTTP Error/Timeout for Dev Apps

It is a bit of a chicken and egg problem.  It's been a while since I started from scratch with a new channel with products to sell, so I'm not sure where you start these days and I don't want to lead you down the wrong path.  However, if you're trying to "getPurchases" those purchases have to be associated with a channel.  I can see it failing if you have a new channel because there wouldn't be any way for there to be purchases associated with it.  If you don't already have a channel with products attached I would think you'd need to create a channel, create the products, attach the products to the new channel, and then do the "use for billing testing" thing.  If you have any existing channels with products attached try setting one of them to "use for billing testing" and see if getPurchases in your dev channel works.

If I get a chance I'll try turning off "use for billing testing" on all of my channels to see what happens if I try getPurchases in a dev channel.

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.
0 Kudos