refactor(discord-bot): move types to their services

This commit is contained in:
Pihkaal
2025-12-04 19:08:27 +01:00
parent 464f367c80
commit 1b53f82e8a
4 changed files with 32 additions and 38 deletions

View File

@@ -1,6 +1,20 @@
import { env } from "~/env";
import { redis } from "@lbf-bot/database";
import type { QuestResult } from "~/types";
export type QuestResult = {
quest: {
id: string;
promoImageUrl: string;
promoImagePrimaryColor: string;
};
participants: Array<QuestParticipant>;
};
export type QuestParticipant = {
playerId: string;
username: string;
xp: number;
};
export const getLatestQuest = async (): Promise<QuestResult> => {
const response = await fetch(