From 58d231e72f279aae3215980dae153846fceca538 Mon Sep 17 00:00:00 2001 From: MrPiglr Date: Sat, 7 Feb 2026 04:52:01 +0000 Subject: [PATCH] Major: Add complete platform architecture with full data models - Add Prisma schema with all database models - Creator channels, streams, VOD, clips, monetization - Real-time chat, polls, interactions - Subscriptions, donations, payouts - Social graph (followers), clips, leaderboards - Complete Platform Architecture documentation - API structure and routes documentation - Implementation roadmap (8 phases) - Updated README with platform vision - Install core dependencies: Prisma, Clerk, Stripe, Socket.io Ready for Phase 1 development with database setup. --- README.md | 75 +- docs/API_STRUCTURE.md | 175 ++++ docs/DATABASE_SCHEMA.md | 382 +++++++++ docs/IMPLEMENTATION_ROADMAP.md | 329 ++++++++ docs/PLATFORM_ARCHITECTURE.md | 159 ++++ package-lock.json | 1452 +++++++++++++++++++++++++++++++- package.json | 9 +- prisma/schema.prisma | 323 +++++++ 8 files changed, 2879 insertions(+), 25 deletions(-) create mode 100644 docs/API_STRUCTURE.md create mode 100644 docs/DATABASE_SCHEMA.md create mode 100644 docs/IMPLEMENTATION_ROADMAP.md create mode 100644 docs/PLATFORM_ARCHITECTURE.md create mode 100644 prisma/schema.prisma diff --git a/README.md b/README.md index 73e009f..6bd3940 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,78 @@ # AeThex Live -A modern live streaming platform built with Next.js, featuring HLS video playback, real-time chat, and a sleek sci-fi aesthetic. +**A complete creator streaming platform** - Multi-channel streaming, community features, creator monetization, gaming tournaments, music/DJ tools, and enterprise streaming all in one. ![AeThex Live](https://github.com/user-attachments/assets/8c34bf6e-4ca1-40e5-86e8-c7a35f304bb7) -## Features +## 🎯 Platform Vision -- 🎥 **HLS Video Player** - Looping video player with hls.js support +AeThex LIVE combines the best of Twitch, YouTube Live, Discord, and creator platforms: + +- 🎬 **Multi-channel Streaming** - Creators manage multiple streaming channels +- 💬 **Real-time Community** - Live chat, reactions, gifting, polls, and moderation +- 💰 **Creator Monetization** - Subscriptions, donations, tips, and direct payouts +- 🎮 **Gaming/Esports** - Tournaments, leaderboards, competitive rankings +- 🎵 **Music/DJ Studio** - Special audio features and visualization +- 📚 **Education/Enterprise** - Webinars, conferences, courses +- 🎯 **Engagement Tools** - Clips, highlights, trending content, recommendations +- 📊 **Creator Dashboard** - Analytics, viewer insights, revenue tracking + +## ✨ Features (Roadmap) + +### Phase 1: Foundation ✅ (Current) +- ✅ HLS video player with auto-recovery +- ✅ Stream hosting infrastructure +- 🔄 User authentication (Clerk) +- 🔄 Basic creator profiles +- 🔄 Real-time chat with Socket.io + +### Phase 2: Social & Discovery +- Multi-channel management +- Stream discovery & search +- Follow/subscribe system +- Creator recommendations + +### Phase 3: Creator Tools & VOD +- VOD archives +- Clip creation & editing +- Advanced analytics +- Stream health monitoring + +### Phase 4: Monetization +- Subscriptions (tiered) +- Donations/tips +- Gifting system +- Creator payouts + +### Phase 5: Community & Engagement +- Live polls +- Reactions & emotes +- Channel points +- Moderation tools + +### Phase 6: Gaming/Esports +- Tournaments +- Leaderboards +- Match tracking +- Competitive rankings + +### Phase 7: Music/DJ Features +- DJ studio mode +- Audio visualization +- Music library +- Spotify integration + +### Phase 8: Enterprise/Education +- Webinar features +- Screen sharing +- Course creation +- Certificate generation + +- 🎥 **HLS Video Player** - High-quality streaming with hls.js support - 🎨 **Sci-Fi Dark Theme** - Immersive dark theme with cyan/blue accents -- 👥 **Live Viewer Count** - Real-time viewer count with animated indicator -- 💬 **Chat Sidebar** - Interactive chat interface for viewer engagement -- 🎵 **Now Playing** - Metadata display for current track/content -- 📱 **Responsive Design** - Works seamlessly on desktop and mobile +- 👥 **Live Viewer Count** - Real-time viewer tracking +- 💬 **Chat Sidebar** - Interactive community chat +- 📱 **Responsive Design** - Desktop and mobile optimized ## Tech Stack diff --git a/docs/API_STRUCTURE.md b/docs/API_STRUCTURE.md new file mode 100644 index 0000000..8ecfbe7 --- /dev/null +++ b/docs/API_STRUCTURE.md @@ -0,0 +1,175 @@ +# AeThex LIVE - API Structure + +## API Routes + +### Authentication +- `POST /api/auth/register` - Create account +- `POST /api/auth/login` - Login +- `POST /api/auth/logout` - Logout +- `GET /api/auth/me` - Get current user +- `POST /api/auth/refresh` - Refresh token + +### Users +- `GET /api/users/:id` - Get user profile +- `PATCH /api/users/:id` - Update profile +- `GET /api/users/:id/followers` - Get user followers +- `POST /api/users/:username/follow` - Follow user +- `DELETE /api/users/:username/follow` - Unfollow user +- `GET /api/users/:id/stats` - User statistics + +### Channels +- `POST /api/channels` - Create channel +- `GET /api/channels/:slug` - Get channel +- `PATCH /api/channels/:id` - Update channel +- `DELETE /api/channels/:id` - Delete channel +- `GET /api/channels/:id/streams` - Get channel streams +- `GET /api/channels/:id/followers` - Get followers +- `POST /api/channels/:id/follow` - Follow channel +- `DELETE /api/channels/:id/follow` - Unfollow channel +- `GET /api/channels/:id/analytics` - Channel analytics +- `GET /api/channels/:id/settings` - Channel settings +- `PATCH /api/channels/:id/settings` - Update settings + +### Streams & Live +- `POST /api/streams` - Create/start stream +- `GET /api/streams/:id` - Get stream details +- `PATCH /api/streams/:id` - Update stream +- `DELETE /api/streams/:id` - End stream +- `GET /api/streams/:id/viewers` - Get viewer count +- `POST /api/streams/:id/webhooks` - Stream webhooks (from provider) +- `GET /api/browse` - Browse live streams +- `GET /api/search` - Search streams +- `GET /api/recommended` - Recommended streams + +### Chat (Real-time via Socket.io) +- `socket.emit('join-stream', {streamId})` - Join chat +- `socket.emit('send-message', {message})` - Send message +- `socket.emit('delete-message', {messageId})` - Delete message +- `socket.on('new-message', handler)` - Receive messages +- `socket.on('user-joined', handler)` - User joined +- `socket.on('user-left', handler)` - User left + +### VOD & Archives +- `GET /api/vods/:id` - Get VOD +- `GET /api/channels/:id/vods` - Get channel VODs +- `GET /api/vods/:id/progress` - Get watch progress +- `POST /api/vods/:id/progress` - Save watch progress +- `POST /api/vods/:id/report` - Report VOD + +### Clips +- `POST /api/clips` - Create clip +- `GET /api/clips/:id` - Get clip +- `PATCH /api/clips/:id` - Update clip +- `DELETE /api/clips/:id` - Delete clip +- `GET /api/channels/:id/clips` - Get channel clips +- `POST /api/clips/:id/like` - Like clip +- `DELETE /api/clips/:id/like` - Unlike clip +- `GET /api/clips/trending` - Trending clips + +### Monetization +- `POST /api/subscriptions` - Create subscription +- `GET /api/subscriptions/me` - Get my subscriptions +- `DELETE /api/subscriptions/:id` - Cancel subscription +- `POST /api/donations` - Create donation +- `GET /api/donations/me` - My donations +- `GET /api/channels/:id/revenue` - Channel revenue +- `GET /api/payouts` - Get payouts +- `POST /api/payouts/request` - Request payout + +### Interactions +- `POST /api/polls` - Create poll +- `GET /api/polls/:id` - Get poll +- `POST /api/polls/:id/vote` - Vote on poll +- `POST /api/reactions` - Send reaction +- `POST /api/gifts` - Send gift + +### Gaming/Tournaments +- `POST /api/tournaments` - Create tournament +- `GET /api/tournaments/:id` - Get tournament +- `POST /api/tournaments/:id/join` - Join tournament +- `GET /api/leaderboards/:name` - Get leaderboard +- `GET /api/leaderboards/:name/entries/:userId` - Get user rank + +### Moderation +- `GET /api/moderation/queue` - Get mod queue +- `POST /api/moderation/queue/:id/approve` - Approve +- `POST /api/moderation/queue/:id/reject` - Reject +- `POST /api/channels/:id/bans` - Ban user +- `DELETE /api/channels/:id/bans/:userId` - Unban user +- `GET /api/channels/:id/bans` - Get bans + +## Real-time Events (Socket.io) + +### Stream Events +- `stream:started` - Stream went live +- `stream:ended` - Stream ended +- `stream:updated` - Stream metadata changed +- `viewers:updated` - Viewer count changed +- `viewers:joined` - User joined stream +- `viewers:left` - User left stream + +### Chat Events +- `chat:message` - New chat message +- `chat:deleted` - Message deleted +- `chat:cleared` - Chat cleared +- `chat:emote` - Emote sent +- `chat:ban` - User banned + +### Interaction Events +- `poll:created` - Poll started +- `poll:voted` - Someone voted +- `poll:ended` - Poll ended +- `reaction:sent` - Reaction/emote displayed +- `gift:sent` - Gift displayed to chat + +### Monetization Events +- `subscription:new` - New subscriber +- `donation:received` - Donation received +- `milestone:reached` - Milestone (100 followers, etc.) + +## WebSocket Message Format + +```json +{ + "type": "event_type", + "payload": { + // Event-specific data + }, + "timestamp": "2026-02-07T12:00:00Z" +} +``` + +## Error Responses + +```json +{ + "error": true, + "code": "ERROR_CODE", + "message": "Human readable message", + "status": 400 +} +``` + +## Rate Limiting + +- Public endpoints: 100 req/min per IP +- Authenticated endpoints: 300 req/min per user +- Streaming endpoints: 50 req/min +- Chat: 5 messages/10 seconds per user + +## Pagination + +``` +GET /api/resource?page=1&limit=20 +``` + +Response: +```json +{ + "data": [...], + "total": 100, + "page": 1, + "limit": 20, + "hasMore": true +} +``` diff --git a/docs/DATABASE_SCHEMA.md b/docs/DATABASE_SCHEMA.md new file mode 100644 index 0000000..19f9c4d --- /dev/null +++ b/docs/DATABASE_SCHEMA.md @@ -0,0 +1,382 @@ +# Database Schema for AeThex LIVE + +## Users & Authentication + +```sql +-- Users table +CREATE TABLE users ( + id UUID PRIMARY KEY, + username VARCHAR(255) UNIQUE NOT NULL, + email VARCHAR(255) UNIQUE NOT NULL, + display_name VARCHAR(255), + bio TEXT, + avatar_url VARCHAR(255), + banner_url VARCHAR(255), + is_creator BOOLEAN DEFAULT false, + verified BOOLEAN DEFAULT false, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- User settings +CREATE TABLE user_settings ( + user_id UUID PRIMARY KEY REFERENCES users(id), + email_notifications BOOLEAN DEFAULT true, + two_factor_enabled BOOLEAN DEFAULT false, + privacy_level VARCHAR(50) DEFAULT 'public', -- public, private, friends + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +``` + +## Channels & Streaming + +```sql +-- Channels table +CREATE TABLE channels ( + id UUID PRIMARY KEY, + user_id UUID NOT NULL REFERENCES users(id), + name VARCHAR(255) NOT NULL, + slug VARCHAR(255) UNIQUE NOT NULL, + description TEXT, + category VARCHAR(100), -- gaming, music, education, etc. + language VARCHAR(50), + is_live BOOLEAN DEFAULT false, + total_views BIGINT DEFAULT 0, + follower_count INT DEFAULT 0, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Streams (live sessions) +CREATE TABLE streams ( + id UUID PRIMARY KEY, + channel_id UUID NOT NULL REFERENCES channels(id), + title VARCHAR(255) NOT NULL, + description TEXT, + status VARCHAR(50), -- live, ended, scheduled + stream_key VARCHAR(255) UNIQUE NOT NULL, + hls_url VARCHAR(255), + thumbnail_url VARCHAR(255), + viewer_count INT DEFAULT 0, + started_at TIMESTAMP, + ended_at TIMESTAMP, + duration_seconds INT, + is_archived BOOLEAN DEFAULT true, + archive_url VARCHAR(255), + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Stream tags +CREATE TABLE stream_tags ( + stream_id UUID REFERENCES streams(id), + tag VARCHAR(100), + PRIMARY KEY (stream_id, tag) +); +``` + +## Social Features + +```sql +-- Followers/Subscriptions +CREATE TABLE followers ( + follower_id UUID NOT NULL REFERENCES users(id), + channel_id UUID NOT NULL REFERENCES channels(id), + follow_date TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + notification_enabled BOOLEAN DEFAULT true, + PRIMARY KEY (follower_id, channel_id) +); + +-- User follows +CREATE TABLE user_follows_user ( + follower_id UUID NOT NULL REFERENCES users(id), + following_id UUID NOT NULL REFERENCES users(id), + follow_date TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + PRIMARY KEY (follower_id, following_id) +); +``` + +## Chat & Moderation + +```sql +-- Chat messages +CREATE TABLE chat_messages ( + id UUID PRIMARY KEY, + stream_id UUID NOT NULL REFERENCES streams(id), + user_id UUID NOT NULL REFERENCES users(id), + message TEXT NOT NULL, + is_deleted BOOLEAN DEFAULT false, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Chat bans/moderation +CREATE TABLE chat_bans ( + id UUID PRIMARY KEY, + channel_id UUID NOT NULL REFERENCES channels(id), + banned_user_id UUID NOT NULL REFERENCES users(id), + reason TEXT, + banned_until TIMESTAMP, + is_permanent BOOLEAN DEFAULT false, + created_by UUID NOT NULL REFERENCES users(id), + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Moderation queue +CREATE TABLE moderation_queue ( + id UUID PRIMARY KEY, + stream_id UUID REFERENCES streams(id), + message_id UUID REFERENCES chat_messages(id), + reported_by UUID NOT NULL REFERENCES users(id), + reason VARCHAR(255), + status VARCHAR(50) DEFAULT 'pending', -- pending, approved, rejected + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +``` + +## Monetization + +```sql +-- Subscriptions +CREATE TABLE subscriptions ( + id UUID PRIMARY KEY, + subscriber_id UUID NOT NULL REFERENCES users(id), + channel_id UUID NOT NULL REFERENCES channels(id), + tier VARCHAR(50), -- basic, premium, vip + price_cents INT NOT NULL, + stripe_subscription_id VARCHAR(255), + status VARCHAR(50), -- active, cancelled, expired + started_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + ended_at TIMESTAMP, + auto_renew BOOLEAN DEFAULT true, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Donations/Tips +CREATE TABLE donations ( + id UUID PRIMARY KEY, + donor_id UUID NOT NULL REFERENCES users(id), + channel_id UUID NOT NULL REFERENCES channels(id), + stream_id UUID REFERENCES streams(id), + amount_cents INT NOT NULL, + currency VARCHAR(3) DEFAULT 'USD', + message TEXT, + stripe_charge_id VARCHAR(255), + status VARCHAR(50) DEFAULT 'completed', -- pending, completed, failed + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Creator payouts +CREATE TABLE payouts ( + id UUID PRIMARY KEY, + user_id UUID NOT NULL REFERENCES users(id), + amount_cents INT NOT NULL, + currency VARCHAR(3) DEFAULT 'USD', + stripe_payout_id VARCHAR(255), + status VARCHAR(50) DEFAULT 'pending', -- pending, paid, failed + period_start DATE, + period_end DATE, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +``` + +## Content + +```sql +-- VODs (Video on Demand) +CREATE TABLE vods ( + id UUID PRIMARY KEY, + stream_id UUID UNIQUE NOT NULL REFERENCES streams(id), + title VARCHAR(255), + description TEXT, + thumbnail_url VARCHAR(255), + duration_seconds INT, + views INT DEFAULT 0, + is_public BOOLEAN DEFAULT true, + processing_status VARCHAR(50) DEFAULT 'processing', -- processing, ready, failed + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Clips +CREATE TABLE clips ( + id UUID PRIMARY KEY, + vod_id UUID REFERENCES vods(id), + stream_id UUID REFERENCES streams(id), + creator_id UUID NOT NULL REFERENCES users(id), + channel_id UUID NOT NULL REFERENCES channels(id), + title VARCHAR(255) NOT NULL, + slug VARCHAR(255) UNIQUE NOT NULL, + description TEXT, + thumbnail_url VARCHAR(255), + video_url VARCHAR(255), + start_seconds INT, + duration_seconds INT, + views INT DEFAULT 0, + likes INT DEFAULT 0, + is_public BOOLEAN DEFAULT true, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Clip reactions +CREATE TABLE clip_likes ( + user_id UUID NOT NULL REFERENCES users(id), + clip_id UUID NOT NULL REFERENCES clips(id), + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + PRIMARY KEY (user_id, clip_id) +); +``` + +## Interactions & Engagement + +```sql +-- Live polls +CREATE TABLE polls ( + id UUID PRIMARY KEY, + stream_id UUID NOT NULL REFERENCES streams(id), + question VARCHAR(255) NOT NULL, + duration_seconds INT, + status VARCHAR(50) DEFAULT 'active', -- active, ended + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + ended_at TIMESTAMP +); + +-- Poll options +CREATE TABLE poll_options ( + id UUID PRIMARY KEY, + poll_id UUID NOT NULL REFERENCES polls(id), + option VARCHAR(255) NOT NULL, + vote_count INT DEFAULT 0 +); + +-- Poll votes +CREATE TABLE poll_votes ( + user_id UUID NOT NULL REFERENCES users(id), + poll_option_id UUID NOT NULL REFERENCES poll_options(id), + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + PRIMARY KEY (user_id, poll_option_id) +); + +-- Reactions/Emotes +CREATE TABLE chat_reactions ( + id UUID PRIMARY KEY, + stream_id UUID NOT NULL REFERENCES streams(id), + user_id UUID NOT NULL REFERENCES users(id), + emoji VARCHAR(50), + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Gifting +CREATE TABLE gifts ( + id UUID PRIMARY KEY, + gifter_id UUID NOT NULL REFERENCES users(id), + recipient_id UUID NOT NULL REFERENCES users(id), + stream_id UUID REFERENCES streams(id), + gift_type VARCHAR(50), -- custom types + amount_cents INT NOT NULL, + message TEXT, + stripe_charge_id VARCHAR(255), + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +``` + +## Gaming/Competitions + +```sql +-- Tournaments +CREATE TABLE tournaments ( + id UUID PRIMARY KEY, + name VARCHAR(255) NOT NULL, + description TEXT, + owner_id UUID NOT NULL REFERENCES users(id), + game VARCHAR(255), + status VARCHAR(50) DEFAULT 'draft', -- draft, active, ended + max_participants INT, + prize_pool_cents INT, + started_at TIMESTAMP, + ended_at TIMESTAMP, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Tournament participants +CREATE TABLE tournament_participants ( + id UUID PRIMARY KEY, + tournament_id UUID NOT NULL REFERENCES tournaments(id), + user_id UUID NOT NULL REFERENCES users(id), + channel_id UUID NOT NULL REFERENCES channels(id), + seed INT, + final_rank INT, + joined_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Leaderboards +CREATE TABLE leaderboards ( + id UUID PRIMARY KEY, + name VARCHAR(255) NOT NULL, + game VARCHAR(255), + period VARCHAR(50), -- weekly, monthly, all-time + reset_date DATE +); + +-- Leaderboard entries +CREATE TABLE leaderboard_entries ( + leaderboard_id UUID NOT NULL REFERENCES leaderboards(id), + user_id UUID NOT NULL REFERENCES users(id), + rank INT, + score BIGINT, + updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + PRIMARY KEY (leaderboard_id, user_id) +); +``` + +## Analytics + +```sql +-- Stream analytics +CREATE TABLE stream_analytics ( + id UUID PRIMARY KEY, + stream_id UUID NOT NULL REFERENCES streams(id), + hour_timestamp TIMESTAMP, + viewer_count INT, + peak_viewers INT, + avg_watch_time_seconds INT, + new_followers INT, + subscriptions INT, + donations_cents INT, + chat_messages INT, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- Channel analytics (daily) +CREATE TABLE channel_analytics ( + id UUID PRIMARY KEY, + channel_id UUID NOT NULL REFERENCES channels(id), + date DATE, + total_views INT, + new_followers INT, + subscriptions INT, + donations_cents INT, + revenue_cents INT, + created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +``` + +## Indexes + +```sql +-- Performance indexes +CREATE INDEX idx_users_username ON users(username); +CREATE INDEX idx_users_email ON users(email); +CREATE INDEX idx_channels_user_id ON channels(user_id); +CREATE INDEX idx_channels_slug ON channels(slug); +CREATE INDEX idx_streams_channel_id ON streams(channel_id); +CREATE INDEX idx_streams_status ON streams(status); +CREATE INDEX idx_streams_is_live ON streams(is_live); +CREATE INDEX idx_chat_messages_stream_id ON chat_messages(stream_id, created_at DESC); +CREATE INDEX idx_followers_channel_id ON followers(channel_id); +CREATE INDEX idx_followers_follower_id ON followers(follower_id); +CREATE INDEX idx_subscriptions_channel_id ON subscriptions(channel_id); +CREATE INDEX idx_subscriptions_status ON subscriptions(status); +CREATE INDEX idx_donations_channel_id ON donations(channel_id); +CREATE INDEX idx_vods_stream_id ON vods(stream_id); +CREATE INDEX idx_clips_channel_id ON clips(channel_id); +``` diff --git a/docs/IMPLEMENTATION_ROADMAP.md b/docs/IMPLEMENTATION_ROADMAP.md new file mode 100644 index 0000000..f9d6b28 --- /dev/null +++ b/docs/IMPLEMENTATION_ROADMAP.md @@ -0,0 +1,329 @@ +# AeThex LIVE - Implementation Roadmap + +## Vision +A complete creator platform combining: +- 🎬 **Multi-channel Live Streaming** (Twitch-like) +- 💬 **Real-time Community** (Chat, reactions, gifting) +- 🎮 **Gaming/Esports** (Tournaments, leaderboards) +- 🎵 **Music/DJ Studio Mode** (Special audio features) +- 📚 **Education/Enterprise** (Webinars, conferences) +- 💰 **Creator Monetization** (Subs, donations, payouts) +- 🎯 **Engagement Tools** (Polls, clips, highlights) + +--- + +## Phase 1: Foundation (NOW) +**Goal**: Basic streaming platform with authentication + +### Sprint 1.1: Database & Authentication +- [ ] Set up PostgreSQL on Railway +- [ ] Run Prisma migrations +- [ ] Set up Clerk authentication +- [ ] Create user profiles +- [ ] User settings/preferences + +### Sprint 1.2: Basic Streaming +- [ ] Creator channel creation +- [ ] Stream key management +- [ ] HLS ingestion & playback ✅ (already done) +- [ ] Stream metadata (title, description) +- [ ] Stream status management + +### Sprint 1.3: Real-time Chat +- [ ] Socket.io server setup +- [ ] Chat message storage +- [ ] Real-time message delivery +- [ ] Chat UI component +- [ ] Message deletion/moderation + +--- + +## Phase 2: Social & Discovery (3-4 weeks) +**Goal**: Community features and stream discovery + +### Sprint 2.1: Social Graph +- [ ] Follow/unfollow users +- [ ] Follow/unfollow channels +- [ ] Follower count display +- [ ] Following list +- [ ] Notifications on new streams + +### Sprint 2.2: Discovery & Search +- [ ] Browse live streams +- [ ] Search by title/creator/category +- [ ] Category filtering +- [ ] Recommended streams +- [ ] Trending/trending dashboard +- [ ] Sort by viewers, new, featured + +### Sprint 2.3: Creator Dashboard +- [ ] Stream management UI +- [ ] Go live/end stream UI +- [ ] Viewer count tracker +- [ ] Basic analytics (views, avg watch time) +- [ ] Stream health (bitrate, fps) +- [ ] Recent clips/clips dashboard + +--- + +## Phase 3: Creator Tools & VOD (4-5 weeks) +**Goal**: Content creation and archival + +### Sprint 3.1: VOD Archives +- [ ] Automatic stream archival +- [ ] VOD library management +- [ ] VOD playback (same HLS player) +- [ ] Watch progress tracking +- [ ] Delete/manage VODs + +### Sprint 3.2: Clip Creation +- [ ] Create clips from VODs +- [ ] In-stream clip button +- [ ] Clip editor (trim start/end) +- [ ] Clip management +- [ ] Clip sharing +- [ ] Like & trending clips + +### Sprint 3.3: Advanced Analytics +- [ ] Hourly viewer graphs +- [ ] Peak viewer count +- [ ] Chat activity metrics +- [ ] Revenue dashboard +- [ ] Follower growth +- [ ] Traffic sources + +--- + +## Phase 4: Monetization (4-6 weeks) +**Goal**: Creator revenue streams + +### Sprint 4.1: Subscriptions +- [ ] Tier management (basic/premium/vip) +- [ ] Stripe integration +- [ ] Subscription checkout +- [ ] Subscriber badge in chat +- [ ] Subscriber-only chat +- [ ] Revenue tracking + +### Sprint 4.2: Donations & Gifting +- [ ] Donation button on stream +- [ ] Donation alerts (TTS, visual) +- [ ] Gifting system (send gifts to viewers) +- [ ] Gift animations in chat +- [ ] Fundraising campaigns + +### Sprint 4.3: Payouts +- [ ] Stripe Connect setup +- [ ] Revenue calculation (minus platform cut) +- [ ] Payout requests +- [ ] Payout history +- [ ] Tax forms + +--- + +## Phase 5: Community & Engagement (3-4 weeks) +**Goal**: Deep community features + +### Sprint 5.1: Live Interactions +- [ ] Polls during streams +- [ ] Reaction/emote system +- [ ] Hype train +- [ ] Chat rewards (points) +- [ ] Channel points/currency + +### Sprint 5.2: Community Channels +- [ ] Moderator roles +- [ ] Chat moderation tools +- [ ] Ban/timeout system +- [ ] Auto-moderation (spam, profanity) +- [ ] Mod dashboard + +### Sprint 5.3: Social Features +- [ ] Stream notifications +- [ ] Friend system +- [ ] Private messages +- [ ] Channel announcements +- [ ] Raid system (send viewers to another stream) + +--- + +## Phase 6: Gaming/Esports (5-6 weeks) +**Goal**: Gaming-focused features + +### Sprint 6.1: Tournaments +- [ ] Tournament creation +- [ ] Bracket system (single-elim, double-elim) +- [ ] Team management +- [ ] Tournament chat +- [ ] Prize pool management + +### Sprint 6.2: Leaderboards +- [ ] Game-specific leaderboards +- [ ] Time-based leaderboards (weekly, monthly, all-time) +- [ ] Leaderboard positioning +- [ ] Achievement badges + +### Sprint 6.3: Competitive Features +- [ ] Match scheduling +- [ ] VOD linking to matches +- [ ] Spectator mode +- [ ] Performance analytics + +--- + +## Phase 7: Music/DJ Features (3-4 weeks) +**Goal**: Music-specific tools + +### Sprint 7.1: DJ Mode +- [ ] Special layout for music +- [ ] Song queue display +- [ ] Current track info +- [ ] Music visualization (animated, audio-reactive) + +### Sprint 7.2: Music Library +- [ ] Upload/manage tracklist +- [ ] Spotify integration (if licensing allows) +- [ ] Now playing display +- [ ] Spotify widget + +### Sprint 7.3: Audio Quality +- [ ] High bitrate streaming +- [ ] Lossless audio (FLAC) option +- [ ] Audio level metrics +- [ ] EQ visualization + +--- + +## Phase 8: Enterprise/Education (3-4 weeks) +**Goal**: Business use cases + +### Sprint 8.1: Webinar Features +- [ ] Screen sharing +- [ ] Presentation mode +- [ ] Q&A system (moderated) +- [ ] Recording management + +### Sprint 8.2: Education Features +- [ ] Course creation +- [ ] Session scheduling +- [ ] Attendance tracking +- [ ] Certificate generation + +### Sprint 8.3: Organization Features +- [ ] Teams/organizations +- [ ] Org analytics +- [ ] Org branding +- [ ] Multi-streamer management + +--- + +## Phase 9: Polish & Scale (Ongoing) +**Goal**: Performance, reliability, expansion + +### Sprint 9.1: Performance +- [ ] CDN optimization +- [ ] Database query optimization +- [ ] Caching strategy (Redis) +- [ ] Load testing + +### Sprint 9.2: Mobile Apps +- [ ] Mobile web PWA +- [ ] iOS app (React Native) +- [ ] Android app (React Native) + +### Sprint 9.3: Integrations +- [ ] OBS integration +- [ ] Chatbot support +- [ ] Webhook integrations +- [ ] API for third-parties + +--- + +## Technology Stack + +### Frontend +- Next.js 16 +- React 19 +- TypeScript +- Tailwind CSS +- Socket.io client +- Stripe React Elements + +### Backend +- Next.js API Routes +- Node.js +- Prisma ORM +- Socket.io +- Stripe API +- Clerk + +### Database +- PostgreSQL (Railway) +- Redis (Upstash on Railway) + +### Services +- Clerk (Auth) +- Stripe (Payments) +- Cloudflare Stream or Mux (Video) +- Cloudflare R2 (Storage) +- SendGrid/Resend (Email) + +--- + +## Development Setup + +### Prerequisites +```bash +# Install Node.js 20+ +# Set up Railway project with PostgreSQL +# Get Clerk API keys +# Get Stripe API keys +``` + +### Initial Setup +```bash +# 1. Clone repository +git clone https://github.com/AeThex-LABS/aethex.live +cd aethex.live + +# 2. Install dependencies +npm install + +# 3. Set up environment variables +cp .env.example .env.local + +# 4. Set up database +npx prisma migrate dev + +# 5. Start development +npm run dev +``` + +--- + +## Success Metrics (MVP) + +- [ ] 100+ creators +- [ ] 1000+ concurrent viewers +- [ ] 99.9% uptime +- [ ] <2s latency (stream) +- [ ] <100ms chat latency +- [ ] $10k+ monthly creator revenue + +--- + +## Long-term Vision + +AeThex LIVE becomes the go-to platform for: +- Independent creators +- Gaming communities +- Music/DJ culture +- Educational content +- Business streaming + +With: +- Best-in-class streaming quality +- Creator-first monetization +- Community-driven features +- Open API for extensions +- Global CDN presence diff --git a/docs/PLATFORM_ARCHITECTURE.md b/docs/PLATFORM_ARCHITECTURE.md new file mode 100644 index 0000000..9cff3f0 --- /dev/null +++ b/docs/PLATFORM_ARCHITECTURE.md @@ -0,0 +1,159 @@ +# AeThex LIVE - Complete Platform Architecture + +## System Overview + +``` +┌─────────────────────────────────────────────────────┐ +│ AeThex LIVE Creator Platform │ +├─────────────────────────────────────────────────────┤ +│ │ +│ Frontend (Next.js) │ +│ ├─ Creator Dashboard │ +│ ├─ Watch Page (Single Stream) │ +│ ├─ Discovery/Browse │ +│ ├─ User Profiles │ +│ ├─ Community Channels │ +│ └─ Creator Monetization UI │ +│ │ +│ Backend (Node.js/Next.js API Routes) │ +│ ├─ Authentication (Clerk) │ +│ ├─ User Management │ +│ ├─ Channel/Stream Management │ +│ ├─ VOD Management │ +│ ├─ Real-time Chat (Socket.io) │ +│ ├─ Monetization/Payments (Stripe) │ +│ ├─ Analytics & Reports │ +│ └─ Content Moderation │ +│ │ +│ Database (PostgreSQL on Railway) │ +│ ├─ Users & Profiles │ +│ ├─ Channels & Streams │ +│ ├─ VOD/Clips │ +│ ├─ Chat/Messages │ +│ ├─ Social Graph (Followers) │ +│ ├─ Monetization (Subscriptions, Donations) │ +│ ├─ Polls & Interactions │ +│ └─ Analytics │ +│ │ +│ Services │ +│ ├─ Streaming (Cloudflare/Mux) │ +│ ├─ Storage (Cloudflare R2/S3) │ +│ ├─ Video Processing (FFmpeg) │ +│ ├─ Cache (Redis on Railway) │ +│ └─ Email (Resend/SendGrid) │ +│ │ +└─────────────────────────────────────────────────────┘ +``` + +## Data Models + +### Core Entities +- **User** - Creator/Viewer accounts +- **Channel** - Creator's channel (can have multiple) +- **Stream** - Live streaming session +- **VOD** - Video on demand (archived stream) +- **Clip** - User-created highlight clip +- **ChatMessage** - Stream chat +- **Follower** - Social graph +- **Subscription** - Paid membership +- **Donation/Tip** - One-time payment +- **Poll** - Live poll/interaction +- **Leaderboard** - Gaming/competition rankings + +### Features by Priority + +#### Phase 1: Foundation (Current) +- [x] HLS streaming player +- [ ] User authentication +- [ ] Basic profiles +- [ ] Real-time chat + +#### Phase 2: Multi-Channel & Discovery +- [ ] Multi-channel support +- [ ] Stream discovery/browse +- [ ] Search & recommendations +- [ ] Follow system + +#### Phase 3: Creator Tools +- [ ] Creator dashboard +- [ ] Stream analytics +- [ ] VOD archives +- [ ] Basic clip creation + +#### Phase 4: Monetization +- [ ] Subscriptions +- [ ] Donations/tips +- [ ] Payout system +- [ ] Revenue analytics + +#### Phase 5: Community & Engagement +- [ ] Community channels +- [ ] Polls & reactions +- [ ] Gifting +- [ ] User badges/roles + +#### Phase 6: Advanced Features +- [ ] Gaming tournaments +- [ ] Leaderboards +- [ ] Music/DJ mode +- [ ] Clips & highlights +- [ ] Auto-moderation +- [ ] Notifications + +## Tech Stack + +**Frontend** +- Next.js 16 (React 19) +- TypeScript +- Tailwind CSS +- Socket.io client +- Stripe React + +**Backend** +- Next.js API Routes +- Node.js +- Socket.io server +- Prisma ORM + +**Database** +- PostgreSQL (Railway) +- Redis (Upstash/Railway) + +**Authentication** +- Clerk (or NextAuth.js) + +**Payments** +- Stripe + +**Streaming** +- Cloudflare Stream or Mux + +**Storage** +- Cloudflare R2 or AWS S3 + +**Real-time** +- Socket.io + +## Database Schema + +See `docs/DATABASE_SCHEMA.md` + +## API Structure + +See `docs/API_STRUCTURE.md` + +## Implementation Order + +1. Set up Prisma & PostgreSQL +2. User authentication (Clerk) +3. Channel & stream creation +4. Real-time chat +5. VOD storage +6. Follow system +7. Basic dashboard +8. Stripe integration +9. Advanced features + +--- + +**Ready to build the complete platform!** diff --git a/package-lock.json b/package-lock.json index ffff404..6c8a74d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -8,10 +8,17 @@ "name": "aethex-live", "version": "0.1.0", "dependencies": { + "@clerk/nextjs": "^6.37.3", + "@prisma/client": "^7.3.0", "hls.js": "^1.6.15", "next": "16.1.6", + "next-auth": "^4.24.13", + "prisma": "^7.3.0", "react": "19.2.3", - "react-dom": "19.2.3" + "react-dom": "19.2.3", + "socket.io": "^4.8.3", + "socket.io-client": "^4.8.3", + "stripe": "^20.3.1" }, "devDependencies": { "@tailwindcss/postcss": "^4", @@ -22,6 +29,9 @@ "eslint-config-next": "16.1.6", "tailwindcss": "^4", "typescript": "^5" + }, + "engines": { + "node": ">=20.9.0" } }, "node_modules/@alloc/quick-lru": { @@ -230,6 +240,15 @@ "node": ">=6.0.0" } }, + "node_modules/@babel/runtime": { + "version": "7.28.6", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.28.6.tgz", + "integrity": "sha512-05WQkdpL9COIMz4LjTxGpPNCdlpyimKppYNoJ5Di5EUObifl8t4tuLuUBBZEpoLYOmfvIWrsp9fCl0HoPRVTdA==", + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, "node_modules/@babel/template": { "version": "7.28.6", "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.28.6.tgz", @@ -278,6 +297,169 @@ "node": ">=6.9.0" } }, + "node_modules/@chevrotain/cst-dts-gen": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/@chevrotain/cst-dts-gen/-/cst-dts-gen-10.5.0.tgz", + "integrity": "sha512-lhmC/FyqQ2o7pGK4Om+hzuDrm9rhFYIJ/AXoQBeongmn870Xeb0L6oGEiuR8nohFNL5sMaQEJWCxr1oIVIVXrw==", + "license": "Apache-2.0", + "dependencies": { + "@chevrotain/gast": "10.5.0", + "@chevrotain/types": "10.5.0", + "lodash": "4.17.21" + } + }, + "node_modules/@chevrotain/gast": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/@chevrotain/gast/-/gast-10.5.0.tgz", + "integrity": "sha512-pXdMJ9XeDAbgOWKuD1Fldz4ieCs6+nLNmyVhe2gZVqoO7v8HXuHYs5OV2EzUtbuai37TlOAQHrTDvxMnvMJz3A==", + "license": "Apache-2.0", + "dependencies": { + "@chevrotain/types": "10.5.0", + "lodash": "4.17.21" + } + }, + "node_modules/@chevrotain/types": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/@chevrotain/types/-/types-10.5.0.tgz", + "integrity": "sha512-f1MAia0x/pAVPWH/T73BJVyO2XU5tI4/iE7cnxb7tqdNTNhQI3Uq3XkqcoteTmD4t1aM0LbHCJOhgIDn07kl2A==", + "license": "Apache-2.0" + }, + "node_modules/@chevrotain/utils": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/@chevrotain/utils/-/utils-10.5.0.tgz", + "integrity": "sha512-hBzuU5+JjB2cqNZyszkDHZgOSrUUT8V3dhgRl8Q9Gp6dAj/H5+KILGjbhDpc3Iy9qmqlm/akuOI2ut9VUtzJxQ==", + "license": "Apache-2.0" + }, + "node_modules/@clerk/backend": { + "version": "2.30.1", + "resolved": "https://registry.npmjs.org/@clerk/backend/-/backend-2.30.1.tgz", + "integrity": "sha512-GoxnJzVH0ycNPAGCDMfo3lPBFbo5nehpLSVFjgGEnzIRGGahBtAB8PQT7KM2zo58pD8apjb/+suhcB/WCiEasQ==", + "license": "MIT", + "dependencies": { + "@clerk/shared": "^3.44.0", + "@clerk/types": "^4.101.14", + "standardwebhooks": "^1.0.0", + "tslib": "2.8.1" + }, + "engines": { + "node": ">=18.17.0" + } + }, + "node_modules/@clerk/clerk-react": { + "version": "5.60.0", + "resolved": "https://registry.npmjs.org/@clerk/clerk-react/-/clerk-react-5.60.0.tgz", + "integrity": "sha512-P88FncsJpq/3WZJhhlj+md8mYb35BIXpr462C/figwsBGHsinr8VuBQUMcMZZ/6M34C8ABfLTPa6PHVp6+3D5Q==", + "license": "MIT", + "dependencies": { + "@clerk/shared": "^3.44.0", + "tslib": "2.8.1" + }, + "engines": { + "node": ">=18.17.0" + }, + "peerDependencies": { + "react": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0", + "react-dom": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0" + } + }, + "node_modules/@clerk/nextjs": { + "version": "6.37.3", + "resolved": "https://registry.npmjs.org/@clerk/nextjs/-/nextjs-6.37.3.tgz", + "integrity": "sha512-kammmf4b5R2Izb/SN4UbEa/6rdyop9fPHwZkyyJoVfgMLFM26fwpXWaSqVJPe4YL2BmHKP+orIOolzTmEhhdQQ==", + "license": "MIT", + "dependencies": { + "@clerk/backend": "^2.30.1", + "@clerk/clerk-react": "^5.60.0", + "@clerk/shared": "^3.44.0", + "@clerk/types": "^4.101.14", + "server-only": "0.0.1", + "tslib": "2.8.1" + }, + "engines": { + "node": ">=18.17.0" + }, + "peerDependencies": { + "next": "^13.5.7 || ^14.2.25 || ^15.2.3 || ^16", + "react": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0", + "react-dom": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0" + } + }, + "node_modules/@clerk/shared": { + "version": "3.44.0", + "resolved": "https://registry.npmjs.org/@clerk/shared/-/shared-3.44.0.tgz", + "integrity": "sha512-kH+chNeZwqml3IDpWLgebWECfOZifyUQO4OISd/96w1EuCY1Bzw6cBq/ZbpsoO8jyG8/6bGr/MGXLhDzTrpPfA==", + "hasInstallScript": true, + "license": "MIT", + "dependencies": { + "csstype": "3.1.3", + "dequal": "2.0.3", + "glob-to-regexp": "0.4.1", + "js-cookie": "3.0.5", + "std-env": "^3.9.0", + "swr": "2.3.4" + }, + "engines": { + "node": ">=18.17.0" + }, + "peerDependencies": { + "react": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0", + "react-dom": "^18.0.0 || ~19.0.3 || ~19.1.4 || ~19.2.3 || ~19.3.0-0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + }, + "react-dom": { + "optional": true + } + } + }, + "node_modules/@clerk/shared/node_modules/csstype": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz", + "integrity": "sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==", + "license": "MIT" + }, + "node_modules/@clerk/types": { + "version": "4.101.14", + "resolved": "https://registry.npmjs.org/@clerk/types/-/types-4.101.14.tgz", + "integrity": "sha512-jl7DywmeaZx1IntgEXcjDZq2uyk+X/1yAZOjxOboeGTS0rNTiQNhv7xK8tFVjexsUAFrYlwC1AxhFuJiMDQjow==", + "license": "MIT", + "dependencies": { + "@clerk/shared": "^3.44.0" + }, + "engines": { + "node": ">=18.17.0" + } + }, + "node_modules/@electric-sql/pglite": { + "version": "0.3.15", + "resolved": "https://registry.npmjs.org/@electric-sql/pglite/-/pglite-0.3.15.tgz", + "integrity": "sha512-Cj++n1Mekf9ETfdc16TlDi+cDDQF0W7EcbyRHYOAeZdsAe8M/FJg18itDTSwyHfar2WIezawM9o0EKaRGVKygQ==", + "license": "Apache-2.0", + "peer": true + }, + "node_modules/@electric-sql/pglite-socket": { + "version": "0.0.20", + "resolved": "https://registry.npmjs.org/@electric-sql/pglite-socket/-/pglite-socket-0.0.20.tgz", + "integrity": "sha512-J5nLGsicnD9wJHnno9r+DGxfcZWh+YJMCe0q/aCgtG6XOm9Z7fKeite8IZSNXgZeGltSigM9U/vAWZQWdgcSFg==", + "license": "Apache-2.0", + "bin": { + "pglite-server": "dist/scripts/server.js" + }, + "peerDependencies": { + "@electric-sql/pglite": "0.3.15" + } + }, + "node_modules/@electric-sql/pglite-tools": { + "version": "0.2.20", + "resolved": "https://registry.npmjs.org/@electric-sql/pglite-tools/-/pglite-tools-0.2.20.tgz", + "integrity": "sha512-BK50ZnYa3IG7ztXhtgYf0Q7zijV32Iw1cYS8C+ThdQlwx12V5VZ9KRJ42y82Hyb4PkTxZQklVQA9JHyUlex33A==", + "license": "Apache-2.0", + "peerDependencies": { + "@electric-sql/pglite": "0.3.15" + } + }, "node_modules/@emnapi/core": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/@emnapi/core/-/core-1.8.1.tgz", @@ -455,6 +637,18 @@ "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } }, + "node_modules/@hono/node-server": { + "version": "1.19.9", + "resolved": "https://registry.npmjs.org/@hono/node-server/-/node-server-1.19.9.tgz", + "integrity": "sha512-vHL6w3ecZsky+8P5MD+eFfaGTyCeOHUIFYMGpQGbrBTSmNNoxv0if69rEZ5giu36weC5saFuznL411gRX7bJDw==", + "license": "MIT", + "engines": { + "node": ">=18.14.1" + }, + "peerDependencies": { + "hono": "^4" + } + }, "node_modules/@humanfs/core": { "version": "0.19.1", "resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.1.tgz", @@ -1023,6 +1217,19 @@ "@jridgewell/sourcemap-codec": "^1.4.14" } }, + "node_modules/@mrleebo/prisma-ast": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/@mrleebo/prisma-ast/-/prisma-ast-0.13.1.tgz", + "integrity": "sha512-XyroGQXcHrZdvmrGJvsA9KNeOOgGMg1Vg9OlheUsBOSKznLMDl+YChxbkboRHvtFYJEMRYmlV3uoo/njCw05iw==", + "license": "MIT", + "dependencies": { + "chevrotain": "^10.5.0", + "lilconfig": "^2.1.0" + }, + "engines": { + "node": ">=16" + } + }, "node_modules/@napi-rs/wasm-runtime": { "version": "0.2.12", "resolved": "https://registry.npmjs.org/@napi-rs/wasm-runtime/-/wasm-runtime-0.2.12.tgz", @@ -1228,6 +1435,168 @@ "node": ">=12.4.0" } }, + "node_modules/@panva/hkdf": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@panva/hkdf/-/hkdf-1.2.1.tgz", + "integrity": "sha512-6oclG6Y3PiDFcoyk8srjLfVKyMfVCKJ27JwNPViuXziFpmdz+MZnZN/aKY0JGXgYuO/VghU0jcOAZgWXZ1Dmrw==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/panva" + } + }, + "node_modules/@prisma/client": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/@prisma/client/-/client-7.3.0.tgz", + "integrity": "sha512-FXBIxirqQfdC6b6HnNgxGmU7ydCPEPk7maHMOduJJfnTP+MuOGa15X4omjR/zpPUUpm8ef/mEFQjJudOGkXFcQ==", + "license": "Apache-2.0", + "dependencies": { + "@prisma/client-runtime-utils": "7.3.0" + }, + "engines": { + "node": "^20.19 || ^22.12 || >=24.0" + }, + "peerDependencies": { + "prisma": "*", + "typescript": ">=5.4.0" + }, + "peerDependenciesMeta": { + "prisma": { + "optional": true + }, + "typescript": { + "optional": true + } + } + }, + "node_modules/@prisma/client-runtime-utils": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/@prisma/client-runtime-utils/-/client-runtime-utils-7.3.0.tgz", + "integrity": "sha512-dG/ceD9c+tnXATPk8G+USxxYM9E6UdMTnQeQ+1SZUDxTz7SgQcfxEqafqIQHcjdlcNK/pvmmLfSwAs3s2gYwUw==", + "license": "Apache-2.0" + }, + "node_modules/@prisma/config": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/@prisma/config/-/config-7.3.0.tgz", + "integrity": "sha512-QyMV67+eXF7uMtKxTEeQqNu/Be7iH+3iDZOQZW5ttfbSwBamCSdwPszA0dum+Wx27I7anYTPLmRmMORKViSW1A==", + "license": "Apache-2.0", + "dependencies": { + "c12": "3.1.0", + "deepmerge-ts": "7.1.5", + "effect": "3.18.4", + "empathic": "2.0.0" + } + }, + "node_modules/@prisma/debug": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/@prisma/debug/-/debug-7.3.0.tgz", + "integrity": "sha512-yh/tHhraCzYkffsI1/3a7SHX8tpgbJu1NPnuxS4rEpJdWAUDHUH25F1EDo6PPzirpyLNkgPPZdhojQK804BGtg==", + "license": "Apache-2.0" + }, + "node_modules/@prisma/dev": { + "version": "0.20.0", + "resolved": "https://registry.npmjs.org/@prisma/dev/-/dev-0.20.0.tgz", + "integrity": "sha512-ovlBYwWor0OzG+yH4J3Ot+AneD818BttLA+Ii7wjbcLHUrnC4tbUPVGyNd3c/+71KETPKZfjhkTSpdS15dmXNQ==", + "license": "ISC", + "dependencies": { + "@electric-sql/pglite": "0.3.15", + "@electric-sql/pglite-socket": "0.0.20", + "@electric-sql/pglite-tools": "0.2.20", + "@hono/node-server": "1.19.9", + "@mrleebo/prisma-ast": "0.13.1", + "@prisma/get-platform": "7.2.0", + "@prisma/query-plan-executor": "7.2.0", + "foreground-child": "3.3.1", + "get-port-please": "3.2.0", + "hono": "4.11.4", + "http-status-codes": "2.3.0", + "pathe": "2.0.3", + "proper-lockfile": "4.1.2", + "remeda": "2.33.4", + "std-env": "3.10.0", + "valibot": "1.2.0", + "zeptomatch": "2.1.0" + } + }, + "node_modules/@prisma/engines": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/@prisma/engines/-/engines-7.3.0.tgz", + "integrity": "sha512-cWRQoPDXPtR6stOWuWFZf9pHdQ/o8/QNWn0m0zByxf5Kd946Q875XdEJ52pEsX88vOiXUmjuPG3euw82mwQNMg==", + "hasInstallScript": true, + "license": "Apache-2.0", + "dependencies": { + "@prisma/debug": "7.3.0", + "@prisma/engines-version": "7.3.0-16.9d6ad21cbbceab97458517b147a6a09ff43aa735", + "@prisma/fetch-engine": "7.3.0", + "@prisma/get-platform": "7.3.0" + } + }, + "node_modules/@prisma/engines-version": { + "version": "7.3.0-16.9d6ad21cbbceab97458517b147a6a09ff43aa735", + "resolved": "https://registry.npmjs.org/@prisma/engines-version/-/engines-version-7.3.0-16.9d6ad21cbbceab97458517b147a6a09ff43aa735.tgz", + "integrity": "sha512-IH2va2ouUHihyiTTRW889LjKAl1CusZOvFfZxCDNpjSENt7g2ndFsK0vdIw/72v7+jCN6YgkHmdAP/BI7SDgyg==", + "license": "Apache-2.0" + }, + "node_modules/@prisma/engines/node_modules/@prisma/get-platform": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/@prisma/get-platform/-/get-platform-7.3.0.tgz", + "integrity": "sha512-N7c6m4/I0Q6JYmWKP2RCD/sM9eWiyCPY98g5c0uEktObNSZnugW2U/PO+pwL0UaqzxqTXt7gTsYsb0FnMnJNbg==", + "license": "Apache-2.0", + "dependencies": { + "@prisma/debug": "7.3.0" + } + }, + "node_modules/@prisma/fetch-engine": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/@prisma/fetch-engine/-/fetch-engine-7.3.0.tgz", + "integrity": "sha512-Mm0F84JMqM9Vxk70pzfNpGJ1lE4hYjOeLMu7nOOD1i83nvp8MSAcFYBnHqLvEZiA6onUR+m8iYogtOY4oPO5lQ==", + "license": "Apache-2.0", + "dependencies": { + "@prisma/debug": "7.3.0", + "@prisma/engines-version": "7.3.0-16.9d6ad21cbbceab97458517b147a6a09ff43aa735", + "@prisma/get-platform": "7.3.0" + } + }, + "node_modules/@prisma/fetch-engine/node_modules/@prisma/get-platform": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/@prisma/get-platform/-/get-platform-7.3.0.tgz", + "integrity": "sha512-N7c6m4/I0Q6JYmWKP2RCD/sM9eWiyCPY98g5c0uEktObNSZnugW2U/PO+pwL0UaqzxqTXt7gTsYsb0FnMnJNbg==", + "license": "Apache-2.0", + "dependencies": { + "@prisma/debug": "7.3.0" + } + }, + "node_modules/@prisma/get-platform": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/@prisma/get-platform/-/get-platform-7.2.0.tgz", + "integrity": "sha512-k1V0l0Td1732EHpAfi2eySTezyllok9dXb6UQanajkJQzPUGi3vO2z7jdkz67SypFTdmbnyGYxvEvYZdZsMAVA==", + "license": "Apache-2.0", + "dependencies": { + "@prisma/debug": "7.2.0" + } + }, + "node_modules/@prisma/get-platform/node_modules/@prisma/debug": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/@prisma/debug/-/debug-7.2.0.tgz", + "integrity": "sha512-YSGTiSlBAVJPzX4ONZmMotL+ozJwQjRmZweQNIq/ER0tQJKJynNkRB3kyvt37eOfsbMCXk3gnLF6J9OJ4QWftw==", + "license": "Apache-2.0" + }, + "node_modules/@prisma/query-plan-executor": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/@prisma/query-plan-executor/-/query-plan-executor-7.2.0.tgz", + "integrity": "sha512-EOZmNzcV8uJ0mae3DhTsiHgoNCuu1J9mULQpGCh62zN3PxPTd+qI9tJvk5jOst8WHKQNwJWR3b39t0XvfBB0WQ==", + "license": "Apache-2.0" + }, + "node_modules/@prisma/studio-core": { + "version": "0.13.1", + "resolved": "https://registry.npmjs.org/@prisma/studio-core/-/studio-core-0.13.1.tgz", + "integrity": "sha512-agdqaPEePRHcQ7CexEfkX1RvSH9uWDb6pXrZnhCRykhDFAV0/0P3d07WtfiY8hZWb7oRU4v+NkT4cGFHkQJIPg==", + "license": "Apache-2.0", + "peerDependencies": { + "@types/react": "^18.0.0 || ^19.0.0", + "react": "^18.0.0 || ^19.0.0", + "react-dom": "^18.0.0 || ^19.0.0" + } + }, "node_modules/@rtsao/scc": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@rtsao/scc/-/scc-1.1.0.tgz", @@ -1235,6 +1604,24 @@ "dev": true, "license": "MIT" }, + "node_modules/@socket.io/component-emitter": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.2.tgz", + "integrity": "sha512-9BCxFwvbGg/RsZK9tjXd8s4UcwR0MWeFQ1XEKIQVVvAGJyINdrqKMcTRyLoK8Rse1GjzLV9cwjWV1olXRWEXVA==", + "license": "MIT" + }, + "node_modules/@stablelib/base64": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@stablelib/base64/-/base64-1.0.1.tgz", + "integrity": "sha512-1bnPQqSxSuc3Ii6MhBysoWCg58j97aUjuCSZrGSmDxNqtytIi0k8utUenAwTZN4V5mXXYGsVUI9zeBqy+jBOSQ==", + "license": "MIT" + }, + "node_modules/@standard-schema/spec": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@standard-schema/spec/-/spec-1.1.0.tgz", + "integrity": "sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w==", + "license": "MIT" + }, "node_modules/@swc/helpers": { "version": "0.5.15", "resolved": "https://registry.npmjs.org/@swc/helpers/-/helpers-0.5.15.tgz", @@ -1526,6 +1913,15 @@ "tslib": "^2.4.0" } }, + "node_modules/@types/cors": { + "version": "2.8.19", + "resolved": "https://registry.npmjs.org/@types/cors/-/cors-2.8.19.tgz", + "integrity": "sha512-mFNylyeyqN93lfe/9CSxOGREz8cpzAhH+E93xJ4xWQf62V8sQ/24reV2nyzUWM6H6Xji+GGHpkbLe7pVoUEskg==", + "license": "MIT", + "dependencies": { + "@types/node": "*" + } + }, "node_modules/@types/estree": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz", @@ -1551,8 +1947,8 @@ "version": "20.19.32", "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.32.tgz", "integrity": "sha512-Ez8QE4DMfhjjTsES9K2dwfV258qBui7qxUsoaixZDiTzbde4U12e1pXGNu/ECsUIOi5/zoCxAQxIhQnaUQ2VvA==", - "dev": true, "license": "MIT", + "peer": true, "dependencies": { "undici-types": "~6.21.0" } @@ -1561,7 +1957,6 @@ "version": "19.2.13", "resolved": "https://registry.npmjs.org/@types/react/-/react-19.2.13.tgz", "integrity": "sha512-KkiJeU6VbYbUOp5ITMIc7kBfqlYkKA5KhEHVrGMmUUMt7NeaZg65ojdPk+FtNrBAOXNVM5QM72jnADjM+XVRAQ==", - "dev": true, "license": "MIT", "peer": true, "dependencies": { @@ -2117,6 +2512,19 @@ "win32" ] }, + "node_modules/accepts": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", + "integrity": "sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==", + "license": "MIT", + "dependencies": { + "mime-types": "~2.1.34", + "negotiator": "0.6.3" + }, + "engines": { + "node": ">= 0.6" + } + }, "node_modules/acorn": { "version": "8.15.0", "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.15.0.tgz", @@ -2384,6 +2792,15 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/aws-ssl-profiles": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/aws-ssl-profiles/-/aws-ssl-profiles-1.1.2.tgz", + "integrity": "sha512-NZKeq9AfyQvEeNlN0zSYAaWrmBffJh3IELMZfRpJVWgrpEbtEpnjvzqBPf+mxoI287JohRDoa+/nsfqqiZmF6g==", + "license": "MIT", + "engines": { + "node": ">= 6.0.0" + } + }, "node_modules/axe-core": { "version": "4.11.1", "resolved": "https://registry.npmjs.org/axe-core/-/axe-core-4.11.1.tgz", @@ -2411,6 +2828,15 @@ "dev": true, "license": "MIT" }, + "node_modules/base64id": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/base64id/-/base64id-2.0.0.tgz", + "integrity": "sha512-lGe34o6EHj9y3Kts9R4ZYs/Gr+6N7MCaMlIFA3F1R2O5/m7K06AxfSeO5530PEERE6/WyEg3lsuyw4GHlPZHog==", + "license": "MIT", + "engines": { + "node": "^4.5.0 || >= 5.9" + } + }, "node_modules/baseline-browser-mapping": { "version": "2.9.19", "resolved": "https://registry.npmjs.org/baseline-browser-mapping/-/baseline-browser-mapping-2.9.19.tgz", @@ -2479,6 +2905,34 @@ "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" } }, + "node_modules/c12": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/c12/-/c12-3.1.0.tgz", + "integrity": "sha512-uWoS8OU1MEIsOv8p/5a82c3H31LsWVR5qiyXVfBNOzfffjUWtPnhAb4BYI2uG2HfGmZmFjCtui5XNWaps+iFuw==", + "license": "MIT", + "dependencies": { + "chokidar": "^4.0.3", + "confbox": "^0.2.2", + "defu": "^6.1.4", + "dotenv": "^16.6.1", + "exsolve": "^1.0.7", + "giget": "^2.0.0", + "jiti": "^2.4.2", + "ohash": "^2.0.11", + "pathe": "^2.0.3", + "perfect-debounce": "^1.0.0", + "pkg-types": "^2.2.0", + "rc9": "^2.1.2" + }, + "peerDependencies": { + "magicast": "^0.3.5" + }, + "peerDependenciesMeta": { + "magicast": { + "optional": true + } + } + }, "node_modules/call-bind": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.8.tgz", @@ -2576,6 +3030,44 @@ "url": "https://github.com/chalk/chalk?sponsor=1" } }, + "node_modules/chevrotain": { + "version": "10.5.0", + "resolved": "https://registry.npmjs.org/chevrotain/-/chevrotain-10.5.0.tgz", + "integrity": "sha512-Pkv5rBY3+CsHOYfV5g/Vs5JY9WTHHDEKOlohI2XeygaZhUeqhAlldZ8Hz9cRmxu709bvS08YzxHdTPHhffc13A==", + "license": "Apache-2.0", + "dependencies": { + "@chevrotain/cst-dts-gen": "10.5.0", + "@chevrotain/gast": "10.5.0", + "@chevrotain/types": "10.5.0", + "@chevrotain/utils": "10.5.0", + "lodash": "4.17.21", + "regexp-to-ast": "0.5.0" + } + }, + "node_modules/chokidar": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-4.0.3.tgz", + "integrity": "sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==", + "license": "MIT", + "dependencies": { + "readdirp": "^4.0.1" + }, + "engines": { + "node": ">= 14.16.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/citty": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/citty/-/citty-0.1.6.tgz", + "integrity": "sha512-tskPPKEs8D2KPafUypv2gxwJP8h/OaJmC82QQGGDQcHvXX43xF2VDACcJVmZ0EuSxkpO9Kc4MlrA3q0+FG58AQ==", + "license": "MIT", + "dependencies": { + "consola": "^3.2.3" + } + }, "node_modules/client-only": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/client-only/-/client-only-0.0.1.tgz", @@ -2609,6 +3101,21 @@ "dev": true, "license": "MIT" }, + "node_modules/confbox": { + "version": "0.2.4", + "resolved": "https://registry.npmjs.org/confbox/-/confbox-0.2.4.tgz", + "integrity": "sha512-ysOGlgTFbN2/Y6Cg3Iye8YKulHw+R2fNXHrgSmXISQdMnomY6eNDprVdW9R5xBguEqI954+S6709UyiO7B+6OQ==", + "license": "MIT" + }, + "node_modules/consola": { + "version": "3.4.2", + "resolved": "https://registry.npmjs.org/consola/-/consola-3.4.2.tgz", + "integrity": "sha512-5IKcdX0nnYavi6G7TtOhwkYzyjfJlatbjMjuLSfE2kYT5pMDOilZ4OvMhi637CcDICTmz3wARPoyhqyX1Y+XvA==", + "license": "MIT", + "engines": { + "node": "^14.18.0 || >=16.10.0" + } + }, "node_modules/convert-source-map": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-2.0.0.tgz", @@ -2616,11 +3123,36 @@ "dev": true, "license": "MIT" }, + "node_modules/cookie": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.2.tgz", + "integrity": "sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/cors": { + "version": "2.8.6", + "resolved": "https://registry.npmjs.org/cors/-/cors-2.8.6.tgz", + "integrity": "sha512-tJtZBBHA6vjIAaF6EnIaq6laBBP9aq/Y3ouVJjEfoHbRBcHBAHYcMh/w8LDrk2PvIMMq8gmopa5D4V8RmbrxGw==", + "license": "MIT", + "dependencies": { + "object-assign": "^4", + "vary": "^1" + }, + "engines": { + "node": ">= 0.10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, "node_modules/cross-spawn": { "version": "7.0.6", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz", "integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==", - "dev": true, "license": "MIT", "dependencies": { "path-key": "^3.1.0", @@ -2635,7 +3167,6 @@ "version": "3.2.3", "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.2.3.tgz", "integrity": "sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==", - "dev": true, "license": "MIT" }, "node_modules/damerau-levenshtein": { @@ -2703,7 +3234,6 @@ "version": "4.4.3", "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz", "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==", - "dev": true, "license": "MIT", "dependencies": { "ms": "^2.1.3" @@ -2724,6 +3254,15 @@ "dev": true, "license": "MIT" }, + "node_modules/deepmerge-ts": { + "version": "7.1.5", + "resolved": "https://registry.npmjs.org/deepmerge-ts/-/deepmerge-ts-7.1.5.tgz", + "integrity": "sha512-HOJkrhaYsweh+W+e74Yn7YStZOilkoPb6fycpwNLKzSPtruFs48nYis0zy5yJz1+ktUhHxoRDJ27RQAWLIJVJw==", + "license": "BSD-3-Clause", + "engines": { + "node": ">=16.0.0" + } + }, "node_modules/define-data-property": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", @@ -2760,6 +3299,36 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/defu": { + "version": "6.1.4", + "resolved": "https://registry.npmjs.org/defu/-/defu-6.1.4.tgz", + "integrity": "sha512-mEQCMmwJu317oSz8CwdIOdwf3xMif1ttiM8LTufzc3g6kR+9Pe236twL8j3IYT1F7GfRgGcW6MWxzZjLIkuHIg==", + "license": "MIT" + }, + "node_modules/denque": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/denque/-/denque-2.1.0.tgz", + "integrity": "sha512-HVQE3AAb/pxF8fQAoiqpvg9i3evqug3hoiwakOyZAwJm+6vZehbkYXZ0l4JxS+I3QxM97v5aaRNhj8v5oBhekw==", + "license": "Apache-2.0", + "engines": { + "node": ">=0.10" + } + }, + "node_modules/dequal": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/dequal/-/dequal-2.0.3.tgz", + "integrity": "sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA==", + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/destr": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/destr/-/destr-2.0.5.tgz", + "integrity": "sha512-ugFTXCtDZunbzasqBxrK93Ik/DRYsO6S/fedkWEMKqt04xZ4csmnmwGDBAb07QWNaGMAmnTIemsYZCksjATwsA==", + "license": "MIT" + }, "node_modules/detect-libc": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", @@ -2783,6 +3352,18 @@ "node": ">=0.10.0" } }, + "node_modules/dotenv": { + "version": "16.6.1", + "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.6.1.tgz", + "integrity": "sha512-uBq4egWHTcTt33a72vpSG0z3HnPuIl6NqYcTrKEg2azoEyl2hpW0zqlxysq2pK9HlDIHyHyakeYaYnSAwd8bow==", + "license": "BSD-2-Clause", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://dotenvx.com" + } + }, "node_modules/dunder-proto": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", @@ -2798,6 +3379,16 @@ "node": ">= 0.4" } }, + "node_modules/effect": { + "version": "3.18.4", + "resolved": "https://registry.npmjs.org/effect/-/effect-3.18.4.tgz", + "integrity": "sha512-b1LXQJLe9D11wfnOKAk3PKxuqYshQ0Heez+y5pnkd3jLj1yx9QhM72zZ9uUrOQyNvrs2GZZd/3maL0ZV18YuDA==", + "license": "MIT", + "dependencies": { + "@standard-schema/spec": "^1.0.0", + "fast-check": "^3.23.1" + } + }, "node_modules/electron-to-chromium": { "version": "1.5.286", "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.286.tgz", @@ -2812,6 +3403,57 @@ "dev": true, "license": "MIT" }, + "node_modules/empathic": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/empathic/-/empathic-2.0.0.tgz", + "integrity": "sha512-i6UzDscO/XfAcNYD75CfICkmfLedpyPDdozrLMmQc5ORaQcdMoc21OnlEylMIqI7U8eniKrPMxxtj8k0vhmJhA==", + "license": "MIT", + "engines": { + "node": ">=14" + } + }, + "node_modules/engine.io": { + "version": "6.6.5", + "resolved": "https://registry.npmjs.org/engine.io/-/engine.io-6.6.5.tgz", + "integrity": "sha512-2RZdgEbXmp5+dVbRm0P7HQUImZpICccJy7rN7Tv+SFa55pH+lxnuw6/K1ZxxBfHoYpSkHLAO92oa8O4SwFXA2A==", + "license": "MIT", + "dependencies": { + "@types/cors": "^2.8.12", + "@types/node": ">=10.0.0", + "accepts": "~1.3.4", + "base64id": "2.0.0", + "cookie": "~0.7.2", + "cors": "~2.8.5", + "debug": "~4.4.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.18.3" + }, + "engines": { + "node": ">=10.2.0" + } + }, + "node_modules/engine.io-client": { + "version": "6.6.4", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.6.4.tgz", + "integrity": "sha512-+kjUJnZGwzewFDw951CDWcwj35vMNf2fcj7xQWOctq1F2i1jkDdVvdFG9kM/BEChymCH36KgjnW0NsL58JYRxw==", + "license": "MIT", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.4.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.18.3", + "xmlhttprequest-ssl": "~2.1.1" + } + }, + "node_modules/engine.io-parser": { + "version": "5.2.3", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.3.tgz", + "integrity": "sha512-HqD3yTBfnBxIrbnM1DoD6Pcq8NECnh8d4As1Qgh0z5Gg3jRRIqijury0CL3ghu/edArpUYiYqQiDUQBIs4np3Q==", + "license": "MIT", + "engines": { + "node": ">=10.0.0" + } + }, "node_modules/enhanced-resolve": { "version": "5.19.0", "resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.19.0.tgz", @@ -3452,6 +4094,34 @@ "node": ">=0.10.0" } }, + "node_modules/exsolve": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/exsolve/-/exsolve-1.0.8.tgz", + "integrity": "sha512-LmDxfWXwcTArk8fUEnOfSZpHOJ6zOMUJKOtFLFqJLoKJetuQG874Uc7/Kki7zFLzYybmZhp1M7+98pfMqeX8yA==", + "license": "MIT" + }, + "node_modules/fast-check": { + "version": "3.23.2", + "resolved": "https://registry.npmjs.org/fast-check/-/fast-check-3.23.2.tgz", + "integrity": "sha512-h5+1OzzfCC3Ef7VbtKdcv7zsstUQwUDlYpUTvjeUsJAssPgLn7QzbboPtL5ro04Mq0rPOsMzl7q5hIbRs2wD1A==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/dubzzz" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/fast-check" + } + ], + "license": "MIT", + "dependencies": { + "pure-rand": "^6.1.0" + }, + "engines": { + "node": ">=8.0.0" + } + }, "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -3503,6 +4173,12 @@ "dev": true, "license": "MIT" }, + "node_modules/fast-sha256": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/fast-sha256/-/fast-sha256-1.3.0.tgz", + "integrity": "sha512-n11RGP/lrWEFI/bWdygLxhI+pVeo1ZYIVwvvPkW7azl/rOy+F3HYRZ2K5zeE9mmkhQppyv9sQFx0JM9UabnpPQ==", + "license": "Unlicense" + }, "node_modules/fastq": { "version": "1.20.1", "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.20.1.tgz", @@ -3593,6 +4269,22 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/foreground-child": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.1.tgz", + "integrity": "sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==", + "license": "ISC", + "dependencies": { + "cross-spawn": "^7.0.6", + "signal-exit": "^4.0.1" + }, + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, "node_modules/function-bind": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", @@ -3634,6 +4326,15 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/generate-function": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/generate-function/-/generate-function-2.3.1.tgz", + "integrity": "sha512-eeB5GfMNeevm/GRYq20ShmsaGcmI81kIX2K9XQx5miC8KdHaC6Jm0qQ8ZNeGOi7wYB8OsdxKs+Y2oVuTFuVwKQ==", + "license": "MIT", + "dependencies": { + "is-property": "^1.0.2" + } + }, "node_modules/generator-function": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/generator-function/-/generator-function-2.0.1.tgz", @@ -3679,6 +4380,12 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/get-port-please": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/get-port-please/-/get-port-please-3.2.0.tgz", + "integrity": "sha512-I9QVvBw5U/hw3RmWpYKRumUeaDgxTPd401x364rLmWBJcOQ753eov1eTgzDqRG9bqFIfDc7gfzcQEWrUri3o1A==", + "license": "MIT" + }, "node_modules/get-proto": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", @@ -3724,6 +4431,23 @@ "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" } }, + "node_modules/giget": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/giget/-/giget-2.0.0.tgz", + "integrity": "sha512-L5bGsVkxJbJgdnwyuheIunkGatUF/zssUoxxjACCseZYAVbaqdh9Tsmmlkl8vYan09H7sbvKt4pS8GqKLBrEzA==", + "license": "MIT", + "dependencies": { + "citty": "^0.1.6", + "consola": "^3.4.0", + "defu": "^6.1.4", + "node-fetch-native": "^1.6.6", + "nypm": "^0.6.0", + "pathe": "^2.0.3" + }, + "bin": { + "giget": "dist/cli.mjs" + } + }, "node_modules/glob-parent": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", @@ -3737,6 +4461,12 @@ "node": ">=10.13.0" } }, + "node_modules/glob-to-regexp": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", + "integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==", + "license": "BSD-2-Clause" + }, "node_modules/globals": { "version": "14.0.0", "resolved": "https://registry.npmjs.org/globals/-/globals-14.0.0.tgz", @@ -3784,9 +4514,19 @@ "version": "4.2.11", "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==", - "dev": true, "license": "ISC" }, + "node_modules/grammex": { + "version": "3.1.12", + "resolved": "https://registry.npmjs.org/grammex/-/grammex-3.1.12.tgz", + "integrity": "sha512-6ufJOsSA7LcQehIJNCO7HIBykfM7DXQual0Ny780/DEcJIpBlHRvcqEBWGPYd7hrXL2GJ3oJI1MIhaXjWmLQOQ==", + "license": "MIT" + }, + "node_modules/graphmatch": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/graphmatch/-/graphmatch-1.1.0.tgz", + "integrity": "sha512-0E62MaTW5rPZVRLyIJZG/YejmdA/Xr1QydHEw3Vt+qOKkMIOE8WDLc9ZX2bmAjtJFZcId4lEdrdmASsEy7D1QA==" + }, "node_modules/has-bigints": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.1.0.tgz", @@ -3904,6 +4644,38 @@ "integrity": "sha512-E3a5VwgXimGHwpRGV+WxRTKeSp2DW5DI5MWv34ulL3t5UNmyJWCQ1KmLEHbYzcfThfXG8amBL+fCYPneGHC4VA==", "license": "Apache-2.0" }, + "node_modules/hono": { + "version": "4.11.4", + "resolved": "https://registry.npmjs.org/hono/-/hono-4.11.4.tgz", + "integrity": "sha512-U7tt8JsyrxSRKspfhtLET79pU8K+tInj5QZXs1jSugO1Vq5dFj3kmZsRldo29mTBfcjDRVRXrEZ6LS63Cog9ZA==", + "license": "MIT", + "peer": true, + "engines": { + "node": ">=16.9.0" + } + }, + "node_modules/http-status-codes": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/http-status-codes/-/http-status-codes-2.3.0.tgz", + "integrity": "sha512-RJ8XvFvpPM/Dmc5SV+dC4y5PCeOhT3x1Hq0NU3rjGeg5a/CqlhZ7uudknPwZFz4aeAXDcbAyaeP7GAo9lvngtA==", + "license": "MIT" + }, + "node_modules/iconv-lite": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.7.2.tgz", + "integrity": "sha512-im9DjEDQ55s9fL4EYzOAv0yMqmMBSZp6G0VvFyTMPKWxiSBHUj9NW/qqLmXUwXrrM7AvqSlTCfvqRb0cM8yYqw==", + "license": "MIT", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, "node_modules/ignore": { "version": "5.3.2", "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", @@ -4226,6 +4998,12 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/is-property": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-property/-/is-property-1.0.2.tgz", + "integrity": "sha512-Ks/IoX00TtClbGQr4TWXemAnktAQvYB7HzcCxDGqEZU6oCmb2INHuOoKxbtR+HFkmYWBKv/dOZtGRiAjDhj92g==", + "license": "MIT" + }, "node_modules/is-regex": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.2.1.tgz", @@ -4382,7 +5160,6 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", - "dev": true, "license": "ISC" }, "node_modules/iterator.prototype": { @@ -4407,12 +5184,29 @@ "version": "2.6.1", "resolved": "https://registry.npmjs.org/jiti/-/jiti-2.6.1.tgz", "integrity": "sha512-ekilCSN1jwRvIbgeg/57YFh8qQDNbwDb9xT/qu2DAHbFFZUicIl4ygVaAvzveMhMVr3LnpSKTNnwt8PoOfmKhQ==", - "dev": true, "license": "MIT", "bin": { "jiti": "lib/jiti-cli.mjs" } }, + "node_modules/jose": { + "version": "4.15.9", + "resolved": "https://registry.npmjs.org/jose/-/jose-4.15.9.tgz", + "integrity": "sha512-1vUQX+IdDMVPj4k8kOxgUqlcK518yluMuGZwqlr44FS1ppZB/5GWh4rZG89erpOBOJjU/OBsnCVFfapsRz6nEA==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/panva" + } + }, + "node_modules/js-cookie": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/js-cookie/-/js-cookie-3.0.5.tgz", + "integrity": "sha512-cEiJEAEoIbWfCZYKWhVwFuvPX1gETRYPw6LlaTKoxD3s2AkXzkCjnp6h0V77ozyqj0jakteJ4YqDJT830+lVGw==", + "license": "MIT", + "engines": { + "node": ">=14" + } + }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -4801,6 +5595,15 @@ "url": "https://opencollective.com/parcel" } }, + "node_modules/lilconfig": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-2.1.0.tgz", + "integrity": "sha512-utWOt/GHzuUxnLKxB6dk81RoOeoNeHgbrXiuGk4yyF5qlRz+iIVWu56E2fqGHFrXz0QNUhLB/8nKqvRH66JKGQ==", + "license": "MIT", + "engines": { + "node": ">=10" + } + }, "node_modules/locate-path": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", @@ -4817,6 +5620,12 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "license": "MIT" + }, "node_modules/lodash.merge": { "version": "4.6.2", "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", @@ -4824,6 +5633,12 @@ "dev": true, "license": "MIT" }, + "node_modules/long": { + "version": "5.3.2", + "resolved": "https://registry.npmjs.org/long/-/long-5.3.2.tgz", + "integrity": "sha512-mNAgZ1GmyNhD7AuqnTG3/VQ26o760+ZYBPKjPvugO8+nLbYfX6TVpJPseBvopbdY+qpZ/lKUnmEc1LeZYS3QAA==", + "license": "Apache-2.0" + }, "node_modules/loose-envify": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", @@ -4847,6 +5662,21 @@ "yallist": "^3.0.2" } }, + "node_modules/lru.min": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/lru.min/-/lru.min-1.1.4.tgz", + "integrity": "sha512-DqC6n3QQ77zdFpCMASA1a3Jlb64Hv2N2DciFGkO/4L9+q/IpIAuRlKOvCXabtRW6cQf8usbmM6BE/TOPysCdIA==", + "license": "MIT", + "engines": { + "bun": ">=1.0.0", + "deno": ">=1.30.0", + "node": ">=8.0.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/wellwelwel" + } + }, "node_modules/magic-string": { "version": "0.30.21", "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.21.tgz", @@ -4891,6 +5721,27 @@ "node": ">=8.6" } }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "license": "MIT", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, "node_modules/minimatch": { "version": "3.1.2", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", @@ -4918,9 +5769,40 @@ "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", - "dev": true, "license": "MIT" }, + "node_modules/mysql2": { + "version": "3.15.3", + "resolved": "https://registry.npmjs.org/mysql2/-/mysql2-3.15.3.tgz", + "integrity": "sha512-FBrGau0IXmuqg4haEZRBfHNWB5mUARw6hNwPDXXGg0XzVJ50mr/9hb267lvpVMnhZ1FON3qNd4Xfcez1rbFwSg==", + "license": "MIT", + "dependencies": { + "aws-ssl-profiles": "^1.1.1", + "denque": "^2.1.0", + "generate-function": "^2.3.1", + "iconv-lite": "^0.7.0", + "long": "^5.2.1", + "lru.min": "^1.0.0", + "named-placeholders": "^1.1.3", + "seq-queue": "^0.0.5", + "sqlstring": "^2.3.2" + }, + "engines": { + "node": ">= 8.0" + } + }, + "node_modules/named-placeholders": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/named-placeholders/-/named-placeholders-1.1.6.tgz", + "integrity": "sha512-Tz09sEL2EEuv5fFowm419c1+a/jSMiBjI9gHxVLrVdbUkkNUUfjsVYs9pVZu5oCon/kmRh9TfLEObFtkVxmY0w==", + "license": "MIT", + "dependencies": { + "lru.min": "^1.1.0" + }, + "engines": { + "node": ">=8.0.0" + } + }, "node_modules/nanoid": { "version": "3.3.11", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.11.tgz", @@ -4962,11 +5844,21 @@ "dev": true, "license": "MIT" }, + "node_modules/negotiator": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.3.tgz", + "integrity": "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, "node_modules/next": { "version": "16.1.6", "resolved": "https://registry.npmjs.org/next/-/next-16.1.6.tgz", "integrity": "sha512-hkyRkcu5x/41KoqnROkfTm2pZVbKxvbZRuNvKXLRXxs3VfyO0WhY50TQS40EuKO9SW3rBj/sF3WbVwDACeMZyw==", "license": "MIT", + "peer": true, "dependencies": { "@next/env": "16.1.6", "@swc/helpers": "0.5.15", @@ -5015,6 +5907,38 @@ } } }, + "node_modules/next-auth": { + "version": "4.24.13", + "resolved": "https://registry.npmjs.org/next-auth/-/next-auth-4.24.13.tgz", + "integrity": "sha512-sgObCfcfL7BzIK76SS5TnQtc3yo2Oifp/yIpfv6fMfeBOiBJkDWF3A2y9+yqnmJ4JKc2C+nMjSjmgDeTwgN1rQ==", + "license": "ISC", + "dependencies": { + "@babel/runtime": "^7.20.13", + "@panva/hkdf": "^1.0.2", + "cookie": "^0.7.0", + "jose": "^4.15.5", + "oauth": "^0.9.15", + "openid-client": "^5.4.0", + "preact": "^10.6.3", + "preact-render-to-string": "^5.1.19", + "uuid": "^8.3.2" + }, + "peerDependencies": { + "@auth/core": "0.34.3", + "next": "^12.2.5 || ^13 || ^14 || ^15 || ^16", + "nodemailer": "^7.0.7", + "react": "^17.0.2 || ^18 || ^19", + "react-dom": "^17.0.2 || ^18 || ^19" + }, + "peerDependenciesMeta": { + "@auth/core": { + "optional": true + }, + "nodemailer": { + "optional": true + } + } + }, "node_modules/next/node_modules/postcss": { "version": "8.4.31", "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.31.tgz", @@ -5043,6 +5967,12 @@ "node": "^10 || ^12 || >=14" } }, + "node_modules/node-fetch-native": { + "version": "1.6.7", + "resolved": "https://registry.npmjs.org/node-fetch-native/-/node-fetch-native-1.6.7.tgz", + "integrity": "sha512-g9yhqoedzIUm0nTnTqAQvueMPVOuIY16bqgAJJC8XOOubYFNwz6IER9qs0Gq2Xd0+CecCKFjtdDTMA4u4xG06Q==", + "license": "MIT" + }, "node_modules/node-releases": { "version": "2.0.27", "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.27.tgz", @@ -5050,16 +5980,53 @@ "dev": true, "license": "MIT" }, + "node_modules/nypm": { + "version": "0.6.5", + "resolved": "https://registry.npmjs.org/nypm/-/nypm-0.6.5.tgz", + "integrity": "sha512-K6AJy1GMVyfyMXRVB88700BJqNUkByijGJM8kEHpLdcAt+vSQAVfkWWHYzuRXHSY6xA2sNc5RjTj0p9rE2izVQ==", + "license": "MIT", + "dependencies": { + "citty": "^0.2.0", + "pathe": "^2.0.3", + "tinyexec": "^1.0.2" + }, + "bin": { + "nypm": "dist/cli.mjs" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/nypm/node_modules/citty": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/citty/-/citty-0.2.0.tgz", + "integrity": "sha512-8csy5IBFI2ex2hTVpaHN2j+LNE199AgiI7y4dMintrr8i0lQiFn+0AWMZrWdHKIgMOer65f8IThysYhoReqjWA==", + "license": "MIT" + }, + "node_modules/oauth": { + "version": "0.9.15", + "resolved": "https://registry.npmjs.org/oauth/-/oauth-0.9.15.tgz", + "integrity": "sha512-a5ERWK1kh38ExDEfoO6qUHJb32rd7aYmPHuyCu3Fta/cnICvYmgd2uhuKXvPD+PXB+gCEYYEaQdIRAjCOwAKNA==", + "license": "MIT" + }, "node_modules/object-assign": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", - "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" } }, + "node_modules/object-hash": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/object-hash/-/object-hash-2.2.0.tgz", + "integrity": "sha512-gScRMn0bS5fH+IuwyIFgnh9zBdo4DV+6GhygmWM9HyNJSgS0hScp1f5vjtm7oIIOiT9trXrShAkLFSc2IqKNgw==", + "license": "MIT", + "engines": { + "node": ">= 6" + } + }, "node_modules/object-inspect": { "version": "1.13.4", "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.13.4.tgz", @@ -5173,6 +6140,54 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/ohash": { + "version": "2.0.11", + "resolved": "https://registry.npmjs.org/ohash/-/ohash-2.0.11.tgz", + "integrity": "sha512-RdR9FQrFwNBNXAr4GixM8YaRZRJ5PUWbKYbE5eOsrwAjJW0q2REGcf79oYPsLyskQCZG1PLN+S/K1V00joZAoQ==", + "license": "MIT" + }, + "node_modules/oidc-token-hash": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/oidc-token-hash/-/oidc-token-hash-5.2.0.tgz", + "integrity": "sha512-6gj2m8cJZ+iSW8bm0FXdGF0YhIQbKrfP4yWTNzxc31U6MOjfEmB1rHvlYvxI1B7t7BCi1F2vYTT6YhtQRG4hxw==", + "license": "MIT", + "engines": { + "node": "^10.13.0 || >=12.0.0" + } + }, + "node_modules/openid-client": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/openid-client/-/openid-client-5.7.1.tgz", + "integrity": "sha512-jDBPgSVfTnkIh71Hg9pRvtJc6wTwqjRkN88+gCFtYWrlP4Yx2Dsrow8uPi3qLr/aeymPF3o2+dS+wOpglK04ew==", + "license": "MIT", + "dependencies": { + "jose": "^4.15.9", + "lru-cache": "^6.0.0", + "object-hash": "^2.2.0", + "oidc-token-hash": "^5.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/panva" + } + }, + "node_modules/openid-client/node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/openid-client/node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "license": "ISC" + }, "node_modules/optionator": { "version": "0.9.4", "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.4.tgz", @@ -5268,7 +6283,6 @@ "version": "3.1.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", - "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -5281,6 +6295,18 @@ "dev": true, "license": "MIT" }, + "node_modules/pathe": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.3.tgz", + "integrity": "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==", + "license": "MIT" + }, + "node_modules/perfect-debounce": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/perfect-debounce/-/perfect-debounce-1.0.0.tgz", + "integrity": "sha512-xCy9V055GLEqoFaHoC1SoLIaLmWctgCUaBaWxDZ7/Zx4CTyX7cJQLJOok/orfjZAh9kEYpjJa4d0KcJmCbctZA==", + "license": "MIT" + }, "node_modules/picocolors": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", @@ -5300,6 +6326,17 @@ "url": "https://github.com/sponsors/jonschlinkert" } }, + "node_modules/pkg-types": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/pkg-types/-/pkg-types-2.3.0.tgz", + "integrity": "sha512-SIqCzDRg0s9npO5XQ3tNZioRY1uK06lA41ynBC1YmFTmnY6FjUjVt6s4LoADmwoig1qqD0oK8h1p/8mlMx8Oig==", + "license": "MIT", + "dependencies": { + "confbox": "^0.2.2", + "exsolve": "^1.0.7", + "pathe": "^2.0.3" + } + }, "node_modules/possible-typed-array-names": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.1.0.tgz", @@ -5339,6 +6376,42 @@ "node": "^10 || ^12 || >=14" } }, + "node_modules/postgres": { + "version": "3.4.7", + "resolved": "https://registry.npmjs.org/postgres/-/postgres-3.4.7.tgz", + "integrity": "sha512-Jtc2612XINuBjIl/QTWsV5UvE8UHuNblcO3vVADSrKsrc6RqGX6lOW1cEo3CM2v0XG4Nat8nI+YM7/f26VxXLw==", + "license": "Unlicense", + "engines": { + "node": ">=12" + }, + "funding": { + "type": "individual", + "url": "https://github.com/sponsors/porsager" + } + }, + "node_modules/preact": { + "version": "10.28.3", + "resolved": "https://registry.npmjs.org/preact/-/preact-10.28.3.tgz", + "integrity": "sha512-tCmoRkPQLpBeWzpmbhryairGnhW9tKV6c6gr/w+RhoRoKEJwsjzipwp//1oCpGPOchvSLaAPlpcJi9MwMmoPyA==", + "license": "MIT", + "peer": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/preact" + } + }, + "node_modules/preact-render-to-string": { + "version": "5.2.6", + "resolved": "https://registry.npmjs.org/preact-render-to-string/-/preact-render-to-string-5.2.6.tgz", + "integrity": "sha512-JyhErpYOvBV1hEPwIxc/fHWXPfnEGdRKxc8gFdAZ7XV4tlzyzG847XAyEZqoDnynP88akM4eaHcSOzNcLWFguw==", + "license": "MIT", + "dependencies": { + "pretty-format": "^3.8.0" + }, + "peerDependencies": { + "preact": ">=10" + } + }, "node_modules/prelude-ls": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", @@ -5349,6 +6422,46 @@ "node": ">= 0.8.0" } }, + "node_modules/pretty-format": { + "version": "3.8.0", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-3.8.0.tgz", + "integrity": "sha512-WuxUnVtlWL1OfZFQFuqvnvs6MiAGk9UNsBostyBOB0Is9wb5uRESevA6rnl/rkksXaGX3GzZhPup5d6Vp1nFew==", + "license": "MIT" + }, + "node_modules/prisma": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/prisma/-/prisma-7.3.0.tgz", + "integrity": "sha512-ApYSOLHfMN8WftJA+vL6XwAPOh/aZ0BgUyyKPwUFgjARmG6EBI9LzDPf6SWULQMSAxydV9qn5gLj037nPNlg2w==", + "hasInstallScript": true, + "license": "Apache-2.0", + "peer": true, + "dependencies": { + "@prisma/config": "7.3.0", + "@prisma/dev": "0.20.0", + "@prisma/engines": "7.3.0", + "@prisma/studio-core": "0.13.1", + "mysql2": "3.15.3", + "postgres": "3.4.7" + }, + "bin": { + "prisma": "build/index.js" + }, + "engines": { + "node": "^20.19 || ^22.12 || >=24.0" + }, + "peerDependencies": { + "better-sqlite3": ">=9.0.0", + "typescript": ">=5.4.0" + }, + "peerDependenciesMeta": { + "better-sqlite3": { + "optional": true + }, + "typescript": { + "optional": true + } + } + }, "node_modules/prop-types": { "version": "15.8.1", "resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.8.1.tgz", @@ -5361,6 +6474,23 @@ "react-is": "^16.13.1" } }, + "node_modules/proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "license": "MIT", + "dependencies": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, + "node_modules/proper-lockfile/node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "license": "ISC" + }, "node_modules/punycode": { "version": "2.3.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", @@ -5371,6 +6501,22 @@ "node": ">=6" } }, + "node_modules/pure-rand": { + "version": "6.1.0", + "resolved": "https://registry.npmjs.org/pure-rand/-/pure-rand-6.1.0.tgz", + "integrity": "sha512-bVWawvoZoBYpp6yIoQtQXHZjmz35RSVHnUOTefl8Vcjr8snTPY1wnpSPMWekcFwbxI6gtmT7rSYPFvz71ldiOA==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/dubzzz" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/fast-check" + } + ], + "license": "MIT" + }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -5392,6 +6538,16 @@ ], "license": "MIT" }, + "node_modules/rc9": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/rc9/-/rc9-2.1.2.tgz", + "integrity": "sha512-btXCnMmRIBINM2LDZoEmOogIZU7Qe7zn4BpomSKZ/ykbLObuBdvG+mFq11DL6fjH1DRwHhrlgtYWG96bJiC7Cg==", + "license": "MIT", + "dependencies": { + "defu": "^6.1.4", + "destr": "^2.0.3" + } + }, "node_modules/react": { "version": "19.2.3", "resolved": "https://registry.npmjs.org/react/-/react-19.2.3.tgz", @@ -5422,6 +6578,19 @@ "dev": true, "license": "MIT" }, + "node_modules/readdirp": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-4.1.2.tgz", + "integrity": "sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg==", + "license": "MIT", + "engines": { + "node": ">= 14.18.0" + }, + "funding": { + "type": "individual", + "url": "https://paulmillr.com/funding/" + } + }, "node_modules/reflect.getprototypeof": { "version": "1.0.10", "resolved": "https://registry.npmjs.org/reflect.getprototypeof/-/reflect.getprototypeof-1.0.10.tgz", @@ -5445,6 +6614,12 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/regexp-to-ast": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/regexp-to-ast/-/regexp-to-ast-0.5.0.tgz", + "integrity": "sha512-tlbJqcMHnPKI9zSrystikWKwHkBqu2a/Sgw01h3zFjvYrMxEDYHzzoMZnUrbIfpTFEsoRnnviOXNCzFiSc54Qw==", + "license": "MIT" + }, "node_modules/regexp.prototype.flags": { "version": "1.5.4", "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.4.tgz", @@ -5466,6 +6641,15 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/remeda": { + "version": "2.33.4", + "resolved": "https://registry.npmjs.org/remeda/-/remeda-2.33.4.tgz", + "integrity": "sha512-ygHswjlc/opg2VrtiYvUOPLjxjtdKvjGz1/plDhkG66hjNjFr1xmfrs2ClNFo/E6TyUFiwYNh53bKV26oBoMGQ==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/remeda" + } + }, "node_modules/resolve": { "version": "1.22.11", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.11.tgz", @@ -5507,6 +6691,15 @@ "url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1" } }, + "node_modules/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, "node_modules/reusify": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.1.0.tgz", @@ -5597,6 +6790,12 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "license": "MIT" + }, "node_modules/scheduler": { "version": "0.27.0", "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.27.0.tgz", @@ -5613,6 +6812,17 @@ "semver": "bin/semver.js" } }, + "node_modules/seq-queue": { + "version": "0.0.5", + "resolved": "https://registry.npmjs.org/seq-queue/-/seq-queue-0.0.5.tgz", + "integrity": "sha512-hr3Wtp/GZIc/6DAGPDcV4/9WoZhjrkXsi5B/07QgX8tsdc6ilr7BFM6PM6rbdAX1kFSDYeZGLipIZZKyQP0O5Q==" + }, + "node_modules/server-only": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/server-only/-/server-only-0.0.1.tgz", + "integrity": "sha512-qepMx2JxAa5jjfzxG79yPPq+8BuFToHd1hm7kI+Z4zAq1ftQiP7HcxMhDDItrbtwVeLg/cY2JnKnrcFkmiswNA==", + "license": "MIT" + }, "node_modules/set-function-length": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", @@ -5724,7 +6934,6 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", - "dev": true, "license": "MIT", "dependencies": { "shebang-regex": "^3.0.0" @@ -5737,7 +6946,6 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", - "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -5819,6 +7027,74 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "license": "ISC", + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/socket.io": { + "version": "4.8.3", + "resolved": "https://registry.npmjs.org/socket.io/-/socket.io-4.8.3.tgz", + "integrity": "sha512-2Dd78bqzzjE6KPkD5fHZmDAKRNe3J15q+YHDrIsy9WEkqttc7GY+kT9OBLSMaPbQaEd0x1BjcmtMtXkfpc+T5A==", + "license": "MIT", + "dependencies": { + "accepts": "~1.3.4", + "base64id": "~2.0.0", + "cors": "~2.8.5", + "debug": "~4.4.1", + "engine.io": "~6.6.0", + "socket.io-adapter": "~2.5.2", + "socket.io-parser": "~4.2.4" + }, + "engines": { + "node": ">=10.2.0" + } + }, + "node_modules/socket.io-adapter": { + "version": "2.5.6", + "resolved": "https://registry.npmjs.org/socket.io-adapter/-/socket.io-adapter-2.5.6.tgz", + "integrity": "sha512-DkkO/dz7MGln0dHn5bmN3pPy+JmywNICWrJqVWiVOyvXjWQFIv9c2h24JrQLLFJ2aQVQf/Cvl1vblnd4r2apLQ==", + "license": "MIT", + "dependencies": { + "debug": "~4.4.1", + "ws": "~8.18.3" + } + }, + "node_modules/socket.io-client": { + "version": "4.8.3", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.8.3.tgz", + "integrity": "sha512-uP0bpjWrjQmUt5DTHq9RuoCBdFJF10cdX9X+a368j/Ft0wmaVgxlrjvK3kjvgCODOMMOz9lcaRzxmso0bTWZ/g==", + "license": "MIT", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.4.1", + "engine.io-client": "~6.6.1", + "socket.io-parser": "~4.2.4" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/socket.io-parser": { + "version": "4.2.5", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.5.tgz", + "integrity": "sha512-bPMmpy/5WWKHea5Y/jYAP6k74A+hvmRCQaJuJB6I/ML5JZq/KfNieUVo/3Mh7SAqn7TyFdIo6wqYHInG1MU1bQ==", + "license": "MIT", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.4.1" + }, + "engines": { + "node": ">=10.0.0" + } + }, "node_modules/source-map-js": { "version": "1.2.1", "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.1.tgz", @@ -5828,6 +7104,15 @@ "node": ">=0.10.0" } }, + "node_modules/sqlstring": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/sqlstring/-/sqlstring-2.3.3.tgz", + "integrity": "sha512-qC9iz2FlN7DQl3+wjwn3802RTyjCx7sDvfQEXchwa6CWOx07/WVfh91gBmQ9fahw8snwGEWU3xGzOt4tFyHLxg==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, "node_modules/stable-hash": { "version": "0.0.5", "resolved": "https://registry.npmjs.org/stable-hash/-/stable-hash-0.0.5.tgz", @@ -5835,6 +7120,22 @@ "dev": true, "license": "MIT" }, + "node_modules/standardwebhooks": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/standardwebhooks/-/standardwebhooks-1.0.0.tgz", + "integrity": "sha512-BbHGOQK9olHPMvQNHWul6MYlrRTAOKn03rOe4A8O3CLWhNf4YHBqq2HJKKC+sfqpxiBY52pNeesD6jIiLDz8jg==", + "license": "MIT", + "dependencies": { + "@stablelib/base64": "^1.0.0", + "fast-sha256": "^1.3.0" + } + }, + "node_modules/std-env": { + "version": "3.10.0", + "resolved": "https://registry.npmjs.org/std-env/-/std-env-3.10.0.tgz", + "integrity": "sha512-5GS12FdOZNliM5mAOxFRg7Ir0pWz8MdpYm6AY6VPkGpbA7ZzmbzNcBJQ0GPvvyWgcY7QAhCgf9Uy89I03faLkg==", + "license": "MIT" + }, "node_modules/stop-iteration-iterator": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.1.0.tgz", @@ -5985,6 +7286,23 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/stripe": { + "version": "20.3.1", + "resolved": "https://registry.npmjs.org/stripe/-/stripe-20.3.1.tgz", + "integrity": "sha512-k990yOT5G5rhX3XluRPw5Y8RLdJDW4dzQ29wWT66piHrbnM2KyamJ1dKgPsw4HzGHRWjDiSSdcI2WdxQUPV3aQ==", + "license": "MIT", + "engines": { + "node": ">=16" + }, + "peerDependencies": { + "@types/node": ">=16" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + } + } + }, "node_modules/styled-jsx": { "version": "5.1.6", "resolved": "https://registry.npmjs.org/styled-jsx/-/styled-jsx-5.1.6.tgz", @@ -6034,6 +7352,19 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/swr": { + "version": "2.3.4", + "resolved": "https://registry.npmjs.org/swr/-/swr-2.3.4.tgz", + "integrity": "sha512-bYd2lrhc+VarcpkgWclcUi92wYCpOgMws9Sd1hG1ntAu0NEy+14CbotuFjshBU2kt9rYj9TSmDcybpxpeTU1fg==", + "license": "MIT", + "dependencies": { + "dequal": "^2.0.3", + "use-sync-external-store": "^1.4.0" + }, + "peerDependencies": { + "react": "^16.11.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" + } + }, "node_modules/tailwindcss": { "version": "4.1.18", "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-4.1.18.tgz", @@ -6055,6 +7386,15 @@ "url": "https://opencollective.com/webpack" } }, + "node_modules/tinyexec": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-1.0.2.tgz", + "integrity": "sha512-W/KYk+NFhkmsYpuHq5JykngiOCnxeVL8v8dFnqxSD8qEEdRfXk1SDM6JzNqcERbcGYj9tMrDQBYV9cjgnunFIg==", + "license": "MIT", + "engines": { + "node": ">=18" + } + }, "node_modules/tinyglobby": { "version": "0.2.15", "resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.15.tgz", @@ -6257,7 +7597,7 @@ "version": "5.9.3", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", - "dev": true, + "devOptional": true, "license": "Apache-2.0", "peer": true, "bin": { @@ -6315,7 +7655,6 @@ "version": "6.21.0", "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", - "dev": true, "license": "MIT" }, "node_modules/unrs-resolver": { @@ -6394,11 +7733,51 @@ "punycode": "^2.1.0" } }, + "node_modules/use-sync-external-store": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.6.0.tgz", + "integrity": "sha512-Pp6GSwGP/NrPIrxVFAIkOQeyw8lFenOHijQWkUTrDvrF4ALqylP2C/KCkeS9dpUM3KvYRQhna5vt7IL95+ZQ9w==", + "license": "MIT", + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0" + } + }, + "node_modules/uuid": { + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", + "license": "MIT", + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/valibot": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/valibot/-/valibot-1.2.0.tgz", + "integrity": "sha512-mm1rxUsmOxzrwnX5arGS+U4T25RdvpPjPN4yR0u9pUBov9+zGVtO84tif1eY4r6zWxVxu3KzIyknJy3rxfRZZg==", + "license": "MIT", + "peerDependencies": { + "typescript": ">=5" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/vary": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", + "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, "node_modules/which": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "dev": true, "license": "ISC", "dependencies": { "isexe": "^2.0.0" @@ -6509,6 +7888,35 @@ "node": ">=0.10.0" } }, + "node_modules/ws": { + "version": "8.18.3", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.18.3.tgz", + "integrity": "sha512-PEIGCY5tSlUt50cqyMXfCzX+oOPqN0vuGqWzbcJ2xvnkzkq46oOpz7dQaTDBdfICb4N14+GARUDw2XV2N4tvzg==", + "license": "MIT", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": ">=5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xmlhttprequest-ssl": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.1.2.tgz", + "integrity": "sha512-TEU+nJVUUnA4CYJFLvK5X9AOeH4KvDvhIfm0vV1GaQRtchnG0hgK5p8hw/xjv8cunWYCsiPCSDzObPyhEwq3KQ==", + "engines": { + "node": ">=0.4.0" + } + }, "node_modules/yallist": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", @@ -6529,6 +7937,16 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/zeptomatch": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/zeptomatch/-/zeptomatch-2.1.0.tgz", + "integrity": "sha512-KiGErG2J0G82LSpniV0CtIzjlJ10E04j02VOudJsPyPwNZgGnRKQy7I1R7GMyg/QswnE4l7ohSGrQbQbjXPPDA==", + "license": "MIT", + "dependencies": { + "grammex": "^3.1.11", + "graphmatch": "^1.1.0" + } + }, "node_modules/zod": { "version": "4.3.6", "resolved": "https://registry.npmjs.org/zod/-/zod-4.3.6.tgz", diff --git a/package.json b/package.json index f0f3ec9..f5e7e12 100644 --- a/package.json +++ b/package.json @@ -12,10 +12,17 @@ "lint": "eslint" }, "dependencies": { + "@clerk/nextjs": "^6.37.3", + "@prisma/client": "^7.3.0", "hls.js": "^1.6.15", "next": "16.1.6", + "next-auth": "^4.24.13", + "prisma": "^7.3.0", "react": "19.2.3", - "react-dom": "19.2.3" + "react-dom": "19.2.3", + "socket.io": "^4.8.3", + "socket.io-client": "^4.8.3", + "stripe": "^20.3.1" }, "devDependencies": { "@tailwindcss/postcss": "^4", diff --git a/prisma/schema.prisma b/prisma/schema.prisma new file mode 100644 index 0000000..e72321b --- /dev/null +++ b/prisma/schema.prisma @@ -0,0 +1,323 @@ +// This is your Prisma schema file, +// learn more about it in the docs: https://pris.ly/d/prisma-schema + +generator client { + provider = "prisma-client-js" +} + +datasource db { + provider = "postgresql" + url = env("DATABASE_URL") +} + +// ===== USERS & AUTHENTICATION ===== + +model User { + id String @id @default(cuid()) + clerkId String @unique // Clerk user ID + username String @unique + email String @unique + displayName String? + bio String? + avatarUrl String? + bannerUrl String? + isCreator Boolean @default(false) + verified Boolean @default(false) + + // Relations + channels Channel[] + followedUsers UserFollow[] @relation("following") + followers UserFollow[] @relation("follower") + chatMessages ChatMessage[] + subscriptions Subscription[] + donations Donation[] + followers Follower[] + clips Clip[] + + createdAt DateTime @default(now()) + updatedAt DateTime @updatedAt + + @@index([username]) + @@index([email]) + @@index([clerkId]) +} + +model UserFollowUser { + followerId String + followingId String + follower User @relation("follower", fields: [followerId], references: [id], onDelete: Cascade) + following User @relation("following", fields: [followingId], references: [id], onDelete: Cascade) + followDate DateTime @default(now()) + + @@id([followerId, followingId]) + @@index([followerId]) + @@index([followingId]) +} + +// ===== CHANNELS & STREAMING ===== + +model Channel { + id String @id @default(cuid()) + userId String + user User @relation(fields: [userId], references: [id], onDelete: Cascade) + + name String @unique + slug String @unique + description String? + category String? // gaming, music, education, etc. + language String? + language String? + + isLive Boolean @default(false) + totalViews BigInt @default(0) + + streams Stream[] + followers Follower[] + subscriptions Subscription[] + donations Donation[] + clips Clip[] + + createdAt DateTime @default(now()) + updatedAt DateTime @updatedAt + + @@index([userId]) + @@index([slug]) +} + +model Stream { + id String @id @default(cuid()) + channelId String + channel Channel @relation(fields: [channelId], references: [id], onDelete: Cascade) + + title String + description String? + status String @default("scheduled") // live, ended, scheduled + + streamKey String @unique + hlsUrl String? + thumbnailUrl String? + + viewerCount Int @default(0) + + startedAt DateTime? + endedAt DateTime? + durationSeconds Int? + + isArchived Boolean @default(true) + archiveUrl String? + + chatMessages ChatMessage[] + vod VOD? + polls Poll[] + + createdAt DateTime @default(now()) + updatedAt DateTime @updatedAt + + @@index([channelId]) + @@index([status]) + @@index([isLive]) +} + +// ===== SOCIAL FEATURES ===== + +model Follower { + id String @id @default(cuid()) + userId String + user User @relation(fields: [userId], references: [id], onDelete: Cascade) + channelId String + channel Channel @relation(fields: [channelId], references: [id], onDelete: Cascade) + + notificationEnabled Boolean @default(true) + + followDate DateTime @default(now()) + + @@unique([userId, channelId]) + @@index([channelId]) +} + +// ===== CHAT & MODERATION ===== + +model ChatMessage { + id String @id @default(cuid()) + streamId String + stream Stream @relation(fields: [streamId], references: [id], onDelete: Cascade) + + userId String + user User @relation(fields: [userId], references: [id], onDelete: Cascade) + + message String + isDeleted Boolean @default(false) + + createdAt DateTime @default(now()) + + @@index([streamId]) + @@index([createdAt]) +} + +// ===== MONETIZATION ===== + +model Subscription { + id String @id @default(cuid()) + subscriberId String + subscriber User @relation(fields: [subscriberId], references: [id], onDelete: Cascade) + + channelId String + channel Channel @relation(fields: [channelId], references: [id], onDelete: Cascade) + + tier String // basic, premium, vip + priceCents Int + stripeSubscriptionId String? + + status String @default("active") // active, cancelled, expired + + autoRenew Boolean @default(true) + + startedAt DateTime @default(now()) + endedAt DateTime? + + createdAt DateTime @default(now()) + updatedAt DateTime @updatedAt + + @@unique([subscriberId, channelId]) + @@index([channelId]) + @@index([status]) +} + +model Donation { + id String @id @default(cuid()) + donorId String + donor User @relation(fields: [donorId], references: [id], onDelete: Cascade) + + channelId String + channel Channel @relation(fields: [channelId], references: [id], onDelete: Cascade) + + streamId String? // Optional: specific stream + + amountCents Int + currency String @default("USD") + message String? + + stripeChargeId String? + status String @default("completed") // pending, completed, failed + + createdAt DateTime @default(now()) + + @@index([channelId]) + @@index([status]) +} + +// ===== CONTENT ===== + +model VOD { + id String @id @default(cuid()) + streamId String @unique + stream Stream @relation(fields: [streamId], references: [id], onDelete: Cascade) + + title String? + description String? + thumbnailUrl String? + + durationSeconds Int? + views Int @default(0) + + isPublic Boolean @default(true) + processingStatus String @default("processing") // processing, ready, failed + + clips Clip[] + + createdAt DateTime @default(now()) + updatedAt DateTime @updatedAt + + @@index([streamId]) +} + +model Clip { + id String @id @default(cuid()) + vodId String? + vod VOD? @relation(fields: [vodId], references: [id], onDelete: SetNull) + + channelId String + channel Channel @relation(fields: [channelId], references: [id], onDelete: Cascade) + + creatorId String + creator User @relation(fields: [creatorId], references: [id], onDelete: Cascade) + + title String + slug String @unique + description String? + thumbnailUrl String? + videoUrl String? + + startSeconds Int? + durationSeconds Int? + + views Int @default(0) + likes Int @default(0) + + isPublic Boolean @default(true) + + clipLikes ClipLike[] + + createdAt DateTime @default(now()) + updatedAt DateTime @updatedAt + + @@index([channelId]) + @@index([creatorId]) +} + +model ClipLike { + id String @id @default(cuid()) + userId String + clipId String + clip Clip @relation(fields: [clipId], references: [id], onDelete: Cascade) + + createdAt DateTime @default(now()) + + @@unique([userId, clipId]) + @@index([clipId]) +} + +// ===== INTERACTIONS ===== + +model Poll { + id String @id @default(cuid()) + streamId String + stream Stream @relation(fields: [streamId], references: [id], onDelete: Cascade) + + question String + durationSeconds Int? + + status String @default("active") // active, ended + + options PollOption[] + + createdAt DateTime @default(now()) + endedAt DateTime? + + @@index([streamId]) +} + +model PollOption { + id String @id @default(cuid()) + pollId String + poll Poll @relation(fields: [pollId], references: [id], onDelete: Cascade) + + option String + voteCount Int @default(0) + + votes PollVote[] + + @@index([pollId]) +} + +model PollVote { + id String @id @default(cuid()) + optionId String + option PollOption @relation(fields: [optionId], references: [id], onDelete: Cascade) + userId String + + createdAt DateTime @default(now()) + + @@unique([userId, optionId]) + @@index([optionId]) +}