Sleeper NFL Fantasy Data API avatar

Sleeper NFL Fantasy Data API

Pricing

from $1.08 / 1,000 item extracteds

Go to Apify Store
Sleeper NFL Fantasy Data API

Sleeper NFL Fantasy Data API

Export public Sleeper NFL leagues, users, rosters, weekly matchups, drafts, transactions, and referenced players by username or league ID.

Pricing

from $1.08 / 1,000 item extracteds

Rating

0.0

(0)

Developer

Stas Persiianenko

Stas Persiianenko

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

0

Monthly active users

5 days ago

Last modified

Categories

Share

Export public Sleeper NFL fantasy data by username or league ID.

The Actor combines Sleeper's public league endpoints into one normalized dataset for recurring fantasy analysis. It returns league settings, public members, rosters, weekly matchups, drafts, draft picks, transactions, and referenced player profiles. No Sleeper login, cookies, browser, or proxy is required.

What can you do with this Actor?

  • Resolve a public Sleeper username and discover that user's NFL leagues for a season.
  • Export one or more known leagues without first looking up a username.
  • Join league members to rosters for ownership analysis.
  • Compare weekly matchup scores and starting lineups.
  • Review waivers, free-agent moves, trades, and other weekly transactions.
  • Export draft metadata and every pick from each league draft.
  • Enrich roster player IDs with profiles from Sleeper's NFL player catalog.
  • Schedule the same input to feed dashboards, spreadsheets, databases, and fantasy tools.

Who is it for?

Fantasy analysts can build matchup reports and transaction summaries.

League commissioners can archive public league settings, members, rosters, and drafts.

App developers can use a stable Apify dataset instead of orchestrating many Sleeper endpoints.

Data teams can schedule repeat exports and compare dataset snapshots downstream.

Why use it instead of calling one endpoint?

A league analysis usually needs several related resources. This Actor resolves usernames, discovers season leagues, follows league-to-draft relationships, and optionally maps roster player IDs to profiles. It provides:

  • one validated input contract;
  • bounded retries for transient Sleeper API errors;
  • a global output limit;
  • normalized join keys on every row;
  • the complete source object in data;
  • Apify scheduling, webhooks, integrations, API access, and MCP access.

Data you can extract

Record typeWhat it containsUseful join fields
leagueLeague name, season, status, scoring and roster settingsleagueId, season
userPublic username, display name, avatar, league metadatauserId, leagueId
rosterOwner, players, starters, reserve/taxi lists, settingsrosterId, userId, leagueId
matchupWeekly points, starters, players, matchup pairingmatchupId, rosterId, week
draftDraft type, status, settings, order, start timedraftId, leagueId
draft_pickPick number, player, roster, round, pick metadatadraftId, playerId, rosterId
transactionWaivers, trades, adds, drops, roster participantstransactionId, leagueId, week
playerReferenced NFL player profile and team/position dataplayerId

Every item includes recordType, sourceUrl, and scrapedAt. Fields that do not apply to an entity are null. The data object preserves all public fields returned by Sleeper so advanced users are not limited to the overview columns.

Getting started

  1. Open the Actor input page.
  2. Enter a public Sleeper username, one or more league IDs, or both.
  3. Set season when using username-based league discovery.
  4. Select the record types you need.
  5. Add NFL week numbers for matchups and transactions.
  6. Set maxItems to cap total dataset records.
  7. Click Start.
  8. Open the Results dataset or export it as JSON, CSV, Excel, XML, or RSS.

The prefilled league ID comes from Sleeper's public API documentation and is suitable for a small evaluation run.

Input parameters

FieldTypeDefaultDescription
usernamestringnonePublic Sleeper username to resolve
leagueIdsstring[]nonePublic Sleeper NFL league IDs
seasonstringcurrent Sleeper seasonSeason for username league discovery
weeksstring[]["1"]Weeks 1–18 used for matchups and transactions
entityTypesstring[]league, user, roster, matchup, draft, draft pick, transactionRecords to export
maxItemsinteger500Maximum total rows, from 1 to 10,000

