Sleeper API in Excel Power Query: Payout Tracker

Fantasy sports platform Sleeper has developed an API to give players access to a trove of league-specific data that is not publicly accessible on other platforms. Things like like historical roster makeup, results over time, and setting changes are now easily viewable by anyone who plays fantasy on Sleeper. Needless to say, the Sleeper API represents a perfect opportunity to build and share a user-friendly, Excel based tool.

Most Fantasy Football leagues operate under slightly different sets of rules. In the league I run, we’ve implemented some unique payouts during our regular season. The top two scorers each week get $5, and everyone who wins a regular season match gets $4. As commissioner, one of my duties is to track these payouts over the course of the season so that each player gets the correct amount at the end of the year. This used to be a task that I loathed with a fiery passion!

When we started these payouts I had to manually enter scores from our league into a spreadsheet to calculate the correct amounts. This annoying process often led to mistakes and miscalculations. Thankfully those days are over now that I have the Hyzermetrics Fantasy Football Payout Tracker!

The tracker gives commissioners the ability to track custom payout structures in their league. It relies on the LeagueID, which is can be found on your browser any time you access your league.

Once you have your LeagueID, enter it into cell C4 of the tracker.

Next, populate your payouts! You can have a prize for a weekly win, and you can assign prizes for each position.

Finally, go up to the Data ribbon and click Refresh All. The first time you do this, you may see a pop-up about privacy levels. In this case, you can check the “Ignore Privacy Levels” checkbox.

Congrats, once you’ve gone through these steps you will now have a functioning payout calculator! Refresh it each week to update the payout amounts. Hopefully this tool will save my fellow commissioners a headache or two this Fantasy Football season.

Leave a comment