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

# Bettercontact Enrich: Inputs, Cost & CLI Example

> Launch a BetterContact enrichment job for one known contact. Includes inputs, outputs, pricing notes, Deepline CLI examples, and GTM automation guidance.

## Run in Enrichment Spreadsheet

<Info>
  Use this function as a column step in `deepline enrich`.
</Info>

```bash theme={null}
deepline enrich --input leads.csv --output leads.enriched.csv --with 'result=bettercontact_enrich:{"first_name":"{{first_name}}","last_name":"{{last_name}}"}' --json
```

<Tip>
  Map payload values to spreadsheet columns with `{{column_name}}` placeholders.
</Tip>

## Input Schema

| Name                           | Type      | Required | Default | Description                                                                                                                          |
| ------------------------------ | --------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| `payload.first_name`           | `string`  | Yes      |         | Contact first name.                                                                                                                  |
| `payload.last_name`            | `string`  | Yes      |         | Contact last name.                                                                                                                   |
| `payload.company`              | `string`  | No       |         | Legacy company identifier preserved for migration compatibility.                                                                     |
| `payload.company_domain`       | `string`  | No       |         | Company domain, for example acme.com.                                                                                                |
| `payload.linkedin_url`         | `string`  | No       |         | Optional LinkedIn profile URL.                                                                                                       |
| `payload.enrich_phone_number`  | `boolean` | No       | `false` | When true, BetterContact also attempts mobile phone enrichment.                                                                      |
| `payload.enrich_email_address` | `boolean` | No       | `true`  | Deprecated legacy flag preserved for contract compatibility.                                                                         |
| `payload.wait_for_completion`  | `boolean` | No       | `true`  | Deprecated legacy sync hint preserved for contract compatibility.                                                                    |
| `payload.poll_interval_ms`     | `integer` | No       | `2000`  | Deprecated legacy sync hint preserved for contract compatibility.                                                                    |
| `payload.max_wait_ms`          | `integer` | No       | `30000` | Deprecated legacy sync hint preserved for contract compatibility. Larger values are clamped to the Deepline async sync-wait ceiling. |

<details>
  <summary>Show raw input schema</summary>

  ### Input JSON Schema

  ```json theme={null}
  {
    "type": "object",
    "description": "Submit one contact for BetterContact async enrichment. Use bettercontact_get_result with the returned request id to retrieve terminal results.",
    "properties": {
      "first_name": {
        "type": "string",
        "description": "Contact first name.",
        "minLength": 1
      },
      "last_name": {
        "type": "string",
        "description": "Contact last name.",
        "minLength": 1
      },
      "company": {
        "type": "string",
        "description": "Legacy company identifier preserved for migration compatibility.",
        "minLength": 1
      },
      "company_domain": {
        "type": "string",
        "description": "Company domain, for example acme.com.",
        "minLength": 1
      },
      "linkedin_url": {
        "type": "string",
        "description": "Optional LinkedIn profile URL.",
        "minLength": 1
      },
      "enrich_phone_number": {
        "type": "boolean",
        "description": "When true, BetterContact also attempts mobile phone enrichment.",
        "default": false
      },
      "enrich_email_address": {
        "type": "boolean",
        "description": "Deprecated legacy flag preserved for contract compatibility.",
        "default": true
      },
      "wait_for_completion": {
        "type": "boolean",
        "description": "Deprecated legacy sync hint preserved for contract compatibility.",
        "default": true
      },
      "poll_interval_ms": {
        "type": "integer",
        "description": "Deprecated legacy sync hint preserved for contract compatibility.",
        "default": 2000,
        "minimum": 250,
        "maximum": 10000
      },
      "max_wait_ms": {
        "type": "integer",
        "description": "Deprecated legacy sync hint preserved for contract compatibility. Larger values are clamped to the Deepline async sync-wait ceiling.",
        "default": 30000,
        "minimum": 1000,
        "maximum": 120000
      }
    },
    "required": [
      "first_name",
      "last_name"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Output Schema

| Name          | Type     | Required | Default | Description                                    |
| ------------- | -------- | -------- | ------- | ---------------------------------------------- |
| `result.data` | `object` | Yes      |         | Provider response payload.                     |
| `result.meta` | `object` | No       |         | Additional response metadata (status, paging). |

<details>
  <summary>Show raw output schema</summary>

  ### Output JSON Schema

  ```json theme={null}
  {
    "type": "object",
    "description": "Standard tool result payload.",
    "properties": {
      "data": {
        "type": "object",
        "description": "Provider response payload.",
        "properties": {
          "success": {
            "type": "boolean"
          },
          "id": {
            "type": "string"
          },
          "message": {
            "type": "string"
          }
        },
        "additionalProperties": false
      },
      "meta": {
        "type": "object",
        "description": "Additional response metadata (status, paging).",
        "additionalProperties": true
      }
    },
    "required": [
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Advanced: Direct CLI

<Info>
  Use direct execution for single payload debugging.
</Info>

```bash theme={null}
deepline tools execute bettercontact_enrich --payload '{
  "first_name": "string",
  "last_name": "string"
}' --json
```

### CLI flags

| Flag                        | Description                                         |
| --------------------------- | --------------------------------------------------- |
| `--json`                    | Print machine-readable output.                      |
| `--wait`                    | Wait for terminal provider status when supported.   |
| `--debug`                   | Enable wait mode with additional status/log output. |
| `--wait-timeout SECONDS`    | Max seconds to wait in wait mode.                   |
| `--poll-interval SECONDS`   | Polling interval in seconds during wait mode.       |
| `--timeout SECONDS`         | Request timeout in seconds.                         |
| `--connect-timeout SECONDS` | Connection timeout in seconds.                      |

## Cost

* Pricing model: `per_result` (per result).
* Estimated Deepline credits: `0.69` per pricing unit.
* Billing mode: `post_deduct`.
