public interface MailgunTemplatesApi extends MailgunApi
Templates Api.
This API allows you to store predefined templates and use them to send messages using the Sending API.
The API has the following limitations:
100 templates per domain 10 versions per template 100Kb max template size
| Modifier and Type | Method and Description |
|---|---|
TemplateWithMessageResponse |
createNewTemplateVersion(String domain,
String templateName,
TemplateVersionRequest request)
Create a new version of a template.
|
feign.Response |
createNewTemplateVersionFeignResponse(String domain,
String templateName,
TemplateVersionRequest request)
Create a new version of a template.
|
ResponseWithMessage |
deleteAllTemplatesInDomain(String domain)
Delete all stored templates for the domain.
|
feign.Response |
deleteAllTemplatesInDomainFeignResponse(String domain)
Delete all stored templates for the domain.
|
TemplateVersionResponse |
deleteSpecificTemplateVersion(String domain,
String templateName,
String templateVersion)
Delete a specific version of the template.
|
feign.Response |
deleteSpecificTemplateVersionFeignResponse(String domain,
String templateName,
String templateVersion)
Delete a specific version of the template.
|
TemplateStatusResponse |
deleteTemplate(String domain,
String name)
Delete the template.
|
feign.Response |
deleteTemplateFeignResponse(String domain,
String name)
Delete the template.
|
TemplateWithVersionResponse |
getActiveTemplateVersionContent(String domain,
String name)
Returns the content of the active version of the template with metadata information.
|
feign.Response |
getActiveTemplateVersionContentFeignResponse(String domain,
String name)
Returns the content of the active version of the template with metadata information.
|
TemplatesResult |
getAllTemplates(String domain)
Returns a list of stored templates for the domain (limit to 10 entries).
|
TemplatesResult |
getAllTemplates(String domain,
PagingWithPivot queryOptions)
Returns a list of stored templates for the domain with paging.
|
feign.Response |
getAllTemplatesFeignResponse(String domain)
Returns a list of stored templates for the domain (limit to 10 entries).
|
feign.Response |
getAllTemplatesFeignResponse(String domain,
PagingWithPivot queryOptions)
Returns a list of stored templates for the domain with paging.
|
TemplateAllVersionsResponse |
getAllTemplateVersions(String domain,
String templateName)
Returns a list of stored versions of the template (limit to 10 entries).
|
TemplateAllVersionsResponse |
getAllTemplateVersions(String domain,
String templateName,
PagingWithPivot queryOptions)
Returns a list of stored versions of the template.
|
feign.Response |
getAllTemplateVersionsFeignResponse(String domain,
String templateName)
Returns a list of stored versions of the template (limit to 10 entries).
|
feign.Response |
getAllTemplateVersionsFeignResponse(String domain,
String templateName,
PagingWithPivot queryOptions)
Returns a list of stored versions of the template.
|
TemplateWithVersionResponse |
getSpecifiedVersionTemplateContent(String domain,
String templateName,
String tag)
Retrieve information and content of specified version of the template.
|
feign.Response |
getSpecifiedVersionTemplateContentFeignResponse(String domain,
String templateName,
String tag)
Retrieve information and content of specified version of the template.
|
TemplateResponse |
getTemplate(String domain,
String name)
Returns metadata information about a stored template.
|
feign.Response |
getTemplateFeignResponse(String domain,
String name)
Returns metadata information about a stored template.
|
TemplateWithMessageResponse |
storeNewTemplate(String domain,
TemplateRequest request)
This API stores a new template, including its name, description and (optionally) the template content.
|
feign.Response |
storeNewTemplateFeignResponse(String domain,
TemplateRequest request)
This API stores a new template, including its name, description and (optionally) the template content.
|
TemplateVersionResponse |
updateSpecificTemplateVersion(String domain,
String templateName,
String tag,
UpdateTemplateVersionRequest request)
Update information or content of the specific version of the template.
|
feign.Response |
updateSpecificTemplateVersionFeignResponse(String domain,
String templateName,
String tag,
UpdateTemplateVersionRequest request)
Update information or content of the specific version of the template.
|
TemplateStatusResponse |
updateTemplate(String domain,
String name,
String description)
Update the metadata information of the template.
|
feign.Response |
updateTemplateFeignResponse(String domain,
String name,
String description)
Update the metadata information of the template.
|
getApiVersionTemplatesResult getAllTemplates(String domain)
Returns a list of stored templates for the domain (limit to 10 entries).
domain - Name of the domainTemplatesResultfeign.Response getAllTemplatesFeignResponse(String domain)
Returns a list of stored templates for the domain (limit to 10 entries).
domain - Name of the domainResponseTemplatesResult getAllTemplates(String domain, PagingWithPivot queryOptions)
Returns a list of stored templates for the domain with paging.
domain - Name of the domainqueryOptions - PagingWithPivotTemplatesResultfeign.Response getAllTemplatesFeignResponse(String domain, PagingWithPivot queryOptions)
Returns a list of stored templates for the domain with paging.
domain - Name of the domainqueryOptions - PagingWithPivotResponseTemplateResponse getTemplate(String domain, String name)
Returns metadata information about a stored template.
domain - Name of the domainname - Name of the templateTemplateResponsefeign.Response getTemplateFeignResponse(String domain, String name)
Returns metadata information about a stored template.
domain - Name of the domainname - Name of the templateResponseTemplateWithVersionResponse getActiveTemplateVersionContent(String domain, String name)
Returns the content of the active version of the template with metadata information.
domain - Name of the domainname - Name of the templateTemplateWithVersionResponsefeign.Response getActiveTemplateVersionContentFeignResponse(String domain, String name)
Returns the content of the active version of the template with metadata information.
domain - Name of the domainname - Name of the templateResponseTemplateWithMessageResponse storeNewTemplate(String domain, TemplateRequest request)
This API stores a new template, including its name, description and (optionally) the template content.
If the template content is provided, a new version is automatically created and becomes the active version.
domain - Name of the domainrequest - TemplateRequestTemplateWithMessageResponsefeign.Response storeNewTemplateFeignResponse(String domain, TemplateRequest request)
This API stores a new template, including its name, description and (optionally) the template content.
If the template content is provided, a new version is automatically created and becomes the active version.
domain - Name of the domainrequest - TemplateRequestResponseTemplateStatusResponse updateTemplate(String domain, String name, String description)
Update the metadata information of the template.
domain - Name of the domainname - Name of the templatedescription - Updated description of the templateTemplateStatusResponsefeign.Response updateTemplateFeignResponse(String domain, String name, String description)
Update the metadata information of the template.
domain - Name of the domainname - Name of the templatedescription - Updated description of the templateResponseTemplateStatusResponse deleteTemplate(String domain, String name)
Delete the template.
NOTE: This method deletes all versions of the specified template.domain - Name of the domainname - Name of the templateTemplateStatusResponsefeign.Response deleteTemplateFeignResponse(String domain, String name)
Delete the template.
NOTE: This method deletes all versions of the specified template.domain - Name of the domainname - Name of the templateResponseResponseWithMessage deleteAllTemplatesInDomain(String domain)
Delete all stored templates for the domain.
domain - Name of the domainResponseWithMessagefeign.Response deleteAllTemplatesInDomainFeignResponse(String domain)
Delete all stored templates for the domain.
domain - Name of the domainResponseTemplateAllVersionsResponse getAllTemplateVersions(String domain, String templateName)
Returns a list of stored versions of the template (limit to 10 entries).
domain - Name of the domaintemplateName - Name of the templateTemplateAllVersionsResponsefeign.Response getAllTemplateVersionsFeignResponse(String domain, String templateName)
Returns a list of stored versions of the template (limit to 10 entries).
domain - Name of the domaintemplateName - Name of the templateResponseTemplateAllVersionsResponse getAllTemplateVersions(String domain, String templateName, PagingWithPivot queryOptions)
Returns a list of stored versions of the template.
domain - Name of the domaintemplateName - Name of the templatequeryOptions - PagingWithPivotTemplateAllVersionsResponsefeign.Response getAllTemplateVersionsFeignResponse(String domain, String templateName, PagingWithPivot queryOptions)
Returns a list of stored versions of the template.
domain - Name of the domaintemplateName - Name of the templatequeryOptions - PagingWithPivotResponseTemplateWithVersionResponse getSpecifiedVersionTemplateContent(String domain, String templateName, String tag)
Retrieve information and content of specified version of the template.
domain - Name of the domaintemplateName - Name of the templatetag - Tag of the template versionTemplateWithVersionResponsefeign.Response getSpecifiedVersionTemplateContentFeignResponse(String domain, String templateName, String tag)
Retrieve information and content of specified version of the template.
domain - Name of the domaintemplateName - Name of the templatetag - Tag of the template versionResponseTemplateWithMessageResponse createNewTemplateVersion(String domain, String templateName, TemplateVersionRequest request)
Create a new version of a template. If the template does not contain any other versions, the first version becomes active.
domain - Name of the domaintemplateName - Name of the templaterequest - TemplateVersionRequestTemplateWithMessageResponsefeign.Response createNewTemplateVersionFeignResponse(String domain, String templateName, TemplateVersionRequest request)
Create a new version of a template. If the template does not contain any other versions, the first version becomes active.
domain - Name of the domaintemplateName - Name of the templaterequest - TemplateVersionRequestResponseTemplateVersionResponse updateSpecificTemplateVersion(String domain, String templateName, String tag, UpdateTemplateVersionRequest request)
Update information or content of the specific version of the template.
domain - Name of the domaintemplateName - Name of the templatetag - Tag of the template versionrequest - UpdateTemplateVersionRequestTemplateVersionResponsefeign.Response updateSpecificTemplateVersionFeignResponse(String domain, String templateName, String tag, UpdateTemplateVersionRequest request)
Update information or content of the specific version of the template.
domain - Name of the domaintemplateName - Name of the templatetag - Tag of the template versionrequest - UpdateTemplateVersionRequestResponseTemplateVersionResponse deleteSpecificTemplateVersion(String domain, String templateName, String templateVersion)
domain - Name of the domaintemplateName - Name of the templatetemplateVersion - Template version tagTemplateVersionResponsefeign.Response deleteSpecificTemplateVersionFeignResponse(String domain, String templateName, String templateVersion)
domain - Name of the domaintemplateName - Name of the templatetemplateVersion - Template version tagResponseCopyright © 2022. All rights reserved.