This project has moved and is read-only. For the latest updates, please go here.

Querying Similar Places

Get a list of nearby places with similar names.

Entity: Geo
Type: GeoType.SimilarPlaces
Name Purpose Type Required
Attribute Name/value pair separated by "=" (i.e. "street_address=123 4th Street") string no
ContainedWithin PlaceID to restrict results to string no
Lat Latitude to search dec yes
Long Longitude to search dec yes
Name Place name string yes

            var geoResponse =
                (from g in twitterCtx.Geo
                 where g.Type == GeoType.SimilarPlaces &&
                       g.Latitude == 37.78215 &&
                       g.Longitude == -122.40060 &&
                       g.PlaceName == "Twitter HQ"
                 select g)

            if (geoResponse != null && geoResponse.Places != null)
                geoResponse.Places.ForEach(place =>
                        "Name: {0}, Country: {1}, Type: {2}",
                        place.Name, place.Country, place.PlaceType));

Twitter API: geo/similar_places

Last edited Nov 29, 2013 at 3:53 AM by JoeMayo, version 7