Overview
Naturalead provides a two-step CSV import process that lets you preview and map columns before committing leads to your account. This prevents data errors and gives you full control over how CSV columns map to lead fields.1
Upload CSV for Preview
Upload your CSV file to get a preview of parsed rows and detected columns.
2
Map Columns and Confirm
Define how CSV columns map to lead fields, then confirm the import.
All imported leads are automatically deduplicated by phone number. If a lead with the same phone already exists in your account, it will be updated rather than duplicated.
Step 1: Upload CSV for Preview
Send your CSV file as a multipart form upload. The API parses the file and returns detected columns along with a sample of rows so you can verify the data before importing.columns— an array of detected column names from the CSV header rowrows— a sample of parsed rows for verificationuploadId— a temporary identifier to reference this upload in the confirm step
Step 2: Map Columns and Confirm Import
Once you have reviewed the preview, send a column mapping and theuploadId to confirm the import. The mapping tells Naturalead which CSV column corresponds to each lead field.
Field Mapping Rules
The mapping object maps CSV column names (keys) to Naturalead lead fields (values).
Any CSV column mapped to a value that is not a recognized lead field is automatically stored as a custom field on the lead. For example, mapping
"Company" to "company" will create a custom field called company on each lead.
Deduplication
Naturalead deduplicates leads by phone number within your account. During import:- If a lead with the same phone number already exists, the existing lead is updated with the new data.
- If no match is found, a new lead is created.
Tracking Imports with importBatchId
Every confirmed import generates a uniqueimportBatchId. Use this ID to:
- Filter leads by import batch using the List Leads API
- Track import history to see which leads came from which file
- Roll back imports by identifying and deleting all leads from a specific batch
Store the
importBatchId returned from the confirm response. It is the only way to identify which leads were part of a specific import.Error Handling
When some rows fail validation but others succeed, the API performs a partial import and returns both the count of successfully imported leads and details about skipped rows in the response.