feat: profileStats endpoint for U8
All checks were successful
Build / build (pull_request) Successful in 1m58s

This commit is contained in:
2025-11-05 17:19:25 +01:00
parent be064fd249
commit d479ddd7a0
2 changed files with 2 additions and 2 deletions

View File

@@ -1,11 +1,10 @@
import type { RequestHandler } from "express";
import { getAccountIdForRequest } from "../../services/loginService.ts";
import { getInventory } from "../../services/inventoryService.ts";
import { getStats } from "../../services/statsService.ts";
import type { IStatsClient } from "../../types/statTypes.ts";
const viewController: RequestHandler = async (req, res) => {
const accountId = await getAccountIdForRequest(req);
const accountId = String(req.query.id ?? req.query.lookupId);
const inventory = await getInventory(accountId, "XPInfo");
const playerStats = await getStats(accountId);

View File

@@ -6,6 +6,7 @@ import { leaderboardController } from "../controllers/stats/leaderboardControlle
const statsRouter = express.Router();
statsRouter.get("/view.php", viewController);
statsRouter.get("/profileStats.php", viewController);
statsRouter.post("/upload.php", uploadController);
statsRouter.post("/leaderboardWeekly.php", leaderboardController);
statsRouter.post("/leaderboardArchived.php", leaderboardController);