Log daily football results and league standings to Sheets

By General Input

Every morning, automatically record yesterday's match results and each league's latest table into a spreadsheet you can chart or pivot.

Integrations

  • API-Sports
  • Google Sheets

Type

Deterministic Code

Categories

  • Personal Productivity
  • Operations

Every morning at 7am, automatically log yesterday's football results and today's league standings from API-Sports into Google Sheets, so I build a season-long record I can chart or pivot. This is a deterministic fetch-and-append logging job: loop over my leagues, fetch, map fields, and append. No summarizing or judgement.

Trigger: run on a cron schedule every day at 7:00am in my timezone. Keep a fixed list of the leagues I track at the top of the workflow so I can edit it. Each league is identified by its API-Sports league ID and the current season, which is a 4-digit starting year (for example season 2025 for the 2025/26 campaign).

Step 1, yesterday's results. For each tracked league, call API-Sports 'List Fixtures (Live, By Date, League, or Team)' filtered by that league ID, the season, and yesterday's date in YYYY-MM-DD format for my timezone. Keep only fixtures whose status is finished (FT, AET, or PEN). For every finished match, append one row to the Results tab of my Google Sheet using Google Sheets 'Append Values', with these columns: match date, league name, home team, away team, final score written as home goals - away goals, and status. If a league returns zero fixtures for yesterday (results is 0), skip it and append nothing for that league.

Step 2, standings snapshot. For each tracked league, call API-Sports 'Get Standings' for the league ID and season. For every team in the returned table, append one row to the Standings tab using Google Sheets 'Append Values', with these columns: today's date as the snapshot date, league name, position or rank, team name, points, goal difference, and recent form. Tagging every row with today's date is what lets me chart a team's position over time; a one-off standings table cannot do that.

Notes: API-Sports is read-only and returns data inside a response array with a results count, so treat results:0 as a valid empty answer, not an error. When appending, use the option that parses input like the Sheets UI (USER_ENTERED) so dates and numbers land as real dates and numbers. Always append after the last row of each tab so the history accumulates and nothing already logged is overwritten.

Related prompts

Explore more prompts
Call overdue Xero customers with an AI collections agentLocal listing health board for every location you manageLet support send one-off Loops emails without an engineerStop cold emails to anyone with a live deal in PipedriveiMessage campaign console with pre-flight checks and delivery boardLinkedIn Ads budget pacing dashboard for every client accountFront desk appointment confirmation board for the next 3 daysGive your team Looker numbers without buying more seatsBuild audience segments from product usage and push to LoopsTurn the people who engage with your posts into Pipedrive leads