Class: ApiSports::VenuesResource

Inherits:
Resource
  • Object
show all
Defined in:
lib/api_sports/resources/venues.rb

Instance Attribute Summary

Attributes inherited from Resource

#client

Instance Method Summary collapse

Methods inherited from Resource

#get_request, #get_single_resource, #handle_response, #initialize

Constructor Details

This class inherits a constructor from ApiSports::Resource

Instance Method Details

#retrieve(**params) ⇒ Object



5
6
7
8
9
10
# File 'lib/api_sports/resources/venues.rb', line 5

def retrieve(**params)
  response = get_single_resource("venues", params: params) do |r|
    r.body["response"].first
  end
  Venue.new(response)
end