# devict-events A small project for devICT event-related things. - A process that polls the [OpenMeet](https://openmeet.net) API for upcoming events and sends slack notifications about them. - An API for more easily interacting with devICT event data. ## Event Notifier On a configurable interval the loop: 1. Fetches events for the next 7 days from OpenMeet, authenticating via ATProto (handle + app password) on the first call and refreshing the OpenMeet access token as needed. 2. Diffs the response against the slugs seen on the previous fetch to find new events, then notifies every configured channel about each one. 3. On the configured day-of-week and time-of-day (in `America/Chicago`), sends a digest of the upcoming week to every channel. ## Events API A simple fastify API, with an OpenAPI spec generated from JSON schemas attached to the routes directly. `GET /health` returns `{"status":"ok"}` — used by the uptime probes in the infra repo. ## Configuration Available config can be seen in `.env.example`, with more details in `src/config.ts`. ## Run ```sh npm start # poll loop npm run once # single fetch, weekly-digest format, then exit npm run once event [slug] # single fetch, new-event format ``` ## Test, lint, and typechecking ```sh npm run check ```