At least one of username or leagueIds is required. League IDs are strings because Sleeper identifiers are larger than safe integers in some languages.

Input example: league rosters

{
"leagueIds": ["289646328504385536"],
"entityTypes": ["league", "user", "roster"],
"maxItems": 50
}

Input example: weekly analysis

{
"leagueIds": ["289646328504385536"],
"weeks": ["1"],
"entityTypes": [
"roster",
"matchup",
"transaction",
"draft",
"draft_pick",
"player"
],
"maxItems": 500
}

Output example

{
"recordType": "roster",
"sourceUrl": "https://api.sleeper.app/v1/league/289646328504385536/rosters",
"leagueId": "289646328504385536",
"season": "2018",
"week": null,
"userId": "188815879448829952",
"username": null,
"displayName": null,
"rosterId": 1,
"matchupId": null,
"draftId": null,
"transactionId": null,
"playerId": null,
"name": null,
"status": null,
"data": {
"roster_id": 1,
"owner_id": "188815879448829952",
"players": ["4046", "4017"]
},
"scrapedAt": "2026-09-05T06:00:00.000Z"
}

The example is shortened. Actual data objects contain the complete response supplied by Sleeper.

Record ordering and limits

Rows are emitted in deterministic workflow order:

  1. resolved username and discovered leagues;
  2. explicit league details;
  3. league users;
  4. rosters;
  5. matchups by requested week;
  6. transactions by requested week;
  7. drafts and picks;
  8. referenced player profiles.

maxItems applies across all record types and leagues. When the limit is reached, later entity types are not fetched or emitted. Choose only the entity types needed for predictable exports.

Referenced player enrichment

Selecting player first collects player IDs from the requested league rosters. The Actor then downloads Sleeper's NFL player catalog once and emits only profiles referenced by those rosters. It does not dump the entire catalog.

This is the heaviest mode because the upstream player catalog is large. Use a practical maxItems and request player only when profile enrichment is needed.

Weekly matchups and transactions

Sleeper exposes matchups and transactions by NFL week. Supply one or more values from 1 through 18. The Actor applies the same weeks to both entity types.

Future weeks or inactive historical weeks can legitimately return no rows. That does not prevent league, member, roster, or draft records from being exported.

How much does it cost to export Sleeper NFL fantasy records?

Pricing uses pay per event:

  • one Start event per run;
  • one Sleeper record event for each useful dataset item saved.

The run start costs $0.002. The per-record tiers are $0.00207 FREE, $0.0018 BRONZE, $0.001404 SILVER, and $0.00108 GOLD / PLATINUM / DIAMOND. The active price is also shown on the Actor pricing tab before a run starts. There is no separate fee for users, rosters, matchups, drafts, transactions, or players; all use the same record event.

For a cost estimate, multiply the applicable record price by the requested output count and add the start event. The Actor never charges a record event for rejected, duplicate, or failed records. Platform usage treatment follows the pricing details shown in your Apify account.

Scheduling recurring fantasy analysis

Create an Apify Schedule with the same league IDs and weeks. After each run, send the dataset to:

  • Google Sheets for commissioner reports;
  • a webhook for a fantasy application;
  • Make or Zapier for no-code workflows;
  • BigQuery, PostgreSQL, or another warehouse;
  • your own service through the dataset API.

For week-by-week monitoring, update the weeks input as the NFL season progresses or maintain separate scheduled Tasks per week. Use a downstream key such as recordType + leagueId + week + rosterId to compare snapshots.

cURL API example

Set APIFY_TOKEN in your environment, then run:

curl -X POST \
"https://api.apify.com/v2/acts/automation-lab~sleeper-nfl-fantasy-api/runs?token=$APIFY_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"leagueIds": ["289646328504385536"],
"weeks": ["1"],
"entityTypes": ["league", "roster", "matchup"],
"maxItems": 100
}'

Poll the returned run or use the synchronous endpoint when the expected result is small. Never commit your Apify token to source control.

JavaScript API example

