itsapi / dvbris.com

Portfolio of our websites
http://dvbris.com/
3 stars 1 forks source link

Twitter API for bios #9

Closed geraintwhite closed 10 years ago

geraintwhite commented 10 years ago

It would be nice to use the twitter API for getting our bios.

API 1.1 requires authentication for all requests, and JavaScript cannot authenticate using Oauth. It must be done server side.

olls commented 10 years ago

http://www.timacheson.com/Blog/2013/jul/twitter_api_proxy

geraintwhite commented 10 years ago

Have you tried it? On 17 Mar 2014 08:18, "Oliver Faircliff" notifications@github.com wrote:

http://www.timacheson.com/Blog/2013/jul/twitter_api_proxy

Reply to this email directly or view it on GitHubhttps://github.com/itsapi/portfolio/issues/9#issuecomment-37792777 .

geraintwhite commented 10 years ago

Did you read that it is for ASP.NET?

olls commented 10 years ago

Yes, I was using it as an example of something we could build/find alternate.

geraintwhite commented 10 years ago

I looked, oauth can't be done in JavaScript. We'd have to have a server side authenticator. On 17 Mar 2014 17:13, "Oliver Faircliff" notifications@github.com wrote:

Yes, I was using it as an example of something we could build/find alternate.

Reply to this email directly or view it on GitHubhttps://github.com/itsapi/portfolio/issues/9#issuecomment-37842674 .

olls commented 10 years ago

I know, that's the point of this, it does the server side authenticating and acts as a proxy for us to access the API.

olls commented 10 years ago

Using YQL as the proxy: http://derek.io/blog/2010/how-to-secure-oauth-in-javascript/ a bit old, might still work.

olls commented 10 years ago

Using Node for the server side auth: https://gist.github.com/olls/1ccbac5e4310721efa17

olls commented 10 years ago

40d76053c5884270af496df96c1cf0b4da5d788d