Get email message template content API

This API is used to view the content of the message template.

📘

Know your endpoint

Based on the domain you use to log in to Webex Campaign, the endpoint domain for your API varies. For more information, refer to the Know Your API Endpoints section.

Headers

The following table describes the request headers:

Request HeaderDescription
content-typeapplication/json
authorizationAccess token or API Secret Key in Bearer format

Example: Bearer $(key)

Request Example



https://yourapihubdomain.io/v1/message-templates/16654964070008?channel=email

Response Parameters

This API will return the following response parameters:

ParameterDescription
nameReturns the name of the queried message template
formatReturns the format of the queried message template.

- 0 (only HTML)
- 1 (only Text)
- 2 (Both HTML and Text)
- 3 (AMP) [not supported in this release]
subjectReturns the subject of the queried message template
htmlcontentReturns the HTML content of the queried message template
textcontentReturns the text content of the queried message template

Failure Response Codes

The API will return code within the response as per the following table in case of failure scenarios.

HTTP Status CodeCode within API ResponseDescription
400400I/O error on post request. Cannot retry due to server authentication, in streaming mode.
400400Invalid channel :: channel name
401430Authorization failed. This resource is not allowed to access using this TOKEN or KEY
401NAInvalid token or Access token expired
404404Not found
500500Internal server error
500500Required String parameter 'channel' is not present"
Language