Evernote OAuth in C++
It was while developing this that I learned that Evernote SDK for C++ doesn’t really provide any integration with OAuth. I couldn’t even find a well formed solution for the same on the Internet, except some forum posts suggesting using any available OAuth 1.0 client. Searching for OAuth clients for C++, I found O2. Using this, I was able to create a simple OAuth integration for Evernote.
Here are the steps :-
- Taking cue from O2 integration with Dropbox,
I extended O1 to create
EvernoteAuthenticatoris initialized and called. Moreover, it handles the signals generated by
EvernoteAuthenticatorto open a browser, which is required for the user to enter his credentials to log in. It also allows the developer to use the sandboxed environment (more about that later).