Use email templates to organize email content and add style to make emails stand out to customers and vendors. You can create a variety of email templates to use for different types of transactions, different vendors, or different customers. You can add merge fields to populate emails with dynamic data from Sage Intacct, such as the vendor name, contact information, and so on.
Returns a collection with a key, ID, and link for each email template. This operation is mostly for use in testing; use query to find objects that meet certain criteria and to specify properties that are returned.
Subscription | Company |
---|---|
User type | Business |
Permissions | Email templates: List |
OK
Bad Request
{- "ia::result": [
- {
- "key": "1",
- "id": "1",
- "href": "/objects/company-config/email-template/1"
}, - {
- "key": "2",
- "id": "2",
- "href": "/objects/company-config/email-template/2"
}
], - "ia::meta": {
- "totalCount": 2,
- "start": 1,
- "pageSize": 100,
- "next": null,
- "previous": null
}
}
Creates a new email template.
Subscription | Company |
---|---|
User type | Business |
Permissions | Email templates: Add |
Email template to create
name required | string Name for the email template. Example: "Sales invoice-Monthly" | ||||||
subject required | string Enter a combination of text and merge fields as desired to create an informative subject line. Example: "Account statement due by {!ARINVOICE.WHENDUE!}" | ||||||
body required | string Enter a combination of text, merge fields, and HTML markup as desired to create and customize the message. Example: "Message for all to see" | ||||||
status | string Default: "active" Object status. Active objects are fully functional. Inactive objects are essentially hidden and cannot be used or referenced. Example: "active" | ||||||
description | string Description of the email template. Example: "Used to send monthly sales invoices." | ||||||
object Sender information for the email template. | |||||||
| |||||||
object Recipient information for the email template. You can put one or more email addresses in each field (use commas to separate multiple addresses), or you can use one or more merge fields in each field. The merge fields are replaced with the actual email addresses when the email is sent. | |||||||
| |||||||
object Logo information for the email template. The logo is included in the email if the | |||||||
| |||||||
includeTxnAttachments | boolean Default: false Set to Example: true | ||||||
includeProjectInvoiceTxnAttachments | boolean Default: false Set to Example: true | ||||||
templateType | string Default: "arInvoice" The type of transaction to use this email template for. This value determines the merge fields available for use in the subject and body of the email template. Example: "arInvoice" | ||||||
useSendersPreferredDateFormat | boolean Default: false Set to Example: true | ||||||
combineAttachmentsToZip | string Default: "none" Combine attachments into a zip file
Example: "none" |
Created
Bad Request
{- "name": "New Customer Email Template",
- "description": "Email template for new customers",
- "templateType": "purchasingTxn",
- "subject": "Welcome!",
- "body": "New customers receive a 10% discount on their first subscription order."
}
{- "ia::result": {
- "id": "12",
- "key": "12",
- "href": "/objects/company-config/email-template/12"
}, - "ia::meta": {
- "totalCount": 1,
- "totalSuccess": 1,
- "totalError": 0
}
}
Returns detailed information for a specified email template.
Subscription | Company |
---|---|
User type | Business |
Permissions | Email templates: List, View |
key required | string System-assigned key for the email-template. Example: 12 |
OK
Bad Request
{- "ia::result": {
- "id": "2",
- "key": "2",
- "audit": {
- "createdDateTime": "2014-08-22T18:45:25Z",
- "modifiedDateTime": "2014-05-19T06:12:46Z",
- "createdByUser": {
- "key": "1",
- "href": "/objects/company-config/user/1"
}, - "createdBy": "1",
- "modifiedByUser": {
- "key": "82",
- "href": "/objects/company-config/user/82"
}, - "modifiedBy": "82"
}, - "status": "active",
- "name": "Email Template for Customer",
- "description": "Email Template for Customer",
- "templateType": "contract",
- "recipients": {
- "to": "{!CONTRACT.DISPLAYCONTACT.EMAIL1}",
- "cc": "'{!CONTRACT.DISPLAYCONTACT.EMAIL2!};{!CONTRACT.BILLTO.EMAIL1!}'",
- "bcc": null
}, - "subject": "Renewal notification for contract: {!CONTRACT.CONTRACTID!}",
- "body": "'Hi {!CONTRACT.CUSTOMERNAME!},\n\nThis is a friendly reminder that the contract {!CONTRACT.CONTRACTID!}--{!CONTRACT.NAME!} is renewing {!CONTRACT.ENDDATE!}. The renewal contract is {!CONTRACT.BASECURR!}.\nPlease contact your sales representative if you have any questions.\nRegards,\nContract Team.'",
- "logo": {
- "isLogoIncluded": true,
- "verticalPosition": "top",
- "horizontalPosition": "left"
}, - "includeTxnAttachments": false,
- "includeProjectInvoiceTxnAttachments": false,
- "useSendersPreferredDateFormat": null,
- "combineAttachmentsToZip": "none",
- "href": "/objects/company-config/email-template/2"
}, - "ia::meta": {
- "totalCount": 1,
- "totalSuccess": 1,
- "totalError": 0
}
}
Updates an existing email template by setting field values. Any fields not provided remain unchanged.
Subscription | Company |
---|---|
User type | Business |
Permissions | Email templates: Edit |
key required | string System-assigned key for the email-template. Example: 12 |
status | string Default: "active" Object status. Active objects are fully functional. Inactive objects are essentially hidden and cannot be used or referenced. Example: "active" | ||||||
name | string Name for the email template. Example: "Sales invoice-Monthly" | ||||||
description | string Description of the email template. Example: "Used to send monthly sales invoices." | ||||||
object Sender information for the email template. | |||||||
| |||||||
object Recipient information for the email template. You can put one or more email addresses in each field (use commas to separate multiple addresses), or you can use one or more merge fields in each field. The merge fields are replaced with the actual email addresses when the email is sent. | |||||||
| |||||||
subject | string Enter a combination of text and merge fields as desired to create an informative subject line. Example: "Account statement due by {!ARINVOICE.WHENDUE!}" | ||||||
body | string Enter a combination of text, merge fields, and HTML markup as desired to create and customize the message. Example: "Message for all to see" | ||||||
object Logo information for the email template. The logo is included in the email if the | |||||||
| |||||||
includeTxnAttachments | boolean Default: false Set to Example: true | ||||||
includeProjectInvoiceTxnAttachments | boolean Default: false Set to Example: true | ||||||
templateType | string Default: "arInvoice" The type of transaction to use this email template for. This value determines the merge fields available for use in the subject and body of the email template. Example: "arInvoice" | ||||||
useSendersPreferredDateFormat | boolean Default: false Set to Example: true | ||||||
combineAttachmentsToZip | string Default: "none" Combine attachments into a zip file
Example: "none" |
OK
Bad Request
{- "name": "New Customer Email SW",
- "includeTxnAttachments": true
}
{- "ia::result": {
- "id": "6",
- "key": "6",
- "href": "/objects/company-config/email-template/6"
}, - "ia::meta": {
- "totalCount": 1,
- "totalSuccess": 1,
- "totalError": 0
}
}
Deletes an email template.
Subscription | Company |
---|---|
User type | Business |
Permissions | Email templates: Delete |
key required | string System-assigned key for the email-template. Example: 12 |
No Content
Bad Request
{- "ia::result": {
- "ia::error": {
- "code": "invalidRequest",
- "message": "A POST request requires a payload",
- "errorId": "REST-1028",
- "additionalInfo": {
- "messageId": "IA.REQUEST_REQUIRES_A_PAYLOAD",
- "placeholders": {
- "OPERATION": "POST"
}, - "propertySet": { }
}, - "supportId": "Kxi78%7EZuyXBDEGVHD2UmO1phYXDQAAAAo"
}
}, - "ia::meta": {
- "totalCount": 1,
- "totalSuccess": 0,
- "totalError": 1
}
}
Use the query service to find email templates that meet certain criteria and to specify the properties that are returned.
OK
Bad Request
{- "ia::result": {
- "ia::error": {
- "code": "invalidRequest",
- "message": "A POST request requires a payload",
- "errorId": "REST-1028",
- "additionalInfo": {
- "messageId": "IA.REQUEST_REQUIRES_A_PAYLOAD",
- "placeholders": {
- "OPERATION": "POST"
}, - "propertySet": { }
}, - "supportId": "Kxi78%7EZuyXBDEGVHD2UmO1phYXDQAAAAo"
}
}, - "ia::meta": {
- "totalCount": 1,
- "totalSuccess": 0,
- "totalError": 1
}
}