class ExpressPigeon::Templates

Public Class Methods

new() click to toggle source
# File lib/expresspigeon-ruby/templates.rb, line 5
def initialize
  @endpoint = 'templates'
end

Public Instance Methods

copy(template_id, template_name, merge_fields = {}) click to toggle source
# File lib/expresspigeon-ruby/templates.rb, line 9
def copy(template_id, template_name, merge_fields = {})
  post "#{@endpoint}/#{template_id}/copy", name: template_name, merge_fields: merge_fields
end
delete(template_id) click to toggle source

Deletes existing template

# File lib/expresspigeon-ruby/templates.rb, line 14
def delete(template_id)
  del "#{@endpoint}/#{template_id}"
end