Guides
Contact enrichment
Find work emails and phone numbers for people, or domains, phones and LinkedIn pages for companies, a few at a time or in large batches.
Enrichment finds contact details for records you have already identified: an email address or phone number for a person, and a domain, phone number or LinkedIn page for a company. You send what you know about each record, name the fields you want, and pay only for values that are newly found.
There are two ways to ask, and they take the same request body:
| Use | When | Answer |
|---|---|---|
A lookup, POST /v1/enrichment/lookups | Up to 20 records, when you want the values in the same call. | 200 with the rows, once found or once the wait is over. |
A job, POST /v1/enrichment/jobs | Larger batches, up to 10,000 records, that you read when they finish. | 202 with a handle to poll. |
Both need the dsp.enrichment.write scope. Reading jobs needs dsp.enrichment.read or dsp.enrichment.write. Every field and error is in the enrichment reference.
What you can ask for#
entity says what the records are, and decides which fields you may ask for:
entity | Fields | Identify each record by |
|---|---|---|
contacts (default) | EMAIL, PHONE | linkedin_url, or person_id (an id from search), or a name (full_name, or first_name and last_name) with company_domain or company_name. |
accounts | DOMAIN, PHONE, LINKEDIN_URL | company_domain, company_name, the company's LinkedIn page as linkedin_url, or company_id. |
fields has no default, so nothing is looked up or charged that you did not ask for. An item may narrow the request with its own fields, a subset of the request's. external_id is your own id for the row, returned with it. A person field sent for accounts, or a company id sent for contacts, is refused with 422.
Prefer linkedin_url or person_id for people. A value already found for the same profile or record comes back free, while a row identified only by a name and a company is looked up, and charged, every time.
Look up a few records#
POSThttps://api.sproutsdata.ai/v1/enrichment/lookups
curl -X POST "https://api.sproutsdata.ai/v1/enrichment/lookups" \
-H "X-API-Key: $SPROUTS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"fields": ["EMAIL"],
"items": [{ "linkedin_url": "https://www.linkedin.com/in/jane-doe-example" }]
}'- Up to 20 items. For more, start a job.
wait_seconds(0 to 20) is how long the lookup may work before it answers with what it has. Left out, the API chooses, always within the request's time budget.- A lookup that does not finish in the call answers
complete: false. The rest goes on as a job whose id isjob_id: read it as a job (below) for the remaining rows. Rows still being looked up list their fields inincomplete. Idempotency-Keyis optional (up to 255 characters). Send it to retry safely: the same key returns the first answer and is not charged again.
Enrich a batch with a job#
POSThttps://api.sproutsdata.ai/v1/enrichment/jobs
A job takes up to 10,000 items and needs an Idempotency-Key (up to 255 characters): without one the request is refused with 400. Send one new key per job, and the same key only to retry it. A retry returns the first job with reused: true; the same key sent with a different body is 409 enrichment.idempotency_key_reused.
curl -X POST "https://api.sproutsdata.ai/v1/enrichment/jobs" \
-H "X-API-Key: $SPROUTS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"name": "Q4 prospects",
"fields": ["EMAIL", "PHONE"],
"items": [
{ "linkedin_url": "https://www.linkedin.com/in/jane-doe-example" },
{ "full_name": "Alex Example", "company_domain": "stripe.com" }
]
}'The answer is 202 with the job's job_id, status and total_rows. Then:
- Poll
GET /v1/enrichment/jobs/{job_id}untilstatusiscompleted,failedorcancelled. Along the way it reportscounts(rows done, and each field's rows by outcome),credits_usedso far and aneta_seconds. A job isqueued, thenrunning;cancellingwhile a cancel takes effect. - Page the rows with
GET /v1/enrichment/jobs/{job_id}/results, in the order you sent them.limitis 1 to 500 (default 100); whilehas_moreistrue, sendnext_cursorback ascursor. Rows can be read while the job runs. - Cancel with
POST /v1/enrichment/jobs/{job_id}/cancelif you need to stop it. Only values already found are charged. Cancelling is safe to repeat.
GET /v1/enrichment/jobs lists the workspace's jobs, newest first, and takes a status filter.
Reading a row#
Each row in a lookup or a job's results has:
idx: its position in theitemsyou sent, from 0.input: the item as you sent it.outcome:found,partial,not_found,error,cancelled,skippedorsuppressed.fields: one entry per field asked, each with astatus, thevaluewhen found,verified, and areasonwhen there is no value (no_source,sources_unavailable,not_found,not_enough_inputorerror).values_foundandcredits: the values newly found for this row, and what they cost.
Emails for contacts are verified according to verify_mode: skip, moderate (syntax, domain and the source's own signal) or strict (every email checked by a verifier). Left out, the workspace's setting applies.
re_enrich decides what happens to values already known. Off (the default), a value already found for the same LinkedIn profile or record comes back at no charge. On, it is looked up, and charged, again.
What it costs#
You pay per value newly found. A value already known for the same record is free, and so is a miss. These are the default prices, in credits:
| Field | Per value found |
|---|---|
EMAIL | 1 |
PHONE | 9 |
DOMAIN | 1 |
LINKEDIN_URL | 1 |
Before anything is looked up, the most the request could cost (every field of every item, each at its price) is held from the balance. If the balance cannot cover it, the answer is 402 with credits.insufficient and nothing is looked up. When the lookup or job ends, only the values found are charged and the rest of the hold is released. One job may hold at most 30,000 credits: a larger request is refused with 422, so split it or ask for fewer fields. For an estimate before you send, use POST /v1/credits/quote with operation: "enrichment", rows and fields (see Credits and usage).
A job's credits_charged is set once it has ended, and values_found counts the values charged for. A job can also be stopped by the API, with a stop_reason:
time_limit: still running 6 hours after it started.no_credits: the workspace could no longer cover it.
What it found until then is charged.
Do-Not-Contact records#
People and companies on the Do-Not-Contact list are never looked up or charged. A request that names some of them goes ahead without them, and their positions in items are listed in suppressed_rows. In a lookup's answer and a job's results, such a row reads outcome: "suppressed" with every field blanked. A row whose record joins the list after it was enriched reads the same way. A request in which every item is on the list is refused with 422.
Results expire#
A job's rows are kept for 7 days after it ends. After that, /results answers 410 with enrichment.results_expired: start a new job to enrich the records again.
Limits#
- More than 20 items in a lookup is refused: start a job instead.
- Too many lookups running for one caller, or too many open jobs in the workspace, answers
429withquota.burst_exceededandRetry-After. - Reads of jobs and their results count toward the higher polling limit (see Rate limits).