import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('automation-lab/sleeper-nfl-fantasy-api').call({
leagueIds: ['289646328504385536'],
weeks: ['1'],
entityTypes: ['roster', 'matchup', 'transaction'],
maxItems: 200,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

Python API example

import os
from apify_client import ApifyClient
client = ApifyClient(os.environ["APIFY_TOKEN"])
run = client.actor("automation-lab/sleeper-nfl-fantasy-api").call(run_input={
"leagueIds": ["289646328504385536"],
"entityTypes": ["league", "user", "roster"],
"maxItems": 50,
})
items = client.dataset(run["defaultDatasetId"]).list_items().items
print(items)

Use with MCP and AI agents

Claude Code

Add the Actor to Claude Code:

claude mcp add --transport http apify \
"https://mcp.apify.com?tools=automation-lab/sleeper-nfl-fantasy-api"

Claude Desktop, Cursor, and VS Code

Desktop and editor clients can use this equivalent JSON configuration:

{
"mcpServers": {
"apify": {
"url": "https://mcp.apify.com?tools=automation-lab/sleeper-nfl-fantasy-api"
}
}
}

Example prompts:

  • “Export users and rosters for Sleeper league 289646328504385536.”
  • “Get week 1 matchups and transactions and summarize roster changes.”
  • “Fetch draft picks and referenced player profiles for this public league.”

Reliability and retries

The Actor calls Sleeper's public JSON API directly. Each request has a 20-second timeout. Transient network errors, HTTP 429 responses, and server errors are retried up to three times with bounded backoff. Stable client errors and missing league IDs fail immediately with a non-zero run status.

No proxy fallback is enabled because the public API works anonymously. If Sleeper changes or rate-limits an endpoint, inspect the run log rather than treating an empty response as successful extraction.

Limitations

  • Only public Sleeper data is available.
  • The workflow is limited to NFL leagues.
  • Username league discovery is season-specific.
  • Sleeper can remove old leagues or change its public response fields.
  • Weekly endpoints may be empty for weeks without activity.
  • Player enrichment requires downloading the large NFL player catalog.
  • The Actor does not calculate standings, projections, optimal lineups, or win probabilities.
  • It does not monitor continuously inside one run; use Apify Schedules for recurring exports.

Legality and responsible use

Sleeper exposes these endpoints publicly, but public availability does not remove your responsibilities. Use the data only for legitimate fantasy analysis, league administration, research, or applications you are authorized to operate. Do not use public usernames or metadata for harassment, unwanted profiling, or spam. Follow Sleeper's terms, Apify's policies, and applicable privacy and database laws. Store exported data only as long as your purpose requires.

Troubleshooting

The run says a league was not found.

Check that the league ID contains digits only and that the league still exists publicly. Copy the ID from a Sleeper league URL rather than a team or user URL.

Username lookup returns a user but no leagues.

Set the season that contains the user's league. A user can exist without participating in an NFL league in the chosen season.

There are no transaction or matchup rows.

Check the requested weeks and season context. A valid week with no activity can return an empty array.

The output stopped before player records.

Increase maxItems or deselect earlier entity types. The global cap may be reached before player enrichment begins.

The run was rate-limited.

The Actor retries bounded transient failures automatically. If retries are exhausted, wait before starting another run or reduce the number of leagues and weeks per run.

FAQ

Does this Actor require my Sleeper password?

No. It uses public anonymous Sleeper API endpoints and never accepts account credentials.

Can I export several leagues in one run?

Yes. Add multiple IDs to leagueIds; maxItems remains a global cap.

Can I combine username and league ID inputs?

Yes. The Actor deduplicates discovered and explicitly supplied league IDs.

Are records flattened completely?

Important join and display fields are normalized at the top level. The complete source object remains in data so no public source fields are intentionally discarded.

Can I fetch only roster players?

Select roster and player. Player profiles are limited to IDs referenced by fetched rosters.

How fresh is the data?

Each run fetches the current response from Sleeper. scrapedAt records when each dataset item was created.

For player rankings and projections outside Sleeper league state, use FantasyPros NFL Projections & Rankings.

That Actor is a complementary dataset. It does not replace Sleeper league users, rosters, matchups, drafts, or transactions.