With the Email endpoints you can manage Custom Domains and Notification Templates.
CustomDomainDto Object
| Property | Type | Description |
|---|---|---|
| id | string | The id of the custom domain object. |
| domain | string | The domain name. |
| dns | DnsDto | Contains the DNS records that must be added to your domain. |
| valid | boolean | The indicator of the DNS records validity. |
DnsDto Object
| Property | Type | Description |
|---|---|---|
| mailCname | RecordDto | Record that must be added to your domain. |
| dkim1 | RecordDto | Record that must be added to your domain. |
| dkim2 | RecordDto | Record that must be added to your domain. |
RecordDto Object
| Property | Type | Description |
|---|---|---|
| valid | boolean | The indicator of the DNS record validity. |
| type | string | The type of the record that must be added to your domain. |
| host | string | The host name of the record that must be added to your domain. |
| data | string | The value of the record that must be added to your domain. |
CustomDomainRequestBody Object
| Property | Type | Description |
|---|---|---|
| domain | string | The domain name. |
NotificationTemplateResponseDto Object
| Property | Type | Description |
|---|---|---|
| id | string | The id of the template. |
| status | object | The current status of the template. It holds status ('active', 'disabled' or 'deleted') and an optional description. |
| isCustom | boolean | Boolean flag indicates customized template. |
| type | TypeDto | It holds the type related properties. |
| settings | SettingsDto | It holds the settings related properties. |
| content | ContentDto | It holds the content related properties. |
TypeDto Object
| Property | Type | Description |
|---|---|---|
| isScheduleCustom | boolean | Boolean flag indicates customized schedule. |
| isTriggerCustom | boolean | Boolean flag indicates customized trigger. |
| name | string | Name of the template. |
| schedule | number[] | Sets how many days after an impact creation a signup nudging email is sent out to your customer. |
| template | string | The name of the template. It can be: 'invitation', 'update', 'nudge'. |
| trigger | string[] | The name of the triggers. It can be: 'offsetPerOrder', 'offsetPerProduct', 'offsetBySpend', 'offsetByStoreRevenue', 'offsetByPercentageOrder', 'offsetPerSubscription', 'offsetPerReview', 'byLoyaltyPoints', 'byPercentageOfPaidInvoice', 'byPercentageOfRevenue', 'bySpendOfPaidInvoice', 'byTieredSpendOfPaidInvoice', 'perPaidInvoice', 'perCompletedForm', 'perSelectedAnswer', 'customerCartContribution', 'customerChoicePerOrder'. The name of a custom integration trigger is also allowed. |
SettingsDto Object
| Property | Type | Description |
|---|---|---|
| alias | string | This is the name display for the specified sender email address. |
| from | EmailDto | The email address used for sending emails. |
| isAliasCustom | boolean | Boolean flag indicates customized alias. |
| isFromCustom | boolean | Boolean flag indicates customized sender email address. |
| isPreheaderCustom | boolean | Boolean flag indicates customized preheader. |
| isSubjectCustom | boolean | Boolean flag indicates customized subject. |
| preheader | string | The preheader is the text following the subject line when an email is previewed. |
| schedule | ScheduleDto | You can choose to send your template continuously starting at the selected start date or only during a specific date range. |
| subject | string | Your subject line is one of the first things that your customers read and is a key driver in successful open rates. |
EmailDto Object
| Property | Type | Description |
|---|---|---|
| domain | string | The domain name used for sending emails based on this template. |
| name | string | The name part of the email address. |
ScheduleDto Object
| Property | Type | Description |
|---|---|---|
| startDate | string | The start date of the scheduled email sending. |
| isEndDateCustom | boolean | Boolean flag indicates customized schedule end date. |
| endDate | string | The end date of the scheduled email sending. |
ContentDto Object
| Property | Type | Description |
|---|---|---|
| body | string | Use our pre-defined email body or customise it to fit your brand. Add dynamic data by using the variables provided. |
| headerImage | string | Add your own logo to the top of the email or use our pre-defined header image. If you use your own header image please ensure it is maximum 1370 x 700, or has a 2:1 aspect ratio. |
| isBodyCustom | boolean | Boolean flag indicates customized body. |
| isFooterHidden | boolean | Hide our email footer explaining the benefits of Greenspark. |
| isFooterHiddenCustom | boolean | Boolean flag indicates customized hidden footer setting. |
| isHeaderImageCustom | boolean | Boolean flag indicates customized header image. |
| isTotalImpactHidden | boolean | Hide your total impact so far within your emails. |
| isTotalImpactHiddenCustom | boolean | Boolean flag indicates customized hidden total impact setting. |
TestNotificationTemplateRequestDto Object
| Property | Type | Description |
|---|---|---|
| customerEmail | string | Test recipient email address. |
| notificationTemplate | NotificationTemplateRequestDto | Notification template to test. |
NotificationTemplateRequestDto Object
| Property | Type | Description |
|---|---|---|
| isActive | boolean | Start sending this template to your customers. |
| type | TypeRequestBody | It holds the type related properties. |
| settings | SettingsRequestBody | It holds the settings related properties. |
| content | ContentRequestBody | It holds the content related properties. |
TypeRequestBody Object
| Property | Type | Description |
|---|---|---|
| name | string | maxLength: 200 Name of the template |
| template | string | The type of the template. 'invitation', 'update', 'nudge' |
| trigger | string[] | Choose the impact action which triggers your email to be sent out. 'offsetPerOrder', 'offsetPerProduct', 'offsetBySpend', 'offsetByStoreRevenue', 'offsetByPercentageOrder', 'offsetPerSubscription', 'offsetPerReview', 'byLoyaltyPoints', 'byPercentageOfPaidInvoice', 'byPercentageOfRevenue', 'bySpendOfPaidInvoice', 'byTieredSpendOfPaidInvoice', 'perPaidInvoice', 'perCompletedForm', 'perSelectedAnswer', 'customerCartContribution', 'customerChoicePerOrder' The name of a custom integration trigger is also allowed. |
| schedule | number[] | Sets how many days after an impact creation a signup nudging email is sent out to your customer. integer |
SettingsRequestBody Object
| Property | Type | Description |
|---|---|---|
| from | EmailRequestBody | The email address used for sending emails. |
| alias | string | maxLength: 200 This is the name display for the specified sender email address. |
| subject | string | maxLength: 200 Your subject line is one of the first things that your customers read and is a key driver in successful open rates. |
| preheader | string | maxLength: 200 The preheader is the text following the subject line when an email is previewed. |
| schedule | ScheduleRequestBody | You can choose to send your template continuously starting at the selected start date or only during a specific date range. |
EmailRequestBody Object
| Property | Type | Description |
|---|---|---|
| name | string | maxLength: 200 The name part of the email address. |
| domain | string | maxLength: 200 The domain name used for sending emails based on this template. |
ScheduleRequestBody Object
| Property | Type | Description |
|---|---|---|
| startDate | string | The start date of the scheduled email sending. ISO8601 date and time string. |
| endDate | string | The end date of the scheduled email sending. ISO8601 date and time string. |
ContentRequestBody Object
| Property | Type | Description |
|---|---|---|
| headerImage | string | maxLength: 50000 Add your own logo to the top of the email or use our pre-defined header image. If you use your own header image please ensure it is maximum 1370 x 700, or has a 2:1 aspect ratio. You can upload it as a base 64 encoded image. |
| body | string | maxLength: 10000 Use our pre-defined email body or customise it to fit your brand. Add dynamic data by using the variables provided. |
| isFooterHidden | boolean | Hide our email footer explaining the benefits of Greenspark. |
| isTotalImpactHidden | boolean | Hide your total impact so far within your emails. |