here is something i just ran against the search API (i formatted
the JSON for readability).
[ra...@tw-mbp13-raffi twitter (homing_pigeon)]$ curl "http://search.twitter.com/search.json?q=&ands=twitter+FTW&from=raffi
"
{
"results":
[
{
"profile_image_url":"http://a1.twimg.com/profile_images/364041028/raffi-headshot-casual_normal.png
",
"created_at":"Fri,
20 Nov 2009 15:40:40 +0000",
"from_user":"raffi",
"to_user_id":null,
"text":"Soy milk, FTW (@ Twitter in SF) http://bit.ly/NUNGf
",
"id":5892191934,
"from_user_id":278432,
"geo":
{
"type":"Point",
"coordinates":
[
37.7824,
-122.4009
]
},
"iso_language_code":"en",
"source":"<a href="http://foursquare.com"
rel="nofollow">foursquare</a>"
}
],
"max_id":5900232920,
"since_id":0,
"refresh_url":"?since_id=5900232920&q=+twitter+FTW+from
%3Araffi",
"results_per_page":15,
"page":1,
"completed_in":0.01934,
"query":"+twitter+FTW+from%3Araffi"
}
On Nov 20, 2009, at 2:21 PM, JOHN OBRIEN wrote:
Quick question...
What format will [geo] be from the /search api?
just the lat long, something like...
[geo] => 37.78029 -122.39697
I am watching a bunch of tweets coming into our service, but I
can't find one that is populated, so just thought I would ask.
(And I can't see anything from my account just yet... )
Thanks,
John
http://twapperkeeper.com
On Nov 19, 2009, at 4:51 PM, Raffi Krikorian wrote:
As you may have seen on the Twitter blog [1], geotagging is now
available for all users and developers throughout Twitter's
APIs. Specific geotagging methods have been added and existing
formats expanded to accommodate this rich new information.
To get started developing with this API and sending geotweets,
check out
http://apiwiki.twitter.com/Twitter-REST-API-Method%3A-statuses%C2%A0update
Geotweets now carry the geotag whenever available and whenever
they appear in our REST, Search, and Streaming APIs.
Remember, geotagging is disabled by default on users' accounts.
Encourage your users to enable it by sending them to their
settings page [2]. From that page, a user can turn this feature
on by checking the "Enable geotagging" checkbox. Alternatively,
we're also providing a mobile optimized geotagging settings page
[3] that you can send them too as well. As a developer, you can
determine whether a user has enabled geotagging by calling the
users/show method [4] or in any other <user> element returned by
the REST API where a user object shows up -- just look for the
geo_enabled flag.
For more hints on how to use geotagging, check out our
Geotagging Best Practices page [5] where we have UX mock-ups,
hints on how to best support user privacy, and more.
We're really excited about this feature! And more is coming.
Go get lost. We'll send help.
[1] http://blog.twitter.com/2009/11/think-globally-tweet-locally.html
[2] http://twitter.com/account/settings
[3] http://m.twitter.com/account/settings/geo
[4] http://apiwiki.twitter.com/Twitter-REST-API-Method%3A-users%C2%A0show
[5] http://help.twitter.com/forums/26810/entries/78525
--
Raffi Krikorian
Twitter Platform Team
[email protected] | @raffi
--
Raffi Krikorian
Twitter Platform Team
[email protected] | @raffi