B2B data API: what’s in it and how to query it
What a B2B data API gives you that a database UI doesn’t, the people and company data in B2Benrich, and how to query it with one key.
Dag Holmen · Updated · 5 min read
A B2B data API gives you people and company records as JSON over HTTP. Instead of logging into a database, clicking filters and exporting a CSV, you send a request from your own code and get structured rows back. The same query runs again tomorrow, in a script, a workflow tool or an AI agent, with no one touching a UI.
B2Benrich is a B2B data API built for that. One API key covers person enrichment, company enrichment, people search, company search and an AI search that turns a sentence into filters. This guide covers what's in the data, which endpoint does what, and how to make your first requests.
What an API gives you that a database UI doesn't
A B2B database with a web app is fine when one person builds one list. It gets awkward once lists become part of a system.
- Queries live in code. The filters behind a list are a JSON body you can version, review and rerun, not a set of checkboxes someone remembers.
- Results land where you work. Write them to your warehouse, a CRM, a sheet or a queue. No export and re-import step.
- Steps chain together. Search for people, add their emails, match them to accounts you already have, all in one job.
- Jobs run on a schedule. Rerun the same search every week and diff the results to catch new hires and job changes.
If you'd rather have someone build the list for you, a UI or a service is the better fit. An API is for the person who wants the raw records and will do the shaping themselves.
What's in the B2Benrich data
People
Search endpoints return person records with these fields:
| Group | Fields |
|---|---|
| Identity | id, full_name, first_name, last_name, linkedin_url, profile_pic |
| Role | job_title |
| Company | company_name, company_domain, company_linkedin_url, company_id, industry, company_size, company_revenue |
| Location | city, state_code, state_name, country_code, country_name, country_region |
Work emails aren't part of the search record. You get them with a separate call that takes a first name, last name and domain, which the email finder API guide covers.
Companies
Company search records carry id, name, description, domain, industry, hq_city, hq_state, hq_country, employees_range, revenue_range and linkedin_url. You can also filter people by the technologies their company uses.
The endpoints, grouped by job
Every endpoint is a POST with a JSON body and your key in the X-Api-Key header.
| You want to | Endpoint | You send |
|---|---|---|
| Enrich a person | /v1/enrich/person/linkedin-to-person | A LinkedIn profile URL |
| Find a work email | /v1/enrich/person/name-domain-to-email | First name, last name, domain |
| Enrich a company | /v1/enrich/companies/domain-to-company | A domain |
| Enrich a company from LinkedIn | /v1/enrich/companies/linkedin-to-company | A LinkedIn company URL |
| Search people across companies | /v1/search/prospector | Contact and company filters |
| List people at one company | /v1/search/company-employees | A domain, LinkedIn URL or company ID |
| Find a title at a named company | /v1/search/title-company | A job title and company name |
| Search companies | /v1/search/companies | Industry, size, revenue, location filters |
| Search in plain English | /v1/search/ai | A sentence |
| Get valid filter values | /v1/search/meta/{field} | The field name |
There are also lookups by B2Benrich ID (/v1/enrich/person/get-by-id and /v1/enrich/companies/get-by-id), a company lookup by LinkedIn numeric ID, a fuzzy company-name search and a person lookup by name and company domain.
Your first request
The quickest way to see the data is the AI search. Describe who you want and it returns matching people, plus the structured search it built from your sentence.
curl --request POST \
--url https://api.b2benrich.com/v1/search/ai \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: YOUR_API_KEY' \
--data '{ "query": "VP of Sales at software companies that use Salesforce" }'
The response has records (person records like the table above) and a prospector_search object. That second part is the useful bit for builders: it shows you the contact and company filters the API chose. Copy it into a Prospector request and you have a repeatable, pageable query instead of a one-off sentence.
Use exact filter values
Structured filters only match exact values. "SaaS" won't match if the industry is stored as "Software Development". The meta endpoint lists every allowed value for a field, page by page:
curl --request POST \
--url https://api.b2benrich.com/v1/search/meta/industry_linkedin \
--header 'Content-Type: application/json' \
--header 'X-Api-Key: YOUR_API_KEY' \
--data '{ "page": 1 }'
It returns values (each with a value) and has_more. Fields include industry_linkedin, job_level, job_function, job_title, technologies, employee_count_range, revenue_range and country_name. Cache the lists locally and validate your filters against them before you run a big search.
Size a list before you pull it
/v1/search/prospector/count takes the same filters as a Prospector search and returns only the number of matches. Run it while you tune filters: if the count is tiny, loosen a filter; if it's huge, add a company size or region. Then page through the real search. The prospecting API guide walks through the full loop, and the people search API guide covers the narrower endpoints.
What to check in a B2B data provider's API
If you're comparing B2B data providers for API use, the questions that matter to a builder are mostly about the interface, not the marketing:
- Can you search, or only enrich? Enrichment needs an identifier you already have. Search finds records you don't.
- Are filters structured, with a way to list valid values? Free-text-only search is hard to automate.
- Can you count before you pull? It saves you from paging through a list you'll throw away.
- Do records have stable IDs? You need them to dedupe across runs and join people to companies.
- Does the price punish reruns? B2Benrich is one plan: unlimited API usage for $500 a month, no credits, so pulling a big list or rerunning a search weekly doesn't cost more.
New to the topic? What is data enrichment explains the enrichment side in more depth.
Where it fits
It's a plain REST API, so it works from any language, script, workflow tool or AI agent that can make an HTTP request. Common setups: a nightly script that writes search results to a warehouse table, a workflow that enriches new CRM records as they arrive, or an agent that calls the AI search and then the email finder. Full reference is in the docs.
Frequently asked questions
- What is a B2B data API?
- A B2B data API gives you business contact and company records over HTTP, usually as JSON. You send filters or an identifier such as a domain or LinkedIn URL, and get structured records back that your code can store, join and reuse.
- What’s the difference between a B2B database and a B2B data API?
- A B2B database is the set of people and company records. A B2B data API is a way to query it from code. With an API you can rerun the same search on a schedule, chain search and enrichment steps, and write results straight to your own systems instead of exporting files.
- What is a B2B contact database?
- A B2B contact database holds professional records: names, job titles, the company each person works for, LinkedIn URLs and location. In B2Benrich you query it with the people search endpoints and add work emails with the name-and-domain email finder.
- Does the B2Benrich API return email addresses?
- Search results return names, titles, companies, LinkedIn URLs and locations. To get a work email, call the name-domain-to-email endpoint with the person’s first name, last name and company domain.
- How do I know which filter values the API accepts?
- Call the meta endpoint for the field, for example /v1/search/meta/industry_linkedin or /v1/search/meta/job_level. It returns every allowed value, page by page, so you can match your filters exactly.
- Which languages and tools can call the API?
- Any language or tool that can send an HTTP POST with a JSON body and a header. That includes cURL, Python, JavaScript, workflow tools with an HTTP step, and AI agents.
Related guides
- Prospecting API: build lead lists from contact and company filtersCombine job, company and tech-stack filters in one query, count the matches before you pull, and page through the results into your own tools.
- People search API: find contacts by title, company and locationSearch for people by job title, company, seniority and location, list everyone at a company, or describe who you want in plain English.
- What is B2B data enrichment? A guide for buildersWhat B2B data enrichment is, the people and company fields you can add, how enrichment works over an API, and how to run it on your own lists.