GET Requests

Data type:

URLs:

Base Company; Clean Employee; Base Employee; Base Jobs

https://api.coresignal.com/cdapi/v2/data_requests/{data_request_id}/files https://api.coresignal.com/cdapi/v2/data_requests/{data_request_id}/files/{file_name}


Overview

Send a GET request to each of the specified GET endpoints to retrieve data in bulk:

  1. Make a query in the /v2/data_requests/{data_request_id}/files endpoint to see the status of your data request. Collect the file name to use further.

  2. Collect the data request ID and the file name. Make a query in the /v2/data_requests/{data_request_id}/files/{file_name} endpoint and download the data in a JSON.gz file.

You can download the prepared dataset as many times as you like within 30 days of the query submission.


Instructions

GET the file name

Send a GET request to the endpoint /v2/data_requests/{data_request_id}/files to see the status of your data request.

Endpoint usage

  1. Take the data request ID (obtained from any of the POST endpoints). Paste it in the following cURL request instead of {request_id} and your API Key instead of {API Key}:

Request body template
curl -X 'GET' \
'https://api.coresignal.com/cdapi/v2/data_requests/{data_request_id}/files' \
-H 'accept: application/json' \
-H 'apikey: {API Key}'
  1. Import the cURL request to any API-compatible application.

  2. Send the request.

  • If you do not see a file name, the data request is not ready. Send the request again until you can see the file name.

  1. Retrieve the file name.

File name example
{
  "data_request_files": [
    "json/part-00000-2c3d41c2-99c2-43ff-a39c-7ad7h63h7cd9-h000.json.gz"
  ]
}
  • Each JSON.gz file contains a maximum of 10,000 JSON records. Requests that exceed the limit will be rejected.

Insufficient credits

The following message indicates that your query is too expensive.

Try adding "limit": {integer} parameter to your query.

Insufficient credits
{
    "detail": "Insufficient credits"
}

GET the file

Request downloadable files by making a GET request to the /v2/data_requests/{data_request_id}/files/{file_name} endpoint.

Endpoint usage

  1. Paste the data request ID and file name in the following template. Use your API Key instead of {API Key}:

Request body template
curl -X 'GET' \
'https://api.coresignal.com/cdapi/v2/data_requests/{data_request_id}/files/{file_name}' \
  -H 'accept: application/json' \
  -H 'apikey: {API Key}'

The data request ID is obtained via the POST requests. The file name is obtained using the data request ID in the /v2/data_requests/{data_request_id}/files endpoint.

  1. Import the cURL to any API-compatible application.

  2. Send the request

  3. Download the data

Check for similar methods to retrieve the file using other API-compatible applications.

Last updated

Was this helpful?