code: def team_scores(self, team_scores, time):
          
          data = []
          for score in team_scores['matches']:
              if score['status'] == 'FINISHED':
                  item = {'date': score["utcDate"].split('T')[0],
                          'homeTeamName': score['homeTeam']['name'],
                          'goalsHomeTeam': score['score']['fullTime']['homeTeam'],
                          'goalsAwayTeam': score['score']['fullTime']['awayTeam'],
                          'awayTeamName': score['awayTeam']['name']}
                  data.append(item)
          self.generate_output({'team_scores': data})
docs: Store output of team scores to a JSON file