Skip to content

Commit

Permalink
update docs to be MZ places specific
Browse files Browse the repository at this point in the history
  • Loading branch information
botsonfirst committed Sep 20, 2017
1 parent 39e2ea2 commit 63f1711
Show file tree
Hide file tree
Showing 14 changed files with 78 additions and 78 deletions.
2 changes: 1 addition & 1 deletion docs/errors.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
In addition to any already [assigned HTTP status codes](https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml) The Who's On First API assigns specific meaning to certain codes and defines the following additional status codes for representing errors or a failure scenario, across all API methods:
In addition to any already [assigned HTTP status codes](https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml) The Mapzen Places API assigns specific meaning to certain codes and defines the following additional status codes for representing errors or a failure scenario, across all API methods:

<a name="mapzen"></a>
### Mapzen errors
Expand Down
18 changes: 9 additions & 9 deletions docs/formats.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ The default response format is [JSON](formats.md#json).
#### Example request

```
curl -X GET 'https://whosonfirst-api.mapzen.com/?method=whosonfirst.places.getInfoMulti&api_key=your-mapzen-api-key&ids=101712565,101712563&format=chicken'
curl -X GET 'https://places.mapzen.com/v1/?method=mapzen.places.getInfoMulti&api_key=your-mapzen-api-key&ids=101712565,101712563&format=chicken'
```

#### Example response
Expand Down Expand Up @@ -55,7 +55,7 @@ CSV (Comma Separated Value)
#### Example request

```
curl -X GET 'https://whosonfirst-api.mapzen.com?method=whosonfirst.places.search&api_key=your-mapzen-api-key&q=poutine&page=1&per_page=1&format=csv'
curl -X GET 'https://places.mapzen.com/v1?method=mapzen.places.search&api_key=your-mapzen-api-key&q=poutine&page=1&per_page=1&format=csv'
```

#### Example response
Expand All @@ -67,7 +67,7 @@ curl -X GET 'https://whosonfirst-api.mapzen.com?method=whosonfirst.places.search
< Date: Tue, 28 Feb 2017 21:13:37 GMT
< Status: 200 OK
< X-api-pagination-cursor:
< X-api-pagination-next-query: method=whosonfirst.places.search&amp;q=poutine&amp;extras=geom%3Abbox&amp;per_page=1&amp;page=2&amp;format=csv
< X-api-pagination-next-query: method=mapzen.places.search&amp;q=poutine&amp;extras=geom%3Abbox&amp;per_page=1&amp;page=2&amp;format=csv
< X-api-pagination-page: 1
< X-api-pagination-pages: 13
< X-api-pagination-per-page: 1
Expand All @@ -93,7 +93,7 @@ GeoJSON is a data-interchange format based on JavaScript. For more details, cons
#### Example request

```
curl -X GET 'https://whosonfirst-api.mapzen.com?method=whosonfirst.places.getInfoMulti&api_key=your-mapzen-api-key&&ids=101712565,101712563&format=geojson'
curl -X GET 'https://places.mapzen.com/v1/?method=mapzen.places.getInfoMulti&api_key=your-mapzen-api-key&&ids=101712565,101712563&format=geojson'
```

#### Example response
Expand Down Expand Up @@ -173,7 +173,7 @@ JSON (JavaScript Object Notation) is a data-interchange format based on JavaScri
#### Example request

```
curl -X GET 'https://whosonfirst-api.mapzen.com?method=whosonfirst.places.search&api_key=your-mapzen-api-key&q=poutine&page=1&per_page=1&format=json'
curl -X GET 'https://places.mapzen.com/v1/?method=whosonfirst.places.search&api_key=your-mapzen-api-key&q=poutine&page=1&per_page=1&format=json'
```

#### Example response
Expand All @@ -185,7 +185,7 @@ curl -X GET 'https://whosonfirst-api.mapzen.com?method=whosonfirst.places.search
< Date: Tue, 28 Feb 2017 22:29:49 GMT
< Status: 200 OK
< X-api-pagination-cursor:
< X-api-pagination-next-query: method=whosonfirst.places.search&amp;q=poutine&amp;extras=geom%3Abbox&amp;per_page=1&amp;page=2
< X-api-pagination-next-query: method=mapzen.places.search&amp;q=poutine&amp;extras=geom%3Abbox&amp;per_page=1&amp;page=2
< X-api-pagination-page: 1
< X-api-pagination-pages: 13
< X-api-pagination-per-page: 1
Expand All @@ -195,7 +195,7 @@ curl -X GET 'https://whosonfirst-api.mapzen.com?method=whosonfirst.places.search
<
{
"cursor": null,
"next_query": "method=whosonfirst.places.search&q=poutine&extras=geom%3Abbox&per_page=1&page=2",
"next_query": "method=mapzen.places.search&q=poutine&extras=geom%3Abbox&per_page=1&page=2",
"page": 1,
"pages": 13,
"per_page": 1,
Expand Down Expand Up @@ -227,7 +227,7 @@ As in a Who's On First "meta" file. A meta file is really just a CSV file with a
#### Example request

```
curl -X GET 'https://whosonfirst-api.mapzen.com?method=whosonfirst.places.search&api_key=your-mapzen-api-key&q=poutine&page=1&per_page=1&format=meta'
curl -X GET 'https://places.mapzen.com/v1/?method=mapzen.places.search&api_key=your-mapzen-api-key&q=poutine&page=1&per_page=1&format=meta'
```

#### Example response
Expand All @@ -239,7 +239,7 @@ curl -X GET 'https://whosonfirst-api.mapzen.com?method=whosonfirst.places.search
< Date: Tue, 28 Feb 2017 22:25:13 GMT
< Status: 200 OK
< X-api-pagination-cursor:
< X-api-pagination-next-query: method=whosonfirst.places.search&amp;q=poutine&amp;extras=geom%3Abbox&amp;per_page=1&amp;page=2&amp;format=meta
< X-api-pagination-next-query: method=mapzen.places.search&amp;q=poutine&amp;extras=geom%3Abbox&amp;per_page=1&amp;page=2&amp;format=meta
< X-api-pagination-page: 1
< X-api-pagination-pages: 13
< X-api-pagination-per-page: 1
Expand Down
8 changes: 4 additions & 4 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<a name="intro"></a>
The Who's On First API allows developers (and robots) programmatic access to query and retrieve Who's On First data via a [REST-ish](#cgi) interface.
The Mapzen Places API allows developers (and robots) programmatic access to query and retrieve Who's On First data via a [REST-ish](#cgi) interface.

API methods are dispatched over `HTTP` with one or more query parameters and data is returned in response as [JSON](formats.md#json) by default but you may also specify [CSV](formats.md#csv) or Who's On First's own [meta](formats.md#meta) formatted responses for certain [API methods](methods.md).

The endpoint for the Who's On First API is: **[https://whosonfirst-api.mapzen.com/](https://whosonfirst-api.mapzen.com/)**
The endpoint for the Mapzen Places API is: **[https://places.mapzen.com/v1/](https://places.mapzen.com/v1/)**

All errors are returned using [HTTP status codes](errors.md) in the `400-599` range.

Expand All @@ -18,12 +18,12 @@ Which is to say: The point is for _the thing to work_ but there are probably sti

Also some methods are "more beta" than others. These methods are flagged as being `experimental` which means that both either their inputs or their outputs _may_ change without warning. We'll try not to introduce any backwards incompatible changes but you should approach these API methods defensively.

Finally the API is not feature complete yet. The easiest way to think about the Who's On First API is to look at the Who's On First [Spelunker]() website and imagine that anything you can do there to search and navigate all those places should also be possible via the API. As of this writing it is not but we'll get there. If there is anything currently missing that you'd like or need to do sooner than later [send up a flare](https://twitter.co/alloftheplaces) and we'll see about adding it to the list.
Finally the API is not feature complete yet. The easiest way to think about the Mapzen Places API is to look at the Who's On First [Spelunker](https://whosonfirst.mapzen.com/spelunker/) website and imagine that anything you can do there to search and navigate all those places should also be possible via the API. As of this writing it is not but we'll get there. If there is anything currently missing that you'd like or need to do sooner than later [send up a flare](https://twitter.co/alloftheplaces) and we'll see about adding it to the list.

<a name="keys"></a>
### API Keys

To use the Who's On First API, you should [first obtain a free developer API key](https://mapzen.com/documentation/overview/).
To use the Mapzen Places API, you should [first obtain a free developer API key](https://mapzen.com/documentation/overview/).

<a name="rate_limits"></a>
### Rate limits
Expand Down
Loading

0 comments on commit 63f1711

Please sign in to comment.