Skip to content
Wille Marcel edited this page Dec 11, 2018 · 8 revisions

How to use the OSMCha API

Our API is very useful when you need other software to process the OSMCha data. Check some instructions on how to start using it.

Filtering changesets

Go to the Filters page, and fill the desired filter parameters to search for changesets. Apply the search to check the results. If it gave you the results that you wanted, save the filter.

Getting the token

Go to your OSMCha user page and copy your Token.

Reaching the API

Open another tab in your browser, access https://osmcha.mapbox.com/api-docs/#!/aoi/aoi_read and click on the Authorize button. Paste Token <the_token_code_you_copied_from_your_user_page> and click on the authorize button.

Go back to the other OSMCha tab and copy the id of the filter that you saved (it's available on the tab URL or on the Saved Filters section of your user page. Paste it in the id field of the get /api/v1/aoi/{id}/ section.

Using other software to reach the API

  • curl

curl -X GET --header 'Accept: application/json' --header 'Authorization: Token <your-token>' 'https://osmcha.mapbox.com/api/v1/aoi/<aoi_id>/'

Clone this wiki locally