Class: CreateSend::Transactional::ClassicEmail
- Inherits:
-
CreateSend
- Object
- CreateSend
- CreateSend::Transactional::ClassicEmail
- Defined in:
- lib/createsend/transactional_classic_email.rb
Instance Attribute Summary collapse
-
#options ⇒ Object
Returns the value of attribute options.
Attributes inherited from CreateSend
Instance Method Summary collapse
- #groups ⇒ Object
-
#initialize(auth, client_id = nil) ⇒ ClassicEmail
constructor
A new instance of ClassicEmail.
- #send(options) ⇒ Object
Methods inherited from CreateSend
#add_auth_details_to_options, #administrators, #auth, authorize_url, #billing_details, #clients, #countries, #delete, exchange_token, #external_session_url, #get, #get_primary_contact, #handle_response, #post, #put, refresh_access_token, #refresh_token, #set_primary_contact, #systemdate, #timezones, user_agent
Constructor Details
#initialize(auth, client_id = nil) ⇒ ClassicEmail
Returns a new instance of ClassicEmail.
6 7 8 9 10 |
# File 'lib/createsend/transactional_classic_email.rb', line 6 def initialize(auth, client_id = nil) @auth = auth @client_id = client_id super end |
Instance Attribute Details
#options ⇒ Object
Returns the value of attribute options.
4 5 6 |
# File 'lib/createsend/transactional_classic_email.rb', line 4 def @options end |
Instance Method Details
#groups ⇒ Object
17 18 19 20 |
# File 'lib/createsend/transactional_classic_email.rb', line 17 def groups response = get "/transactional/classicemail/groups", :query => client_id response.map{|item| Hashie::Mash.new(item)} end |
#send(options) ⇒ Object
12 13 14 15 |
# File 'lib/createsend/transactional_classic_email.rb', line 12 def send() response = post "/transactional/classicemail/send", { :body => .to_json , :query => client_id } response.map{|item| Hashie::Mash.new(item)} end |