export type Json = string | number | boolean | null | { [key: string]: Json | undefined } | Json[]; export interface Database { public: { Tables: { users: { Row: { id: string; display_name: string; avatar_color: string | null; recovery_code: string | null; last_active_at: string; created_at: string; }; Insert: { id: string; display_name: string; avatar_color?: string | null; recovery_code?: string | null; last_active_at?: string; created_at?: string; }; Update: { id?: string; display_name?: string; avatar_color?: string | null; recovery_code?: string | null; last_active_at?: string; created_at?: string; }; }; groups: { Row: { id: string; name: string; invite_code: string; created_by: string; created_at: string; }; Insert: { id?: string; name: string; invite_code: string; created_by: string; created_at?: string; }; Update: { id?: string; name?: string; invite_code?: string; created_by?: string; created_at?: string; }; }; group_members: { Row: { group_id: string; user_id: string; role: "admin" | "member"; joined_at: string; }; Insert: { group_id: string; user_id: string; role: "admin" | "member"; joined_at?: string; }; Update: { group_id?: string; user_id?: string; role?: "admin" | "member"; joined_at?: string; }; }; movies: { Row: { id: string; group_id: string; tmdb_id: number; title: string; year: number; poster_path: string | null; genres: string[]; trailer_url: string | null; trailer_url_refreshed_at: string | null; metadata_refreshed_at: string | null; added_by: string | null; watched: boolean; watched_at: string | null; added_at: string; }; Insert: { id?: string; group_id: string; tmdb_id: number; title: string; year: number; poster_path?: string | null; genres?: string[]; trailer_url?: string | null; trailer_url_refreshed_at?: string | null; metadata_refreshed_at?: string | null; added_by: string; watched?: boolean; watched_at?: string | null; added_at?: string; }; Update: { id?: string; group_id?: string; tmdb_id?: number; title?: string; year?: number; poster_path?: string | null; genres?: string[]; trailer_url?: string | null; trailer_url_refreshed_at?: string | null; metadata_refreshed_at?: string | null; added_by?: string | null; watched?: boolean; watched_at?: string | null; added_at?: string; }; }; landing_reel_posters: { Row: { id: number; tmdb_id: number; poster_path: string; title: string; refreshed_at: string; }; Insert: { id?: number; tmdb_id: number; poster_path: string; title: string; refreshed_at?: string; }; Update: { id?: number; tmdb_id?: number; poster_path?: string; title?: string; refreshed_at?: string; }; }; }; Views: Record; Functions: Record; Enums: Record; }; }