OAuth2 vs Public API

Posted by Adam Tannon on Programmers See other posts from Programmers or by Adam Tannon
Published on 2012-07-02T13:10:32Z Indexed on 2012/07/02 15:23 UTC
Read the original article Hit count: 243

My understanding of OAuth (2.0) is that its a software stack and protocol to allow 2+ web apps to share information about a single end user. User A is a member of Site B and Site C; Site B wants to fetch some data from Site C about User A, and this is where OAuth steps in.

So first off, if this assessment is incorrect, please begin by clarifying this for me and correcting me!

Assuming I'm on the right track, then I guess I'm not seeing the need for OAuth to begin with (!). I'm sure I'm just not seeing the "forest through the trees" here, but the way I see it, couldn't Site C just expose a public API that Site B could use to fetch the same data (sans OAuth)? If Site C required user credentials to access the data, could this public API just use HTTPS for secure transport and require username/password as a part of each API call?

Again, I'm sure I'm missing something, but I'm just not understanding why I would need OAuth when a secure, public API written and exposed by Site C seems more than capable of delivering what Site B needs regarding User A.

In general, I'm looking for a set of guidelines to go by when deciding to choose between using OAuth for my web apps or just writing my own web service ( exposing public API).

Thanks in advance!

© Programmers or respective owner

Related posts about web-applications

Related posts about web-services