Class: Mailtrap::InboundFoldersAPI
- Inherits:
-
Object
- Object
- Mailtrap::InboundFoldersAPI
- Includes:
- BaseAPI
- Defined in:
- lib/mailtrap/inbound_folders_api.rb
Instance Attribute Summary
Attributes included from BaseAPI
Instance Method Summary collapse
-
#create(options) ⇒ InboundFolder
Creates a new inbound folder.
-
#delete(folder_id) ⇒ Object
Deletes an inbound folder along with all of its inboxes.
-
#get(folder_id) ⇒ InboundFolder
Retrieves a specific inbound folder.
-
#initialize(client = Mailtrap::Client.new) ⇒ InboundFoldersAPI
constructor
A new instance of InboundFoldersAPI.
-
#list ⇒ Array<InboundFolder>
Lists all inbound folders in the account.
-
#update(folder_id, options) ⇒ InboundFolder
Updates an inbound folder.
Methods included from BaseAPI
Constructor Details
#initialize(client = Mailtrap::Client.new) ⇒ InboundFoldersAPI
Returns a new instance of InboundFoldersAPI.
14 15 16 |
# File 'lib/mailtrap/inbound_folders_api.rb', line 14 def initialize(client = Mailtrap::Client.new) @client = client end |
Instance Method Details
#create(options) ⇒ InboundFolder
Creates a new inbound folder
39 40 41 |
# File 'lib/mailtrap/inbound_folders_api.rb', line 39 def create() base_create() end |
#delete(folder_id) ⇒ Object
Deletes an inbound folder along with all of its inboxes
58 59 60 |
# File 'lib/mailtrap/inbound_folders_api.rb', line 58 def delete(folder_id) base_delete(folder_id) end |
#get(folder_id) ⇒ InboundFolder
Retrieves a specific inbound folder
29 30 31 |
# File 'lib/mailtrap/inbound_folders_api.rb', line 29 def get(folder_id) base_get(folder_id) end |
#list ⇒ Array<InboundFolder>
Lists all inbound folders in the account
21 22 23 |
# File 'lib/mailtrap/inbound_folders_api.rb', line 21 def list base_list end |
#update(folder_id, options) ⇒ InboundFolder
Updates an inbound folder
50 51 52 |
# File 'lib/mailtrap/inbound_folders_api.rb', line 50 def update(folder_id, ) base_update(folder_id, ) end |