import

Description

This function can be used to import subscribers with CSV files.



Params

Name Type Description
apiKey string API key previously generated.
fileContent string The content of the CSV file that you want to import, encoded with base64.
groups array The ids of the groups for this import.
fields array Optional parameter to specify the mapping between the fields in the file and the fields in Mailrelay. If not specified, the first field is the email and the second the name of the subscriber.
delimiter string Optional parameter to specify the delimiter char for the fields in the file. Example: "," for CSV files.
enclosure string Optional parameter to specify the enclosure char for the fields in the file. Example: " for CSV files.
@param string $escape Optional parameter to specify the escape chart for the fields in the file. Example: "" for CSV files.
headers boolean Set to true if your CSV file contains headers at the first line. They will be ignored in this case.
existingEmails boolean What should we do with existing emails? Use "skip" to ignore these emails or "replace" to add the existing emails to the groups that you specified. If not specified the value is "replace".
notificationUrl string Optional parameter to set a notification URL. This url will be called after the import is finsihed. The POST request will contain a single parameter called "id" with the ID of the import.

 

Returned data

Type: integer

Description: The ID of the import that was created. You may check the progress and status of the import by calling getImportData function.

 

Json sample code

Json sample code is not available.

 

Result of API call

API call result sample code is not available.

Menu Title