func (s *DeleteTemplateService) buildURL() (string, url.Values, error) {
	path, err := uritemplates.Expand("/_search/template/{id}", map[string]string{
		"id": s.id,
	})
	if err != nil {
		return "", url.Values{}, err
	}
	params := url.Values{}
	if s.version != nil {
		params.Set("version", fmt.Sprintf("%d", *s.version))
	}
	if s.versionType != "" {
		params.Set("version_type", s.versionType)
	}
	return path, params, nil
}
buildURL builds the URL for the operation.
package elastic
import (
	"fmt"
	"net/url"
	"gopkg.in/olivere/elastic.v3/uritemplates"
)
type DeleteTemplateService struct {
	client      *Client
	pretty      bool
	id          string
	version     *int
	versionType string
}
func NewDeleteTemplateService(client *Client) *DeleteTemplateService {
	return &DeleteTemplateService{
		client: client,
	}
}
func (s *DeleteTemplateService) Id(id string) *DeleteTemplateService {
	s.id = id
	return s
}
func (s *DeleteTemplateService) Version(version int) *DeleteTemplateService {
	s.version = &version
	return s
}
func (s *DeleteTemplateService) VersionType(versionType string) *DeleteTemplateService {
	s.versionType = versionType
	return s
}