# ElasticEmail::TemplatesApi All URIs are relative to *https://api.elasticemail.com/v4* | Method | HTTP request | Description | | ------ | ------------ | ----------- | | [**templates_by_name_delete**](TemplatesApi.md#templates_by_name_delete) | **DELETE** /templates/{name} | Delete Template | | [**templates_by_name_get**](TemplatesApi.md#templates_by_name_get) | **GET** /templates/{name} | Load Template | | [**templates_by_name_put**](TemplatesApi.md#templates_by_name_put) | **PUT** /templates/{name} | Update Template | | [**templates_get**](TemplatesApi.md#templates_get) | **GET** /templates | Load Templates | | [**templates_post**](TemplatesApi.md#templates_post) | **POST** /templates | Add Template | ## templates_by_name_delete > templates_by_name_delete(name) Delete Template Delete template with the specified name. Required Access Level: ModifyTemplates ### Examples ```ruby require 'time' require 'ElasticEmail' # setup authorization ElasticEmail.configure do |config| # Configure API key authorization: apikey config.api_key['apikey'] = 'YOUR API KEY' # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil) # config.api_key_prefix['apikey'] = 'Bearer' end api_instance = ElasticEmail::TemplatesApi.new name = 'Template01' # String | Name of template. begin # Delete Template api_instance.templates_by_name_delete(name) rescue ElasticEmail::ApiError => e puts "Error when calling TemplatesApi->templates_by_name_delete: #{e}" end ``` #### Using the templates_by_name_delete_with_http_info variant This returns an Array which contains the response data (`nil` in this case), status code and headers. > templates_by_name_delete_with_http_info(name) ```ruby begin # Delete Template data, status_code, headers = api_instance.templates_by_name_delete_with_http_info(name) p status_code # => 2xx p headers # => { ... } p data # => nil rescue ElasticEmail::ApiError => e puts "Error when calling TemplatesApi->templates_by_name_delete_with_http_info: #{e}" end ``` ### Parameters | Name | Type | Description | Notes | | ---- | ---- | ----------- | ----- | | **name** | **String** | Name of template. | | ### Return type nil (empty response body) ### Authorization [apikey](../README.md#apikey) ### HTTP request headers - **Content-Type**: Not defined - **Accept**: Not defined ## templates_by_name_get >