Tool for manually logging into Twitter using OAuth, with Cocoa code demonstrating the OAuth login process for Twitter
Twitter uses OAuth as its supported form of authentication. This is fine for some apps like clients where users need to authenticate themselves, but it doesn't work well for bots or scripts run by one person. If the bot needs an access token, it can be a real pain to obtain without writing the intermediate code.
This application, OAuthery, serves a simple purpose. You supply it the consumer key and secret for your OAuth application. It creates a request token and the URL for authorizing it. You complete the authorization in a web browser and get a PIN number. You then enter that PIN number back into the application, and it spits out your access key and secret. At this point, the user authentication is complete, and you can add those credentials to your script, and access API resources.
This is largely intended as a developer tool for people developing applications with Twitter's OAuth implementation. It also provides code to show exactly how to perform the authentication process with OAuth and Twitter, so that developers who wish to implement such functionality in their own apps can use this as reference.
Easy way: Download the application from the Downloads section. No installation needed.
Hard way: Clone the repository, update the submodules, and build the application in Xcode.
To use, you will first need an OAuth application registered with Twitter. To do this, go to the OAuth Clients page on Twitter, and set up an application. Make sure you select "Client" for Application Type, which will use the PIN-based authentication flow. Once your application is set up, Twitter will provide you with two bits of data, the consumer key and the consumer secret.
At this point, you can use OAuthery to obtain an access token.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.