Many methods require the user to be logged in. At present there is only one way to accomplish this.
Please note that this Authentication API has been deprecated. Please refer to the OAuth API for more information.
There are step-by-step how-to's to guide you through the setup and development procedure for each of the authentication modes:
Note that these are just our suggestions which will work in most cases. There may be application-specific reasons you'd want to use, say, the desktop application style of authentication for a web based app or the mobile style of authentication for a command-line app, etc. If in doubt, check them all out.
Commandline applications will probably want to use the mobile authentication mode.