
As you might know twitter is going to provide geolocation information in the near future. That’s great news and makes the geolocation support in the twibble mobile client even more useful. This also means the geolocation api we have been providing for some time will no longer be necessary in order to pull location data out of the twitter stream. You’ll get something like
"geo":
{
"type":"Point",
"coordinates":[37.78029, -122.39697]
}
directly from the twitter stream. Let’s see how geolocation will change the twitter world!
Below the previous information on our api. Please do not rely on the availabilty of our api.
twibble provides an API. You can subscribe to geocoded twitter timelines that you can feed into your blog. This should work fairly well if you have a GPS enabled device like the iPhone or Nokia N95. twibble understands locations sent by twitteriffic (iPhone) and twibble mobile, and manual entered locations in the twitter user profile. As an example, this URI displays the last location of twitter user twibble (hey, that’s us
.
The feeds are in kml and georss format. The API allows you to display the locations of yourself and your twitter friends in Google Earth, Google Maps, or any other georss/kml aware application. You can also include the feeds into your own application or blog. The format of the twibble output data is very similar to the output data of the twitter API. Basically, the twibble API adds some additional geo elements to the standard twitter output but lets the basic structure unchanged. If you want to play with it below are some examples.
Google Earth:
In Google Earth click on Add->Network Link and enter the following URI:
http://api.twibble.de/statuses/user_timeline.kml. If prompted for a password enter your twitter credentials. This should display your location(s). If you want to watch the locations of your friends add this URI:
http://api.twibble.de/statuses/friends_timeline.kml
Of course, you can add more than just one network link. Google Earth can also auto update your view say every 5 minutes. This is how it looks like in Google Earth with a GPS postion sent by a Nokia N95:

Google Maps:
In the example above http://api.twibble.de/statuses/user_timeline/twibble.kml?count=1 returns the last location of twitter user twibble. Just replace twibble with your screen name. Note the count parameter whichs tells the api just to return the last status of twibble. Both kml (suffix .kml) and GeoRSS (suffix .rss or .georss) should work. Note, this will only display public twitter profiles because Google maps currently does not support authentication of overlay maps.
Embeddable Google Maps:
Follow the instructions for Google maps above and generate an iframe using “Link to this page” in the top right-hand corner. You will get a HTML snippet you can insert in your web page.
Use the data in your own application
As you’ve seen in the examples above the twibble API works very similar to the twitter API. Currently you can get gecoded timelines (cf. twitter Status Methods as described in the twitter API):
friends_timeline (you need to authenticate)
URL: http://api.twibble.de/statuses/friends_timeline.format
Formats: xml, kml, georss
Parameters:
- id. Optional. Specifies the ID or screen name of the user for whom to return the friends_timeline. Ex: http://twitter.com/statuses/friends_timeline/12345.xml or http://twitter.com/statuses/friends_timeline/bob.json.
- since. Optional. Narrows the returned results to just those statuses created after the specified HTTP-formatted date.
and similar also the user_timeline:
URL: http://api.twibble.de/statuses/user_timeline.format
Formats: xml, kml, georss
The output is probably best explored using a command line tool like curl. E.g. try
curl http://api.twibble.de/thilo/statuses/user_timeline/twibble.kml or
curl -u http://api.twibble.de/thilo/statuses/friends_timeline.xml. You will notice the extra location element.
33 responses so far ↓
Is it possible to display just the location of the last status of a user rather than a complete timeline? For example, I am getting ready to leave on a trip and would like to have an embedded Google Map on my web site that shows my current location (as specified by my last tweet). Is this possible?
Thanks, Rich
Rich, that should be possible. If I understand you correctly you want some sort of kml file that has only one entry with your last position, right?
Yes, that is correct.
Also, with your existing API call, I am trying to call:
http://api.twibble.de/statuses/user_timeline/richwagner.kml
I am getting the following error:
Line 19: contains syntax errors
However, I was actually getting the same tweets/locations to work fine this weekend.
Rich, it seems your user_timeline is currently empty:
http://api.twibble.de/statuses/user_timeline/richwagner.json
gives an empty list. This one works:
http://api.twibble.de/statuses/user_timeline/twibble.kml
But I agree that shouldn’t result in an error. I’ll have a look at it!
Do you know why the timeline would be empty? See my latest tweets below—note that I do have L: location info in each.
richwagner We made it to the Hampton Inn in Blythe. It is a wicked 106 degrees!!!! Great day of riding. We’ll blog tonight! (L:BLYTHE,CA) 08:08 AM May 25, 2008 from twhirl
richwagner Passing Buzzards Peak. Very hot! Approaching 104 degrees. We are riding strong, however. (L:33.14278,-114.86389) 08:04 AM May 25, 2008 from twhirl
richwagner Unbelievable scenery this morning. Sand dunes in all directions. Great video blog stuff! (L:RUTHVEN,CA) 07:58 AM May 25, 2008 from twhirl
richwagner Leaving Brawley before the sun comes up.
4:30am is not a time in which any human should be on a bike. (L:BRAWLEY,CA) 07:56 AM May 25, 2008 from twhirl
How long do locations stay “current” in the user timeline? IOW, I had a user timeline that originally mapped out exactly as desired on the day the entries were entered, but now my user time returns empty.
Rich, you should now see all of your tweets up to 20 in the user timeline (before it was all tweets within the last 48 hours). However, the friends_timeline doesn’t work any more (without authentication) because twitter has changed the api. Pls see http://www.twibble.de/2008/06/06/twibble-weekend-news/ Thanks for reporting!
Hey, I really like the .georss capabilities of the twibble api! Thank you for distributing it and providing the service!
Is there a way to make it only grab the latest tweet? As in with the Twitter API’s “?count=1″ This ability would be very helpful.
Thanks again!
@Nate here you go: ‘http://api.twibble.de/statuses/user_timeline.georss?count=1′ should give you the latest geocoded tweet of the authenticated user. The count parameter also works for the other formats (kml, xml, json) and timelines (friends_timeline and complete_timeline). In addition the twibble-API understands iPhone-Positions sent by Twitterrific
Great API. IS there a way to get a geocoded search feed rather than a user feed? i.e. a KML’d version of something like http://search.twitter.com/search?q=twibble ?
[...] Twibble – Its a Twitter client application for the Nokia N95. [...]
think you for this action
This is great. How do you geocode the place names in a tweet (e.g. L:Hamburg:)? Is it a Google geocoding application? I’m curious about the level of accuracy. Thanks!
Great feature, the automatic GPS tagging from Nokia 95 8B. But: it twibbles only a readable location for the Twibble desktop and API, right? Non-Twibble readers need to copy and paste the location into f.e. Google Earth. Why doesn’t Twibble automatically make a link to a map site???
@Tim searches are geocoded using the Google geocoder and Yahoo as a fallback.
@Rick Basically there are 2 options: A L:: string or a link to a maps app (e.g. Google maps). The former is more general as other applications/mash-ups can parse it and do funny things with it (e.g. this one). You’re right, the latter makes it easy to show your position to other people. Maybe (power) twitter or identi.ca will eventually recognize the L: tag
Does this work with identica.ca or just twitter? I imagine there would be a problem with the same name on both services.
[...] this cool API: http://www.twibble.de/twibble-api/ __________________ SkiLeases.com Need a Blog or Website? – [...]
Hi, is the google maps database down? I have used it before and i had no problem at all..but when on the last week i have this error message when I search for a location:
“File not found at http://api.twibble.de/statu….”
not even the link for the tiwbble location (at the beggining of this page) seems to be working.
@Henry you’re right, as for now it’s twitter only
@Rafael works here. If I enter http://api.twibble.de/statuses/user_timeline/twibble.kml?count=1 in the search field of Google maps I see the last location of twibble.
how do i get the location on my blackberry twibble to work?
Is twibble still working ? It seems like it is not parsing properly my twitter entries. Are you working on something at the moment ?
now it seems to be working again , strange
[...] seguro de todos, tendo o sistema ssl ativo e também aceitando o sistema de posicionamento de seus tweets/fotos. (caso você tenha GPS em seu [...]
Can I use your api for twitterfox?
hi i typed my User id in the right place, the green light comes up but no sub folders, i type my friends id and it works..???
[...] mentioned in his post, third party developers like Germany’s Twibble have already produced geo-location services for Twitter. They relied on information pulled from the location details in users’ profiles or from [...]
[...] הצייצנים הישראלית. לכן, התחלתי להשתעשע עם API שונים. ל Twibble, יצרני אפליקציות טוויטר למחשב ולסלולרי, יש API שמזכיר [...]
hello,
i can’t see my location via google maps an twibble.
i do everything and replace twibble in the example http://api.twibble.de/statuses/user_timeline/twibble.kml?count=1 …
what is wrong?
Hi Salih, you did everything right! Currently the api has been disabled since twitter itself is going to add geolocation to the tweet stream (see above).
[...] Twitterfon (Windows) http://twitterfon.net/ Twibble (Nokia, BB, SonyEricsson) http://www.twibble.de/twibble-api/ Possibly related posts: (automatically generated)Twitter’s quiet problem15 June [...]
Leave a Comment