mirror of
https://github.com/AmruthPillai/Reactive-Resume.git
synced 2026-07-26 01:44:53 +10:00
99c602e3c7
* Migrate from Biome to Oxlint/Oxfmt * pin version of autofix * set version of autofix * pin version of autofix * [autofix.ci] apply automated fixes * better comments, test formatter * [autofix.ci] apply automated fixes * Potential fix for pull request finding Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
26 lines
960 B
TypeScript
26 lines
960 B
TypeScript
import z from "zod";
|
|
|
|
import { publicProcedure } from "../context";
|
|
import { type FeatureFlags, flagsService } from "../services/flags";
|
|
|
|
export const flagsRouter = {
|
|
get: publicProcedure
|
|
.route({
|
|
method: "GET",
|
|
path: "/flags",
|
|
tags: ["Feature Flags"],
|
|
operationId: "getFeatureFlags",
|
|
summary: "Get feature flags",
|
|
description:
|
|
"Returns the current feature flags for this Reactive Resume instance. Feature flags control instance-wide settings such as whether new user signups or email-based authentication are disabled. No authentication required.",
|
|
successDescription: "The current feature flags for this instance.",
|
|
})
|
|
.output(
|
|
z.object({
|
|
disableSignups: z.boolean().describe("Whether new user signups are disabled on this instance."),
|
|
disableEmailAuth: z.boolean().describe("Whether email-based authentication is disabled on this instance."),
|
|
}),
|
|
)
|
|
.handler((): FeatureFlags => flagsService.getFlags()),
|
|
};
|