Quickstart
This guide walks you through your first successful GET /api/company/search in about five minutes. You need a CompanyData account and an API key.
New accounts include a 7-day free trial with API access. After signup, copy your key from the dashboard. For rate limits (50 requests/second) and monthly quotas, see Authentication.
For machine-readable API definitions (OpenAPI 3.0), use the spec at /openapi.json.
1. Get your API key
- Create an account and pick a plan (trial included on signup).
- Open your dashboard and copy your API key.
2. Set your API key
Store the key in your environment. Every request sends it in the x-api-key header (see Authentication).
Terminal
export COMPANYDATA_API_KEY="your_key_here"
.env (Node)
COMPANYDATA_API_KEY=your_key_here
Do not commit API keys to git or client-side code. Use environment variables or a secrets manager in production.
3. Search companies (first request)
This example searches companies in the Netherlands (countryCode=NL) matching BoldData.
Recommended: npm SDK
Use the official JavaScript/TypeScript package @companydata/protool-sdk:
npm install @companydata/protool-sdk
import { ApiClient } from '@companydata/protool-sdk'
const client = new ApiClient({
baseUrl: 'https://app.companydata.com',
auth: { type: 'apiKey', apiKey: process.env.COMPANYDATA_API_KEY ?? '' },
})
const result = await client.company.search({
countryCode: 'NL',
search: 'BoldData',
page: 1,
pageSize: 25,
})
console.log(result.data)
Or use any HTTP client — see the JavaScript SDK for retries, timeouts, and export helpers.
cURL / HTTP
curl -G "https://app.companydata.com/api/company/search" \
--data-urlencode "countryCode=NL" \
--data-urlencode "search=BoldData" \
-H "x-api-key: $COMPANYDATA_API_KEY"
4. Confirm it worked
A successful search returns HTTP 200 and JSON with a data array. Search uses standard pagination (default pageSize 25; up to 50 records total across pages for search — see Company search & export and Pagination).
Example response shape (fields vary by subscription):
{
"data": [
{
"name": "Example B.V.",
"countryCode": "NL",
"registrationNumber": "12345678"
}
],
"page": 1,
"pageSize": 25
}
Common errors
- 401 Unauthorized — missing or invalid
x-api-key. Check the key and Authentication. - 429 Too Many Requests — rate limit exceeded (default 50 requests/second).
- 4xx / 5xx with message — see the response body; confirm query parameters in query parameters.