๐ŸŽฌ The Odyssey โ€” AMC Lincoln Square 13 Seat Checker

A val that watches every showtime of The Odyssey at AMC Lincoln Square 13 & IMAX for the next 3 weeks (sliding from now), renders a live gallery of clickable calendar buttons (date ยท time ยท format ยท seats occupied vs capacity), and emails an update digest every 25 minutes.

  • GET / โ€” the gallery. Each showtime is a button; click it to go straight to the AMC seat map / ticket page for that showing. Day buttons jump to each date.
  • GET /api/data.json โ€” the raw report (showtimes grouped by date).
  • GET /source โ€” this repo.

Data sources

SourceWhat you getRequires
AMC Theatres API (primary)Exact dates, times, formats, auditoriums, sold-out flags and precise occupied/total seat counts (via seating-layouts)AMC_VENDOR_KEY
Fandango napi (fallback)Dates, times, formats, availability and buy links โ€” no seat countsnothing (auto)

The AMC website itself (amctheatres.com) and its api.amctheatres.com showtimes endpoint are behind a bot-protection queue and vendor auth, so the app favors the official developer API and falls back to Fandango's internal API (the same source other public showtime scrapers use).

Setup (2 minutes)

  1. Get a free AMC developer key (self-serve, free): https://developers.amctheatres.com Note: keys are reported to activate on Thursdays โ€” if yours isn't live immediately, the app keeps working on the Fandango fallback until it is.

  2. Add the key to this val:

    ๐Ÿ‘‰ Add AMC_VENDOR_KEY here: https://www.val.town/x/cwervo/amc-odyssey-seats/environment-variables?key=AMC_VENDOR_KEY

Optional env vars:

  • EMAIL_TO โ€” digest recipient (defaults to cwervooo@yahoo.com). โš ๏ธ On the free Val Town plan, std/email can only send to your own Val Town account email. The digest tries EMAIL_TO first and, if that's rejected, falls back to the account owner's address so updates still arrive until you're on Pro.
  • FANDANGO_THEATER_ID โ€” override the fallback theatre (default AABQI = AMC Lincoln Square 13).

Schedule

digest.ts runs on an interval. The free tier allows โ‰ฅ 15 minutes between runs; this val is configured for every 25 minutes. Each run:

  1. Fetches all Odyssey showtimes at the theatre (next 21 days).
  2. Pulls exact seat layouts per showtime (cached ~15 min in blob storage to be nice to the API).
  3. Emails the digest and the gallery reflects the newest data on next load.

Files

gallery.tsx        HTTP โ€” the calendar-button gallery (and /api/data.json)
digest.ts          interval โ€” every 25 min, emails the update
src/config.ts      theatre/movie/search window/recipient configuration
src/amc.ts         AMC Theatres API client (X-AMC-Vendor-Key, HAL envelopes)
src/fandango.ts    Fandango napi fallback client
src/showtimes.ts   normalization + seat-count cache + report builder

Why not the showtimes URL you sent?

The referenced page (https://www.amctheatres.com/movies/the-odyssey-76238/showtimes) sits behind AMC's "Global Safety Net" bot queue (a JS-challenge redirect), so a serverless fetch can't read it, and the JSON API behind it rejects requests without a vendor key. This val uses the two working public paths instead โ€” the official developer API (which returns the same data, plus seat counts) and Fandango.