> For the complete documentation index, see [llms.txt](https://docs.goodfit.io/goodfit-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.goodfit.io/goodfit-docs/apis/enrichment-api/company-endpoints.md).

# Company endpoints

## Enrich a company

> Adds the company to your Goodfit dataset asynchronously. A company new to your dataset appears within minutes with its name, domain and LinkedIn URL, and its data points, scores and tags normally follow within minutes; segments arrive with your next daily dataset update. Poll GET /request/{requestId} with the returned id to see how the request resolved and, through dataStatus, when the company is filled in.

```json
{"openapi":"3.1.0","info":{"title":"Goodfit Enrichment API","version":"1.0.0"},"tags":[{"name":"Company enrichment"}],"servers":[{"url":"https://api.goodfit.io"}],"security":[{"apiKey":["ENRICHMENT_API"]}],"components":{"securitySchemes":{"apiKey":{"type":"apiKey","in":"header","name":"Authorization","description":"Your Goodfit API key, sent as the bare header value"}}},"paths":{"/enrichment/enrich":{"post":{"operationId":"enrichment:enrichCompany","summary":"Enrich a company","description":"Adds the company to your Goodfit dataset asynchronously. A company new to your dataset appears within minutes with its name, domain and LinkedIn URL, and its data points, scores and tags normally follow within minutes; segments arrive with your next daily dataset update. Poll GET /request/{requestId} with the returned id to see how the request resolved and, through dataStatus, when the company is filled in.","tags":["Company enrichment"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"domain":{"type":"string","minLength":1},"email":{"description":"Used only to derive a domain. Personal providers rejected","type":"string","format":"email","pattern":"^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"},"externalIds":{"type":"object","properties":{"salesforce":{"type":"string"},"hubspot":{"anyOf":[{"type":"string"},{"type":"number"}]}}},"forceOverrideExternalIds":{"type":"boolean"},"syncToCRM":{"description":"Write the company to every connected CRM once its data points, scores and tags are filled in, or at once if it already is. Defaults to false","type":"boolean"}}}}}},"responses":{"201":{"description":"The request is recorded and queued","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"success":{"type":"boolean","const":true},"requestId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"}},"required":["success","requestId"],"additionalProperties":false}}}},"400":{"description":"Neither a domain nor an email was given, or neither yields a business domain","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["INVALID_REQUEST"]}},"required":["error","code"],"additionalProperties":false}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["UNAUTHENTICATED"]}},"required":["error","code"],"additionalProperties":false}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["FORBIDDEN"]}},"required":["error","code"],"additionalProperties":false}}}},"429":{"description":"Too many requests","headers":{"Retry-After":{"description":"Seconds to wait before retrying","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["RATE_LIMITED"]}},"required":["error","code"],"additionalProperties":false}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["INTERNAL_ERROR"]}},"required":["error","code"],"additionalProperties":false}}}}}}}}}
```

## Get an enrichment request

> isChargable is omitted while the request is Queued. dataStatus is BASIC while the company has only its name, domain and LinkedIn URL, and FULL once a build has filled in its data points, scores and tags.

```json
{"openapi":"3.1.0","info":{"title":"Goodfit Enrichment API","version":"1.0.0"},"tags":[{"name":"Company enrichment"}],"servers":[{"url":"https://api.goodfit.io"}],"security":[{"apiKey":["ENRICHMENT_API"]}],"components":{"securitySchemes":{"apiKey":{"type":"apiKey","in":"header","name":"Authorization","description":"Your Goodfit API key, sent as the bare header value"}}},"paths":{"/enrichment/request/{requestId}":{"get":{"operationId":"enrichment:getEnrichmentRequest","summary":"Get an enrichment request","description":"isChargable is omitted while the request is Queued. dataStatus is BASIC while the company has only its name, domain and LinkedIn URL, and FULL once a build has filled in its data points, scores and tags.","tags":["Company enrichment"],"parameters":[{"name":"requestId","in":"path","required":true,"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"}}],"responses":{"200":{"description":"Get an enrichment request","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"requestId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$"},"inputs":{"type":"object","properties":{"domain":{"type":"string"},"syncToCRM":{"type":"boolean"}},"required":["domain"],"additionalProperties":false},"status":{"type":"string","enum":["Queued","Completed","Error","Skipped","Unknown"]},"context":{"anyOf":[{"type":"object","properties":{"skipReason":{"anyOf":[{"type":"string","enum":["INVALID_DOMAIN","BLACKLISTED_DOMAIN","DOMAIN_NOT_LOADABLE","DOMAIN_PARKED","ID_RES_NO_COMPANY_ID","ID_RES_NO_LINKEDIN_ID","ID_RES_NO_LINKEDIN_RECORD","SKIP_CREATE_CLIENT_DEST","LINKEDIN_NOT_ACTIVE"]},{"type":"null"}]},"skipReasonDescription":{"type":"string"},"errorMessage":{"anyOf":[{"type":"string"},{"type":"null"}]},"domainCheck":{"anyOf":[{"type":"object","properties":{"domainLoads":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"loadedUrl":{"anyOf":[{"type":"string"},{"type":"null"}]}},"additionalProperties":false},{"type":"null"}]}},"additionalProperties":false},{"type":"null"}]},"isChargable":{"anyOf":[{"type":"boolean"},{"type":"null"}]},"dataStatus":{"description":"Only on a Completed request. BASIC while the company has just its name, domain and LinkedIn URL; FULL once a build has filled in its data points, scores and tags, normally within minutes","type":"string","enum":["BASIC","FULL"]}},"required":["requestId","inputs","status","context"],"additionalProperties":false}}}},"400":{"description":"Bad request","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["INVALID_REQUEST"]}},"required":["error","code"],"additionalProperties":false}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["UNAUTHENTICATED"]}},"required":["error","code"],"additionalProperties":false}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["FORBIDDEN"]}},"required":["error","code"],"additionalProperties":false}}}},"404":{"description":"No enrichment request with this id exists for your account","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["NOT_FOUND"]}},"required":["error","code"],"additionalProperties":false}}}},"429":{"description":"Too many requests","headers":{"Retry-After":{"description":"Seconds to wait before retrying","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["RATE_LIMITED"]}},"required":["error","code"],"additionalProperties":false}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"error":{"description":"Human readable. Wording may change between releases","type":"string"},"code":{"description":"Stable identifier. Match on this rather than on `error`","type":"string","enum":["INTERNAL_ERROR"]}},"required":["error","code"],"additionalProperties":false}}}}}}}}}
```
