# Find a Work Email Address by Name and Company via API: Easy Guide

By [Florian Martens](https://pipe0.com/authors/florian-martens) · Published Apr 8, 2025

Source: https://pipe0.com/blog/find-work-email-with-pipe0

> Learn how to get a work email address using name and company info with pipe0 API



In this blog post, we explore how you can generate a work email address via an API endpoint.
For this, we use [pipe0](https://pipe0.com).

Pipe0 is a framework for data enrichment. To enrich data with pipe0 you use enrichment pipes.
There are several pipes available to find a work email address via API. For this blog post, we're
using the pipe [person:workemail:waterfall@1](https://www.pipe0.com/docs/pipe-catalog/person:workemail:waterfall/1).

This pipe relies on fetching contact data from multiple sources as a waterfall.

The cost per invocation is \~13ct. per work email address.

## Prerequisites [#prerequisites]

🙆🏼‍♂️ Go to [pipe0](https://pipe0.com) and create an account <br />
🔑 Create an API Key

## Request object [#request-object]

<CodeBlockTabs defaultValue="Typescript">
  <CodeBlockTabsList>
    <CodeBlockTabsTrigger value="Typescript">
      Typescript
    </CodeBlockTabsTrigger>

    <CodeBlockTabsTrigger value="cURL">
      cURL
    </CodeBlockTabsTrigger>
  </CodeBlockTabsList>

  <CodeBlockTab value="Typescript">
    ```typescript
    const id = "1";
    const result = await fetch("https://api.pipe0.com/v1/pipes/run/sync", {
      method: "POST",
      headers: {
        "Authorization": `Bearer <API_KEY>`,
        "Content-Type": "application/json",
      },
      body: JSON.stringify({
        pipes: [
          { pipe_id: "person:name:join@1" },
          {
            pipe_id: "person:workemail:waterfall@1",
            config: {
              providers: [
                { provider: "leadmagic" },
                { provider: "prospeo" },
                { provider: "amplemarket" },
                { provider: "hunter" },
              ],
            },
          },
        ],
        input: [{ id, first_name: "<FIRST_NAME>", last_name: "<LAST_NAME>", company_domain: "<COMPANY_DOMAIN>" }]
      })
    });

    const response = await result.json();

    // Print email
    console.log(response.records[id].fields.work_email.value);
    ```
  </CodeBlockTab>

  <CodeBlockTab value="cURL">
    ```shell
    curl -X POST "https://api.pipe0.com/v1/pipes/run/sync" \
    -H "Authorization: Bearer <API_KEY>" \
    -H "Content-Type: application/json" \
    -d '{
        "pipes": [
          { "pipe_id": "person:name:join@1" },
          { "pipe_id": "person:workemail:waterfall@1", "config": { "providers": [{ "provider": "leadmagic" }, { "provider": "prospeo" }, { "provider": "amplemarket" }, { "provider": "hunter" }] } }
        ],
        "input": [{ "id": "1", "first_name": "<FIRST_NAME>", "last_name": "<LAST_NAME>", "company_domain": "<COMPANY_DOMAIN>" }]
    }'
    ```
  </CodeBlockTab>
</CodeBlockTabs>

## Advantages of using providers in a waterfall [#advantages-of-using-providers-in-a-waterfall]

We used a waterfall enrichment. Waterfall enrichments are great for
retrieving email addresses via API. They are great since we don't fail for failed lookups. This way,
we can try to get the email address from the first provider. If the provider is able to find the contact
information, we return it. If it does not, we go to the second provider.

## Using pipe0 [#using-pipe0]

In this example we used [pipe0](https://pipe0.com) instead of querying providers directly. Using pipe0
has many advantages:

* Use 50+ enrichment providers with one subscription
* Combine multiple enrichments in one API call
* Up-to-date API documentation and best-in-class DX
* Combine data enrichment, web scraping, and AI for powerful solutions
