Class: Courier::Resources::Automations
- Inherits:
-
Object
- Object
- Courier::Resources::Automations
- Defined in:
- lib/courier/resources/automations.rb,
lib/courier/resources/automations/invoke.rb
Defined Under Namespace
Classes: Invoke
Instance Attribute Summary collapse
Instance Method Summary collapse
-
#initialize(client:) ⇒ Automations
constructor
private
A new instance of Automations.
-
#list(cursor: nil, version: nil, request_options: {}) ⇒ Courier::Models::AutomationTemplateListResponse
Some parameter documentations has been truncated, see Models::AutomationListParams for more details.
Constructor Details
#initialize(client:) ⇒ Automations
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Automations.
40 41 42 43 |
# File 'lib/courier/resources/automations.rb', line 40 def initialize(client:) @client = client @invoke = Courier::Resources::Automations::Invoke.new(client: client) end |
Instance Attribute Details
#invoke ⇒ Courier::Resources::Automations::Invoke (readonly)
7 8 9 |
# File 'lib/courier/resources/automations.rb', line 7 def invoke @invoke end |
Instance Method Details
#list(cursor: nil, version: nil, request_options: {}) ⇒ Courier::Models::AutomationTemplateListResponse
Some parameter documentations has been truncated, see Models::AutomationListParams for more details.
Get the list of automations.
25 26 27 28 29 30 31 32 33 34 35 |
# File 'lib/courier/resources/automations.rb', line 25 def list(params = {}) parsed, = Courier::AutomationListParams.dump_request(params) query = Courier::Internal::Util.encode_query_params(parsed) @client.request( method: :get, path: "automations", query: query, model: Courier::AutomationTemplateListResponse, options: ) end |