Class: Amocrm::Resources::Salesbot
- Inherits:
-
Object
- Object
- Amocrm::Resources::Salesbot
- Defined in:
- lib/amocrm/resources/salesbot.rb
Instance Method Summary collapse
-
#initialize(client:) ⇒ Salesbot
constructor
private
A new instance of Salesbot.
-
#run(body:, request_options: {}) ⇒ Amocrm::Models::SalesbotRunResponse::SalesbotRunResponse, Amocrm::Models::SalesbotRunResponse::Problem
Run salesbot (batch, up to 100 tasks).
Constructor Details
#initialize(client:) ⇒ Salesbot
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 Salesbot.
30 31 32 |
# File 'lib/amocrm/resources/salesbot.rb', line 30 def initialize(client:) @client = client end |
Instance Method Details
#run(body:, request_options: {}) ⇒ Amocrm::Models::SalesbotRunResponse::SalesbotRunResponse, Amocrm::Models::SalesbotRunResponse::Problem
Run salesbot (batch, up to 100 tasks).
16 17 18 19 20 21 22 23 24 25 |
# File 'lib/amocrm/resources/salesbot.rb', line 16 def run(params) parsed, = Amocrm::SalesbotRunParams.dump_request(params) @client.request( method: :post, path: "api/v2/salesbot/run", body: parsed[:body], model: Amocrm::Models::SalesbotRunResponse, options: ) end |