Skip to main content
The endpoint for the person search api is https://api.peopledatalabs.com/v5/person/search.

Person Search API Access and Billing.

We charge per record retrieved. Each person record in the “data” array of the response counts as a single “credit” against your total package.

Usage

PDL’s Search API is perfect for finding specific segments of people that you need in order to power your projects and products. This product gives you direct access to query our full API dataset. There are many degrees of freedom which allow you to find any kind of person(s) with a single query.

Requests

See Authentication and Requests to see possible ways to input requests. We recommend using a JSON object to capture request parameters and will do so in the examples below.

Rate Limiting

The current default rate limit is 10 requests per minute.

Input Parameters

Response

The HTTP Response code will be 200 for any valid request, regardless of whether records were found for your query or not. For that reason, pay close attention to the “total” value in your response object to understand query success. Each person record in the “data” array of the response counts as a single “credit” against your total package - this value has a maximum of one record by default to prevent happy accidents.

Response Fields

Abridged 200 Response Example (full example here):

Building a Query

It is required to provide a value for either the query parameter or the sql parameter in order to receive a successful response. The query value should align directly with the Elasticsearch DSL. SQL queries are executed using Elasticsearch SQL. Most typical query types are available but some are excluded. For all available query types see here. When an API request is executed, the query is run directly against our API dataset without doing any additional cleaning or pre-processing. This means that you have a ton of freedom to explore the dataset and return the perfect records. It also means that understanding the available fields can be very helpful to making successful queries. Field descriptions can be found here and the Elasticsearch mapping underlying this api can be found here. To help you identify how to best query for specific sub-entities (schools, companies, and locations), we offer a suite of enrichment APIs for these sub-entities called the Cleaner APIs

Walkthroughs

All code is Python, cURL, JavaScript and Ruby.

Basic Usage

“I want to make a query and save the results to a file.”

Using POST Requests

“I would like to use POST requests to query instead of GET requests so that I can make queries with a lot of parameters”
Difference between GET and POST requestsSee here for a comparison of the practical differences between GET and POST requests. Perhaps most practically, POST requests do not have any limit on the amount of data that can be passed in the request.

Searching Specific Datasets

“I want to run a simple query against PDL’s phone dataset
Maintaining Backwards CompatibilityThe dataset parameter was introduced with the July 2021 release, which also changed the default dataset from all to resume. For users that want to maintain the same performance in their queries prior to this change, set the dataset parameter to all as shown in the example below.

Excluding Datasets

“I want to run a simple query against all PDL datasets except the email and phone datasets”

Bulk Retrieval

“I want to pull all the current employees at Amazon and save their profiles to a csv file.”
High Credit Usage Code BelowThe code example below illustrates pulling all the employee profiles in a large company, and is meant primarily for demonstrating the use of the scroll_token parameter when retrieving large amounts of records. As a result this code mostly illustrative meaning it can use up a lot of credits, and doesn’t have any error handling. The MAX_NUM_RECORDS_LIMIT parameter in the example below sets the maximum number of profiles (e.g. credits) that will be pulled, so please set that accordingly when testing this example.

Sales Prospecting

“I want to email engineering leaders at the following companies to reach out about my product: stripe.com, plaid.com, xignite.com, square.com.”

Recruiting

“I have a client looking for marketing managers and dishwashers in Oregon, but NOT in portland (don’t ask why). They want to reach out on LinkedIn, so they asked that each candidate have a Linkedin URL. I want as many people as PDL can give me matching this criteria.”

Ads

“I want to sell yachts to rich people via ads on Facebook.”

Customer Insights

“I want to discover some things about my biggest customer, Zenefits.”

Advanced Examples

I want to find X number of people at each company in my list

Query Limitations

The following Elasticsearch query types will be accepted: Most specialized options are disabled, such as boosting and custom scoring. No aggregations. Any SQL query that translates to the above available query types via the ES SQL translate API will be accepted. This means most basic SQL. No joins, groupbys, etc. Any array found in the query (such as a terms array) will have a hard limit of 100 elements. Any query containing an array surpassing this limit will be rejected.

Full Example Response

JSON

Full Field Mapping

This section contains the Elasticsearch mapping for our full Person Schema indicating which fields have been indexed and made searchable through our Person Search API, along with the corresponding data type for the field.
JSON

All Field Descriptions

See this doc.