Company Enrichment API
curl --request POST \
--url https://api.peoplecontext.com/v1/company/enrich \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"linkedin_slug": "<string>",
"linkedin_id": "<string>",
"linkedin_url": "<string>",
"company_id": "<string>"
}
'import requests
url = "https://api.peoplecontext.com/v1/company/enrich"
payload = {
"linkedin_slug": "<string>",
"linkedin_id": "<string>",
"linkedin_url": "<string>",
"company_id": "<string>"
}
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({
linkedin_slug: '<string>',
linkedin_id: '<string>',
linkedin_url: '<string>',
company_id: '<string>'
})
};
fetch('https://api.peoplecontext.com/v1/company/enrich', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.peoplecontext.com/v1/company/enrich",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'linkedin_slug' => '<string>',
'linkedin_id' => '<string>',
'linkedin_url' => '<string>',
'company_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.peoplecontext.com/v1/company/enrich"
payload := strings.NewReader("{\n \"linkedin_slug\": \"<string>\",\n \"linkedin_id\": \"<string>\",\n \"linkedin_url\": \"<string>\",\n \"company_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.peoplecontext.com/v1/company/enrich")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"linkedin_slug\": \"<string>\",\n \"linkedin_id\": \"<string>\",\n \"linkedin_url\": \"<string>\",\n \"company_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.peoplecontext.com/v1/company/enrich")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"linkedin_slug\": \"<string>\",\n \"linkedin_id\": \"<string>\",\n \"linkedin_url\": \"<string>\",\n \"company_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"matched": true,
"company": {
"company_id": "<string>",
"linkedin_slug": "<string>",
"linkedin_id": "<string>",
"profile": {
"name": "<string>",
"tagline": "<string>",
"description": "<string>",
"industry": "<string>",
"company_size": "<string>",
"employees": 123,
"founded": 123,
"website": "<string>",
"phone": "<string>",
"specialties": [
{}
]
},
"headquarters": {
"city": "<string>",
"region": "<string>",
"country": "<string>",
"postal_code": "<string>",
"line1": "<string>",
"line2": "<string>"
},
"images": {
"logo": "<string>",
"cover": "<string>"
}
}
}Company Endpoints
Company Enrichment API
Enrich company profiles using LinkedIn company identifiers
POST
/
v1
/
company
/
enrich
Company Enrichment API
curl --request POST \
--url https://api.peoplecontext.com/v1/company/enrich \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"linkedin_slug": "<string>",
"linkedin_id": "<string>",
"linkedin_url": "<string>",
"company_id": "<string>"
}
'import requests
url = "https://api.peoplecontext.com/v1/company/enrich"
payload = {
"linkedin_slug": "<string>",
"linkedin_id": "<string>",
"linkedin_url": "<string>",
"company_id": "<string>"
}
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({
linkedin_slug: '<string>',
linkedin_id: '<string>',
linkedin_url: '<string>',
company_id: '<string>'
})
};
fetch('https://api.peoplecontext.com/v1/company/enrich', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.peoplecontext.com/v1/company/enrich",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'linkedin_slug' => '<string>',
'linkedin_id' => '<string>',
'linkedin_url' => '<string>',
'company_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.peoplecontext.com/v1/company/enrich"
payload := strings.NewReader("{\n \"linkedin_slug\": \"<string>\",\n \"linkedin_id\": \"<string>\",\n \"linkedin_url\": \"<string>\",\n \"company_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.peoplecontext.com/v1/company/enrich")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"linkedin_slug\": \"<string>\",\n \"linkedin_id\": \"<string>\",\n \"linkedin_url\": \"<string>\",\n \"company_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.peoplecontext.com/v1/company/enrich")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"linkedin_slug\": \"<string>\",\n \"linkedin_id\": \"<string>\",\n \"linkedin_url\": \"<string>\",\n \"company_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"matched": true,
"company": {
"company_id": "<string>",
"linkedin_slug": "<string>",
"linkedin_id": "<string>",
"profile": {
"name": "<string>",
"tagline": "<string>",
"description": "<string>",
"industry": "<string>",
"company_size": "<string>",
"employees": 123,
"founded": 123,
"website": "<string>",
"phone": "<string>",
"specialties": [
{}
]
},
"headquarters": {
"city": "<string>",
"region": "<string>",
"country": "<string>",
"postal_code": "<string>",
"line1": "<string>",
"line2": "<string>"
},
"images": {
"logo": "<string>",
"cover": "<string>"
}
}
}Endpoint
POST /v1/company/enrich
Authentication
string
required
Bearer token with your API key:
Bearer YOUR_API_KEYRequest Parameters
Request Body (JSON)
At least one identifier is required:string
LinkedIn company slug (e.g., from linkedin.com/company/openai).Example:
"openai"string
LinkedIn’s internal company ID.Example:
"11130470"string
Full LinkedIn company URL. The API will automatically extract the slug.Example:
"linkedin.com/company/openai"Example: "https://www.linkedin.com/company/openai/"string
Internal company ID from People Context API.Example:
"abc123"Identifier Priority: Identifiers are tried in this order:
linkedin_slug > linkedin_id > linkedin_url (slug extracted) > company_id. The API returns as soon as a match is found.Response
Success Response (200 OK)
Returns a JSON object containing the enriched company data.boolean
Whether a matching company was found in the database.
object | null
Company data object (null if no match found)
string
Internal company ID
string
LinkedIn company slug
string
LinkedIn’s internal company ID
object
Company profile information
string
Company name
string
Company tagline/description
string
Full company description
string
Industry category
string
Company size range (e.g., “51-200 employees”)
integer
Approximate employee count
integer
Year founded
string
Company website URL
string
Company phone number
array
Array of company specialties/focus areas
object
Additional fields may be present depending on the data available in the LinkedIn company profile.
No Match Response (200 OK)
When no matching company is found:{
"matched": false,
"company": null
}
Error Responses
All error responses follow the standard format with adetail field:
{
"detail": "Error message describing what went wrong"
}
- 401 Unauthorized - Missing or invalid API key
- 403 Forbidden - Organization is inactive
- 422 Unprocessable Entity - Validation error (missing required parameters or invalid values)
- 429 Too Many Requests - Monthly request limit exceeded
- 500 Internal Server Error - Unexpected server error (e.g., Elasticsearch connection failed)
Examples
# Enrich by LinkedIn slug
curl -X POST "https://api.peoplecontext.com/v1/company/enrich" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"linkedin_slug": "openai"}'
# Enrich by LinkedIn ID
curl -X POST "https://api.peoplecontext.com/v1/company/enrich" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"linkedin_id": "11130470"}'
# Enrich by LinkedIn URL (slug extracted automatically)
curl -X POST "https://api.peoplecontext.com/v1/company/enrich" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"linkedin_url": "linkedin.com/company/openai"}'
import requests
url = "https://api.peoplecontext.com/v1/company/enrich"
headers = {
"Authorization": "Bearer YOUR_API_KEY",
"Content-Type": "application/json"
}
# Enrich by LinkedIn slug
payload = {
"linkedin_slug": "openai"
}
response = requests.post(url, headers=headers, json=payload)
data = response.json()
if data["matched"]:
company = data["company"]
print(f"Name: {company['profile']['name']}")
print(f"Industry: {company['profile']['industry']}")
print(f"Employees: {company['profile']['employees']}")
print(f"Founded: {company['profile']['founded']}")
print(f"Location: {company['headquarters']['city']}, {company['headquarters']['region']}")
else:
print("No match found")
// Enrich by LinkedIn slug
const response = await fetch(
'https://api.peoplecontext.com/v1/company/enrich',
{
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
linkedin_slug: 'openai'
})
}
);
const data = await response.json();
if (data.matched) {
const company = data.company;
console.log(`Name: ${company.profile.name}`);
console.log(`Industry: ${company.profile.industry}`);
console.log(`Employees: ${company.profile.employees}`);
console.log(`Location: ${company.headquarters.city}, ${company.headquarters.region}`);
} else {
console.log('No match found');
}
<?php
$ch = curl_init();
$payload = json_encode([
'linkedin_slug' => 'openai'
]);
curl_setopt($ch, CURLOPT_URL, "https://api.peoplecontext.com/v1/company/enrich");
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $payload);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, [
'Authorization: Bearer YOUR_API_KEY',
'Content-Type: application/json'
]);
$response = curl_exec($ch);
curl_close($ch);
$data = json_decode($response, true);
if ($data['matched']) {
$company = $data['company'];
echo "Name: " . $company['profile']['name'] . "\n";
echo "Industry: " . $company['profile']['industry'] . "\n";
echo "Employees: " . $company['profile']['employees'] . "\n";
}
?>
Sample Response
{
"matched": true,
"company": {
"company_id": "abc123",
"linkedin_slug": "openai",
"linkedin_id": "11130470",
"profile": {
"name": "OpenAI",
"tagline": "Creating safe AGI that benefits all of humanity.",
"description": "OpenAI is an AI research and deployment company...",
"industry": "Research Services",
"company_size": "201-500 employees",
"employees": 5701,
"founded": 2015,
"website": "https://openai.com",
"phone": null,
"specialties": [
"Artificial Intelligence",
"Machine Learning",
"Natural Language Processing",
"Research"
]
},
"headquarters": {
"city": "San Francisco",
"region": "CA",
"country": "United States",
"postal_code": "94110",
"line1": "3180 18th St",
"line2": null
},
"images": {
"logo": "https://media.licdn.com/dms/image/...",
"cover": "https://media.licdn.com/dms/image/..."
}
}
}
Best Practices
URL Flexibility: You can pass full LinkedIn URLs - the API automatically extracts the company slug. This is useful when scraping or working with raw LinkedIn links.
Rate Limits: API requests are subject to rate limits based on your organization’s plan. Monitor your monthly request count to avoid hitting limits.
Data Freshness: LinkedIn company data is refreshed monthly. Check the profile data for recent updates and employee counts.
Use Cases
- Lead Enrichment: Enrich company information from LinkedIn URLs in your CRM
- Market Research: Build company databases with detailed profile information
- Sales Intelligence: Get company size, industry, and location data for targeting
- Data Validation: Verify company information against LinkedIn’s authoritative data
Related
- Person Enrichment API - Enrich individual profiles
- Quickstart - Get started in 5 minutes
- Introduction - Learn about People Context API