FlatSearch API Documentation
Find dealers, check companies, search the web and extract pages over one JSON API. Flat per-request pricing; no per-token charges.
/dealers/find/dealers/exportCheck companiesContact details and a public profile for a company domain, one at a time or up to 50 at once./company/enrich/company/enrich/batchSearch the webLinks and snippets, a cited answer, or multi-query research on a question./search/sources/search/fast/search/extendedExtract pagesAny public URL returned as clean, token-efficient Markdown./extractBuying a finished dealer report rather than building with the API?See the Competitor Dealer Map →
Base URL
https://flatsearchapi.com
Authentication
Every request must include your API key in the X-API-Key request header.
| Key Prefix | Environment | Behavior |
|---|---|---|
sp_live_... | Production | Full live search, deep enrichment, billed against your balance or subscription. |
sp_test_... | Developer Sandbox | Unbilled development queries. Returns live search results without deducting credits. |
1-Click IDE Onboarding
Integrate FlatSearch into Cursor, Claude Code, or GitHub Copilot in seconds. Copy our optimized integration prompt or launch via deep link:
# FlatSearch API — Complete Technical Reference
You are integrating the FlatSearch Live B2B Web & Dealer Intelligence API (https://flatsearchapi.com).
## Base URL
https://flatsearchapi.com
## Authentication
Every request requires:
- Content-Type: application/json
- X-API-Key: sp_live_... (Production) or sp_test_... (Developer Sandbox)
## 8 Production Endpoints Summary
1. POST /v1/dealers/find — Regional dealer discovery with direct phone verification & cited website evidence.
2. POST /v1/dealers/export — Streamed standardized CSV export formatted for Clay and Google Sheets.
3. POST /v1/company/enrich — Company profile: firmographics, SEC Form D, DNS MX records, and tech stack.
4. POST /v1/company/enrich/batch — Concurrent enrichment for up to 50 company domains.
5. POST /v1/search/fast — Synthesized search answer with inline source citations.
6. POST /v1/search/sources — Raw link & snippet extraction with normal and fast modes.
7. POST /v1/search/extended — Deep multi-query research with agentic intent verification.
8. POST /v1/extract — Clean token-efficient Markdown extraction from any public URL.
## Billing
Each plan includes a number of requests per endpoint group (search; research and dealers; pages and companies).
After that, each successful request is charged to the prepaid balance; with no balance left, requests return 403 USAGE_LIMIT_EXCEEDED.
Use exponential backoff (1s, 2s, 4s) when handling 429 or 503 HTTP responses.Rate Limits & Billing
Every plan includes a number of requests per endpoint group: 100 on Free, 50,000 on Developer and 300,000 on Scale. Once they are used, each successful request is charged to your prepaid balance at the rates below. With no balance left, requests return 403 USAGE_LIMIT_EXCEEDED. Included requests are a running total; they don't renew each month.
| Endpoint group | Endpoints | After included requests |
|---|---|---|
| Search | /search/sources, /search/fast | 1¢ per request |
| Research & dealers | /search/extended, /dealers/find, /dealers/export | 2¢ per request |
| Pages & companies | /extract, /company/enrich, /company/enrich/batch | 1¢ per 40 URLs or companies |
Requests per minute
| Endpoints | Free | Prepaid balance | Developer | Scale |
|---|---|---|---|---|
/search/fast, /search/sources, /extract | 20 | 60 | 150 | 300 |
/company/enrich, /company/enrich/batch | 30 | 60 | 150 | 300 |
/search/extended, /dealers/find, /dealers/export | 10 | 30 | 60 | 120 |
Limits apply per API key. Requests over the limit return 429 RATE_LIMIT_EXCEEDED; retry with exponential backoff. Test keys (sp_test_) aren't billed and follow the same limits. Plans and top-ups: API pricing.
Discovers regional dealers, distributors, and suppliers for a product category and location. Reads each company's own website, map listing, and DNS records, and returns the direct phone, street address with coordinates, and a cited website quote for each qualification. A request takes seconds to tens of seconds, depending on how many rows you ask for.
Request Parameters (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
query | string | Yes | Product vertical or dealer type (e.g. "industrial pump distributors"). |
location | string | No | Target city and state (e.g. "Houston, TX"). |
limit | integer | No | Max dealer results to return (default: 25, max: 50). |
custom_fields | object | No | Natural language qualification questions (e.g. {"stocks_goulds": "Does this company stock Goulds pumps?"}). |
Code Example
curl -X POST https://flatsearchapi.com/v1/dealers/find \
-H "Content-Type: application/json" \
-H "X-API-Key: sp_live_YOUR_KEY" \
-d '{
"query": "industrial pump distributors",
"location": "Houston, TX",
"limit": 10
}'Sample Response
{
"query": "industrial pump distributors",
"location": "Houston, TX",
"total_found": 1,
"dealers": [
{
"status": "success",
"schema_version": 3,
"domain": "airindustrialworks.com",
"name": "Air Industrial Works, LLC (Pumps in Stock)",
"phone": "(832) 301-3959",
"emails": ["[email protected]"],
"location": {
"verified_address": "5946 S Loop E, Houston, TX 77033, USA",
"street": "5946 S Loop E",
"city": "Houston",
"state": "TX",
"postcode": "77033",
"coordinates": { "lat": 29.6890756, "lng": -95.3296457 }
},
"ai_qualification": {
"icp_fit": "HIGH",
"fit_reason": "Stocking master distributor of industrial centrifugal, sump, and AODD diaphragm pumps with immediate Houston field dispatch."
},
"evidence": {
"phone": "https://airindustrialworks.com",
"source_urls": ["https://airindustrialworks.com/brands"]
},
"technographics": {
"email_provider": "Rackspace Hosted Email (mx2.emailsrvr.com)",
"detected_saas_tools": { "AI / LLMs": [], "Sales & CRM": ["QuickBooks Enterprise"] }
}
}
]
}Streams an agency-standard CSV with clean column headers directly formatted for 1-click import into Clay, Google Sheets, Instantly, and Smartlead.
Request Parameters (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
query | string | Yes | Product vertical or dealer type (e.g. "CNC tooling dealers"). |
location | string | No | Target location (e.g. "Chicago, IL"). |
limit | integer | No | Number of leads to stream in CSV (default: 25). |
Code Example
curl -X POST https://flatsearchapi.com/v1/dealers/export \
-H "Content-Type: application/json" \
-H "X-API-Key: sp_live_YOUR_KEY" \
-d '{
"query": "CNC tooling dealers",
"location": "Chicago, IL",
"limit": 50
}' \
--output chicago_tooling_dealers.csvMulti-source company enrichment. Pulls firmographics, SEC Form D fundraising filings, DNS mail infrastructure (Exchange / Google), detected software stack, and job board signals.
Request Parameters (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
domain | string | Yes* | Target domain (e.g. "fcxperformance.com"). |
name | string | No | Optional company name fallback if domain is unknown. |
location_hint | string | No | Optional geographic hint (e.g. "Dallas, TX"). |
Code Example
curl -X POST https://flatsearchapi.com/v1/company/enrich \
-H "Content-Type: application/json" \
-H "X-API-Key: sp_live_YOUR_KEY" \
-d '{"domain": "fcxperformance.com"}'Sample Response
{
"status": "success",
"domain": "fcxperformance.com",
"name": "FCX Performance",
"phone": "(214) 320-3604",
"location": {
"street": "9010 John W. Carpenter Fwy",
"city": "Dallas",
"state": "TX",
"country": "United States",
"coordinates": { "lat": 32.8264, "lng": -96.8822 }
},
"technographics": {
"email_provider": "Mimecast Secure Gateway",
"detected_saas_tools": {
"AI / LLMs": ["Anthropic (Claude Enterprise)"],
"Engineering & Product": ["Atlassian (Jira / Confluence)"]
}
},
"hiring_intent": {
"is_actively_hiring": true,
"active_postings_count": 14,
"departments": ["Field Engineering", "Inside Sales"]
}
}Enriches up to 50 companies concurrently. Domains enriched recently are served from cache.
Request Parameters (JSON)
| Field | Type | Required | Description |
|---|---|---|---|
companies | array of objects | Yes | Array of target companies (max 50). Each object requires {"domain": "..."}. |
Code Example
curl -X POST https://flatsearchapi.com/v1/company/enrich/batch \
-H "Content-Type: application/json" \
-H "X-API-Key: sp_live_YOUR_KEY" \
-d '{
"companies": [
{"domain": "elitepumps.net"},
{"domain": "gcpumpinc.com"},
{"domain": "airindustrialworks.com"}
]
}'Low-latency synthesized search for AI chatbots, customer support agents, and interactive research loops. Reads live web sources, filters promotional noise, and returns a structured markdown answer with inline citations.
curl -X POST https://flatsearchapi.com/v1/search/fast \
-H "Content-Type: application/json" \
-H "X-API-Key: sp_live_YOUR_KEY" \
-d '{"query": "Next.js 15 ERR_TOO_MANY_REDIRECTS iron-session subdomains"}'Direct link and snippet retrieval for pipelines that want raw search results without AI answer synthesis. Supports normal (comprehensive) and fast (low-latency) modes.
curl -X POST https://flatsearchapi.com/v1/search/sources \
-H "Content-Type: application/json" \
-H "X-API-Key: sp_live_YOUR_KEY" \
-d '{
"query": "Apple M4 chip architecture specifications",
"num_results": 5,
"mode": "fast",
"categories": "general"
}'Multi-query research for complex multi-part questions. Runs agentic query expansion, intent verification, and cross-references multiple perspectives into an authoritative analysis.
curl -X POST https://flatsearchapi.com/v1/search/extended \
-H "Content-Type: application/json" \
-H "X-API-Key: sp_live_YOUR_KEY" \
-d '{
"query": "Compare Blackwell B200 vs Nvidia H200 GPU architecture, memory bandwidth, and availability timeline",
"stream": false
}'Converts any public URL, such as a blog post, product page or documentation portal, into clean, token-efficient Markdown. One URL per request.
curl -X POST https://flatsearchapi.com/v1/extract \
-H "Content-Type: application/json" \
-H "X-API-Key: sp_live_YOUR_KEY" \
-d '{"url": "https://news.ycombinator.com"}'Errors & Status Codes
All error responses return standard JSON with error, message, and request_id.
| Error Code | HTTP Status | Meaning | Recommended Action |
|---|---|---|---|
INVALID_API_KEY | 401 | Missing, formatted incorrectly, or revoked key. | Ensure X-API-Key starts with sp_live_ or sp_test_. |
USAGE_LIMIT_EXCEEDED | 403 | Included requests for this endpoint group are used and the prepaid balance is zero. | Top up prepaid balance or upgrade plan in dashboard. |
RATE_LIMIT_EXCEEDED | 429 | Per-minute request limit reached. | Retry with exponential backoff (1s, 2s, 4s). |
SEARCH_FAILED | 503 | Search backend returned zero snippets or timed out. | Retry query or broaden location criteria. |
EXTRACT_ERROR | 422 / 502 | Target URL unreachable or blocked by anti-bot. | Verify URL accessibility and public visibility. |