Skip to content

armgit / kaneo

Public Imported from GitHub
0

⚡ Project management that doesn't become the project. Boards, Gantt charts, and GitHub integration. Self-host it or use Kaneo Cloud.

788 B
Raw Blame
import { z } from "../openapi";

export const calendarFeedProjectParam = z.object({ projectId: z.string() });
export const calendarFeedTokenParam = z.object({
  token: z.string().regex(/^[a-f0-9]{64}$/),
});
export const calendarFeedDeleteParam = calendarFeedProjectParam.extend({
  id: z.string(),
});
export const createCalendarFeedBody = z.object({
  labelIds: z.array(z.string().min(1)).max(100).default([]).openapi({
    description:
      "Match any selected label. Omit or leave empty to include all scheduled project tasks.",
  }),
  timeZone: z
    .string()
    .refine((value) => {
      try {
        new Intl.DateTimeFormat("en-US", { timeZone: value });
        return true;
      } catch {
        return false;
      }
    }, "Invalid time zone")
    .default("UTC"),
});