From c16e148088f09177e408e681b06bdee07f82220c Mon Sep 17 00:00:00 2001 From: Zdeno Kuzmany Date: Tue, 2 Mar 2021 11:25:13 +0100 Subject: [PATCH 1/2] Add send custom email to contact by API --- source/includes/_api_endpoint_emails.md | 29 +++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/source/includes/_api_endpoint_emails.md b/source/includes/_api_endpoint_emails.md index 7256a534198..23dae4d4ef8 100644 --- a/source/includes/_api_endpoint_emails.md +++ b/source/includes/_api_endpoint_emails.md @@ -443,6 +443,35 @@ assetAttachments|array|Array of asset ids } ``` +### Send Custom HTML to Contact +```php +sendCustomToContact($emailId, $params); +``` +Send a custom HTML to existing contact. This event is saved to contact's profile, same like button Send email from contact's detail page. + +#### HTTP Request + +`POST /emails/contact/{contactId}/send/custom` + +**Post Parameters** + +Name|Type|Description +----|----|----------- +$params|array|Array of parameters (fromEmail - required, fromName, replyToEmail, replyToName, subject - required, content - required) + +#### Response + +`Expected Response Code: 200` + +**Properties** +```json +{ + "success": 1, + "trackingHash" : "xxxxxx" +} +``` + ### Send Email to Segment ```php Date: Wed, 1 Nov 2023 08:19:50 +0100 Subject: [PATCH 2/2] Update _api_endpoint_emails.md review text --- source/includes/_api_endpoint_emails.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/includes/_api_endpoint_emails.md b/source/includes/_api_endpoint_emails.md index 23dae4d4ef8..b9116a95424 100644 --- a/source/includes/_api_endpoint_emails.md +++ b/source/includes/_api_endpoint_emails.md @@ -443,12 +443,12 @@ assetAttachments|array|Array of asset ids } ``` -### Send Custom HTML to Contact +### Send Custom HTML email to Contact ```php sendCustomToContact($emailId, $params); ``` -Send a custom HTML to existing contact. This event is saved to contact's profile, same like button Send email from contact's detail page. +Send a custom HTML email to an existing contact. This event is saved to contact's profile, same behavior as Send email button from contact's detail page. #### HTTP Request