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)


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

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)


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

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

#list_callsHash

List all the logged calls

Examples:

client.list_calls

Returns:

  • (Hash)


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

def list_calls
  get(:calls)
end