# Preview an enrichment

What POST /person/enrich can cost at most. Same body: `profile_urls` or `person_ids`, not both, plus `include_email` and `max_credits`. Nothing is looked up.

What POST /person/enrich can cost at most. Same body: `profile_urls` or `person_ids`, not both, plus `include_email` and `max_credits`. Nothing is looked up.

## Authentication

Send `Authorization: Bearer gtk_…`. Create the key under **Connect assistant → API keys**. A missing, invalid or revoked key is **401**, including while this API is closed. A valid key while the API is closed for your organization answers **404**, the same body as an unknown path. Every response includes `FounderMCP-Api-Version` and `FounderMCP-Request-Id`.

### Body parameters

- **`profile_urls`** `string[]` — 1 to 25 LinkedIn profile URLs. Send this or `person_ids`, not both.
- **`person_ids`** `string[]` — 1 to 25 person ids (`per_…`) from an earlier response, kept 30 days.
- **`include_email`** `boolean` — Look up a work email. Adds 10 credits per address the real call finds. Defaults to false. No phone.
- **`max_credits`** `integer | null` — Caps the preview.

## Response

- **`object`** `string` · **required** — Always `cost_preview`. One of: `cost_preview`.
- **`endpoint`** `string` · **required** — Which call this previews. One of: `searches`, `leads`, `person.enrich`, `monitors`.
- **`row_key`** `string` · **required** — The row type that sets the headline price.
- **`credits_per_row`** `integer` · **required** — Credits for one row of `row_key`.
- **`max_rows`** `integer` · **required** — The most rows this call can return.
- **`max_credits`** `integer` · **required** — The most the call can spend. A `max_credits` you sent caps it.
- **`period`** `string` · **required** — `call` for one request, `day` for a monitor. One of: `call`, `day`.
- **`rows`** `object[]` · **required** — Every row type the call can deliver: `row_key`, `credits_per_row`, `max_rows`.
- **`notes`** `string[]` · **required** — Plain-language limits of this preview.

## Credits

Free. On the real call a profile is 2 credits and a found email adds 10.

## Errors

- **400** `invalid_request` — Both `profile_urls` and `person_ids`, or neither.
- **401** `authentication_error` — The Authorization header is missing, or the key is unknown or revoked.
- **403** `permission_error` — API access is not part of your plan, or your account is suspended.
- **404** `not_found` — The endpoint does not exist.
- **429** `rate_limit_error` — More than 60 requests per minute, or more than 3 at the same time, on one key. Wait for the Retry-After header.
- **500** `internal_error` — Something went wrong on our side.

## Example

### cURL

```bash
curl -X POST "https://foundermcp.dev/api/v1/person/enrich/preview" \
  -H "Authorization: Bearer $FOUNDERMCP_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "profile_urls": [
      "https://www.linkedin.com/in/jane-example"
    ],
    "include_email": true
  }'
```

### JavaScript

```javascript
const response = await fetch('https://foundermcp.dev/api/v1/person/enrich/preview', {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.FOUNDERMCP_API_KEY}`,
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    "profile_urls": [
      "https://www.linkedin.com/in/jane-example"
    ],
    "include_email": true
  })
});
const body = await response.json();
```

### Python

```python
import json
import os
import urllib.request

payload = {
  "profile_urls": [
    "https://www.linkedin.com/in/jane-example"
  ],
  "include_email": true
}

request = urllib.request.Request(
    "https://foundermcp.dev/api/v1/person/enrich/preview",
    headers={
    "Authorization": f"Bearer {os.environ['FOUNDERMCP_API_KEY']}",
    "Content-Type": "application/json"
    },
    data=json.dumps(payload).encode(),
    method="POST",
)
with urllib.request.urlopen(request) as response:
    body = json.load(response)
```

### Example response

```json
{
  "object": "cost_preview",
  "endpoint": "person.enrich",
  "row_key": "enrich_email",
  "credits_per_row": 12,
  "max_rows": 1,
  "max_credits": 12,
  "period": "call",
  "rows": [
    {
      "row_key": "enrich_profile",
      "credits_per_row": 2,
      "max_rows": 1
    },
    {
      "row_key": "enrich_email",
      "credits_per_row": 12,
      "max_rows": 1
    }
  ],
  "notes": []
}
```
