> ## Documentation Index
> Fetch the complete documentation index at: https://docs.peopledatalabs.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Examples - Company Enrichment API

# Examples

When specifying query parameters within a URL, you should separate them with an ampersand (`&`).  When specifying query parameters within a JSON object, you should use lists for the request parameters.

We've provided code samples in cURL, Python, Ruby, Go and JavaScript. If you aren't comfortable working in any of these languages, feel free to use this [handy tool](https://curlconverter.com/) to convert code from cURL to the language of your choice.

<Tip>
  **We want your feedback!**

  Do you see a bug? Is there an example you'd like to see that's not listed here?

  Head over to the public roadmap and submit a [bug ticket](https://peopledatalabs.canny.io/bugs) or a [feature request](https://peopledatalabs.canny.io/feature-requests) and receive automatic notifications as your bug is resolved or your request is implemented.
</Tip>

## PDL ID

<CodeGroup>
  ```python Python3 SDK theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-python
  from peopledatalabs import PDLPY

  # Create a client, specifying your API key
  CLIENT = PDLPY(
      api_key="YOUR_API_KEY",
  )

  # Create a parameters JSON object
  QUERY_STRING = {"pdl_id":"aKCIYBNF9ey6o5CjHCCO4goHYKlf"}

  # Pass the parameters object to the Company Enrichment API
  response = CLIENT.company.enrichment(**QUERY_STRING)

  # Print the API response
  print(response.text)
  ```

  ```bash cURL theme={null}
  curl -X GET -G \
    'https://api.peopledatalabs.com/v5/company/enrich'\
    -H 'X-Api-Key: xxxx'\
    --data-urlencode 'pdl_id=aKCIYBNF9ey6o5CjHCCO4goHYKlf'
  ```

  ```javascript JavaScript theme={null}
  // See https://github.com/peopledatalabs/peopledatalabs-js
  import PDLJS from 'peopledatalabs';

  // Create a client, specifying your API key
  const PDLJSClient = new PDLJS({ apiKey: "YOUR API KEY" });

  // Create a parameters JSON object
  const queryString = {"pdl_id":"aKCIYBNF9ey6o5CjHCCO4goHYKlf"}

  // Pass the parameters object to the Company Enrichment API
  PDLJSClient.company.enrichment(queryString).then((data) => {
      // Print the API response
      console.log(data);
  }).catch((error) => {
      console.log(error);
  });
  ```

  ```ruby Ruby theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-ruby
  require 'peopledatalabs'

  # Set your API key
  Peopledatalabs.api_key = 'YOUR API KEY'

  # Create a parameters JSON object
  QUERY_STRING = {"pdl_id":"aKCIYBNF9ey6o5CjHCCO4goHYKlf"}

  # Pass the parameters object to the Company Enrichment API
  response = Peopledatalabs::Enrichment.company(params: QUERY_STRING)

  # Print the API response
  puts response
  ```

  ```go Go expandable theme={null}
  package main

  import (
      "fmt"
      "context"
  )

  // See https://github.com/peopledatalabs/peopledatalabs-go
  import (
      pdl "github.com/peopledatalabs/peopledatalabs-go"
      pdlmodel "github.com/peopledatalabs/peopledatalabs-go/model"
  )

  func main() {
      // Set your API key
      apiKey := "YOUR API KEY"
      // Set API key as environmental variable
      // apiKey := os.Getenv("API_KEY")

      // Create a client, specifying your API key
      client := pdl.New(apiKey)
      
      // Create a parameters JSON object
      queryString := pdlmodel.CompanyParams{PdlId: "aKCIYBNF9ey6o5CjHCCO4goHYKlf"}
      
      params := pdlmodel.EnrichCompanyParams{
          CompanyParams: queryString,
      }
      
      // Pass the parameters object to the Company Enrichment API
      response, err := client.Company.Enrich(context.Background(), params)
      // Check for successful response
      if err == nil {
          // Print the API response
          fmt.Println(response)
      }  
  }
  ```

  ```python Python3 theme={null}
  import requests

  # Set your API key
  API_KEY = "YOUR API KEY"

  # Set the Company Enrichment API URL
  PDL_URL = "https://api.peopledatalabs.com/v5/company/enrich"

  # Create a parameters JSON object
  QUERY_STRING = {"pdl_id":"aKCIYBNF9ey6o5CjHCCO4goHYKlf"}

  # Set headers
  HEADERS = {
      'accept': "application/json",
      'content-type': "application/json",
      'x-api-key': API_KEY
      }

  # Pass the parameters object to the Company Enrichment API
  response = requests.request("GET", PDL_URL, headers=HEADERS, params=QUERY_STRING)

  # Print the API response
  print(response.text)
  ```
</CodeGroup>

## Website

<CodeGroup>
  ```python Python3 SDK theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-python
  from peopledatalabs import PDLPY

  # Create a client, specifying your API key
  CLIENT = PDLPY(
      api_key="YOUR_API_KEY",
  )

  # Create a parameters JSON object
  QUERY_STRING = {"website":"google.com"}

  # Pass the parameters object to the Company Enrichment API
  response = CLIENT.company.enrichment(**QUERY_STRING)

  # Print the API response
  print(response.text)
  ```

  ```bash cURL theme={null}
  curl -X GET -G \
    'https://api.peopledatalabs.com/v5/company/enrich'\
    -H 'X-Api-Key: xxxx'\
    --data-urlencode 'website=google.com'
  ```

  ```javascript JavaScript theme={null}
  // See https://github.com/peopledatalabs/peopledatalabs-js
  import PDLJS from 'peopledatalabs';

  // Create a client, specifying your API key
  const PDLJSClient = new PDLJS({ apiKey: "YOUR API KEY" });

  // Create a parameters JSON object
  const queryString = {"website":"google.com"}

  // Pass the parameters object to the Company Enrichment API
  PDLJSClient.company.enrichment(queryString).then((data) => {
      // Print the API response
      console.log(data);
  }).catch((error) => {
      console.log(error);
  });
  ```

  ```ruby Ruby theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-ruby
  require 'peopledatalabs'

  # Set your API key
  Peopledatalabs.api_key = 'YOUR API KEY'

  # Create a parameters JSON object
  QUERY_STRING = {"website":"google.com"}

  # Pass the parameters object to the Company Enrichment API
  response = Peopledatalabs::Enrichment.company(params: QUERY_STRING)

  # Print the API response
  puts response
  ```

  ```go Go expandable theme={null}
  package main

  import (
      "fmt"
      "context"
  )

  // See https://github.com/peopledatalabs/peopledatalabs-go
  import (
      pdl "github.com/peopledatalabs/peopledatalabs-go"
      pdlmodel "github.com/peopledatalabs/peopledatalabs-go/model"
  )

  func main() {
      // Set your API key
      apiKey := "YOUR API KEY"
      // Set API key as environmental variable
      // apiKey := os.Getenv("API_KEY")

      // Create a client, specifying your API key
      client := pdl.New(apiKey)
      
      // Create a parameters JSON object
      queryString := pdlmodel.CompanyParams{Website: "google.com"}
      
      params := pdlmodel.EnrichCompanyParams{
          CompanyParams: queryString,
      }
      
      // Pass the parameters object to the Company Enrichment API
      response, err := client.Company.Enrich(context.Background(), params)
      // Check for successful response
      if err == nil {
          // Print the API response
          fmt.Println(response)
      }  
  }
  ```

  ```python Python3 theme={null}
  import requests

  # Set your API key
  API_KEY = "YOUR API KEY"

  # Set the Company Enrichment API URL
  PDL_URL = "https://api.peopledatalabs.com/v5/company/enrich"

  # Create a parameters JSON object
  QUERY_STRING = {"website":"google.com"}

  # Set headers
  HEADERS = {
      'accept': "application/json",
      'content-type': "application/json",
      'x-api-key': API_KEY
      }

  # Pass the parameters object to the Company Enrichment API
  response = requests.request("GET", PDL_URL, headers=HEADERS, params=QUERY_STRING)

  # Print the API response
  print(response.text)
  ```
</CodeGroup>

## Name

<CodeGroup>
  ```python Python3 SDK theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-python
  from peopledatalabs import PDLPY

  # Create a client, specifying your API key
  CLIENT = PDLPY(
      api_key="YOUR_API_KEY",
  )

  # Create a parameters JSON object
  QUERY_STRING = {"name":"Google, Inc."}

  # Pass the parameters object to the Company Enrichment API
  response = CLIENT.company.enrichment(**QUERY_STRING)

  # Print the API response
  print(response.text)
  ```

  ```bash cURL theme={null}
  curl -X GET -G \
    'https://api.peopledatalabs.com/v5/company/enrich'\
    -H 'X-Api-Key: xxxx'\
    --data-urlencode 'name=Google, Inc.'
  ```

  ```javascript JavaScript theme={null}
  // See https://github.com/peopledatalabs/peopledatalabs-js
  import PDLJS from 'peopledatalabs';

  // Create a client, specifying your API key
  const PDLJSClient = new PDLJS({ apiKey: "YOUR API KEY" });

  // Create a parameters JSON object
  const queryString = {"name":"Google, Inc."}

  // Pass the parameters object to the Company Enrichment API
  PDLJSClient.company.enrichment(queryString).then((data) => {
      // Print the API response
      console.log(data);
  }).catch((error) => {
      console.log(error);
  });
  ```

  ```ruby Ruby theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-ruby
  require 'peopledatalabs'

  # Set your API key
  Peopledatalabs.api_key = 'YOUR API KEY'

  # Create a parameters JSON object
  QUERY_STRING = {"name":"Google, Inc."}

  # Pass the parameters object to the Company Enrichment API
  response = Peopledatalabs::Enrichment.company(params: QUERY_STRING)

  # Print the API response
  puts response
  ```

  ```go Go expandable theme={null}
  package main

  import (
      "fmt"
      "context"
  )

  // See https://github.com/peopledatalabs/peopledatalabs-go
  import (
      pdl "github.com/peopledatalabs/peopledatalabs-go"
      pdlmodel "github.com/peopledatalabs/peopledatalabs-go/model"
  )

  func main() {
      // Set your API key
      apiKey := "YOUR API KEY"
      // Set API key as environmental variable
      // apiKey := os.Getenv("API_KEY")

      // Create a client, specifying your API key
      client := pdl.New(apiKey)
      
      // Create a parameters JSON object
      queryString := pdlmodel.CompanyParams{Name: "Google, Inc."}
      
      params := pdlmodel.EnrichCompanyParams{
          CompanyParams: queryString,
      }
      
      // Pass the parameters object to the Company Enrichment API
      response, err := client.Company.Enrich(context.Background(), params)
      // Check for successful response
      if err == nil {
          // Print the API response
          fmt.Println(response)
      }  
  }
  ```

  ```python Python3 theme={null}
  import requests

  # Set your API key
  API_KEY = "YOUR API KEY"

  # Set the Company Enrichment API URL
  PDL_URL = "https://api.peopledatalabs.com/v5/company/enrich"

  # Create a parameters JSON object
  QUERY_STRING = {"name":"Google, Inc."}

  # Set headers
  HEADERS = {
      'accept': "application/json",
      'content-type': "application/json",
      'x-api-key': API_KEY
      }

  # Pass the parameters object to the Company Enrichment API
  response = requests.request("GET", PDL_URL, headers=HEADERS, params=QUERY_STRING)

  # Print the API response
  print(response.text)
  ```
</CodeGroup>

## Ticker

<CodeGroup>
  ```python Python3 SDK theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-python
  from peopledatalabs import PDLPY

  # Create a client, specifying your API key
  CLIENT = PDLPY(
      api_key="YOUR_API_KEY",
  )

  # Create a parameters JSON object
  QUERY_STRING = {"ticker":"GOOGL"}

  # Pass the parameters object to the Company Enrichment API
  response = CLIENT.company.enrichment(**QUERY_STRING)

  # Print the API response
  print(response.text)
  ```

  ```bash cURL theme={null}
  curl -X GET -G \
    'https://api.peopledatalabs.com/v5/company/enrich'\
    -H 'X-Api-Key: xxxx'\
    --data-urlencode 'ticker=GOOGL'
  ```

  ```javascript JavaScript theme={null}
  // See https://github.com/peopledatalabs/peopledatalabs-js
  import PDLJS from 'peopledatalabs';

  // Create a client, specifying your API key
  const PDLJSClient = new PDLJS({ apiKey: "YOUR API KEY" });

  // Create a parameters JSON object
  const queryString = {"ticker":"GOOGL"}

  // Pass the parameters object to the Company Enrichment API
  PDLJSClient.company.enrichment(queryString).then((data) => {
      // Print the API response
      console.log(data);
  }).catch((error) => {
      console.log(error);
  });
  ```

  ```ruby Ruby theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-ruby
  require 'peopledatalabs'

  # Set your API key
  Peopledatalabs.api_key = 'YOUR API KEY'

  # Create a parameters JSON object
  QUERY_STRING = {"ticker":"GOOGL"}

  # Pass the parameters object to the Company Enrichment API
  response = Peopledatalabs::Enrichment.company(params: QUERY_STRING)

  # Print the API response
  puts response
  ```

  ```go Go expandable theme={null}
  package main

  import (
      "fmt"
      "context"
  )

  // See https://github.com/peopledatalabs/peopledatalabs-go
  import (
      pdl "github.com/peopledatalabs/peopledatalabs-go"
      pdlmodel "github.com/peopledatalabs/peopledatalabs-go/model"
  )

  func main() {
      // Set your API key
      apiKey := "YOUR API KEY"
      // Set API key as environmental variable
      // apiKey := os.Getenv("API_KEY")

      // Create a client, specifying your API key
      client := pdl.New(apiKey)
      
      // Create a parameters JSON object
      queryString := pdlmodel.CompanyParams{Ticker: "GOOGL"}
      
      params := pdlmodel.EnrichCompanyParams{
          CompanyParams: queryString,
      }
      
      // Pass the parameters object to the Company Enrichment API
      response, err := client.Company.Enrich(context.Background(), params)
      // Check for successful response
      if err == nil {
          // Print the API response
          fmt.Println(response)
      }  
  }
  ```

  ```python Python3 theme={null}
  import requests

  # Set your API key
  API_KEY = "YOUR API KEY"

  # Set the Company Enrichment API URL
  PDL_URL = "https://api.peopledatalabs.com/v5/company/enrich"

  # Create a parameters JSON object
  QUERY_STRING = {"ticker":"GOOGL"}

  # Set headers
  HEADERS = {
      'accept': "application/json",
      'content-type': "application/json",
      'x-api-key': API_KEY
      }

  # Pass the parameters object to the Company Enrichment API
  response = requests.request("GET", PDL_URL, headers=HEADERS, params=QUERY_STRING)

  # Print the API response
  print(response.text)
  ```
</CodeGroup>

## Profile

<CodeGroup>
  ```python Python3 SDK theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-python
  from peopledatalabs import PDLPY

  # Create a client, specifying your API key
  CLIENT = PDLPY(
      api_key="YOUR_API_KEY",
  )

  # Create a parameters JSON object
  QUERY_STRING = {"profile":"linkedin.com/company/google"}

  # Pass the parameters object to the Company Enrichment API
  response = CLIENT.company.enrichment(**QUERY_STRING)

  # Print the API response
  print(response.text)
  ```

  ```bash cURL theme={null}
  curl -X GET -G \
    'https://api.peopledatalabs.com/v5/company/enrich'\
    -H 'X-Api-Key: xxxx'\
    --data-urlencode 'profile=linkedin.com/company/google'
  ```

  ```javascript JavaScript theme={null}
  // See https://github.com/peopledatalabs/peopledatalabs-js
  import PDLJS from 'peopledatalabs';

  // Create a client, specifying your API key
  const PDLJSClient = new PDLJS({ apiKey: "YOUR API KEY" });

  // Create a parameters JSON object
  const queryString = {"profile":"linkedin.com/company/google"}

  // Pass the parameters object to the Company Enrichment API
  PDLJSClient.company.enrichment(queryString).then((data) => {
      // Print the API response
      console.log(data);
  }).catch((error) => {
      console.log(error);
  });
  ```

  ```ruby Ruby theme={null}
  # See https://github.com/peopledatalabs/peopledatalabs-ruby
  require 'peopledatalabs'

  # Set your API key
  Peopledatalabs.api_key = 'YOUR API KEY'

  # Create a parameters JSON object
  QUERY_STRING = {"profile":"linkedin.com/company/google"}

  # Pass the parameters object to the Company Enrichment API
  response = Peopledatalabs::Enrichment.company(params: QUERY_STRING)

  # Print the API response
  puts response
  ```

  ```go Go expandable theme={null}
  package main

  import (
      "fmt"
      "context"
  )

  // See https://github.com/peopledatalabs/peopledatalabs-go
  import (
      pdl "github.com/peopledatalabs/peopledatalabs-go"
      pdlmodel "github.com/peopledatalabs/peopledatalabs-go/model"
  )

  func main() {
      // Set your API key
      apiKey := "YOUR API KEY"
      // Set API key as environmental variable
      // apiKey := os.Getenv("API_KEY")

      // Create a client, specifying your API key
      client := pdl.New(apiKey)
      
      // Create a parameters JSON object
      queryString := pdlmodel.CompanyParams{Profile: "linkedin.com/company/google"}
      
      params := pdlmodel.EnrichCompanyParams{
          CompanyParams: queryString,
      }
      
      // Pass the parameters object to the Company Enrichment API
      response, err := client.Company.Enrich(context.Background(), params)
      // Check for successful response
      if err == nil {
          // Print the API response
          fmt.Println(response)
      }  
  }
  ```

  ```python Python3 theme={null}
  import requests

  # Set your API key
  API_KEY = "YOUR API KEY"

  # Set the Company Enrichment API URL
  PDL_URL = "https://api.peopledatalabs.com/v5/company/enrich"

  # Create a parameters JSON object
  QUERY_STRING = {"profile":"linkedin.com/company/google"}

  # Set headers
  HEADERS = {
      'accept': "application/json",
      'content-type': "application/json",
      'x-api-key': API_KEY
      }

  # Pass the parameters object to the Company Enrichment API
  response = requests.request("GET", PDL_URL, headers=HEADERS, params=QUERY_STRING)

  # Print the API response
  print(response.text)
  ```
</CodeGroup>


## Related topics

- [Company Enrichment API](/docs/company-enrichment-api.md)
- [Reference - Company Enrichment API](/docs/reference-company-enrichment-api.md)
- [Quickstart - Company Enrichment API](/docs/quickstart-company-enrichment-api.md)
- [Output Response - Company Enrichment API](/docs/output-response-company-enrichment-api.md)
- [Examples - IP Enrichment API](/docs/examples-ip-enrichment-api.md)
