Saturday, November 13, 2010

Google App Engine and Facebook Connect

So, I've had a hankering to start playing with HTML 5 for some time. Specifically, I'd like to make a spiffy app (maybe a game???) that works on any decent smart phone.

There are a couple prerequisites to getting there, however. Namely:
1. A good idea for an app
2. A place to host it
3. A way to get people to use it

I don't quite have prerequisite 1 yet, so I'll skip that for now. Today, I'm going to focus on problems 2 and 3.

Being a guy with a budget of 0 YEN (for those in the US, that translates to about $0 USD), Google App Engine is the perfect answer to prereq #2. I haven't given Google my credit card number, but I can make up to 10 free, fully scalable applications. (Of course, if this idea ever takes off, I'll have to pay for the bandwidth, but not a concern right now)

As for prereq 3, I figure Facebook would be a great way to get my app "viral". I have no idea what the app will be, but I know it will at least allow users to interact with a community of other users, and it will provide some incentive for users to invite their friends.

By the way, since I'm using Google App Engine, I could instead use the Google User API, and grow my app with those who have Google IDs. However, I'm going to stick with Facebook for now. I just saw the movie "The Social Network" and I want to be a part of the fun.

So, some Google searches brought me two really great references that I shamelessly took for my app.

First is Chris Riccomini's tutorial on integrating Google App Engine with Facebook connect. After getting the Google App Engine SDK, setting up my App Engine Account, and registering an app on Facebook, I was able to see my Facebook profile picture on my site in a matter of minutes.

Another quick grab was some CSS from Harry Roberts , which is custom made for iPhone displays. This might come in handy later on.

With the wiring in place to connect with Facebook, all I needed to do was focus on making the application. I decided to start off with a simple message board (yawn). The message board works just like any other message board, except that it shows the person's Facebook name and profile picture.

Essentially, I just took Chris Riccomini's tutorial as a base, and added some datastore models to the mix. Here's the source if you're curious to see.

Here is a demo of the app (working as of today, I make no promises it will work tomorrow).

Although this message board isn't all that exciting, I now have the foundations in place for my new game. All I need is a great idea.

More to come.

No comments:

Post a Comment