Add wrapper function for retrieving oauth info.
Fix catch syntax.
Update oauth error message/code.
Merge pull request #586 from mapbox/tm-oauth

Add wrapper function for retrieving oauth info