Create Contact Import
create-contact-importImport contacts from a CSV file into Resend. Provide the CSV via file path, raw content, or URL. Works asynchronously, returning an import ID to track progress.
Instructions
Bulk-import contacts from a CSV file into Resend. The import is processed asynchronously: this returns an import ID immediately, then use get-contact-import to poll its status and counts. Provide the CSV via exactly one of filePath, content, or url. Max file size 100MB.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | URL of a CSV file to fetch and upload. Use one of filePath, content, or url. | |
| topics | No | Topic subscription configurations applied to the imported contacts. | |
| content | No | Raw CSV text to upload (e.g. "email,first_name\na@b.com,Ada"). Use one of filePath, content, or url. | |
| filePath | No | Local path to a CSV file to read and upload. Use one of filePath, content, or url. | |
| filename | No | Name for the uploaded file. Defaults to "contacts.csv". | |
| columnMap | No | Maps contact fields to CSV header names. When omitted, headers are matched case-sensitively to "email", "first_name", and "last_name". | |
| onConflict | No | How to handle contacts that already exist: "upsert" updates them, "skip" leaves them unchanged. Defaults to "upsert". | |
| segmentIds | No | Array of segment IDs to assign the imported contacts to. |