changemaker.lite/api/src/modules/social/spotlight.schemas.ts
bunker-admin 08d8066157 Add ticketed events, Jitsi meeting integration, social features, and calendar system
- Ticketed events: full CRUD, ticket tiers (free/paid/donation), Stripe checkout,
  QR-based check-in scanner, public event pages, ticket confirmation emails
- Event formats: IN_PERSON/ONLINE/HYBRID with auto Jitsi meeting room lifecycle,
  ticket-gated meeting access, moderator JWT tokens, feature-flag guarded
- Social engagement: challenges with scoring/leaderboards, referral tracking,
  volunteer spotlight, impact stories, campaign celebrations, wall of fame
- Social calendar: personal calendar layers, shared calendar items with
  recurrence, scheduling polls, mobile day view
- MCP server: events tool pack with full admin CRUD + meeting token generation
- Unified calendar: eventFormat-aware tags, online event indicators
- Updated docs site, pangolin configs, and various admin UI improvements

Bunker Admin
2026-03-06 14:33:33 -07:00

28 lines
959 B
TypeScript

import { z } from 'zod';
export const nominateSchema = z.object({
userId: z.string().cuid(),
headline: z.string().max(200).optional(),
story: z.string().max(2000).optional(),
});
export const updateSpotlightSchema = z.object({
headline: z.string().max(200).optional(),
story: z.string().max(2000).optional(),
});
export const featureSchema = z.object({
month: z.string().regex(/^\d{4}-\d{2}$/, 'Month must be in YYYY-MM format'),
});
export const listSpotlightsSchema = z.object({
page: z.coerce.number().int().min(1).default(1),
limit: z.coerce.number().int().min(1).max(100).default(20),
status: z.enum(['NOMINATED', 'APPROVED', 'FEATURED', 'ARCHIVED']).optional(),
});
export type NominateInput = z.infer<typeof nominateSchema>;
export type UpdateSpotlightInput = z.infer<typeof updateSpotlightSchema>;
export type FeatureInput = z.infer<typeof featureSchema>;
export type ListSpotlightsInput = z.infer<typeof listSpotlightsSchema>;