# contacts Detailed flag specifications for `resend contacts` commands. --- ## contacts list | Flag | Type | Default | Description | |------|------|---------|-------------| | `--limit ` | number | 10 | Max results (1-100) | | `--after ` | string | — | Forward pagination | | `--before ` | string | — | Backward pagination | --- ## contacts create | Flag | Type | Required | Description | |------|------|----------|-------------| | `--email ` | string | Yes | Contact email | | `--first-name ` | string | No | First name | | `--last-name ` | string | No | Last name | | `--unsubscribed` | boolean | No | Globally unsubscribe | | `--properties ` | string | No | Custom properties JSON | | `--segment-id ` | string[] | No | Add to segment(s) | --- ## contacts get **Argument:** `` — Contact UUID or email address (both accepted) --- ## contacts update **Argument:** `` — Contact UUID or email address | Flag | Type | Description | |------|------|-------------| | `--unsubscribed` | boolean | Set unsubscribed | | `--no-unsubscribed` | boolean | Re-subscribe | | `--properties ` | string | Merge properties (set key to `null` to clear) | --- ## contacts delete **Argument:** `` — Contact UUID or email address | Flag | Type | Required | Description | |------|------|----------|-------------| | `--yes` | boolean | Yes (non-interactive) | Skip confirmation | **Alias:** `rm` --- ## contacts segments List segments a contact belongs to. **Argument:** `` — Contact UUID or email --- ## contacts add-segment **Argument:** `` — Contact UUID or email | Flag | Type | Required | Description | |------|------|----------|-------------| | `--segment-id ` | string | Yes (non-interactive) | Segment ID to add to | --- ## contacts remove-segment **Arguments:** `` `` --- ## contacts topics List contact's topic subscriptions. **Argument:** `` — Contact UUID or email --- ## contacts update-topics **Argument:** `` — Contact UUID or email | Flag | Type | Required | Description | |------|------|----------|-------------| | `--topics ` | string | Yes (non-interactive) | JSON array: `[{"id":"topic-uuid","subscription":"opt_in"}]` | Subscription values: `opt_in` | `opt_out` --- ## contacts imports create Bulk-import contacts from a local CSV file. The file is uploaded as multipart form data (max 100MB). Imports run **asynchronously** — the command returns an import id immediately while the file is processed in the background (poll with `contacts imports get`). | Flag | Type | Required | Description | |------|------|----------|-------------| | `--file ` | string | Yes (non-interactive) | Path to the CSV file to import | | `--column-map ` | string | No | JSON object mapping contact fields to CSV column headers: `{"email":"Email","firstName":"First Name","properties":{"plan":{"column":"Plan","type":"string"}}}` | | `--on-conflict ` | string | No | How to handle existing contacts: `upsert` (default, updates) or `skip` | | `--segment-id ` | string[] | No | Add imported contacts to segment(s) — repeatable | | `--topics ` | string | No | JSON array: `[{"id":"topic-uuid","subscription":"opt_in"}]` | Mappable contact fields: `email`, `firstName`, `lastName`, `unsubscribed`, `properties`. Without `--column-map`, columns are matched by the lowercase names `email` (required), `first_name`, `last_name` — matching is **case-sensitive**, so a CSV with `Email`/`First Name` headers fails with `create_error` (422 "missing required email column"). Use `--column-map` to import such a file. --- ## contacts imports get Retrieve a contact import's status and counts. **Argument:** `[id]` — Contact import ID (interactive picker when omitted) Status values: `queued` | `in_progress` | `completed` | `failed` --- ## contacts imports list | Flag | Type | Default | Description | |------|------|---------|-------------| | `--limit ` | number | 10 | Max results (1-100) | | `--after ` | string | — | Forward pagination | | `--before ` | string | — | Backward pagination | | `--status ` | string | — | Filter by status: `queued` \| `in_progress` \| `completed` \| `failed` | **Alias:** `ls`