Web Service Methods
API → Places
- search_places
- get_place_by_id
- get_places_similarities
- get_places_people
- get_places_entries
- get_places_photos
search_places
Will search place names based on the q* parameter that you pass it.
*Arguments:- api_key (required)
- q (required)
- offset (optional, default is 0)
- max (optional, default is 20 and can’t be higher than 20)
<?xml version="1.0" encoding="UTF-8"?> <feed xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns="http://43places.com/xml/2005/rc#"> <title>Place search results for "Kansas" on 43 Places</title> <link href="http://www.43places.com/search/query?q=Kansas" rel="alternate" type="text/html"/> <query>Kansas</query> <pagination> <offset>0</offset> <max>20</max> <total>3</total> <next_offset></next_offset> </pagination> <PLACE OBJECT> <PLACE OBJECT> <PLACE OBJECT> </feed>
The response contains this common object: Place
Demo: /service/search_places?q=Kansas
get_place_by_id
Retrieve information for a particular place, by its id.
Arguments:- api_key (required)
- id (required)
<?xml version="1.0" encoding="UTF-8"?>
<place place_id="191426">
<name>The Robot Co-op Office</name>
<link href="http://www.43places.com/places/view/191426/the-robot-co-op-office-capitol-hill-seattle" rel="alternate" type="text/html"/>
<parent id="200977">Capitol Hill</parent>
<children>
<child id="192017">Bathroom</child>
</children>
<num_registered_people>61</num_registered_people>
<worth_it_data>
<num_say_worth_it>19</num_say_worth_it>
<num_say_not_worth_it>2</num_say_not_worth_it>
<percentage_worth_it>90</percentage_worth_it>
</worth_it_data>
<tags>
<tag>seattle</tag>
<tag>capitol hill</tag>
<tag>office</tag>
<tag>style</tag>
<tag>robots</tag>
<tag>geeks</tag>
<tag>43things</tag>
<tag>yoga studio</tag>
<tag>43places</tag>
<tag>where it's at</tag>
</tags>
<id>tag:43places.com:place:191426</id>
</place>
Demo: /service/get_place_by_id?id=191426
get_places_similarities
This will return a list of up to 5 places which are displayed in the “People who are going here are also going to these things” section of a place’s detail page.
Arguments:- api_key (required)
- id (required)
<?xml version="1.0" encoding="UTF-8"?> <feed xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns="http://43places.com/xml/2005/rc#"> <title>Places similar to "Seattle" on 43 Places</title> <link href="http://www.43places.com/thing/view/106707/seattle-king-county-washington-state" rel="alternate" type="text/html"/> <place place_id="106688"> <name>Chicago</name> <link href="http://www.43places.com/places/view/106688/chicago-illinois" rel="alternate" type="text/html"/> <num_registered_people>260</num_registered_people> <id>tag:43places.com:place:106688</id> </place> <place place_id="106710"> <name>Portland</name> <link href="http://www.43places.com/places/view/106710/portland-oregon" rel="alternate" type="text/html"/> <num_registered_people>146</num_registered_people> <id>tag:43places.com:place:106710</id> </place> <place place_id="106697"> <name>San Francisco</name> <link href="http://www.43places.com/places/view/106697/san-francisco-california" rel="alternate" type="text/html"/> <num_registered_people>440</num_registered_people> <id>tag:43places.com:place:106697</id> </place> </feed>
The response contains this common object: Place
Demo: /service/get_place_similarities?id=106707
get_places_people
This will return up to 20 people at a time that have added this particular place to their list. People will be ordered primarily by the number of entries that they’ve written about the place, and secondarily by their most recent log in date.
Arguments:- api_key (required)
- id (required)
- view (optional, can be set to “want_to_go” (default), “have_been”, or “helpers”)
- want_to_go: people who want to go here
- have_been: people who visited
- helpers: people willing to help
- offset (optional, default is 0)
- max (optional, default is 20 and can’t be higher than 20)
<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns="http://43places.com/xml/2005/rc#">
<title>People who want to go to Seattle on 43 Places</title>
<link href="http://www.43places.com/places/people/106707/seattle-washington-state" rel="alternate" type="text/html"/>
<view>want_to_go</view>
<place place_id="106707">
<name>Seattle</name>
<link href="http://www.43places.com/places/view/106707/seattle-washington-state" rel="alternate" type="text/html"/>
<num_registered_people>389</num_registered_people>
<worth_it_data>
<num_say_worth_it>387</num_say_worth_it>
<num_say_not_worth_it>11</num_say_not_worth_it>
<percentage_worth_it>97</percentage_worth_it>
</worth_it_data>
<id>tag:43places.com:place:106707</id>
</place>
<pagination>
<offset>0</offset>
<max>20</max>
<total>389</total>
<next_offset>20</next_offset>
</pagination>
<PERSON OBJECT>
<PERSON OBJECT>
<PERSON OBJECT>
</feed>
The response contains this common object: Person
Demo: /service/get_places_people?id=106707
get_places_entries
This will return up to 20 entries at a time that have been written about this place. Entries will be returned in reverse chronological order. By default, all entries will be returned, but you can optionally filter them by passing a view argument.
Arguments:- api_key (required)
- id (required)
- offset (optional, default is 0)
- max (optional, default is 20 and can’t be higher than 20)
<?xml version="1.0" encoding="UTF-8"?> <feed xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns="http://43places.com/xml/2005/rc#"> <title>Seattle on 43 Places</title> <link href="http://www.43places.com/places/entries/106707" rel="alternate" type="text/html"/> <view>all</view> <PLACE OBJECT> <pagination> <offset>0</offset> <max>20</max> <total>129</total> <next_offset>20</next_offset> </pagination> <ENTRY OBJECT> <ENTRY OBJECT> <ENTRY OBJECT> </feed>
The response contains this common object: Entry
Demo: /service/get_places_entries?id=106707
get_places_photos
This will return up to 50 photos that have been uploaded for a place, or a place within that places. Images will be returned in the order of popularity (determined by number of cheers).
Arguments:- api_key (required)
- id (required)
<?xml version="1.0" encoding="UTF-8"?>
<place place_id="106707">
<name>Seattle</name>
<link href="http://www.43places.com/places/view/106707/seattle-washington-state" rel="alternate" type="text/html"/>
<photos>
<photo_set uploaded_by="drbrain" id="55225">
<square width="160" height="160">http://media.43places.com/salty/196363s160.jpg</square>
<original width="1800" height="1200">http://media.43places.com/salty/196363xl.jpg</original>
</photo_set>
</photos>
</place>