Class: Exa::Resources::Events

Inherits:
Base
  • Object
show all
Defined in:
lib/exa/resources/events.rb

Instance Attribute Summary

Attributes inherited from Base

#client

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Exa::Resources::Base

Instance Method Details

#list(params = nil) ⇒ Object



8
9
10
11
12
13
14
15
# File 'lib/exa/resources/events.rb', line 8

def list(params = nil)
  client.request(
    method: :get,
    path: events_path,
    query: params,
    response_model: Exa::Responses::EventListResponse
  )
end

#retrieve(event_id) ⇒ Object



17
18
19
20
21
22
23
# File 'lib/exa/resources/events.rb', line 17

def retrieve(event_id)
  client.request(
    method: :get,
    path: events_path(event_id),
    response_model: Exa::Responses::Event
  )
end