/v2/autocomplete/companies| Endpoint | POST /v2/autocomplete/companies |
| Credit cost | 0.1 credits / call |
| Response | Synchronous — up to 15 results |
| When to use | Power a type-ahead input for selecting seed companies in a lookalike search |
Pass the beginning of a company name or domain. Results are ranked by relevance.
curl -X POST "https://api.ocean.io/v2/autocomplete/companies" \
-H "X-Api-Token: YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "stripe"
}'import requests
response = requests.post(
'https://api.ocean.io/v2/autocomplete/companies',
headers={'X-Api-Token': 'YOUR_API_TOKEN'},
json={'name': 'stripe'},
)
data = response.json()const response = await fetch('https://api.ocean.io/v2/autocomplete/companies', {
method: 'POST',
headers: { 'X-Api-Token': 'YOUR_API_TOKEN', 'Content-Type': 'application/json' },
body: JSON.stringify({ name: 'stripe' }),
});
const data = await response.json();Example response:
{
"companies": [
{ "domain": "stripe.com", "name": "Stripe", "logo": "https://cdn2.ocean.io/companies-logos-v1/stripe.com/..." },
{ "domain": "stripedhorse.com", "name": "Striped Horse Brewery", "logo": null }
]
}Use the domain from the selected result as a lookalikeDomains seed in Search Companies or Search People.
| Parameter | Type | Description |
|---|---|---|
name |
string | Required. Beginning of the company name or domain. |
countryFilters |
string[] | Optional. Narrow results to specific countries (ISO alpha-2 codes, e.g. ["us", "gb"]). |
excludeDomains |
string[] | Optional. Domains to omit from results. |
forLookalikeSearch |
boolean | Default true. When true, filters out domains unsuitable as lookalike seeds (bad content, crawl failures, etc.). Set to false only if you're not using results as lookalike seeds. |
apiToken string x-api-token string name string Required forLookalikeSearch boolean 200 Successful Responsedomain string Required logo string name string 400 Bad Requestdetail enum Required "Conflicting API tokens provided in query parameters and headers"402 Payment Requireddetail enum Required "Insufficient credits"403 Forbiddendetail enum Required "API token should be provided in headers or query parameters""Current API token is not registered in our database"404 Not found422 Validation Errormsg string Required type string Required input any