competition_top_scorers
Retrieve top scorers for a football competition using its code. Get player names, goals, assists, and penalties for leagues like Premier League or World Cup.
Instructions
This function, competition_top_scorers sends a httpx request to:
https://api.football-data.org/v4/competitions/{competition_code}/scorers
to find the total scorers in the specified competition.
Please note that only the following competitions are included, and using any
other competition code will result in an error. Use the following competition
codes only:
| WC | FIFA World Cup
| CL | UEFA Champions League
| BL1 | Bundesliga
| DED | Eredivisie
| BSA | Campeonato Brasileiro Série A
| PD | Primera Division
| FL1 | Ligue 1
| ELC | Championship
| PPL | Primeira Liga
| EC | European Championship
| SA | Serie A
| PL | Premier League
Input:
competition_code - the league/tournament that we want to pull scorers from.
Output: a list containing entries about scorers
of the day including the following features:
'event', 'player_name', 'player_num',
'player_position', 'player_team', 'player_goals'
'player_assists', 'player_penalties'
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| competition_code | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |