a dumb-simple discord bot + devvit app which embeds custom countdown cards for events / exams. that's it.
προθεσμία is greek for deadline.
site: prothesmia.xyz
discord: add the bot
reddit: developers.reddit.com/apps/prothesmia
terms / privacy
bot/- the discord bot. plain node, no framework. it takes slash commands over http and edits an embed on a scheduledevvit/- the reddit app. devvit web, typescript. a custom post that draws the card in realtimesite/- prothesmia.xyz. plain html, css and js, deployed by github pages from.github/workflows/pages.yml
the two cards do indeed look alike, but the discord one is drawn as a png and attached to an embed and the reddit one is simple html, css and svg.
- invite the bot to your server
- in the channel you want, use
/countdown setwith your config - leave it. the embed edits itself on the interval you set, 1 to 24 hours
it needs view channels, send messages, embed links, attach files and read message history, and uses no privileged intents. the channel can stay read-only. commands need the manage server permission. several countdowns can share a channel.
commands
/countdown set- post or replace a countdown in this channel/countdown configure- change settings on one that already exists/countdown list- lists every countdown set server-wide with its config/countdown remove- delete a countdown and its card/help- lists these commands
config
label- the title, for exampleJEE Main 2027date- written like2027-01-04 09:00timezone- an IANA name such asAsia/Kolkata; defaults toUTCstart- when the countdown began, before the date; optional. the ring fills gradually fromstartif settag- small text in the top corner,noneto hidefields- beside the ring:target,timeLeft,elapsed, ornonefor just the ringthumbnail- an image url for the top-right corner of the embeddimensions-tall(default) /compactring-default/pride/transinterval- hours between updates,1to24; defaults to1schedule-now/start/custompost_at- the post time for a custom schedule (has to be before the set-date)bump- bool. sends and prunes a random text to mark the channel unread on set intervalbump-interval- bump-rate,1to168; defaults to24
a bump sends one message at random from a fixed list in bot/src/bump.js. it's false unless you explicitly set it true
posts a custom countdown card / embed for a set date. visually similar to the discord embed; a few optional fields; a live d:h:m:s clock if you want one.
- any mod with
everythingprivileges can add it to their community - in the subreddit's mod menu, select
create countdown post - set custom config through the community's installed apps' settings - the post updates accordingly
the countdown post self-pins in the first slot. an optional scheduled thread, with the days left in the title, pins under it. both are posted by the application itself.
settings
events-name | event date | countdown start, separated by;. the start is optionaltimezone- an IANA name,Asia/Kolkataby defaultring styles- default, pride or transcard size- tall, compact or desktop. avoid desktop if most of your members use the phone clientfields- target, time left, elapsed. deselect all for just the ringtag- small text in the top corner,noneto hidelive clock- days, hours, minutes and seconds under a smaller ringcountdown post title- used when a mod creates the postscheduled thread- on or off, the hour, a title and a text. placeholders{days},{event}and{date}
reddit has approved it for the public listing, so any mod can add it from its app page. more in devvit/README.md.
the bot needs node 22.9 or newer, a discord application, and a turso database. set these, in your host or a bot/.env (ignored by git):
DISCORD_TOKEN
DISCORD_APP_ID
DISCORD_PUBLIC_KEY
TURSO_URL
TURSO_TOKEN
cd bot
npm install
npm run register
npm start
npm run registerregisters/countdownand/helpwith discord- set the application's interactions endpoint url to
https://your-host/interactions /healthanswersokand checks for due refreshes, so ping it every few minutes if your host sleeps. it also checks every 5 minutes on its own- the table is created on first start
npm run previewdraws sample cards intobot/out/
the reddit app needs node 24 or newer and a subreddit you moderate.
cd devvit
npm install
npm run login
npm run dev
npm run devplaytests on that subredditnpm run checkandnpm testcheck types and logic,npm run buildbuildsnpm run deployuploads a version,npm run launchsends it to reddit for review
the site is static. serve site/ with anything, for example python3 -m http.server inside it. pushing a change under site/ to main deploys it.
it keeps only what it needs to show a countdown. no accounts, no ads, no tracking, nothing sold. the discord bot stores each countdown's server and channel ids, label, dates and card options. the reddit app keeps two small values in reddit's own storage. the full list is on the privacy page.
it's a hobby project on free hosting, provided as is. it can be slow, restart or stop without notice, so don't rely on it as your only reminder for an exam or a deadline. the terms are short.
MIT.
open an issue, or mail hey@nielandvoid.com.
the pomodoro tool that was previously hosted at prothesmia.xyz is now at klepsydra and is named klepsydra / κλεψύδρα /kleˈpsiðra/.
