AddEmailTemplate

Overview

Adds a new “Email Template” to settings based on information sent via an http form post.

Post Url

https://www.allclients.com/api/2/AddEmailTemplate.aspx
  • SSL is requred
  • White Label CRM Customers: Replace www.allclients.com with your White Label CRM domain name.

Form Fields

Field Max Length* Required Notes
response_type No Default results will be returned in XML. Set this field value to json to return results in JSON format
accountid Yes Must be numeric. Account ID for this account. Found in Settings > API Settings or for White Label CRM in the Admin control panel
apikey Yes API Key for this account. Found in Settings > API Settings or for White Label CRM in the Admin control panel
teammemberid No Must be numeric. Team Member ID. Defaults to 0 (Account Owner).
name 50 Yes Display name for the Email Template
folder 50 No Folder for Email Template. If folder does not exist, it will be created.
subjectline 75 Yes Email Subject Line
messagebody Yes Email Message Body – HTML, Encoded

* You must HTML Encode / Output Escape your HTML, otherwise you will receive a server security error.

** This error will not be in the normal XML format, so be sure you look for a success message to confirm that your content was added

*** Do not include <HTML> or <HEAD> or <BODY> tags in your Email Templates.

Sample Results

Success Message

<?xml version="1.0"?>
<results>
    <message>Success</message>
    <emailtemplateid>15631</emailtemplateid>
</results>

Sample Failure Message

<?xml version="1.0"?>
<results>
    <error>Authentication failed</error>
</results>

<?xml version="1.0"?>
 <results>
     <error>Email Template with this 'name' already exists</error>
 </results>