Update customer email address
curl --request PATCH \
--url https://coreapi.io/customer-email-addresses/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/merge-patch+json' \
--data '
{
"email": "john.doe@example.com",
"receiverName": "John Doe",
"isInvoiceEmail": true,
"isDunningEmail": false
}
'import requests
url = "https://coreapi.io/customer-email-addresses/{id}"
payload = {
"email": "john.doe@example.com",
"receiverName": "John Doe",
"isInvoiceEmail": True,
"isDunningEmail": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/merge-patch+json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {
Authorization: 'Bearer <token>',
'Content-Type': 'application/merge-patch+json'
},
body: JSON.stringify({
email: 'john.doe@example.com',
receiverName: 'John Doe',
isInvoiceEmail: true,
isDunningEmail: false
})
};
fetch('https://coreapi.io/customer-email-addresses/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://coreapi.io/customer-email-addresses/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'email' => 'john.doe@example.com',
'receiverName' => 'John Doe',
'isInvoiceEmail' => true,
'isDunningEmail' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/merge-patch+json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"email": "john.doe@example.com",
"receiverName": "John Doe",
"id": "00000000-0000-0000-0000-000000000000",
"isInvoiceEmail": true,
"isDunningEmail": false,
"default": "true"
}Email
Update customer email address
Update customer email address
Required permissions:customer:writePATCH
/
customer-email-addresses
/
{id}
Update customer email address
curl --request PATCH \
--url https://coreapi.io/customer-email-addresses/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/merge-patch+json' \
--data '
{
"email": "john.doe@example.com",
"receiverName": "John Doe",
"isInvoiceEmail": true,
"isDunningEmail": false
}
'import requests
url = "https://coreapi.io/customer-email-addresses/{id}"
payload = {
"email": "john.doe@example.com",
"receiverName": "John Doe",
"isInvoiceEmail": True,
"isDunningEmail": False
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/merge-patch+json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {
Authorization: 'Bearer <token>',
'Content-Type': 'application/merge-patch+json'
},
body: JSON.stringify({
email: 'john.doe@example.com',
receiverName: 'John Doe',
isInvoiceEmail: true,
isDunningEmail: false
})
};
fetch('https://coreapi.io/customer-email-addresses/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://coreapi.io/customer-email-addresses/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'email' => 'john.doe@example.com',
'receiverName' => 'John Doe',
'isInvoiceEmail' => true,
'isDunningEmail' => false
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/merge-patch+json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}{
"email": "john.doe@example.com",
"receiverName": "John Doe",
"id": "00000000-0000-0000-0000-000000000000",
"isInvoiceEmail": true,
"isDunningEmail": false,
"default": "true"
}Autorisierungen
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Pfadparameter
CustomerEmail identifier
Body
application/merge-patch+jsonapplication/vnd.api+json
The updated CustomerEmail resource
Maximum string length:
255Beispiel:
"john.doe@example.com"
Maximum string length:
255Beispiel:
"John Doe"
Use this email for invoices, credits and financial documents.
Beispiel:
true
Use this email for dunning reminders and payment reminders.
Beispiel:
false
Antwort
CustomerEmail resource updated
Maximum string length:
255Beispiel:
"john.doe@example.com"
Maximum string length:
255Beispiel:
"John Doe"
Beispiel:
"00000000-0000-0000-0000-000000000000"
Use this email for invoices, credits and financial documents.
Beispiel:
true
Use this email for dunning reminders and payment reminders.
Beispiel:
false
Beispiel:
"true"
War diese Seite hilfreich?