Try it right here
This loads the live project from its own domain, exactly as a visitor would see it.
What it does
Fifteen organizations — the Library, five National Park Service sites, the TR Association, the Theodore Roosevelt Center, Friends of Sagamore Hill — plus keyword-scanned national calendars at the Smithsonian, the Library of Congress and the National Archives.
Roosevelt organizations are ingested whole; general calendars are filtered by relevance, with uncertain matches routed to a human review file rather than published or silently dropped. Franklin and Eleanor events are excluded, which is less trivial than it sounds. When a source fails, the last good data stands for seven days and the error surfaces rather than the calendar quietly emptying.
What it can do
- Four embeddable widgets with an auto-sizing iframe loader
- Relevance scoring that separates core, matched and possible events
- Recurring events can be hidden, collapsed to one row, or shown in full
- iCal feeds for special events, everything, virtual, free, and per source
- Seven-day fallback to last-good data, with failures surfaced not hidden
- A snippet builder on the home page for generating embed code
Make it your own
Start by forking the repository into your own organization. Everything below assumes you are working in your fork, not this one.
- Fork and replace the relevance terms in
trevents/model.pywith your own subject keywords. - Add source modules in
trevents/sources/— each needs aSOURCEdict and afetch()returningEventobjects — and register them, list order first being dedupe priority. - Add repository secrets
NPS_API_KEYandFIRECRAWL_API_KEY, the latter for sources that block GitHub runners. - Enable Pages from
main//docs, setdocs/CNAMEand add the DNS record. - Run
pip install -r requirements.txtandpython -m trevents.buildlocally, then trigger the update workflow. - Use
config/overrides.yamlto exclude or correct events, andconfig/manual_events.yamlfor organizations with no readable calendar.
Stuck on a step? Open an issue on the repository. Questions from people adapting these for their own institution are the most useful feedback we get.