I have an application that runs on a server, listens for various tweets using the streaming api, and then occasionally sends tweets out. This worked fine using the old twitter authentication system, but using OAuth has complicated things a bit.
I can successfully start the application up and my browser opens Twitter's OAuth page. If I enter the PIN the application runs fine but I need to be able to restart the application unattended. Twitter's OAuth FAQ http://dev.twitter.com/pages/oauth_faq says that tokens never expire, so what I'd like to do is re-use the authorization token each time the application starts.
How can I do that? Or is there another way to authorize just once?