Skip to content

API Reference

CompanyLens API

REST API for company data enrichment. All endpoints return JSON. Authentication via Bearer token. Base URL: https://companylens.onrender.com

Authentication

Include your API key as a Bearer token in the Authorization header of every request. Keep your key secure and never expose it in client-side code.

Authorization: Bearer YOUR_API_KEY
Note: Never expose your API key in client-side JavaScript. Always make API calls from your backend server.

Data Pipeline

Every enrichment request runs up to seven independent data sources in parallel. Results are merged with conflict resolution and each field gets a confidence score (0.0–1.0) based on source agreement.

01

Website HTML Parsing

Fetches the target domain's HTML and extracts structured data: meta tags (og:title, og:description, og:image), JSON-LD structured data blocks, social profile links from the footer, and canonical brand name from the page title.

meta tags · json-ld · social links · footer scraping
02

DNS / WHOIS Records

Resolves A, CNAME, MX, NS, and TXT records. WHOIS lookup provides registrar, creation date, expiry date, and registrant organization. TXT records often reveal SaaS tools (Google Workspace, Mailchimp, Salesforce) before any page load.

registrar · nameservers · domain age · txt records
03

Tech Stack Fingerprinting

Identifies 90+ technologies from HTTP response headers (X-Powered-By, Server, Via), script src patterns, HTML class names, and DNS MX records. No AI required — deterministic signature matching across frameworks, CDNs, analytics, and payment processors.

90+ signatures · http headers · no ai needed
04

SEC EDGAR

Queries EDGAR's full-text search and XBRL filings API for public US companies. Returns legal name, SIC industry code, employee headcount from annual 10-K filings, and principal office address — all from authoritative regulatory filings.

xbrl filings · sic code · employee count · 10-k
05

Wikidata SPARQL

Executes SPARQL queries against Wikidata's structured knowledge base to retrieve founding year, headquarters city/country, industry classification, and entity identifiers. Cross-referenced with other sources for conflict resolution.

sparql · founded year · headquarters · entity data
06

SMTP / MX Verification

Validates email deliverability by combining MX record lookup with an SMTP handshake (EHLO + RCPT TO probe). Detects email provider, confirms domain accepts mail, and validates common email format patterns (firstname.lastname, first.last, etc.).

mx records · smtp handshake · pattern detection
07

AI-Assisted Web Search

Fills remaining data gaps using AI-assisted web research against public web sources. Used as the final enrichment layer when structured sources (SEC EDGAR, Wikidata, DNS) don't have the data. Returns CEO name, company description, industry, and contact details with a confidence score.

public web · gap filling · ceo name · fallback layer
GET/v1/enrich/companyCompany Profile

Full company enrichment. Returns firmographic data, tech stack, social profiles, WHOIS, DNS records, website metadata, email pattern, company contact info, CEO name, per-field confidence scores, and data source attribution. Data is cached for 7 days — use refresh=true to bypass.

Parameters

NameTypeRequiredDescription
domainstringrequiredThe domain to enrich (e.g. stripe.com)
refreshbooleanoptionalForce fresh data, bypassing the cache (default: false)
Request
curl -X GET \
  "https://companylens.dev/api/enrich?domain=stripe.com" \
  -H "X-API-Key: YOUR_API_KEY"
Response200 OK
{
  "domain": "stripe.com",
  "name": "Stripe",
  "description": "Financial infrastructure platform for the internet.",
  "industry": "Financial Technology",
  "employee_count_range": "5000-10000",
  "founded_year": 2010,
  "location": {
    "city": "San Francisco",
    "state": "CA",
    "country": "US"
  },
  "social_profiles": {
    "linkedin": "https://linkedin.com/company/stripe",
    "twitter": "https://twitter.com/stripe",
    "github": "https://github.com/stripe"
  },
  "tech_stack": ["React", "Cloudflare", "AWS", "Google Analytics"],
  "whois": {
    "registrar": "MarkMonitor Inc.",
    "created_date": "2009-09-17",
    "expires_date": "2031-09-17"
  },
  "email_pattern": "{first}.{last}@stripe.com",
  "company_phone": "+1-888-926-2289",
  "company_email": "info@stripe.com",
  "ceo_name": "Patrick Collison",
  "confidence": {
    "name": 1.0,
    "industry": 0.95,
    "employee_count_range": 0.85,
    "founded_year": 1.0,
    "location": 0.9,
    "email_pattern": 0.75,
    "ceo_name": 0.88
  },
  "data_sources": ["cache", "wikidata", "sec_edgar", "website", "github", "ai_search"],
  "last_updated": "2026-03-24T00:00:00Z"
}
GET/v1/enrich/techTech Stack Detection

