facebook

Over The Air

| 0 comments | facebook mobile application ota12 hack day

Last week, Ali and I attended the 2012 Over The Air, a mobile applications themed hackday. It was held at Bletchley Park, home to the National Museum of Computing, among other things.

There was an extremely packed schedule comprising of talks on a whole manner of subjects relating to the mobile web. I managed to attend the talks on QR codes, WebRTC, Facebook Graph API, O2 Labs and the keynotes.

I would have loved to have seen more, however, we had a hack to build.

Ali had an mbed and a GPS/GPRS module that he had used for his solo project. We decided to use the mbed platform as they were at the event with Vodaphone 3G dongles. We created Dude, Where's My Car?

The mbed device, connected via the 3G dongle, sends GPS co-ordinates to the server every few seconds. These appear in the timeline on the website. You can then create a trip by selecting start and stop positions which is then shared with your friends on Facebook using the open graph API. We made actions of going on a trip which had properties including the trip name and geo-location data.

Ali also had a OBD (On Board Diagnostics) interface that connects to a car. Through this device, the mbed could get a number of parameters from the car such as speed, throttle, rpm, engine temperature etc. This data was added to the server along with the GPS and pased through to Facebook wihin the open graph metadata. It was then used to generate averages, minimums and maximums for the car data. All this then appears on your Facebook timeline looking like the example below.

Facebook Timeline Post

We demo-ed our hack to the judges and audience and ended up winning both the Facebook Open Graph Challenge and the Embedded Hardware Hack Challenge. They loved how we took the real-world action of driving and sharing that with your friends.


Facebook Privacy

| 0 comments | facebook

Facebook privacy has popped up again in the news, yawn.

The personal details of more than 100 million Facebook users have been published on the internet.

Yes and why is this news? Those 100 million Facebook users gave their 'personal details' (happens to be name, gender, profile picture and locality) to Facebook on the internet. So, I am pretty sure that they were expecting to see their names on the internet.

Story Background: A security consultant put the list of users together using the Facebook Graph API. The dataset has now been uploaded to torrent sites allowing people easy access to the names and URLs of Facebook users.

So what is all the fuss about?

The data that has been collected is freely available via a search on Facebook or by a search engine. If people do not want their names 'published' on the internet, then they either need to:

  • use a fake name as their online identity
  • stay offline

Location Aware Facebook

| 0 comments | facebook

If the graph API is anything to go by then it looks like Facebook will be location aware very soon

{ "id": "512982904", "name": "Dylan Jones", "first_name": "Dylan", "last_name": "Jones", "link": "http://www.facebook.com/dylanjamesvernonjones", "location": { "id": null, "name": null }, "gender": "male" }

Notice the location parameter, now a default result in the user information call.


Foebook

| 0 comments | facebook

foebook.co.uk has been updated today to give people a chance to voice there opinions on whether or not Facebook is a good or bad thing

The site asks the basic question: Friend or Foe?

Users can then add any comments they wish to make which in turn, gets displayed on the site for other users to see.

Why? - I bought the domain name a while ago and put together an app that you log into, make friends, award each other points on friendly actions, take points away for un-friendly actions etc. It wasn't very good.

This small and simple device gives an open place for constructive critisism or just silly comments on what may be the biggest online threat we have ever seen.


Facebook Graph API - Project

| 0 comments | facebook

I have managed to crack the OAuth thing that Facebook has taken up to authenticate web apps calling their new Graph API. I found it quite simple actually.

Before you can make restricted requests, you need to be first issued with an auth_token. To get one you need to send a request to:

https://graph.facebook.com/oauth/authorize?client_id=YOUR_APP_ID&redirect_uri=YOUR_APP_URL&scope=LIST_OF_OBJECTS

LIST_OF_OBJECTS is where you comma delimit the list of things you will want to access (ie events,photos,email etc). The call returns a code which you then use along with your secret to retrieve the auth_token

http://graph.facebook.com/oauth/access_token?client_id=YOUR_APP_ID&redirect_uri=YOUR_APP_URL&client_secret=YOUR_APP_SECRET&code=THE_CODE

The auth_token is then returned along with an expiry countdown in seconds. This can then be added to any API calls for which you need permission.

I have used just one PHP script to do everything. It just checks if its receiving instructions by the user to make a call as a GET variable else goes along through the authentication procedure until an auth_token is set

Feel free to test it out over at dyl.anjon.es/musicwall


Facebook Graph - Creating a Social Web

| 0 comments | facebook

Last week, Facebook announced some interesting things at their F8 conference. Their BIG plan for the world is to make it a more social and personalized web. With this in mind they have released a few tools to help the world.

Starting first with their big initiative, the Graph API which is the foundation of the new API.

This is a fantastically easy way to get machine readable (JSON) real-time information from FB. An example:
http://graph.facebook.com/dylanjamesvernonjones

{ "id": "512982904", "name": "Dylan Jones", "first_name": "Dylan", "last_name": "Jones", "link": "http://www.facebook.com/dylanjamesvernonjones" }

You get some basic information on me. You can delve deeper into my life by getting my news feed by calling :
http://graph.facebook.com/dylanjamesvernonjones/feed

{ "data": [ { "id": "512982904_427382302904", "from": { "name": "Dylan Jones", "id": "512982904" }, "message": "And thats the end of that chapter! (that chapter is maths by the way)", "icon": "http://photos-f.ak.fbcdn.net/photos-ak-sf2p/v43/53/146139331013/app_2_146139331013_1286.gif", "attribution": "TweetDeck for iPhone", "actions": [ { "name": "Get TweetDeck", "link": "http://www.tweetdeck.com" } ], "created_time": "2010-04-30T10:01:30+0000", "updated_time": "2010-04-30T10:01:30+0000", "likes": 2 }, { "id": "512982904_119487514744084", "from": { "name": "Dylan Jones", "id": "512982904" }, "message": "Whats that coming over the hill, is it a monster, is it a monster?", "created_time": "2010-04-29T21:14:12+0000", "updated_time": "2010-04-29T21:14:12+0000", "likes": 2 . . . . . . . . . . . .

Using OAuth 2.0 as authentication, you can get more data, if not everything you could possibly want from events, friends, likes etc. More information is available from the documentation on Facebook's Developers site.

I have already put to use this graph API to cache my public facebook messages on my database for inclusion in my live feed on this site located at: me.dylanjones.info For this I just use the json_decode() function in PHP.

Facebook also announced other things such as social plugins inluding their plan to get a 'Like' button on every page online. Some extra metadata is required for web pages to describe content to facebook, rather than using existing protocols - I did try this on dylanjones.info but it is not valid html so I removed it hastily.

More thoughts and uses for the new Facebook Platform later today.