Explore common use cases and examples of how to use our API
Our API is REST based and authentication is via a bearer token in the header of the request, below is an example curl request.
For details on the other endpoints available please see our documentation here: https://product-api.thedatacity.com/api/documentation
ML List
The /companies/userList
endpoint takes one value which is the list ID from within the URL of the product e.g., https://products.thedatacity.com/v2/ml_list/?list_id=1234
curl -X 'GET' 'https://product-api.thedatacity.com/api/companies/userList/1234' -H 'Authorization: Bearer API_KEY
Filters
Within the platform you can apply filters to your list, be default these are not applied when using the API but you can enable them via the following query parameter.
curl -X 'GET' 'https://product-api.thedatacity.com/api/companies/userList/1234?includeFilters=true' -H 'Authorization: Bearer API_KEY
Pagination
By default you get 40 results per request, but you can increase this up to 1,000 per request, using the following query parameter.
Default: 40 records e.g.
https://product-api.thedatacity.com/api/companies/userList/1234
Return Count query parameter specified: up to 1,000 records e.g.
https://product-api.thedatacity.com/api/companies/userList/1234?returnCount=1000
The returnCount parameter can then be paired with the skip parameter, to allow you to paginate through the results e.g.
https://product-api.thedatacity.com/api/companies/userList/1234?returnCount=1000&skip=1000
Explore List
You can use the same format as above for Explore List, the only difference is the endpoint required. For an Explore list you would use:
curl -X 'GET' 'https://product-api.thedatacity.com/api/companies/exploreList/1234' -H 'Authorization: Bearer API_KEY