Template Management
Managing templates can be done via the following endpoints by using the id from the notification type list call and a spcific provider type you want to manage
Available providerTypes
Sms
Email
PushNotification
Endpoints
Get /notification-types/{id}/templates/{providerType}
Post /notification-types/{id}/templates/{providerType}
Put /notification-types/{id}/templates/{providerType}
Delete /notification-types/{id}/templates/{providerType}
Example Body
Available templateTypes
Subject
Body
AdditionalContext
Requirements
Sms
Only requires the
Body
template
Requires the
Subject
andBody
templates
PushNotification
Requires the
Subject
andBody
templates with theAdditionalContext
being optional.
The AdditionalContext
needs to be in the form of an object and will be passed along with the push notification
Templating Engine
Templates are powered by Scriban
Example
Heres an example of what your template value would look like:
this will loop through a list of products displaying the product.name
, product.price
and product.description
by truncating the length of the product.description
by 15 characters