Daily marquee game preview tweet powered by live odds
Every afternoon, an agent picks tonight's biggest matchup, pulls fresh odds and recent form, and posts a sharp 280-character preview to X.
Build me an agent workflow that posts a daily pre-game betting preview to my X account for tonight's marquee matchup, powered by fresh odds from The Odds API.
Trigger: cron, once a day at 4pm in my configured timezone (default America/New_York). Make the time and timezone configurable inputs.
Configurable inputs I want on the workflow:
- sports: list of Odds API sport keys, default ['americanfootball_nfl','basketball_nba','baseball_mlb'] - lookahead_hours: how far out 'tonight' goes, default 8 - marquee_rule: one of 'closest_to_pickem' | 'highest_total' | 'marquee_teams', default 'closest_to_pickem' - marquee_teams: optional list of team names that always qualify (used when marquee_rule = 'marquee_teams', or as a tiebreaker for the other rules) - regions: which Odds API regions to query, default 'us,us2' - tone: short style guide for the tweet, default 'sharp, data-driven, no hype, no emojis' - post_time: cron time and timezone (see trigger)
Steps the agent should run each day:
1. For each sport in `sports`, call The Odds API 'List Events' to get upcoming events. Filter to events whose commence time falls between now and now + lookahead_hours. This call costs no quota, so it's safe to run across multiple sports.
2. Across the combined candidate set, pick exactly one game using `marquee_rule`. For 'closest_to_pickem' the agent will need to call 'Get Odds' with markets=spreads on the small candidate shortlist (cap at 5 candidates to control credits) and choose the event whose median spread across books is closest to 0. For 'highest_total' do the same with markets=totals and pick the highest median total. For 'marquee_teams' filter the candidates to events that include a team in `marquee_teams` and break ties by closest-to-pickem. If multiple rules tie, prefer events with at least one team in `marquee_teams`.
3. For the chosen event, call 'Get Odds' for that single event with markets='h2h,spreads,totals' and regions from `regions`. Compute the consensus (median) spread and total, and identify the single sharpest outlier book — the bookmaker whose spread or total deviates most from the consensus on the favored side. Capture that book's name and the line it's offering.
4. Call 'Get Scores' for the chosen sport with daysFrom=3 to fetch recently completed games. Pull the most recent result for each of the two teams in the chosen matchup and turn it into one short clause of color (for example 'Lakers off a 12-point home loss to Denver, Celtics on a 3-game win streak').
5. Draft a single preview tweet that is at most 280 characters and includes: the matchup (Away @ Home), the consensus spread (favorite and number) and the consensus total, the sharpest outlier book and the line it has, and one sentence of color on recent form for both teams. Honor `tone`. No hashtags, no emojis, no shortened links, no '#GamblingTwitter' filler. Use plain American odds format (e.g. -3.5, O 224.5).
6. Post the tweet to X via the 'Create Tweet' operation on the user's connected X account.
Skip rules — do not post if any of the following is true:
- No events meet the `marquee_rule` bar (e.g. closest-to-pickem rule but every candidate spread is wider than 7, or marquee_teams rule and no candidate includes one of those teams). - Get Odds returns no bookmaker pricing for the chosen event. - The drafted tweet would exceed 280 characters even after a single retry to tighten it. In any skip case, log the reason and exit cleanly without tweeting.
Guardrails:
- Post at most one tweet per run. - Never invent odds, books, or scores; only use values returned by The Odds API. - If The Odds API returns a quota or rate-limit error, stop and surface the error rather than retrying aggressively. - Treat each day independently; do not reference yesterday's pick.
Additional information
What does this prompt do?
- Each afternoon, finds the single most-anticipated game starting in the next 8 hours across your chosen sports.
- Pulls the consensus spread and total from major US sportsbooks, plus the sharpest outlier book worth shopping.
- Adds one line of color on each team's recent form from the last few days of scores.
- Writes a 280-character preview and posts it to your X account, or skips the day cleanly if no game clears the bar.
What do I need to use this?
- An X account you have permission to post from.
- An Odds API key (the free Starter plan is enough to run this daily).
- Your timezone and the sports you want covered, with NFL, NBA, and MLB as the defaults.
How can I customize it?
- Change the time of day it runs and the timezone it uses to define 'tonight'.
- Swap the sports list, for example add college football, the WNBA, or the Premier League.
- Pick how the marquee game is chosen: closest to a pick'em line, highest total, or a list of must-cover teams.
- Tweak the tone of the preview, from sharp and data-driven to playful and fan-facing.
Frequently asked questions
What happens if no big game is on tonight?
Can I change which sports it covers?
How does it pick the 'marquee' game?
Will it ever tweet twice in one day?
Do I need a paid Odds API plan?
Stop staring at odds screens to find tonight's best game.
Connect The Odds API and X once, and Geni picks the matchup, writes the preview, and posts it for you every afternoon.