Optimal Lineup Suggestion
optimal_lineupSuggests a starting lineup by filling the most restrictive slots first, then assigning the best remaining projection for each slot, ranked by season or a given scoring period. Returns a suggestion to review and apply.
Instructions
Suggests a starting lineup for one team: fills the most restrictive slots first (fewest eligible roster players), then the best remaining projection for each slot — the same approach the cheat sheets describe by hand. A heuristic, not a guaranteed-optimal assignment. Ranks by season projection by default, or by a specific scoring period's projection if scoring_period_id is given (a bye-week/no-game player ranks 0 for that period, not by season total). Locked players keep their current slot. This is a suggestion only — pass the resulting moves to set_lineup yourself if you want to apply them.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sport | No | ffl (football), fba (basketball), or flb (baseball). Defaults to ESPN_SPORT. | ffl |
| season | No | Season year. Defaults to ESPN_SEASON. | |
| team_id | No | ||
| league_id | No | ESPN league id. Defaults to ESPN_LEAGUE_ID. | 123456 |
| scoring_period_id | No | Rank by this period's projection instead of season total. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| bench | Yes | ||
| starters | Yes | ||
| usingPeriodProjection | Yes |