views:

32

answers:

1

Hi there,

I hope this is an appropriate question: I'm using the Netflix API and I'm wondering what the best way one would be able to automatically recieve new data when presented (in this case, recently watched films when a Netflix user finishes watching one) The only way I can think of is spamming requests in intervals to query their feed. And would PHP be my best bet?

Thanks

A: 

That's right, Netflix doesn't provide any push notifications through their API. You'll have to poll their feed periodically, but not too often: your consumer key is limited to a certain number of requests per second and requests per day.

I'm not exactly sure what you're trying to do, to know whether PHP would be the right choice. OAuth libraries are available for pretty much every major language, so it's up to you.

Eric Warmenhoven
Thanks Eric. Do you know what the best language would be to poll the server's in, say, 3 hour intervals? PHP is my only back-end language handy with and suppose using cron to run a script would work. What's your take?Thanks again!
Ryan
Well, I think it's really just personal preference. Personally, I'd probably use cron to call a perl script; I think there's already a Netflix perl module in CPAN. If you're more comfortable with PHP there's no reason not to use that.
Eric Warmenhoven
Great, thanks for the advice Eric. Very helpful!
Ryan