Analyzes HTTP headers, HTML content patterns, and DNS MX records to detect the technologies a company uses. Returns categorized stacks across frameworks, analytics, CDN, payment, email, and more.

Parameters

NameTypeRequiredDescription
domainstringrequiredThe domain to scan for technologies
refreshbooleanoptionalForce fresh scan, bypassing the cache (default: false)
Request
curl -X GET \
  "https://companylens.dev/api/enrich?domain=stripe.com&type=tech" \
  -H "X-API-Key: YOUR_API_KEY"
Response200 OK
{
  "domain": "stripe.com",
  "tech_stack": {
    "frameworks":      ["React", "Next.js"],
    "analytics":       ["Google Analytics", "Segment"],
    "payment":         ["Stripe.js"],
    "cdn_hosting":     ["Cloudflare", "AWS CloudFront"],
    "email_provider":  ["SendGrid"],
    "chat_support":    ["Intercom"]
  },
  "last_updated": "2026-03-24T00:00:00Z"
}
GET/v1/enrich/socialSocial Discovery

Discovers social media profiles for a company by scraping the website and probing common URL patterns. Covers LinkedIn, Twitter/X, Facebook, GitHub, YouTube, Instagram, and Crunchbase.

Parameters

NameTypeRequiredDescription
domainstringrequiredThe domain of the company
refreshbooleanoptionalForce fresh discovery, bypassing the cache (default: false)
Request
curl -X GET \
  "https://companylens.onrender.com/v1/enrich/social?domain=stripe.com" \
  -H "Authorization: Bearer YOUR_API_KEY"
Response200 OK
{
  "domain": "stripe.com",
  "social_profiles": {
    "linkedin":   "https://linkedin.com/company/stripe",
    "twitter":    "https://twitter.com/stripe",
    "facebook":   "https://facebook.com/stripeHQ",
    "github":     "https://github.com/stripe",
    "youtube":    "https://youtube.com/c/stripe",
    "instagram":  null,
    "crunchbase": "https://crunchbase.com/organization/stripe"
  },
  "last_updated": "2026-03-24T00:00:00Z"
}
POST/v1/enrich/bulkBulk Enrichment

Enrich up to 10 domains concurrently in a single request. Each result includes success/failure status plus the full enrichment payload. Ideal for batch processing pipelines.

Request Body

NameTypeRequiredDescription
domainsstring[]requiredArray of domains to enrich (max 10)
refreshbooleanoptionalForce fresh data for all domains (default: false)
Request
curl -X POST \
  "https://companylens.onrender.com/v1/enrich/bulk" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"domains": ["stripe.com", "vercel.com", "linear.app"]}'
Response200 OK
{
  "results": [
    { "domain": "stripe.com", "success": true,  "data": { "..." }, "error": null },
    { "domain": "vercel.com", "success": true,  "data": { "..." }, "error": null },
    { "domain": "linear.app", "success": true,  "data": { "..." }, "error": null }
  ],
  "total": 3,
  "succeeded": 3,
  "failed": 0
}

Error Codes

StatusDescription
200 OKRequest succeeded.
400 Bad RequestMissing or invalid domain parameter.
401 UnauthorizedMissing or invalid API key.
422 Unprocessable EntityDomain failed validation (malformed, empty, or not a real domain).
429 Too Many RequestsRate limit exceeded. Check X-RateLimit-Reset header and use exponential backoff.
500 Internal Server ErrorSomething went wrong on our side. Please retry.

Rate Limits

Rate limits are enforced per API key. Check the following headers in every response:

X-RateLimit-Limit:Total requests allowed per month
X-RateLimit-Remaining:Requests remaining this billing cycle
X-RateLimit-Reset:Unix timestamp when quota resets

When you hit a rate limit, the API returns 429 Too Many Requests. Use exponential backoff before retrying.

Ready to start?

500 free lookups per month. No credit card required.

Get your API key →