AIR on Android: TweetrApp Video walk-through


This the final video in my EVA series focusing on the widgets that I have created for the App in a week seminars.  As you’ll discover, it’s really very simple to create a Twitter client, and to integrate Twitter services into new or existing content to add a social element.

EVA’s social widget was created using the Tweetr component library from Sandro Ducceschi at Swfjunkie.com.  He has done an incredible job to build out a complete API for Actionscript 3 developers, taking care of the horrors of Open Authentication and connecting to the Twitter API.  It’s really as simple as creating a few objects and an application token, Sandro has also provided great tutorial videos.

Tweetr requires the open source AS3Crypto component library, a package of classes that help with encryption for client/server applications.  In this case Tweetr relies on AS3Crypto for the Open Authentication communication, another great example of how great the community is.

Finally, I spent a very long time trying to find a suitable List component for this application.  There are many great sets of components out there, not least of which is Flex.  Of course Flex on Mobile devices is going to take some time, so I was glad to finally come across FlepStudio.org and the Tipper component.

If you want to learn more about mobile optimization then drop by the mobile pages at the Developer Connection.  Also coming up in June are some great e-seminars where you’ll learn more about going multi-screen.

Download TwitterApp

, , , ,

  • http://blog.swfjunkie.com Sandro

    Hi Mark

    Thanks for using the tweetr library, i hope the usage experience was a good one :) . I figured i might aswell mention that i’m currently working on a slimmer version of the library, so that you actually only integrate the parts that you actually want to use to reduce the overhead. It’s also planned to eliminate the need to copy the pin for authorization, as to make the user experience a bit smoother.

    So, are you guys actually using EVA? Cool to be part of it :)

  • http://www.flashmobileblog.com Mark Doherty

    Hi Sandro, We are still in the later part of development but the plan is to use it of course.

    I’m so glad to hear that you’re still working on it, the API experience is great, however there were a few issues. One is the PIN and it’s great to hear that it can be fixed, because on mobile devices it’s a horrible UX. I think we’ll see more issues raised by various app developers when the OAuth hammer strikes :-)

    I’m also really happy to hear about the slimmer version, there’s certainly scope to remove the AS3Crypto overhead.

    Mark

  • http://www.advancedcloud.com Yousaf

    Hi Mark,

    Thanks for sharing the application. oAuth is a pain in the backside but I am glad Sandro is on the case :)

    best regards,
    Yousaf

  • weikai

    Hi, Mark,
    Is audio and video capturing from Mic and Camera supported on AIR2 on Android?

  • http://www.flashmobileblog.com Mark Doherty

    Hi Weikai, Currently no, we are considering these features for the future. Using Flash Player 10.1 and PhoneGap it is possible to produce this type of app however. Check here:
    http://www.flashmobileblog.com/?s=flashcam

  • Robert

    This TwitterApp goes a long way to explaining to me how the whole Twitter thing works, but i’m still in the dark as to how I simply send a tweet message to twitter from my iPhone.
    I don’t want to read tweets in my app, just send a tweet on demand. The tweet message is generated by the app, stored in a variable as a string, and sent to a twitter account.
    So, I understand the Authorize bit on first use. This solved one of my biggest headaches. However, now rather than read a list, I need to send the pre-prepared tweet as a shortened (tiny) url. Do you think I can work out how to do this – or even find an example for the iPhone? nada.

  • http://www.facebook.com/rachalmers Robert Chalmers

    Ok, I have this running on the iPhone, developing it in an Adobe CS5+Flash iPhone packager environment. Made a Project of it. As usual it opens the Twitter authorize conversation in the Safari browser. However – the program always starts with the Authorize screen – which you can only use once. I had the same problem in the desktop version – but I believe it should be stepping past the Authorize screen if it finds it already used? yes? no?
    I did have it working ONCE – the first time. I brought up the list of Tweets fine. But exit, start again – and no way will it work. Just tries to Authorize again and fails of course.

  • sonicoliver

    You can do pinless OAuth (authorize without the pin) on both web and AIR and also access twitter API URL directly from AIR apps on iPhone and Android. Tweeter needs some modifications to do it (the hard coded URL’s are old) but it does work.

    Unfortunately the tweetr proxy has limitations in terms of volume of tweets.

  • sonicoliver

    ** EDIT: I mean access twitter API without proxy on AIR. Much better, no post limitations based on server IP address.

  • Anonymous

    Hi Robert,

    There needs to be a small change added to the Tweetr library that listens for the complete event in order to retrieve the appropriate key from Twitter.

    Download the library here:
    http://www.flashmobileblog.com/wp-content/uploads/2010/06/Tweetr.zip

  • Anonymous
  • http://twitter.com/fazermokeur fazermokeur

    Hello, I use the lastest Tweetr Swc compiled by @_sandro and it works pretty fine with the pinless oAuth access. But I can’t logout my users.
    When I call the tweetr.endSession(), I fire all@_sandro:disqus Oauth and Tweetr instance at the StatusComplete Receive, but I can’t log anymore. 
    Any ideas?