Module: RootInsurance::Api::Call

Included in:
Client
Defined in:
lib/root_insurance/api/call.rb

Instance Method Summary collapse

Instance Method Details

#get_call(id:) ⇒ Hash

Get a specific call

Examples:

client.get_call(id: 'd3d13c48-4dc3-4816-8d01-de3215878225')

Parameters:

  • id (String)

    The unique identifier of the call

Returns:

  • (Hash)


20
21
22
# File 'lib/root_insurance/api/call.rb', line 20

def get_call(id:)
  get("calls/#{id}")
end

#list_call_events(id:) ⇒ Hash

List a call’s events

Examples:

client.list_call_events(id: 'd3d13c48-4dc3-4816-8d01-de3215878225')

Parameters:

  • id (String)

    The unique identifier of the call

Returns:

  • (Hash)


31
32
33
# File 'lib/root_insurance/api/call.rb', line 31

def list_call_events(id:)
  get("calls/#{id}/events")
end

#list_callsHash

List all the logged calls

Examples:

client.list_calls

Returns:

  • (Hash)


9
10
11
# File 'lib/root_insurance/api/call.rb', line 9

def list_calls
  get(:calls)
end