API v3 is live and in beta: expect possible malfunctions and breaking changes in the coming days. If you find a bug, please report it to your Sillage contact.

Enrich a client's lead

Look up the email or the phone number of a lead.

Starts a lookup for the email, the phone number, or both, of one lead. The lookup runs in the background: the answer only says what was started. Read the result later with Get a lead or Query leads.

Route

POST/api/v3/partner/workspaces/{partner_workspace_id}/leads/{lead_id}/enrich

Path parameters

ParameterTypeDescription
partner_workspace_idstringYour own ID for the client workspace, as you chose it at creation. URL-encode it in the path.
lead_idintegerID of the lead.

Body parameters

ParameterTypeDescription
fieldsarray of stringsWhat to look up: email, phone, or both. At least one is required and a value cannot be repeated.

Example request

curl -X POST "https://api.getsillage.com/api/v3/partner/workspaces/ws_123/leads/123/enrich" \
  -H "Authorization: Bearer $SILLAGE_MASTER_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "fields": ["email", "phone"]
}'

Success response

Status: 202 Accepted

{
  "data": {
    "id": 123,
    "email": { "status": "pending" },
    "phone": { "status": "completed" }
  }
}

Response fields

FieldTypeDescription
data.idintegerID of the lead.
data.emailobject or nullAlways present. null when email was not requested; otherwise its status is pending or completed.
data.phoneobject or nullAlways present. null when phone was not requested; otherwise its status is pending or completed.

A field is completed at once when the lead already has that value, or when Sillage could fill it in without a new lookup. A field is pending when a lookup is running, including one you started earlier. Sending the same request again never starts a second lookup nor invoices more while a lookup is pending or done. A field whose last lookup failed can be asked for again: that starts a new lookup.

Billing

Enrichment is charged like the rest of the client's usage: invoiced to you, or paid from your prepaid credit pool if you have one. If you are invoiced, the request is never refused for lack of credits. Only lookups that find something are invoiced. When a lookup finds nothing, or when a lookup cannot be started, nothing is invoiced. See Usage for the charges, which appear with scope email_enrichment or phone_enrichment.

Check the result

Poll Get a lead (or Query leads for many leads at once) until enrichment_status leaves pending; some lookups can take hours. The email and phone fields hold the values found, and enrichment_status says where each lookup stands. pending means the lookup is still running. completed means the value was found and is on the lead. failed means nothing was found or the lookup ended in an error; nothing is invoiced. Stop polling once the field is no longer pending.

Errors

StatusMeaning
401The master key is missing or invalid.
402Your Sillage credit pool does not have enough credits for these lookups. Ask Sillage to add credits to your pool. Nothing was started (insufficient_credits). Only happens when you are billed from a prepaid credit pool.
404No workspace found for this partner_workspace_id, or the lead does not exist.
422The lead_id is not valid, fields is missing, empty, repeats a value or holds a value other than email or phone, or the body contains a key other than fields.
429Rate limit exceeded.
500An unexpected server error occurred.

Error responses use RFC 9457 problem documents with Content-Type: application/problem+json. type is always about:blank; code tells one problem from another, detail says what went wrong this time, and errors names the field at fault.

On this page