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