# Company Enrichment

> Resolve a full company profile from a domain, email, phone, or company social URL.

- **Endpoint:** `POST https://api.nyne.ai/company/enrichment`
- **Group:** Company APIs (https://api.nyne.ai/documentation/company.md)
- **Auth:** `X-API-Key` + `X-API-Secret` headers
- **Mode:** Asynchronous - submit returns a `request_id` (normally with `202 Accepted`); poll `GET /company/enrichment?request_id=<request_id>` with the same auth headers until the endpoint reports a terminal response. Where supported, a `callback_url` can notify you when queued work finishes; follow this endpoint's retrieval notes.
- **HTML version:** https://api.nyne.ai/documentation/company/enrichment

Submit one or more identifiers for a company - `domain`, `email`, `phone`, or a company `social_media_url` - and receive a firmographic profile with fields such as industry, headcount, locations, funding, web presence, domains, emails, and phone numbers when available. Fields with no data are omitted from the response. The request is queued asynchronously and returns a `request_id`; poll the status endpoint or supply a `callback_url`. At least one identifier is required. Credits are charged only when the enrichment returns data.

## Authentication

All `/person/*` and `/company/*` endpoints authenticate with an API key and secret sent as HTTP headers on every request: `X-API-Key` and `X-API-Secret`. Create keys from your Nyne.ai dashboard and keep the secret server-side. Rate limits: 100 requests/minute, 1,000 requests/hour. Full guide: https://api.nyne.ai/documentation/authentication.md

## Parameters

| Name | Type | Required | Description | Example |
| --- | --- | --- | --- | --- |
| `domain` | string | no | Company website domain. Scheme, `www.`, and path are stripped automatically before matching. | "tesla.com" |
| `email` | string | no | Company email address. Validated for format. | "contact@example.com" |
| `phone` | string | no | Company phone number (digits, spaces, dashes, parentheses, and + only). | "+1-555-123-4567" |
| `social_media_url` | string | no | Company social profile URL. | "https://www.linkedin.com/company/tesla-motors/" |
| `callback_url` | string | no | http(s) URL on an allowed host that receives the completed enrichment payload. | "https://example.com/webhooks/company-enrichment" |

## Polling for the result

A newly queued submit normally returns `202 Accepted` with a `request_id`. Poll the same path until `status` is `completed` (results stay available afterwards). Where supported, pass a `callback_url` on the submit to receive a webhook when queued work finishes; keep the documented GET as a recovery and retrieval path:

```bash
curl "https://api.nyne.ai/company/enrichment?request_id=<request_id>" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "X-API-Secret: YOUR_API_SECRET"
```

## Credit usage

| Item | Credits | Condition |
| --- | --- | --- |
| Company Enrichment | - | Charged once per request, only on a meaningful result |
| No match | 0 | No data found never burns credits |

## Responses

| Code | Meaning |
| --- | --- |
| `202` | Enrichment queued - poll the status endpoint with the returned request_id |
| `400` | missing_parameters / invalid_email / invalid_phone / invalid_url / invalid_domain / invalid_callback_url |
| `401` | Missing or invalid API credentials |
| `402` | insufficient_credits |
| `403` | subscription_required or ip_not_allowed |
| `404` | not_found - no company matched the supplied identifiers (no credits charged) |
| `429` | rate_limit_exceeded / monthly_limit_exceeded |
| `503` | service_unavailable - the API is temporarily unavailable |

## Example request

### cURL

```bash
curl -X POST https://api.nyne.ai/company/enrichment \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "X-API-Secret: YOUR_API_SECRET" \
  -H "Content-Type: application/json" \
  -d '{
    "social_media_url": "https://www.linkedin.com/company/tesla-motors/"
  }'
```

### Python

```python
import requests

resp = requests.post(
    "https://api.nyne.ai/company/enrichment",
    headers={
        "X-API-Key": "YOUR_API_KEY",
        "X-API-Secret": "YOUR_API_SECRET",
    },
    json={
        "social_media_url": "https://www.linkedin.com/company/tesla-motors/",
    },
)
data = resp.json()
print(data)
```

### Node

```javascript
const resp = await fetch("https://api.nyne.ai/company/enrichment", {
  method: "POST",
  headers: {
    "X-API-Key": "YOUR_API_KEY",
    "X-API-Secret": "YOUR_API_SECRET",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    social_media_url: "https://www.linkedin.com/company/tesla-motors/",
  }),
});
const data = await resp.json();
console.log(data);
```

### PHP

```php
<?php
$ch = curl_init("https://api.nyne.ai/company/enrichment");
curl_setopt_array($ch, [
  CURLOPT_POST => true,
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_HTTPHEADER => [
    "X-API-Key: YOUR_API_KEY",
    "X-API-Secret: YOUR_API_SECRET",
    "Content-Type: application/json",
  ],
  CURLOPT_POSTFIELDS => json_encode([
    "social_media_url" => "https://www.linkedin.com/company/tesla-motors/",
  ]),
]);
$data = json_decode(curl_exec($ch), true);
print_r($data);
```

## Example response

```json
{
  "request_id": "dfd84d2d1f065a9b4e7fbc3df6aabbb6_1700000123_8123",
  "status": "completed",
  "completed": true,
  "result": {
    "company_name": "Tesla, Inc.",
    "website": "https://www.tesla.com",
    "description": "Designs and manufactures electric vehicles and energy storage systems.",
    "linkedin_url": "https://www.linkedin.com/company/tesla-motors/",
    "industry": "Automotive",
    "specialties": [
      "Electric Vehicles",
      "Energy Storage"
    ],
    "headcount_range": "10,001+",
    "locations": [
      {
        "city": "Austin",
        "state": "Texas",
        "country": "United States"
      },
      {
        "city": "Fremont",
        "state": "California",
        "country": "United States"
      }
    ],
    "funding": {
      "last_round": "Post-IPO",
      "funding_total": "20.2B"
    },
    "sic_codes": [
      "3711"
    ],
    "naics_codes": [
      "336111"
    ],
    "emails": [
      "press@tesla.com"
    ],
    "phone_numbers": [
      "+1-512-516-8177"
    ]
  },
  "completed_on": "2026-01-15T10:35:00Z"
}
```

---

All documentation pages are available as Markdown by appending `.md` to their URL. Index: https://api.nyne.ai/llms.txt
