Resend icon

Resend

Send emails, manage contacts, create broadcasts, handle templates, domains, segments, topics, and webhooks using the Resend email platform

Contact → Create Import

AI-generated

Summary

Import contacts in bulk from a CSV file to Resend, mapping CSV columns to contact fields, optionally assigning segments and topic subscriptions, and handling duplicates by skipping or upserting.

Inputs

  • Authentication — Choose either API Key or OAuth2 authentication method for Resend API access.
  • Input Data Field Name (required) — Name of the binary input field holding the CSV file to import; this file contains the contacts to be imported.
  • Import Fields — A collection of import settings including:
  • Column Map (JSON) to map CSV columns to contact fields (email, first_name, last_name, unsubscribed, and custom properties with types: string, number, boolean).
  • File Name string for the CSV file sent to Resend (defaults to input binary filename if empty).
  • On Conflict option to either skip existing contacts or upsert (create or update).
  • Segments list to add imported contacts to by segment name or ID.
  • Topics list for topic subscriptions with subscription status (opt_in or opt_out).

Output shape

a single import object containing details of the contact import job

The operation returns the created import's data object, which includes import metadata. The import uses the CSV file from the specified binary input field, and respects the provided column mappings and options. Maximum CSV file size limits apply according to Resend's API documentation.

Examples

Example 1: Import contacts from a CSV file named 'contacts.csv' supplied in binary field 'data', mapping CSV headers to Resend contact fields, skipping duplicate contacts, and adding them to a specified segment with topic subscriptions.

Authentication set to OAuth2; Input Data Field Name set to 'data'; Import Fields include JSON column mapping for email and first name, file name override 'contacts.csv', onConflict set to 'skip', segments set with one segment ID, topics set with topic IDs and opt_in subscriptions.

Links

Discussion