iPhone

ConferenceGuide 2.0 for iPhone is Out!

ConferenceGuide 2.0 for iPhone has been released on the App Store this morning, after just 3 days of Apple validation. I couldn’t be happier because we’re on time for Jfokus 2010.

So if you plan to attend Jfokus 2010 in Stockholm, Sweden, get your copy of ConferenceGuide now!

We have improved the application with bits and pieces here and there, fixed a few bugs, and added multilingual support, which is particularly interesting for Jfokus since it has sessions in both English and Swedish. By the way, the application interface has also been translated in French and Swedish. More languages to come as we need them for future events.

But certainly the most important evolution, and the reason why this version is 2.0, is that we have added premium packages. The principle is very simple: for some conferences, you will be able to purchase a premium package from within the application in order to unlock certain features. For example, Jfokus premium package includes two of our most requested features:

  • Offline Mode, that downloads all of a conference data to your phone so that you can use it offline, which can be very practical if you don’t have a data connection on site
  • Push Notifications, because if you are offline, it also means that something can change without you knowing it, but with this feature, you are notified in real time whenever a session is cancelled or a speaker is replaced for example. Then all you have to do is read the notification message and conference data will be updated on your iPhone.

We really hope you will like it, all the more so as it is very affordable: you get both of these very useful features for just $0.99 (or 0,79€).

Now remember that if you have any feedback or input concerning our iPhone application, you can simply leave a comment below. And if there are some missing features that you would like us to add, see the User Feedback widget in the right column.

Enjoy!

How to Verify an App Store Transaction Receipt in Java/Groovy?

This post is knowingly quite technical. The journey towards creating a mobile application is filled with technical discoveries and struggles, and we thought it might be interesting to share our experiences. So if you are not a developer your self, it is likely that you won’t understand a lot in the Technical category of this blog. Hopefully it will make you feel like knowing more and you will join the tribe.

In the last few days, I’ve been playing with In-App Purchase on the iPhone and I’ve done some experiments with what they call the Server Product Model, that is a model in which your iPhone application is connected to a server that is responsible to provide commercial content.

In-App Purchase Server Product Model

In-App Purchase Server Product Model

There is something interesting with step 12. It happens after the mobile application has already talked with the App Store to process the payment. So you could think that all the server has to do next is to send the content and we’re good to go… But what if the mobile application was hacked and the payment was not really processed? What if the request was forged? Well, that’s what step 12 is all about. Basically, the mobile application sends some encoded data to the server. The server checks that it’s genuine and sends the content only if it is. Of course it only works if you have a server, and creating one for the sole purpose of checking transactions might not be a good idea. But since I’m using a server to download content from, why not use it to perform some authentication as well?

Now the next question is “How does my server check this transaction receipt with Apple’s app store?”. My server, ConferenceGuide server, is a Grails one. What is cool with Grails is that it comes with a couple of additional Java APIs that are very useful. So without further ado, let’s dive into some code:

    void verifyReceipt(String productId, byte[] receipt) {
        //This is the URL of the REST webservice in iTunes App Store
        URL url = new URL("https://buy.itunes.apple.com/verifyReceipt");

        //make connection, use post mode
        HttpsURLConnection connection = (HttpsURLConnection) url.openConnection();
        connection.setRequestMethod("POST");
        connection.setDoOutput(true);
        connection.setAllowUserInteraction(false);

        //Encode the binary receipt data into Base 64
        //Here I'm using org.apache.commons.codec.binary.Base64 as an encoder, since commons-codec is already in Grails classpath
        Base64 encoder = new Base64();
        String encodedReceipt = new String(encoder.encode(receipt));

        //Create a JSON query object
        //Here I'm using Grails' org.codehaus.groovy.grails.web.json.JSONObject
        Map map = new HashMap();
        map.put("receipt-data", encodedReceipt);
        JSONObject jsonObject = new JSONObject(map);

        //Write the JSON query object to the connection output stream
        PrintStream ps = new PrintStream(connection.getOutputStream());
        ps.print(jsonObject.toString());
        ps.close();

        //Call the service
        BufferedReader br = new BufferedReader(new InputStreamReader(connection.getInputStream()));
        //Extract response
        String str;
        StringBuffer sb = new StringBuffer();
        while ((str = br.readLine()) != null) {
            sb.append(str);
            sb.append("\n");
        }
        br.close();
        String response = sb.toString();

        //Deserialize response
        JSONObject result = new JSONObject(response);
        int status = result.getInt("status");
        if (status == 0) {
            //provide content
        } else {
            //signal error, throw an exception, do your stuff honey!
        }
    }

