Connect Data Legion to Zapier using the Webhooks by Zapier app. This lets you call person and company enrichment APIs from any Zap.
Prerequisites
- A Zapier account (Webhooks by Zapier requires a paid plan)
- A Data Legion API key
Person Enrichment Setup
Add the Webhooks Action
In your Zap, add a new action step. Search for Webhooks by Zapier and select the Custom Request event.
Use Custom Request instead of the POST event. Custom Request lets you set custom headers (needed for API key authentication) and send raw JSON in the body.
Set the following fields:
| Field | Value |
|---|
| Method | POST |
| URL | https://api.datalegion.ai/person/enrich |
See the Person Enrichment API reference for the full list of available fields.
Add two headers:
| Key | Value |
|---|
Content-Type | application/json |
API-Key | Your Data Legion API key |
Data
Set Payload Type to Raw and enter the JSON body in the Data field:
{
"email": "jane.doe@example.com"
}
To use data from a previous step in your Zap (for example, an email from a new CRM contact trigger), click the Data field and select the field from the dropdown. Zapier inserts a placeholder that gets replaced with the actual value at runtime.
For a Custom Request with raw JSON, build the JSON string with Zapier field references inserted where needed. For example, if the trigger provides an email field, the data field would look like:
{"email": "{{trigger_email}}"}
where {{trigger_email}} is the mapped field from your trigger step (the actual field reference appears as a pill in the Zapier editor).
You can add more input fields to improve match accuracy:
{
"email": "jane.doe@example.com",
"first_name": "Jane",
"last_name": "Doe",
"company": "Acme Corp",
"birth_date": "1985-03-15"
}
To limit the response to specific fields, add include_fields to the body:
{
"email": "jane.doe@example.com",
"include_fields": "full_name,job_title,seniority_level,company_name,company_size,company_industry,work_email,mobile_phone,linkedin_url,city,state"
}
See the Person Enrichment API reference for all supported input fields.
Response Handling
Zapier automatically parses the JSON response. The API returns:
{
"matches": [
{
"person": {
"full_name": "jane doe",
"job_title": "senior product manager",
"seniority_level": "senior",
"company_name": "tech company",
"work_email": "jane.doe@techcompany.com",
"mobile_phone": "+15551234567",
"linkedin_url": "https://www.linkedin.com/in/janedoe"
},
"match_metadata": {
"matched_on": ["email"],
"match_type": "exact",
"match_confidence": "high"
}
}
],
"total": 1
}
In subsequent steps, reference response fields using the path from the Webhooks step output. After testing the step, Zapier shows the parsed fields and you can map them by name:
| Field Path | Description |
|---|
matches__0__person__full_name | Full Name |
matches__0__person__job_title | Job Title |
matches__0__person__seniority_level | Seniority |
matches__0__person__company_name | Company |
matches__0__person__company_size | Company Size |
matches__0__person__company_industry | Industry |
matches__0__person__work_email | Work Email |
matches__0__person__mobile_phone | Phone |
matches__0__person__linkedin_url | LinkedIn URL |
If the email doesn’t match any records, the API returns HTTP 404. Use Zapier’s Paths or Filter steps to handle no-match responses and continue the Zap.
Test
Click Test step to send a test request. Verify that the response fields appear correctly in the output, then continue building your Zap.
Company Enrichment Setup
The same approach works for company enrichment. Use the Company Enrich endpoint:
https://api.datalegion.ai/company/enrich
The request body takes a domain, name, LinkedIn ID, or ticker symbol. Add include_fields to limit the response:
{
"domain": "example.com",
"include_fields": "name,domain,legion_employee_count,industry"
}
In subsequent steps, reference company fields from matches__0__company (e.g., matches__0__company__legion_employee_count).
See the Company Enrichment API reference for all supported input and output fields.
A common pattern: trigger on new contacts, enrich them, and update the CRM record.
- HubSpot > New Contact (or Salesforce, Pipedrive, etc.) — triggers when a new contact is created
- Webhooks by Zapier > Custom Request — calls
POST /person/enrich with the contact’s email
- HubSpot > Update Contact — writes enriched fields (title, company, phone, LinkedIn) back to the contact record
Rate Limits
The Data Legion API returns rate limit headers on every response (RateLimit-Remaining, RateLimit-Reset). Zapier runs Zap steps sequentially, so rate limits are rarely hit for trigger-based Zaps. For bulk operations using Zapier’s Transfer tool, monitor your API plan limits when processing large datasets.
See Rate Limiting for details.