OAuth

Codeplex OAuth providers for .NET Framework 4.0 and Windows Phone 7

File:Oauth logo.svg

The project

I started few weeks ago, a new project that allows me to do trading using the APIs provided by E*Trade. The authorization system used is OAuth. My first idea was to create a Windows Phone 7 application for E*Trade, what I started to do. Did you already try to debug web services that you don’t control? Especially when the documentation is not very good. When you send a bad request to the server, you always get the same answer:  The remote server returned an error: NotFound. But what does it mean? Basically everything. That’s why I created a new WPF project to have the full .NET Framework in order to get more information and help me to debug the Web service calls.

What libraries I use

I’m using the Reactive Extensions (Rx) to “wrap” my asynchronous event into observable objects. Then, because E*Trade APIs are based on OAuth protocol for the authorization of the users, I needed an library that helps me to send queries to the server. I’m using the project ReactiveOAuth because it is one of the best I found. I just had to use the source code and modify it, because it was originally created for Twitter, and it seems that every single OAuth provider does not respect the standards.

What’s next

I decided to publish the full source code of my project via CodePlex under the name OAuth Providers. I currently published an updated version of ReactiveOAuth and a basic SDK for E*Trade. I also included an example using WPF that connect to E*Trade and download some stocks information. I’ll publish soon an update of the SDK that will contain more API support.

My next objective is to publish more and more SDK for OAuth providers like Twitter, Facebook, LinkedIn, Foursquare…

Download the SDK