feat: check for new quests, post result embed to discord webhook and cache posted quests

This commit is contained in:
Pihkaal
2025-05-07 18:42:08 +02:00
parent 7b8c47d88d
commit 416d7675f2
9 changed files with 183 additions and 2 deletions

View File

@@ -1 +1,14 @@
console.log("Hello via Bun!");
import { postEmbed } from "./discord";
import { env } from "./env";
import { checkForNewQuest } from "./wov";
const fn = async () => {
const quest = await checkForNewQuest();
if (quest) {
await postEmbed(quest);
console.log(`Quest result posted at: ${new Date().toISOString()}`);
}
};
await fn();
setInterval(fn, env.WOV_FETCH_INTERVAL);