Class: Football::Butler::ApiFootball::Transfers
- Inherits:
-
BaseApiFootball
- Object
- Base
- BaseApiFootball
- Football::Butler::ApiFootball::Transfers
- Defined in:
- lib/football/butler/api_football/transfers.rb
Constant Summary collapse
- PATH =
:transfers
Constants inherited from Base
Class Method Summary collapse
-
.by_player(player:, result:, filters:) ⇒ Object
TRANSFERS.
-
.by_team(team:, result:, filters:) ⇒ Object
/transfers?pteam=team.
Methods inherited from Base
api_class, api_switch, api_switch_method, api_switch_result, error_message, invalid_config_result, not_found_result, reached_limit?, this_class, unsupported_api_call, unsupported_api_endpoint
Class Method Details
.by_player(player:, result:, filters:) ⇒ Object
TRANSFERS
player integer The id of the player
team integer The id of the team
/transfers?player=player
22 23 24 25 |
# File 'lib/football/butler/api_football/transfers.rb', line 22 def by_player(player:, result:, filters:) filters.merge!({ player: player }) Api.get(path: PATH, filters: filters, result: result) end |