Import subscribers
v1
post
/1/newsletters/{domain}/subscribers/import
Import subscribers from a upload id.
By default, if subscribers exists replace the custom fields with the new values
Path parameters
domain
requiredstring
Examples:example
Body Parameters
application/jsoncsv_enclosurestring
Examples:example
csv_separatorstring
Examples:example
fieldsrequiredarray
MinLength:1
groupsarray
ipd_uuidstring
Examples:example
replace_fieldsboolean
upload_idinteger
Examples:31663
Response Body
application/json
resultstring
Possible values:successerrorasynchronous
Result of the HTTP request
Examples:success
dataobject
Example request
<?php
use GuzzleHttp\Client;
$client = new Client();
$headers = [
'Authorization' => 'Bearer YOUR-TOKEN-HERE',
'Content-Type' => 'application/json'
];
$body = '{
"fields": []
}';
$request = new Request('POST', 'https://api.infomaniak.com/1/newsletters/{domain}/subscribers/import', $headers, $body);
$res = $client->sendAsync($request)->wait();
echo $res->getBody();
Example response
application/json
{"result":"success"}