mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-09 21:17:15 +03:00
Add casual mode endpoint
This commit is contained in:
@@ -59,6 +59,7 @@ import { getFeatureFlag } from "./routes/getFeatureFlag";
|
||||
import { getReady } from "./routes/getReady";
|
||||
import { getMetrics } from "./routes/getMetrics";
|
||||
import { getSegmentID } from "./routes/getSegmentID";
|
||||
import { postCasual } from "./routes/postCasual";
|
||||
|
||||
export function createServer(callback: () => void): Server {
|
||||
// Create a service (the app object is just a callback).
|
||||
@@ -234,6 +235,8 @@ function setupRoutes(router: Router, server: Server) {
|
||||
router.get("/api/branding/:prefix", getBrandingByHashEndpoint);
|
||||
router.post("/api/branding", postBranding);
|
||||
|
||||
router.post("/api/casual", postCasual);
|
||||
|
||||
/* istanbul ignore next */
|
||||
if (config.postgres?.enabled) {
|
||||
router.get("/database", (req, res) => dumpDatabase(req, res, true));
|
||||
|
||||
Reference in New Issue
Block a user