That’s all there is to it… plus a few exception handlers here and there to make sure everything goes right for users when something goes wrong on your side. Note that this code works in Groovy and should work in Java as well, which means it’s probably not as short as it could be if it were realy groovified. But it works, for real. Enjoy!

ConferenceGuide 1.1 for iPhone and Future Events

First off, let’s talk about ConferenceGuide 1.1. The iPhone version has been published on the AppStore 2 days ago. Note that it still requires iPhone OS 3.1. New features in this version include:

  • Search in all screens including conferences, speakers and sessions
  • Session “starring”: add sessions to your bookmarks and filter starred sessions
  • When a conference is ongoing and you open the schedule view, it automatically jumps to the next slot
  • You can now view details about the venue for each event
  • Visual feedback has been improved when data is loaded from the server

And of course, a few bugs have been fixed, and some optimization was made. Claes is currently working on implementing the same features on the Android version. He will let you know when it’s ready.

Concerning events now, as you probably know by now, we have fully covered Devoxx a few weeks ago and it was a great success. That’s why we have started to add new events to our coverage calendar. The next 2 ones are Swedish events occurring in parallel on January 26th and 27th:

  • JFokus 2010: another java community conference that gathered 650 people in Stockholm in 2008
  • DagsVara 2010, a publishing and media event in Stockholm as well

Schedule and speaker information are now available in ConferenceGuide and you can start to learn more about these events and maybe prepare your favourite sessions right away.

Last but not least, you may have noticed that MacWorld also appears in the list of upcoming conferences, but does not present any schedule or speaker information. Actually that’s another thing that we have added to ConferenceGuide 1.1: we will add as many events as we can to our database, for free, even if it’s just with a logo, dates and venue information. The idea is to use ConferenceGuide as a big global event calendar for everyone. Now this means a couple of things:

  1. If you know about an event that is not in our list, please let us know so that we can add it
  2. If a lot of you suggest the same event, we will try to add schedule and speaker information to it (we will definitely do it if we are interested in it as well)
  3. If you participate in the organization of a conference and you would like it to be covered by ConferenceGuide to offer this service to your attendees, feel free to contact us. Schedule and speaker information is free, and you won’t even have to do anything. All we would like is that you talk about ConferenceGuide in your official communication about your event.

We have a lot of cool features and events to come in the next few weeks, so stay tuned. Oh, and by the way, if you have feedback, if you notice bugs, or if you have ideas about features or improvements that you miss in ConferenceGuide 1.1 for the iPhone, please leave a comment below.

Upcoming Features in ConferenceGuide

Devoxx is Over

It’s time for a summary. Devoxx was the first real-world test for Conference Guide and I have to say that Claes and I are pretty satisfied. Overall, the iPhone version was downloaded 299 times between its release and Sunday, November 22nd, while the Android version was downloaded 123 times on the same period.

For the iPhone version, we have some country-specific figures:

Sales by country

Sales by country

The Grails server held great, despite the fact that there is still no caching on the client side, leading to a lot of requests. Some people complained about the fact that they needed a network connection to use it, which is not the case with other similar apps. But contrary to those apps, we were able to update the server in real time when there were last minute changes:

  • One university session and one conference session were canceled and replaced by others
  • On Wednesday, when the sound mixer crashed, all sessions were delayed by 15 minutes and we could shift the timetable accordingly.

Now of course, we realize that this online solution is not ideal, and that’s why we are already working on a solution that will take the best of both worlds.

Given the success of this pilot project, we are already working on a new version. Our target is to be ready for the end of January to cover another Java event in Sweden: JFokus. This version should fix most of the limitations we’ve noticed in this version and add a few features, including:

  • The ability to “star” sessions
  • Venue information screen
  • More filters on all screens to get directly to the information you are interested in

We will let you know when the new version is ready. And once again, if you are a conference organizer and you would like your event to be covered by Conference Guide, feel free to contact us.