Flashr Auth demo
For the latest up to date information about Flashr please check out the new Flashr microsite
This seems to be one of the more confusing aspects of the Flickr API (it definitely was to me until I implemented it the first time). This demo basically shows the process of authenticating and also shows how you can store the authentication token in a SharedObject so that a returning user doesn’t need to log in again.
Note: you don’t need to authenticate against flickr.com to use most methods of the API. You only need to do it if you want to access a user’s private photos or to add / update information. The api docs tell you when authenication is necessary (I didn’t necessarily port all this information across into the flashr docs).
Right, here is the demo in action:
And here is the source code. To use the source code just download it and unzip it. Edit the file to put your API Key and secret in. Make sure you have the core of Flashr in your class path and compile the class with these MTASC flags (on top of your normal ones for -cp and -swf):
If you have any problems with the demo then please ask questions on the Flashr mailing list.