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

# Enrich a Contact List with the CLI

> Upload, onboard, and enrich a contact dataset with email and phone data using the Landbase CLI.

# Enrich a Contact List with the CLI

In this tutorial you will upload a contact file, normalize it into a Landbase dataset, run contact enrichment, and download the enriched child dataset.

**What you will need:** [Landbase CLI installed and authenticated](https://www.landbase.com/docs/install.md), plus a CSV or Excel file containing contacts. Rows should include a LinkedIn URL, or a name and company domain.

## 1. Upload the contact file

```bash theme={null}
landbase-cli upload ./leads.csv --name="Leads"
```

Copy the dataset ID from the JSON response. Call it `<uploaded-dataset-id>` below.

## 2. Onboard the dataset

Onboarding normalizes the column names and values so later workflows can use them reliably:

```bash theme={null}
landbase-cli workflow onboard <uploaded-dataset-id> --wait
```

Copy the `output_dataset_id` from the completed workflow. Call it `<onboarded-dataset-id>` below.

## 3. Start contact enrichment

Run the workflow on the onboarded dataset:

```bash theme={null}
landbase-cli workflow contact-enrich <onboarded-dataset-id> --enrich-phone
```

Email and phone enrichment run by default. A positive `--enrich-phone` flag selects phone-only opt-in behavior. Use `--enrich-email` and `--enrich-phone` together when you want both channels explicitly.

The command returns a workflow run ID. Call it `<workflow-run-id>` below.

## 4. Wait for the enriched dataset

```bash theme={null}
landbase-cli workflow wait <workflow-run-id>
```

A successful run returns an `output_dataset_id` for the enriched child dataset. Missing email or phone values are normal when no matching data is available.

## 5. Publish and download the results

Publish the enriched dataset to a file format:

```bash theme={null}
landbase-cli workflow publish <enriched-dataset-id> --format=csv --wait
```

Then download the published child dataset:

```bash theme={null}
landbase-cli datasets download <published-dataset-id> ./enriched.csv
```

Use `datasets lineage <onboarded-dataset-id> --direction=children` if you need to find the child dataset IDs created by the workflows.

## Processing large datasets

Use `--row-slice=START:END` to process a half-open row range when you need to split a large input into separate runs. Run slices one at a time, then recombine the output datasets with `workflow union` without dedupe keys. Use `--overwrite-existing` only when the workflow should replace existing contact values.

## What you learned

* Contact enrichment is a dataset workflow, not a raw JSONL submission command.
* Upload and onboard the input before running `workflow contact-enrich`.
* Contact enrichment creates a child dataset and is asynchronous.
* Use the workflow run ID to recover status and the output dataset ID to continue processing.

**Next step:** See [How enrichment works](https://www.landbase.com/docs/overview/concepts/how-enrichment-works.md) for the shared enrichment model and [contact-enrich migration reference](https://www.landbase.com/docs/reference/cli/contact-enrich.md) for the removed command's migration path.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.