# Search People — Enrich Layer

> Search for people who meet a set of criteria. Returns a single page of results per call — use the next_page URL from the response to retrieve subsequent pages. Cost: 3 credits per profile URL returned. See the documentation.

- Key: `enrich_layer-search-people`
- Type: Action (Read-only)
- Version: 0.0.2
- App: Enrich Layer (`enrich_layer`) — https://pipedream.com/apps/enrich-layer.md
- This page (HTML): https://pipedream.com/apps/enrich-layer/actions/search-people
- Hints: read-only · open-world
- Source: https://github.com/PipedreamHQ/pipedream/blob/master/components/enrich_layer/actions/search-people/search-people.mjs

## Description

Search for people who meet a set of criteria. Returns a single page of results per call — use the `next_page` URL from the response to retrieve subsequent pages. Cost: 3 credits per profile URL returned. [See the documentation](https://enrichlayer.com/docs/api/v2/search-api/person-search).

## Props

| Prop | Type | Required | Description |
|---|---|---|---|
| `country` | `string` | No | Filter people located in this country (Alpha-2 ISO 3166 code). |
| `firstName` | `string` | No | Filter by first name using boolean search. |
| `lastName` | `string` | No | Filter by last name using boolean search. |
| `currentRoleTitle` | `string` | No | Filter by current job title using boolean search (e.g., CEO \|\| Founder). |
| `pastRoleTitle` | `string` | No | Filter by past job title using boolean search. |
| `currentCompanyName` | `string` | No | Filter by current company name using boolean search. |
| `pastCompanyName` | `string` | No | Filter by past company name using boolean search. |
| `currentCompanyProfileUrl` | `string` | No | Filter by current company profile URL. |
| `pastCompanyProfileUrl` | `string` | No | Filter by past company profile URL. |
| `city` | `string` | No | Filter by city. Wrap names with spaces in double quotes. |
| `region` | `string` | No | Filter by region/state/province. |
| `headline` | `string` | No | Filter by headline using boolean search. |
| `summary` | `string` | No | Filter by summary using boolean search. |
| `educationFieldOfStudy` | `string` | No | Filter by field of study. |
| `educationDegreeName` | `string` | No | Filter by degree name (e.g., MBA). |
| `educationSchoolName` | `string` | No | Filter by school name. |
| `educationSchoolProfileUrl` | `string` | No | Filter by school profile URL. |
| `currentRoleBefore` | `string` | No | Filter people who started their current role before this date (ISO 8601). |
| `currentRoleAfter` | `string` | No | Filter people who started their current role after this date (ISO 8601). |
| `currentJobDescription` | `string` | No | Filter by current job description. |
| `pastJobDescription` | `string` | No | Filter by past job description. |
| `industries` | `string` | No | Filter by person's inferred industry. |
| `interests` | `string` | No | Filter by interests. |
| `skills` | `string` | No | Filter by skills using boolean search. Cannot combine with Skills All In List. |
| `skillsAllInList` | `string` | No | Comma-separated list of skills. Returns profiles with ALL listed skills. Cannot combine with Skills. |
| `languages` | `string` | No | Filter by language. |
| `groups` | `string` | No | Filter by group membership. |
| `currentCompanyCountry` | `string` | No | Filter by current company's country (Alpha-2 ISO 3166 code). |
| `currentCompanyRegion` | `string` | No | Filter by current company's region. |
| `currentCompanyCity` | `string` | No | Filter by current company's city. |
| `currentCompanyType` | `string` | No | Filter by current company type. |
| `currentCompanyIndustry` | `string` | No | Filter by current company's industry (includes inferred). |
| `currentCompanyPrimaryIndustry` | `string` | No | Filter by current company's primary industry. |
| `currentCompanySpecialities` | `string` | No | Filter by current company's specialities. |
| `currentCompanyEmployeeCountCategory` | `string` | No | Filter by current company's size. |
| `currentCompanyEmployeeCountMin` | `integer` | No | Filter by minimum current company employee count. |
| `currentCompanyEmployeeCountMax` | `integer` | No | Filter by maximum current company employee count. |
| `currentCompanyDescription` | `string` | No | Filter by current company's description. |
| `currentCompanyFoundedAfterYear` | `integer` | No | Filter by current company founded after this year. |
| `currentCompanyFoundedBeforeYear` | `integer` | No | Filter by current company founded before this year. |
| `currentCompanyFundingAmountMin` | `integer` | No | Filter by minimum current company funding amount. |
| `currentCompanyFundingAmountMax` | `integer` | No | Filter by maximum current company funding amount. |
| `currentCompanyFundingRaisedAfter` | `string` | No | Filter by funding raised after this date (ISO 8601). |
| `currentCompanyFundingRaisedBefore` | `string` | No | Filter by funding raised before this date (ISO 8601). |
| `currentCompanyDomainName` | `string` | No | Filter by current company's domain name. |
| `currentCompanyFollowerCountMin` | `integer` | No | Filter by minimum current company follower count. |
| `currentCompanyFollowerCountMax` | `integer` | No | Filter by maximum current company follower count. |
| `followerCountMin` | `integer` | No | Filter people with more than this many followers. |
| `followerCountMax` | `integer` | No | Filter people with fewer than this many followers. |
| `publicIdentifierInList` | `string` | No | Comma-separated list of person public identifiers to include. |
| `publicIdentifierNotInList` | `string` | No | Comma-separated list of person public identifiers to exclude. |
| `enrichProfiles` | `string` | No | Get the full profile data instead of only profile URLs. enrich adds 1 credit per result. |
| `pageSize` | `integer` | No | Max results per call. Default is 10 (max 100). When enriching, max is 10. |
| `useCache` | `string` | No | if-present returns cached data regardless of age. if-recent returns fresh data (max 29 days old) for 1 extra credit. |

## Run it

**MCP**

```ts
import { Client } from "@modelcontextprotocol/sdk/client/index.js"
import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js"
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const accessToken = await pd.rawAccessToken

const transport = new StreamableHTTPClientTransport(
  new URL("https://remote.mcp.pipedream.net/v3"),
  {
    requestInit: {
      headers: {
        Authorization: `Bearer ${accessToken}`,
        "x-pd-project-id": process.env.PIPEDREAM_PROJECT_ID!,
        "x-pd-environment": "production",
        "x-pd-external-user-id": "{external_user_id}", // any stable ID for this user in your system
        "x-pd-app-slug": "enrich_layer",
      },
    },
  },
)

const mcp = new Client({ name: "my-agent", version: "1.0.0" })
await mcp.connect(transport)

const { tools } = await mcp.listTools()

// listTools() hands your model this tool's input schema, so it can
// fill the arguments itself:
const result = await mcp.callTool({
  name: "enrich_layer-search-people",
  arguments: {
    country: "Country",
    firstName: "First Name",
  },
})
```

**TypeScript**

```ts
import { PipedreamClient } from "@pipedream/sdk"

const pd = new PipedreamClient({
  projectId: process.env.PIPEDREAM_PROJECT_ID!,
  clientId: process.env.PIPEDREAM_CLIENT_ID!,
  clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
  projectEnvironment: "production",
})

const result = await pd.actions.run({
  id: "enrich_layer-search-people",
  externalUserId: "{external_user_id}", // any stable ID for this user in your system
  configuredProps: {
    enrich_layer: { authProvisionId: "apn_xxxxxxx" },
    country: "Country",
    firstName: "First Name",
  },
})

console.log(result)
```

**cURL**

```bash
curl -X POST https://api.pipedream.com/v1/connect/{project_id}/actions/run \
  -H "Content-Type: application/json" \
  -H "X-PD-Environment: production" \
  -H "Authorization: Bearer {access_token}" \
  -d '{
    "external_user_id": "{external_user_id}",
    "id": "enrich_layer-search-people",
    "configured_props": {
      "enrich_layer": { "authProvisionId": "apn_xxxxxxx" },
      "country": "Country",
      "firstName": "First Name"
    }
  }'
```

---

- App: https://pipedream.com/apps/enrich-layer.md · All apps: https://pipedream.com/apps
