module Mailstro class Delivery < Resource attr_reader :email_name def initialize(email_name, options) @email_name = email_name @options = options end def to @options.fetch(:to) end def data @options.fetch(:data, nil) end def deliver post("deliveries", :to => to, :email_name => email_name, :data => data ) end end end