Class: SportsApi::Football::PlayerResource
- Defined in:
- lib/sports_api/football/resources/players/player.rb
Instance Attribute Summary
Attributes inherited from Resource
Instance Method Summary collapse
-
#list(**params) ⇒ Object
Arguments: id: [Integer](optional) - The player ID.
Methods inherited from Resource
Constructor Details
This class inherits a constructor from SportsApi::Resource
Instance Method Details
#list(**params) ⇒ Object
Arguments: id: [Integer](optional) - The player ID. team: [Integer](optional) - The team ID. league: [Integer](optional) - The league ID. season: [Integer](optional) - The season of the league (= YYYY).
Requires the fields Id, League or Team
search: [String](optional) - The name of the coach (>= XXXX). page: [Integer](optional) - Use for the pagination (default: 1).
14 15 16 17 |
# File 'lib/sports_api/football/resources/players/player.rb', line 14 def list(**params) response = get_request('players', params:) Collection.from_response(response, type: SportsApi::Football::Player) end |