> ## 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.

# Smartlead Upsert Email Account: Inputs, Cost & CLI Example

> Creating or updating a sending email account. 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=smartlead_upsert_email_account:{"id":"{{id}}","from_name":"{{from_name}}","from_email":"{{from_email}}","user_name":"{{user_name}}","password":"{{password}}","smtp_host":"{{smtp_host}}","smtp_port":"{{smtp_port}}","imap_host":"{{imap_host}}","imap_port":"{{imap_port}}"}' --json
```

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

## Input Schema

| Name                            | Type      | Required | Default | Description                       |
| ------------------------------- | --------- | -------- | ------- | --------------------------------- |
| `payload.id`                    | `integer` | Yes      |         |                                   |
| `payload.from_name`             | `string`  | Yes      |         | Display name for outgoing emails. |
| `payload.from_email`            | `string`  | Yes      |         | From email address.               |
| `payload.user_name`             | `string`  | Yes      |         | User name for SMTP/IMAP login.    |
| `payload.password`              | `string`  | Yes      |         | Password for SMTP/IMAP login.     |
| `payload.smtp_host`             | `string`  | Yes      |         | SMTP server hostname.             |
| `payload.smtp_port`             | `integer` | Yes      |         | SMTP server port.                 |
| `payload.imap_host`             | `string`  | Yes      |         | IMAP server hostname.             |
| `payload.imap_port`             | `integer` | Yes      |         | IMAP server port.                 |
| `payload.max_email_per_day`     | `integer` | No       |         |                                   |
| `payload.custom_tracking_url`   | `string`  | No       |         |                                   |
| `payload.bcc`                   | `string`  | No       |         |                                   |
| `payload.signature`             | `string`  | No       |         |                                   |
| `payload.warmup_enabled`        | `boolean` | No       |         |                                   |
| `payload.total_warmup_per_day`  | `integer` | No       |         |                                   |
| `payload.daily_rampup`          | `integer` | No       |         |                                   |
| `payload.reply_rate_percentage` | `integer` | No       |         |                                   |
| `payload.client_id`             | `integer` | No       |         |                                   |

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

  ### Input JSON Schema

  ```json theme={null}
  {
    "type": "object",
    "description": "Smartlead add/update email account input.",
    "properties": {
      "id": {
        "type": [
          "integer",
          "null"
        ]
      },
      "from_name": {
        "type": "string",
        "description": "Display name for outgoing emails.",
        "minLength": 1
      },
      "from_email": {
        "type": "string",
        "description": "From email address.",
        "format": "email"
      },
      "user_name": {
        "type": "string",
        "description": "User name for SMTP/IMAP login.",
        "minLength": 1
      },
      "password": {
        "type": "string",
        "description": "Password for SMTP/IMAP login.",
        "minLength": 1
      },
      "smtp_host": {
        "type": "string",
        "description": "SMTP server hostname.",
        "minLength": 1
      },
      "smtp_port": {
        "type": "integer",
        "description": "SMTP server port.",
        "minimum": 1
      },
      "imap_host": {
        "type": "string",
        "description": "IMAP server hostname.",
        "minLength": 1
      },
      "imap_port": {
        "type": "integer",
        "description": "IMAP server port.",
        "minimum": 1
      },
      "max_email_per_day": {
        "type": "integer"
      },
      "custom_tracking_url": {
        "type": "string"
      },
      "bcc": {
        "type": "string"
      },
      "signature": {
        "type": "string"
      },
      "warmup_enabled": {
        "type": "boolean"
      },
      "total_warmup_per_day": {
        "type": [
          "integer",
          "null"
        ]
      },
      "daily_rampup": {
        "type": [
          "integer",
          "null"
        ]
      },
      "reply_rate_percentage": {
        "type": [
          "integer",
          "null"
        ]
      },
      "client_id": {
        "type": [
          "integer",
          "null"
        ]
      }
    },
    "required": [
      "id",
      "from_name",
      "from_email",
      "user_name",
      "password",
      "smtp_host",
      "smtp_port",
      "imap_host",
      "imap_port"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Output Schema

Output schema is not available yet.

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

  ### Output JSON Schema

  ```json theme={null}
  {
    "description": "Raw Smartlead upsert email account payload."
  }
  ```
</details>

## Advanced: Direct CLI

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

```bash theme={null}
deepline tools execute smartlead_upsert_email_account --payload '{
  "id": "integer",
  "from_name": "string",
  "from_email": "string",
  "user_name": "string",
  "password": "string",
  "smtp_host": "string",
  "smtp_port": "integer",
  "imap_host": "string",
  "imap_port": "integer"
}' --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: `fixed` (per call).
* Estimated Deepline credits: `0` per pricing unit.
* Provider-native pricing may still exist outside Deepline credit billing.
* Billing mode: `no_bill`.
