...
Parameter | Description | Required | Valid Values | Default | Examples | Notes | ||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
where | The geographic region for the businesses for which you wish to obtain reviews | Yes | A zip code, city-state pair, or street address (spaces are optional following the comma between a city and state) |
| 91011 | Address-based search is performed when this parameter starts with a number and contains non-numeric characters; it is much slower than searching a named region. | ||||||
what | Search term text | Only if tag and listing_id are absent |
|
| pizza | The term will be used to search both for businesses related to the term and for reviews containing the term. | ||||||
tag | Category of the businesses for whom you wish to obtain reviews | No | A number |
| 1722 (for restaurants) | Tag identifiers are obtained from responses from the Places and Places Search APIs; you can use these values to find recent reviews for businesses related to your search results or recently viewed listings. | ||||||
listing_id | The id of the place whose reviews you would like | No |
|
| 1234567 | If you specify listing_id, do not specify what, where, or tag. | ||||||
publisher | The publisher code that identifies you | Yes |
|
| acme |
| ||||||
customer_only | Whether you wish to restrict the results to reviews of CityGrid Media customers | No | true | false | true |
| ||||||
rating | The minimal rating for the reviews | No | Positive integer between 1 and 10 inclusive |
| 4 | For example, supplying 4 will restrict the response to reviews with a rating of 4 or better. If this parameter is omitted, the result set will not be filtered by rating. | ||||||
days | The maximum age in days for the reviews | No | Positive integer |
| 25 | For example, supplying 14 will restrict the results to reviews which have been posted within the last 14 days. | ||||||
rpp | The maximum number of results to be returned. | No | Positive integer between 1 and 50 inclusive | 20 | 6 |
| ||||||
format | The desired format for the results | No | json | xml | json | json = javascript object notation, xml = extensible markup language, pbuf = Google's Protocol Buffers | ||||||
placement | An optional property for storing additional information you would like CityGrid Media to log for this view | No |
|
| sem_google | For example: if you run a search engine marketing campaign for Google and Yahoo!, you can set the placement property to "sem_google" or "sem_yahoo". Alternatively, if you publish CityGrid listings in different locations in your own site, you can set the placement property to values such as "home_page" or "search" (all up to you). CityGrid will organize reports for you by placement. | ||||||
callback | The name of (your own) JavaScript function that you would like to wrap your JSON response. | No |
|
| display |
| ||||||
i | An optional property for grouping API calls for tracking purposes (the parameter name is short for "impression_id") | No |
|
|
| The value should be set when making subsequent calls that are related to a previously made call. The user should never supply their own generated value for the impression_id. | ||||||
review_type | A filter to only return a certain type of review | No | editorial_review |
| editorial_review |
| ||||||
| An optional property to order the reviews | No | createdate |
| createdate | The createdate sort option sorts by the date in descending order (newer first) the review was written. |
Note |
---|
Arguments must be properly URL-encoded (spaces as %20 or +, ampersands as %26, and so on). |
...
Parameter | Description | Required | Valid Values | Default | Examples | Notes |
---|---|---|---|---|---|---|
lat | Latitude of the center of a circle for a geographic search | Yes |
|
| 37.65056 |
|
lon | Longitude of the center of a circle to search | Yes |
|
| -119.03639 |
|
radius | Radius of a circle search | Yes | Positive number between 1 and 50 inclusive. | 5 | 7.5 | If larger than 50 it defaults to 50. |
what | Search term text | Only if tag and listing_id are absent |
|
| pizza | The term will be used to search both for businesses related to the term and for reviews containing the term. |
tag | Category of the businesses for whom you wish to obtain reviews | No | A number |
| 1722 (for restaurants) | Tag identifiers are obtained from responses from the Places and Places Search APIs; you can use these values to find recent reviews for businesses related to your search results or recently viewed listings. |
listing_id | The id of the place whose reviews you would like | No |
|
| 1234567 | If you specify listing_id, do not specify what, lat, lon, or tag. |
publisher | The publisher code that identifies you | Yes |
|
| acme |
|
customer_only | Whether you wish to restrict the results to reviews of CityGrid Media customers | No | true | false | true |
|
rating | The minimal rating for the reviews | No | Positive integer between 1 and 10 inclusive |
| 4 | For example, supplying 4 will restrict the response to reviews with a rating of 4 or better. If this parameter is omitted, the result set will not be filtered by rating. |
days | The maximum age in days for the reviews | No | Positive integer |
| 25 | For example, supplying 14 will restrict the results to reviews which have been posted within the last 14 days. |
rpp | The maximum number of results to be returned. | No | Positive integer between 1 and 50 inclusive | 20 | 6 |
|
format | The desired format for the results | No | json | xml | json | json = javascript object notation, xml = extensible markup language, pbuf = Google's Protocol Buffers |
placement | An optional property for storing additional information you would like CityGrid Media to log for this view | No |
|
| sem_google | For example: if you run a search engine marketing campaign for Google and Yahoo!, you can set the placement property to "sem_google" or "sem_yahoo". Alternatively, if you publish CityGrid listings in different locations in your own site, you can set the placement property to values such as "home_page" or "search" (all up to you). CityGrid will organize reports for you by placement. |
callback | The name of (your own) JavaScript function that you would like to wrap your JSON response. | No |
|
| display |
|
i | An optional property for grouping API calls for tracking purposes (the parameter name is short for "impression_id") | No |
|
|
| The value should be set when making subsequent calls that are related to a previously made call. The user should never supply their own generated value for the impression_id. |
review_type | A filter to only return a certain type of review | No | editorial_review |
| editorial_review |
|
sort | An optional property to order the reviews . | No | createdate |
| createdate | The createdate sort option sorts by the date in descending order (newer first) the review was written. |
LatLon Usage Examples
The following table provides some example uses and their corresponding URL with query parameters. Click on the links to try them out.
...