Translating a Search URL into an API Query

If you have a search query on the Clearinghouse website that you'd like to translate into an equivalent API query, grab the url link from the search bar.

For example, if I did a search on 'Policing' case types and the 'Occupy' special collection, you would do the following on the website:

Take a look at the search bar and you will see the following url:

https://clearinghouse.net/search/case/?case_type=5039&special_collection=5658&ordering=-summary_approved_date

The important thing to notice is case_type=5039 and special_collection=5658in the url. If you look up the Case Type Endpoint and Special Collection Endpoint, you will see 5039 correlates to Policing and 5658 correlates to Occupy. This can be translated into the following API query:

https://clearinghouse.net/api/v1/case?case_type=5039&special_collection=5658

Last updated