Class: Football::Butler::Apifootball::HeadToHead
- Inherits:
-
BaseApifootball
- Object
- Base
- BaseApifootball
- Football::Butler::Apifootball::HeadToHead
- Defined in:
- lib/football/butler/apifootball/head_to_head.rb
Constant Summary collapse
- PATH =
:get_H2H
Constants inherited from Base
Class Method Summary collapse
Methods inherited from BaseApifootball
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_teams(team_id:, second_team_id:, filters:, result:) ⇒ Object
HEAD TO HEAD
timezone Default timezone: Europe/Berlin. With this filter you can set the timezone
where you want to receive the data. Timezone is in TZ format (exemple: America/New_York).
(Optional)
firstTeam First team name secondTeam Second team name firstTeamId First team Id secondTeamId Second team Id
action=get_H2H&firstTeamId=team_id&secondTeamId=second_team_id
22 23 24 25 |
# File 'lib/football/butler/apifootball/head_to_head.rb', line 22 def by_teams(team_id:, second_team_id:, filters:, result:) filters.merge!(firstTeamId: team_id, secondTeamId: second_team_id) Api.get(path: build_path(PATH), filters: filters, result: result) end |