Class: MailUp::Console::User
- Inherits:
-
Object
- Object
- MailUp::Console::User
- Defined in:
- lib/mailup/console/user.rb
Instance Attribute Summary collapse
-
#api ⇒ Object
Returns the value of attribute api.
Instance Method Summary collapse
-
#emails(params = {}) ⇒ JSON
Retrieve the email messages (cloned and not cloned) for the current user.
-
#initialize(api) ⇒ User
constructor
A new instance of User.
-
#lists(params = {}) ⇒ JSON
Retrieve the admin console lists for the current user.
Constructor Details
#initialize(api) ⇒ User
Returns a new instance of User.
6 7 8 |
# File 'lib/mailup/console/user.rb', line 6 def initialize(api) @api = api end |
Instance Attribute Details
#api ⇒ Object
Returns the value of attribute api.
4 5 6 |
# File 'lib/mailup/console/user.rb', line 4 def api @api end |
Instance Method Details
#emails(params = {}) ⇒ JSON
Retrieve the email messages (cloned and not cloned) for the current user.
71 72 73 |
# File 'lib/mailup/console/user.rb', line 71 def emails(params={}) @api.get("#{@api.path}/User/Emails", params: params) end |
#lists(params = {}) ⇒ JSON
Retrieve the admin console lists for the current user.
39 40 41 |
# File 'lib/mailup/console/user.rb', line 39 def lists(params = {}) @api.get("#{@api.path}/User/Lists", params: params) end |