Templates
/ Get templates details
Get templates details
Method: POST
https://api-prod.enotifiers.com/api/V1/service/template/detailsRequest details
| Parameter | Description | Example |
|---|---|---|
|
templateName string |
The name of the email template. | test_2 |
|
templateCategory string |
The category of the email template. | testing_1 |
Curl code
curl --location
'https://api-prod.enotifiers.com/api/V1/service/template/details' \
--header 'accept: application/json' \
--header 'Content-Type: application/json' \
--header 'Authorization: Basic {{Authorization}}' \
--data '{
"templateName": "test_2",
"templateCategory": "testing_1"
}'
Success response details
| Parameter | Description | Example |
|---|---|---|
| status String |
Indicates the status of the response | success |
| code String |
HTTP status code of the response. | 200 |
| message String |
Provides a descriptive message indicating the outcome of the request |
Template details fetched successfully |
| data.templateName String |
A string representing the name of the template | test_2 |
| data.templateType String |
Indicates the type of the template | transactional |
| data.templateCategory String |
Category of the template | testing_1 |
| data.createdAt String |
Timestamp indicating when the template was created. | 2024-03-14 12:44:35 |
| data.modifiedAt String |
Timestamp indicating when the template was last modified. | 2024-03-26 04:53:33 |
| data.htmlContent String |
HTML content of the template | HTML code |
| data.addedBy String |
Name of the user who added the template. | Ram |
| data.modifiedBy String |
Name of the user who last modified the template | Ram |
{
"status": "success",
"code": "200",
"message": "Template details fetched successfully.",
"data": {
"templateName": "test_2",
"templateType": "transactional",
"templateCategory": "testing_1",
"createdAt": "2024-03-14 12:44:35",
"modifiedAt": "2024-03-26 04:53:33",
"htmlContent": "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD XHTML 1.0 ...>\n<html... },
"addedBy": "Ram",
"modifiedBy": "Ram"
}
}Failure response details
| Parameter | Description | Example |
|---|---|---|
| status String |
Indicates the overall status of the API request. |
failed |
| code String |
Provides the HTTP status code corresponding to the failure. |
400 |
| message String |
Provides the reason for the error | Template does not exists |
| data.error String |
Specific error message providing more context about the issue. |
Template not found |
{
"status": "failed",
"code": "400",
"message": "Template does not exists.",
"data": {
"error": "Template not found."
}
}