Python client for FullEnrich API - Enrich LinkedIn profiles with contact information
Project description
FullEnrich Client
Python client for the FullEnrich API - Enrich LinkedIn profiles with contact information (emails and phone numbers).
Installation
pip install fullenrichclient
Quick Start
from fullenrich import FullEnrich
# Initialize with API key (or set FULLENRICH_API_KEY env var)
client = FullEnrich(api_key="your-api-key")
# Enrich a single LinkedIn profile
response = client.enrich("https://www.linkedin.com/in/username/")
print(f"Enrichment ID: {response.enrichment_id}")
# Wait for results
result = client.wait_for_enrichment(response.enrichment_id)
print(result.results)
Usage
Environment Variables
Set your API key via environment variable (supports .env files):
export FULLENRICH_API_KEY=your-api-key
Then use without passing the key:
client = FullEnrich()
Check Credit Balance
credits = client.get_credits()
print(f"Balance: {credits.balance}")
Enrich Single Profile
response = client.enrich("https://www.linkedin.com/in/username/")
Enrich Multiple Profiles
urls = [
"https://www.linkedin.com/in/user1/",
"https://www.linkedin.com/in/user2/",
"https://www.linkedin.com/in/user3/",
]
response = client.enrich(urls)
With Webhook
response = client.enrich(
linkedin_urls="https://www.linkedin.com/in/username/",
webhook_url="https://your-webhook.com/callback"
)
Select Specific Fields
from fullenrich import FullEnrich, EnrichField
client = FullEnrich()
# Using enum
response = client.enrich(
"https://www.linkedin.com/in/username/",
enrich_fields=[EnrichField.EMAILS]
)
# Using strings
response = client.enrich(
"https://www.linkedin.com/in/username/",
enrich_fields=["contact.emails", "contact.personal_emails"]
)
Available fields:
EnrichField.EMAILS/"contact.emails"- Work emailsEnrichField.PERSONAL_EMAILS/"contact.personal_emails"- Personal emailsEnrichField.PHONES/"contact.phones"- Phone numbers
Enrich by Name/Domain (Without LinkedIn URL)
from fullenrich import FullEnrich, EnrichmentRequest, EnrichField
client = FullEnrich()
requests = [
EnrichmentRequest(
firstname="John",
lastname="Doe",
domain="example.com",
enrich_fields=[EnrichField.EMAILS, EnrichField.PHONES],
),
EnrichmentRequest(
firstname="Jane",
lastname="Smith",
company_name="Acme Inc",
),
]
response = client.enrich_batch(requests)
With Custom Data (for CRM integration)
response = client.enrich(
"https://www.linkedin.com/in/username/",
custom={"crm_contact_id": "123", "user_id": "456"}
)
# Or with enrich_batch for per-person custom data
requests = [
EnrichmentRequest(
linkedin_url="https://www.linkedin.com/in/user1/",
custom={"crm_id": "001"}
),
EnrichmentRequest(
linkedin_url="https://www.linkedin.com/in/user2/",
custom={"crm_id": "002"}
),
]
response = client.enrich_batch(requests)
Enrich and Wait (Convenience Method)
# Start enrichment and wait for results in one call
result = client.enrich_and_wait(
"https://www.linkedin.com/in/username/",
max_attempts=30,
poll_interval=10
)
print(result.results)
Check Enrichment Status
result = client.get_enrichment("enrichment-id")
print(f"Status: {result.status}")
Reverse Email Lookup
Find LinkedIn profiles from email addresses:
# Single email
response = client.reverse_lookup("john@example.com")
# Multiple emails
response = client.reverse_lookup([
"john@example.com",
"jane@example.com"
])
# With webhook
response = client.reverse_lookup(
"john@example.com",
webhook_url="https://your-webhook.com/callback"
)
# Wait for results
result = client.wait_for_reverse_lookup(response.reverse_id)
print(result.datas)
# Or use the convenience method
result = client.reverse_lookup_and_wait("john@example.com")
Context Manager
with FullEnrich() as client:
result = client.enrich_and_wait("https://www.linkedin.com/in/username/")
print(result.results)
API Reference
FullEnrich
Main client class.
Constructor:
api_key(str, optional): API key. Defaults toFULLENRICH_API_KEYenv var.base_url(str, optional): Custom API base URL.timeout(float, optional): Request timeout in seconds. Default: 30.0
Account Methods:
get_credits()- Get current credit balance
Enrichment Methods:
enrich(linkedin_urls, enrich_fields, name, webhook_url, custom)- Start enrichment by LinkedIn URLenrich_batch(requests, name, webhook_url)- Start enrichment with full control (name/domain lookup, custom data)get_enrichment(enrichment_id)- Get enrichment status/resultswait_for_enrichment(enrichment_id, max_attempts, poll_interval)- Poll until completeenrich_and_wait(...)- Convenience method combining enrich + wait
Reverse Lookup Methods:
reverse_lookup(emails, name, webhook_url)- Find LinkedIn profiles from emailsget_reverse_lookup(reverse_id)- Get reverse lookup status/resultswait_for_reverse_lookup(reverse_id, max_attempts, poll_interval)- Poll until completereverse_lookup_and_wait(...)- Convenience method combining reverse_lookup + wait
EnrichmentRequest
For advanced enrichment requests:
linkedin_url- LinkedIn profile URLfirstname- First name (for name/domain lookup)lastname- Last name (for name/domain lookup)domain- Company domain (for name/domain lookup)company_name- Company name (for name/domain lookup)enrich_fields- List of fields to enrichcustom- Custom data dict (max 20 string entries)
EnrichField
Enum of available fields:
EnrichField.EMAILS- Work emailsEnrichField.PERSONAL_EMAILS- Personal emailsEnrichField.PHONES- Phone numbers
EnrichmentStatus
PENDING,PROCESSING,FINISHED,FAILED
ReverseStatus
CREATED,IN_PROGRESS,CANCELED,CREDITS_INSUFFICIENT,FINISHED,RATE_LIMIT,UNKNOWN
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fullenrichclient-0.1.0.tar.gz.
File metadata
- Download URL: fullenrichclient-0.1.0.tar.gz
- Upload date:
- Size: 9.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d0305bc6c8f8b018f424fc566cf54c7b39b27edfd63861f2de283ece98d9862d
|
|
| MD5 |
2db2c2901eedc515b93432160677befd
|
|
| BLAKE2b-256 |
2c6ae8b18546e42d5fcbf74bf47f8c173300b9af71e9adfe9fa7f6e1419054f9
|
File details
Details for the file fullenrichclient-0.1.0-py3-none-any.whl.
File metadata
- Download URL: fullenrichclient-0.1.0-py3-none-any.whl
- Upload date:
- Size: 8.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8c1836ba5930c0ff1c722e570a643c36fadbb9b8a64adfd6265dc4c4a48e2db1
|
|
| MD5 |
2150b15b77f4220b6538a56025e475b5
|
|
| BLAKE2b-256 |
7de22b95d86ca20afb2cd43559b7031e2197c119f280d4d01465d16296d52bc1
|