API Documentation
Generate your API key on the Claude Agent page of your Deeplead account. The same key works for the REST endpoints below and for the MCP endpoint that connects Claude and other AI agents.
MCP endpoint for AI agents
POST https://deeplead.io/api/mcp speaks the Model Context Protocol (Streamable HTTP) and exposes your account as tools: find businesses, save contacts, create and start campaigns, read replies. Send the key as Authorization: Bearer YOUR_API_KEY, or use https://deeplead.io/api/mcp/YOUR_API_KEY for clients that cannot send headers. The Claude Agent page has copy-and-paste setup for Claude.ai, Claude Desktop and Claude Code.
Authentication
All requests are authenticated with your API key as a Bearer token. Requests without a valid key, or from accounts without an active subscription, are rejected with 401 Unauthorized.
Authorization: Bearer YOUR_API_KEYFetch Business Finder Leads
Searches local businesses for a niche in a given city, adds them as contacts to your Deeplead account and returns them in the response. Results are deduplicated by email against your existing contacts.
POST https://deeplead.io/api/v1/niche-finder-leadsRequest Body
| Field | Type | Required | Description |
|---|---|---|---|
niche | string | yes | The business niche to search for, e.g. “dentist” or “roofing company”. |
city | string | yes | The city to search in, e.g. “Austin”. |
count | integer | no | Number of leads to fetch, between 1 and 1000. Defaults to 100. |
metaAds | boolean | no | Only include businesses with (true) or without (false) a Meta pixel on their website. |
tiktokPixel | boolean | no | Only include businesses with (true) or without (false) a TikTok pixel on their website. |
gAnalytics | boolean | no | Only include businesses with (true) or without (false) Google Analytics on their website. |
The pixel filters (metaAds, tiktokPixel, gAnalytics) are based on our own scan of each business’s website. The scan detects tracking codes embedded directly in the page as well as ones loaded through Google Tag Manager containers, so it finds more pixels than a simple check of the page source. Passing false returns only businesses whose website we scanned and found clean — businesses without a scannable website are excluded rather than treated as not tracking.
Example Request
curl -X POST https://deeplead.io/api/v1/niche-finder-leads \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"niche": "dentist",
"city": "Austin",
"count": 100,
"metaAds": true
}'Response
On success the endpoint returns the fetched contacts and the number of credits charged. Each contact includes the business name, address, website, email addresses, phone numbers, social profiles, detected tracking pixels and Google Business categories where available.
{
"contacts": [
{
"businessName": "Smile Dental Austin",
"address": "123 Congress Ave, Austin, TX 78701",
"website": "https://smiledentalaustin.com",
"email": "office@smiledentalaustin.com",
"emails": ["office@smiledentalaustin.com"],
"phone": "+15125550142",
"phone_numbers": ["+15125550142"],
"instagram": "https://instagram.com/smiledentalaustin",
"facebook": "https://facebook.com/smiledentalaustin",
"linkedin": null,
"tiktok": null,
"fbPixel": true,
"tikTokPixel": false,
"gAnalytics": true,
"googleBusinessCategories": ["Dentist", "Cosmetic dentist"]
}
],
"chargedCredits": 87
}Fetching large lead counts can take several minutes, so make sure your HTTP client uses a generous timeout.
Credits
Each lead costs one credit from your Deeplead account. Credits are only charged for contacts that were actually added to your account: if fewer leads are found than requested, or some are duplicates of existing contacts, the difference is refunded automatically. If the request fails, no credits are charged.
Error Responses
| Status | Meaning |
|---|---|
400 | Invalid request body, or the city could not be resolved to a location. |
401 | Missing or invalid API key, or the account is not active. |
402 | Not enough credits for the requested lead count. |
404 | No businesses found for the given niche and city. |
500 | The contacts could not be saved. No credits are charged. |
Getting Access
Every active Deeplead account can generate a key on the Claude Agent page. Questions go to support@deeplead.io.