From 4c2e85e8c8f226e423d0632b308e16babc9d292a Mon Sep 17 00:00:00 2001 From: Tsiry Sandratraina Date: Sat, 27 Dec 2025 21:33:44 +0300 Subject: [PATCH] update drizzle migrations --- ...ordsman.sql => 0000_puzzling_lockheed.sql} | 102 +- apps/api/drizzle/0001_fluffy_epoch.sql | 1 - apps/api/drizzle/0002_sweet_randall_flagg.sql | 3 - apps/api/drizzle/0003_same_rocket_racer.sql | 34 - apps/api/drizzle/0004_long_zzzax.sql | 10 - apps/api/drizzle/0004_whole_greymalkin.sql | 15 - apps/api/drizzle/0005_parched_thor_girl.sql | 1 - apps/api/drizzle/0005_same_hydra.sql | 2 - apps/api/drizzle/0006_slow_bulldozer.sql | 1 - apps/api/drizzle/meta/0000_snapshot.json | 289 +- apps/api/drizzle/meta/0001_snapshot.json | 3132 ---------------- apps/api/drizzle/meta/0002_snapshot.json | 3132 ---------------- apps/api/drizzle/meta/0003_snapshot.json | 3166 ---------------- apps/api/drizzle/meta/0004_snapshot.json | 3323 ---------------- apps/api/drizzle/meta/0005_snapshot.json | 3335 ----------------- apps/api/drizzle/meta/0006_snapshot.json | 3238 ---------------- apps/api/drizzle/meta/_journal.json | 46 +- apps/api/package.json | 3 +- apps/api/src/scripts/seed-feed.ts | 0 19 files changed, 319 insertions(+), 19514 deletions(-) rename apps/api/drizzle/{0000_left_swordsman.sql => 0000_puzzling_lockheed.sql} (88%) delete mode 100644 apps/api/drizzle/0001_fluffy_epoch.sql delete mode 100644 apps/api/drizzle/0002_sweet_randall_flagg.sql delete mode 100644 apps/api/drizzle/0003_same_rocket_racer.sql delete mode 100644 apps/api/drizzle/0004_long_zzzax.sql delete mode 100644 apps/api/drizzle/0004_whole_greymalkin.sql delete mode 100644 apps/api/drizzle/0005_parched_thor_girl.sql delete mode 100644 apps/api/drizzle/0005_same_hydra.sql delete mode 100644 apps/api/drizzle/0006_slow_bulldozer.sql delete mode 100644 apps/api/drizzle/meta/0001_snapshot.json delete mode 100644 apps/api/drizzle/meta/0002_snapshot.json delete mode 100644 apps/api/drizzle/meta/0003_snapshot.json delete mode 100644 apps/api/drizzle/meta/0004_snapshot.json delete mode 100644 apps/api/drizzle/meta/0005_snapshot.json delete mode 100644 apps/api/drizzle/meta/0006_snapshot.json create mode 100644 apps/api/src/scripts/seed-feed.ts diff --git a/apps/api/drizzle/0000_left_swordsman.sql b/apps/api/drizzle/0000_puzzling_lockheed.sql similarity index 88% rename from apps/api/drizzle/0000_left_swordsman.sql rename to apps/api/drizzle/0000_puzzling_lockheed.sql index 5be2b02a..86f834e9 100644 --- a/apps/api/drizzle/0000_left_swordsman.sql +++ b/apps/api/drizzle/0000_puzzling_lockheed.sql @@ -81,7 +81,7 @@ SELECT 'rec_' || xata_private.xid(); $$ LANGUAGE sql IMMUTABLE; CREATE TABLE "album_tracks" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "album_id" text NOT NULL, "track_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, @@ -90,7 +90,7 @@ CREATE TABLE "album_tracks" ( ); --> statement-breakpoint CREATE TABLE "albums" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "title" text NOT NULL, "artist" text NOT NULL, "release_date" text, @@ -115,7 +115,7 @@ CREATE TABLE "albums" ( ); --> statement-breakpoint CREATE TABLE "api_keys" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "name" text NOT NULL, "api_key" text NOT NULL, "shared_secret" text NOT NULL, @@ -127,7 +127,7 @@ CREATE TABLE "api_keys" ( ); --> statement-breakpoint CREATE TABLE "artist_albums" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "artist_id" text NOT NULL, "album_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, @@ -136,7 +136,7 @@ CREATE TABLE "artist_albums" ( ); --> statement-breakpoint CREATE TABLE "artist_tracks" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "artist_id" text NOT NULL, "track_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, @@ -145,7 +145,7 @@ CREATE TABLE "artist_tracks" ( ); --> statement-breakpoint CREATE TABLE "artists" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "name" text NOT NULL, "biography" text, "born" timestamp, @@ -167,7 +167,7 @@ CREATE TABLE "artists" ( ); --> statement-breakpoint CREATE TABLE "dropbox_accounts" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "email" text NOT NULL, "is_beta_user" boolean DEFAULT false NOT NULL, "user_id" text NOT NULL, @@ -178,7 +178,7 @@ CREATE TABLE "dropbox_accounts" ( ); --> statement-breakpoint CREATE TABLE "dropbox_directories" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "name" text NOT NULL, "path" text NOT NULL, "parent_id" text, @@ -191,7 +191,7 @@ CREATE TABLE "dropbox_directories" ( ); --> statement-breakpoint CREATE TABLE "dropbox_paths" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "path" text NOT NULL, "name" text NOT NULL, "dropbox_id" text NOT NULL, @@ -205,14 +205,14 @@ CREATE TABLE "dropbox_paths" ( ); --> statement-breakpoint CREATE TABLE "dropbox_tokens" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "refresh_token" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, "xata_updatedat" timestamp DEFAULT now() NOT NULL ); --> statement-breakpoint CREATE TABLE "dropbox" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "dropbox_token_id" text NOT NULL, "xata_version" text, @@ -220,8 +220,23 @@ CREATE TABLE "dropbox" ( "xata_updatedat" timestamp DEFAULT now() NOT NULL ); --> statement-breakpoint +CREATE TABLE "feeds" ( + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, + "display_name" text NOT NULL, + "description" text, + "did" text NOT NULL, + "uri" text NOT NULL, + "avatar" text, + "user_id" text NOT NULL, + "xata_version" integer, + "xata_createdat" timestamp DEFAULT now() NOT NULL, + "xata_updatedat" timestamp DEFAULT now() NOT NULL, + CONSTRAINT "feeds_did_unique" UNIQUE("did"), + CONSTRAINT "feeds_uri_unique" UNIQUE("uri") +); +--> statement-breakpoint CREATE TABLE "google_drive_accounts" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "email" text NOT NULL, "is_beta_user" boolean DEFAULT false NOT NULL, "user_id" text NOT NULL, @@ -232,7 +247,7 @@ CREATE TABLE "google_drive_accounts" ( ); --> statement-breakpoint CREATE TABLE "google_drive_directories" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "name" text NOT NULL, "path" text NOT NULL, "parent_id" text, @@ -245,7 +260,7 @@ CREATE TABLE "google_drive_directories" ( ); --> statement-breakpoint CREATE TABLE "google_drive_paths" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "google_drive_id" text NOT NULL, "track_id" text NOT NULL, "name" text NOT NULL, @@ -258,14 +273,14 @@ CREATE TABLE "google_drive_paths" ( ); --> statement-breakpoint CREATE TABLE "google_drive_tokens" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "refresh_token" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, "xata_updatedat" timestamp DEFAULT now() NOT NULL ); --> statement-breakpoint CREATE TABLE "google_drive" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "google_drive_token_id" text NOT NULL, "user_id" text NOT NULL, "xata_version" text, @@ -274,7 +289,7 @@ CREATE TABLE "google_drive" ( ); --> statement-breakpoint CREATE TABLE "loved_tracks" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "track_id" text NOT NULL, "uri" text, @@ -283,14 +298,14 @@ CREATE TABLE "loved_tracks" ( ); --> statement-breakpoint CREATE TABLE "playlist_tracks" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "playlist_id" text NOT NULL, "track_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL ); --> statement-breakpoint CREATE TABLE "playlists" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "name" text NOT NULL, "picture" text, "description" text, @@ -305,14 +320,14 @@ CREATE TABLE "playlists" ( ); --> statement-breakpoint CREATE TABLE "profile_shouts" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "shout_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL ); --> statement-breakpoint CREATE TABLE "queue_tracks" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "track_id" text NOT NULL, "position" integer NOT NULL, @@ -323,7 +338,7 @@ CREATE TABLE "queue_tracks" ( ); --> statement-breakpoint CREATE TABLE "scrobbles" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text, "track_id" text, "album_id" text, @@ -337,7 +352,7 @@ CREATE TABLE "scrobbles" ( ); --> statement-breakpoint CREATE TABLE "shout_likes" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "shout_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, @@ -346,14 +361,14 @@ CREATE TABLE "shout_likes" ( ); --> statement-breakpoint CREATE TABLE "shout_reports" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "shout_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL ); --> statement-breakpoint CREATE TABLE "shouts" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "content" text NOT NULL, "track_id" text, "artist_id" text, @@ -368,27 +383,39 @@ CREATE TABLE "shouts" ( ); --> statement-breakpoint CREATE TABLE "spotify_accounts" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "xata_version" integer, "email" text NOT NULL, "user_id" text NOT NULL, "is_beta_user" boolean DEFAULT false NOT NULL, + "spotify_app_id" text, "xata_createdat" timestamp DEFAULT now() NOT NULL, "xata_updatedat" timestamp DEFAULT now() NOT NULL ); --> statement-breakpoint +CREATE TABLE "spotify_apps" ( + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, + "xata_version" integer, + "spotify_app_id" text NOT NULL, + "spotify_secret" text NOT NULL, + "xata_createdat" timestamp DEFAULT now() NOT NULL, + "xata_updatedat" timestamp DEFAULT now() NOT NULL, + CONSTRAINT "spotify_apps_spotify_app_id_unique" UNIQUE("spotify_app_id") +); +--> statement-breakpoint CREATE TABLE "spotify_tokens" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "xata_version" integer, "access_token" text NOT NULL, "refresh_token" text NOT NULL, "user_id" text NOT NULL, + "spotify_app_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, "xata_updatedat" timestamp DEFAULT now() NOT NULL ); --> statement-breakpoint CREATE TABLE "tracks" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "title" text NOT NULL, "artist" text NOT NULL, "album_artist" text NOT NULL, @@ -424,7 +451,7 @@ CREATE TABLE "tracks" ( ); --> statement-breakpoint CREATE TABLE "user_albums" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "album_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, @@ -436,7 +463,7 @@ CREATE TABLE "user_albums" ( ); --> statement-breakpoint CREATE TABLE "user_artists" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "artist_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, @@ -448,16 +475,16 @@ CREATE TABLE "user_artists" ( ); --> statement-breakpoint CREATE TABLE "user_playlists" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "playlist_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, - "uri" text NOT NULL, + "uri" text, CONSTRAINT "user_playlists_uri_unique" UNIQUE("uri") ); --> statement-breakpoint CREATE TABLE "user_tracks" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "user_id" text NOT NULL, "track_id" text NOT NULL, "xata_createdat" timestamp DEFAULT now() NOT NULL, @@ -469,7 +496,7 @@ CREATE TABLE "user_tracks" ( ); --> statement-breakpoint CREATE TABLE "users" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "did" text NOT NULL, "display_name" text, "handle" text NOT NULL, @@ -482,7 +509,7 @@ CREATE TABLE "users" ( ); --> statement-breakpoint CREATE TABLE "webscrobblers" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id(), + "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, "name" text NOT NULL, "uuid" text NOT NULL, "description" text, @@ -504,6 +531,7 @@ ALTER TABLE "dropbox_directories" ADD CONSTRAINT "dropbox_directories_parent_id_ ALTER TABLE "dropbox_paths" ADD CONSTRAINT "dropbox_paths_directory_id_dropbox_directories_xata_id_fk" FOREIGN KEY ("directory_id") REFERENCES "public"."dropbox_directories"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint ALTER TABLE "dropbox" ADD CONSTRAINT "dropbox_user_id_users_xata_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint ALTER TABLE "dropbox" ADD CONSTRAINT "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk" FOREIGN KEY ("dropbox_token_id") REFERENCES "public"."dropbox_tokens"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint +ALTER TABLE "feeds" ADD CONSTRAINT "feeds_user_id_users_xata_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint ALTER TABLE "google_drive_accounts" ADD CONSTRAINT "google_drive_accounts_user_id_users_xata_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint ALTER TABLE "google_drive_directories" ADD CONSTRAINT "google_drive_directories_parent_id_google_drive_directories_xata_id_fk" FOREIGN KEY ("parent_id") REFERENCES "public"."google_drive_directories"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint ALTER TABLE "google_drive_paths" ADD CONSTRAINT "google_drive_paths_directory_id_google_drive_directories_xata_id_fk" FOREIGN KEY ("directory_id") REFERENCES "public"."google_drive_directories"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint @@ -539,7 +567,7 @@ ALTER TABLE "user_albums" ADD CONSTRAINT "user_albums_album_id_albums_xata_id_fk ALTER TABLE "user_artists" ADD CONSTRAINT "user_artists_user_id_users_xata_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint ALTER TABLE "user_artists" ADD CONSTRAINT "user_artists_artist_id_artists_xata_id_fk" FOREIGN KEY ("artist_id") REFERENCES "public"."artists"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint ALTER TABLE "user_playlists" ADD CONSTRAINT "user_playlists_user_id_users_xata_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint -ALTER TABLE "user_playlists" ADD CONSTRAINT "user_playlists_playlist_id_tracks_xata_id_fk" FOREIGN KEY ("playlist_id") REFERENCES "public"."tracks"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint +ALTER TABLE "user_playlists" ADD CONSTRAINT "user_playlists_playlist_id_playlists_xata_id_fk" FOREIGN KEY ("playlist_id") REFERENCES "public"."playlists"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint ALTER TABLE "user_tracks" ADD CONSTRAINT "user_tracks_user_id_users_xata_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint ALTER TABLE "user_tracks" ADD CONSTRAINT "user_tracks_track_id_tracks_xata_id_fk" FOREIGN KEY ("track_id") REFERENCES "public"."tracks"("xata_id") ON DELETE no action ON UPDATE no action;--> statement-breakpoint -ALTER TABLE "webscrobblers" ADD CONSTRAINT "webscrobblers_user_id_users_xata_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("xata_id") ON DELETE no action ON UPDATE no action; \ No newline at end of file +ALTER TABLE "webscrobblers" ADD CONSTRAINT "webscrobblers_user_id_users_xata_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("xata_id") ON DELETE no action ON UPDATE no action; diff --git a/apps/api/drizzle/0001_fluffy_epoch.sql b/apps/api/drizzle/0001_fluffy_epoch.sql deleted file mode 100644 index 84a76322..00000000 --- a/apps/api/drizzle/0001_fluffy_epoch.sql +++ /dev/null @@ -1 +0,0 @@ -ALTER TABLE "user_playlists" ALTER COLUMN "uri" DROP NOT NULL; \ No newline at end of file diff --git a/apps/api/drizzle/0002_sweet_randall_flagg.sql b/apps/api/drizzle/0002_sweet_randall_flagg.sql deleted file mode 100644 index 8e565437..00000000 --- a/apps/api/drizzle/0002_sweet_randall_flagg.sql +++ /dev/null @@ -1,3 +0,0 @@ -ALTER TABLE "user_playlists" DROP CONSTRAINT "user_playlists_playlist_id_tracks_xata_id_fk"; ---> statement-breakpoint -ALTER TABLE "user_playlists" ADD CONSTRAINT "user_playlists_playlist_id_playlists_xata_id_fk" FOREIGN KEY ("playlist_id") REFERENCES "public"."playlists"("xata_id") ON DELETE no action ON UPDATE no action; \ No newline at end of file diff --git a/apps/api/drizzle/0003_same_rocket_racer.sql b/apps/api/drizzle/0003_same_rocket_racer.sql deleted file mode 100644 index a5c4dbe6..00000000 --- a/apps/api/drizzle/0003_same_rocket_racer.sql +++ /dev/null @@ -1,34 +0,0 @@ -ALTER TABLE "album_tracks" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "albums" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "api_keys" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "artist_albums" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "artist_tracks" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "artists" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "dropbox_accounts" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "dropbox_directories" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "dropbox_paths" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "dropbox_tokens" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "dropbox" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "google_drive_accounts" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "google_drive_directories" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "google_drive_paths" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "google_drive_tokens" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "google_drive" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "loved_tracks" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "playlist_tracks" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "playlists" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "profile_shouts" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "queue_tracks" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "scrobbles" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "shout_likes" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "shout_reports" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "shouts" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "spotify_accounts" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "spotify_tokens" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "tracks" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "user_albums" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "user_artists" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "user_playlists" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "user_tracks" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "users" ALTER COLUMN "xata_id" SET DEFAULT xata_id();--> statement-breakpoint -ALTER TABLE "webscrobblers" ALTER COLUMN "xata_id" SET DEFAULT xata_id(); \ No newline at end of file diff --git a/apps/api/drizzle/0004_long_zzzax.sql b/apps/api/drizzle/0004_long_zzzax.sql deleted file mode 100644 index 7015ff14..00000000 --- a/apps/api/drizzle/0004_long_zzzax.sql +++ /dev/null @@ -1,10 +0,0 @@ -CREATE TABLE "spotify_apps" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, - "xata_version" integer, - "spotify_app_id" text NOT NULL, - "xata_createdat" timestamp DEFAULT now() NOT NULL, - "xata_updatedat" timestamp DEFAULT now() NOT NULL -); ---> statement-breakpoint -ALTER TABLE "spotify_accounts" ADD COLUMN "spotify_app_id" text NOT NULL;--> statement-breakpoint -ALTER TABLE "spotify_tokens" ADD COLUMN "spotify_app_id" text NOT NULL; \ No newline at end of file diff --git a/apps/api/drizzle/0004_whole_greymalkin.sql b/apps/api/drizzle/0004_whole_greymalkin.sql deleted file mode 100644 index 452e0e34..00000000 --- a/apps/api/drizzle/0004_whole_greymalkin.sql +++ /dev/null @@ -1,15 +0,0 @@ -CREATE TABLE "feeds" ( - "xata_id" text PRIMARY KEY DEFAULT xata_id() NOT NULL, - "display_name" text NOT NULL, - "description" text, - "did" text NOT NULL, - "uri" text NOT NULL, - "user_id" text NOT NULL, - "xata_version" integer, - "xata_createdat" timestamp DEFAULT now() NOT NULL, - "xata_updatedat" timestamp DEFAULT now() NOT NULL, - CONSTRAINT "feeds_did_unique" UNIQUE("did"), - CONSTRAINT "feeds_uri_unique" UNIQUE("uri") -); ---> statement-breakpoint -ALTER TABLE "feeds" ADD CONSTRAINT "feeds_user_id_users_xata_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("xata_id") ON DELETE no action ON UPDATE no action; \ No newline at end of file diff --git a/apps/api/drizzle/0005_parched_thor_girl.sql b/apps/api/drizzle/0005_parched_thor_girl.sql deleted file mode 100644 index f30627e6..00000000 --- a/apps/api/drizzle/0005_parched_thor_girl.sql +++ /dev/null @@ -1 +0,0 @@ -ALTER TABLE "feeds" ADD COLUMN "avatar" text; \ No newline at end of file diff --git a/apps/api/drizzle/0005_same_hydra.sql b/apps/api/drizzle/0005_same_hydra.sql deleted file mode 100644 index 08727106..00000000 --- a/apps/api/drizzle/0005_same_hydra.sql +++ /dev/null @@ -1,2 +0,0 @@ -ALTER TABLE "spotify_accounts" ALTER COLUMN "spotify_app_id" DROP NOT NULL;--> statement-breakpoint -ALTER TABLE "spotify_apps" ADD COLUMN "spotify_secret" text NOT NULL; \ No newline at end of file diff --git a/apps/api/drizzle/0006_slow_bulldozer.sql b/apps/api/drizzle/0006_slow_bulldozer.sql deleted file mode 100644 index 2d20642f..00000000 --- a/apps/api/drizzle/0006_slow_bulldozer.sql +++ /dev/null @@ -1 +0,0 @@ -ALTER TABLE "spotify_apps" ADD CONSTRAINT "spotify_apps_spotify_app_id_unique" UNIQUE("spotify_app_id"); \ No newline at end of file diff --git a/apps/api/drizzle/meta/0000_snapshot.json b/apps/api/drizzle/meta/0000_snapshot.json index f2a2f278..78012a6d 100644 --- a/apps/api/drizzle/meta/0000_snapshot.json +++ b/apps/api/drizzle/meta/0000_snapshot.json @@ -1,5 +1,5 @@ { - "id": "6b33dcd0-52df-4403-bdc0-31517769923d", + "id": "64a52c57-c2fc-42d9-b22d-cbda7161f465", "prevId": "00000000-0000-0000-0000-000000000000", "version": "7", "dialect": "postgresql", @@ -12,7 +12,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "album_id": { "name": "album_id", @@ -90,7 +91,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "title": { "name": "title", @@ -244,7 +246,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "name": { "name": "name", @@ -328,7 +331,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "artist_id": { "name": "artist_id", @@ -406,7 +410,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "artist_id": { "name": "artist_id", @@ -484,7 +489,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "name": { "name": "name", @@ -616,7 +622,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "email": { "name": "email", @@ -696,7 +703,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "name": { "name": "name", @@ -787,7 +795,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "path": { "name": "path", @@ -884,7 +893,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "refresh_token": { "name": "refresh_token", @@ -923,7 +933,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -993,6 +1004,111 @@ "checkConstraints": {}, "isRLSEnabled": false }, + "public.feeds": { + "name": "feeds", + "schema": "", + "columns": { + "xata_id": { + "name": "xata_id", + "type": "text", + "primaryKey": true, + "notNull": true, + "default": "xata_id()" + }, + "display_name": { + "name": "display_name", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "description": { + "name": "description", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "did": { + "name": "did", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "uri": { + "name": "uri", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "avatar": { + "name": "avatar", + "type": "text", + "primaryKey": false, + "notNull": false + }, + "user_id": { + "name": "user_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "xata_version": { + "name": "xata_version", + "type": "integer", + "primaryKey": false, + "notNull": false + }, + "xata_createdat": { + "name": "xata_createdat", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "xata_updatedat": { + "name": "xata_updatedat", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": { + "feeds_user_id_users_xata_id_fk": { + "name": "feeds_user_id_users_xata_id_fk", + "tableFrom": "feeds", + "tableTo": "users", + "columnsFrom": [ + "user_id" + ], + "columnsTo": [ + "xata_id" + ], + "onDelete": "no action", + "onUpdate": "no action" + } + }, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "feeds_did_unique": { + "name": "feeds_did_unique", + "nullsNotDistinct": false, + "columns": [ + "did" + ] + }, + "feeds_uri_unique": { + "name": "feeds_uri_unique", + "nullsNotDistinct": false, + "columns": [ + "uri" + ] + } + }, + "policies": {}, + "checkConstraints": {}, + "isRLSEnabled": false + }, "public.google_drive_accounts": { "name": "google_drive_accounts", "schema": "", @@ -1001,7 +1117,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "email": { "name": "email", @@ -1081,7 +1198,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "name": { "name": "name", @@ -1172,7 +1290,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "google_drive_id": { "name": "google_drive_id", @@ -1263,7 +1382,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "refresh_token": { "name": "refresh_token", @@ -1302,7 +1422,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "google_drive_token_id": { "name": "google_drive_token_id", @@ -1380,7 +1501,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -1459,7 +1581,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "playlist_id": { "name": "playlist_id", @@ -1524,7 +1647,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "name": { "name": "name", @@ -1627,7 +1751,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -1692,7 +1817,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -1783,7 +1909,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -1920,7 +2047,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -1999,7 +2127,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -2064,7 +2193,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "content": { "name": "content", @@ -2232,7 +2362,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "xata_version": { "name": "xata_version", @@ -2259,6 +2390,12 @@ "notNull": true, "default": false }, + "spotify_app_id": { + "name": "spotify_app_id", + "type": "text", + "primaryKey": false, + "notNull": false + }, "xata_createdat": { "name": "xata_createdat", "type": "timestamp", @@ -2296,6 +2433,66 @@ "checkConstraints": {}, "isRLSEnabled": false }, + "public.spotify_apps": { + "name": "spotify_apps", + "schema": "", + "columns": { + "xata_id": { + "name": "xata_id", + "type": "text", + "primaryKey": true, + "notNull": true, + "default": "xata_id()" + }, + "xata_version": { + "name": "xata_version", + "type": "integer", + "primaryKey": false, + "notNull": false + }, + "spotify_app_id": { + "name": "spotify_app_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "spotify_secret": { + "name": "spotify_secret", + "type": "text", + "primaryKey": false, + "notNull": true + }, + "xata_createdat": { + "name": "xata_createdat", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + }, + "xata_updatedat": { + "name": "xata_updatedat", + "type": "timestamp", + "primaryKey": false, + "notNull": true, + "default": "now()" + } + }, + "indexes": {}, + "foreignKeys": {}, + "compositePrimaryKeys": {}, + "uniqueConstraints": { + "spotify_apps_spotify_app_id_unique": { + "name": "spotify_apps_spotify_app_id_unique", + "nullsNotDistinct": false, + "columns": [ + "spotify_app_id" + ] + } + }, + "policies": {}, + "checkConstraints": {}, + "isRLSEnabled": false + }, "public.spotify_tokens": { "name": "spotify_tokens", "schema": "", @@ -2304,7 +2501,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "xata_version": { "name": "xata_version", @@ -2330,6 +2528,12 @@ "primaryKey": false, "notNull": true }, + "spotify_app_id": { + "name": "spotify_app_id", + "type": "text", + "primaryKey": false, + "notNull": true + }, "xata_createdat": { "name": "xata_createdat", "type": "timestamp", @@ -2375,7 +2579,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "title": { "name": "title", @@ -2596,7 +2801,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -2694,7 +2900,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -2792,7 +2999,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -2817,7 +3025,7 @@ "name": "uri", "type": "text", "primaryKey": false, - "notNull": true + "notNull": false } }, "indexes": {}, @@ -2835,10 +3043,10 @@ "onDelete": "no action", "onUpdate": "no action" }, - "user_playlists_playlist_id_tracks_xata_id_fk": { - "name": "user_playlists_playlist_id_tracks_xata_id_fk", + "user_playlists_playlist_id_playlists_xata_id_fk": { + "name": "user_playlists_playlist_id_playlists_xata_id_fk", "tableFrom": "user_playlists", - "tableTo": "tracks", + "tableTo": "playlists", "columnsFrom": [ "playlist_id" ], @@ -2871,7 +3079,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "user_id": { "name": "user_id", @@ -2969,7 +3178,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "did": { "name": "did", @@ -3047,7 +3257,8 @@ "name": "xata_id", "type": "text", "primaryKey": true, - "notNull": true + "notNull": true, + "default": "xata_id()" }, "name": { "name": "name", diff --git a/apps/api/drizzle/meta/0001_snapshot.json b/apps/api/drizzle/meta/0001_snapshot.json deleted file mode 100644 index caa1aa79..00000000 --- a/apps/api/drizzle/meta/0001_snapshot.json +++ /dev/null @@ -1,3132 +0,0 @@ -{ - "id": "6ebb9775-b900-418c-bbd8-b704571a20d5", - "prevId": "6b33dcd0-52df-4403-bdc0-31517769923d", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.album_tracks": { - "name": "album_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "album_tracks_album_id_albums_xata_id_fk": { - "name": "album_tracks_album_id_albums_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "album_tracks_track_id_tracks_xata_id_fk": { - "name": "album_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.albums": { - "name": "albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "release_date": { - "name": "release_date", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "year": { - "name": "year", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "albums_uri_unique": { - "name": "albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - }, - "albums_apple_music_link_unique": { - "name": "albums_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "albums_spotify_link_unique": { - "name": "albums_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "albums_tidal_link_unique": { - "name": "albums_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "albums_youtube_link_unique": { - "name": "albums_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "albums_sha256_unique": { - "name": "albums_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.api_keys": { - "name": "api_keys", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "api_key": { - "name": "api_key", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shared_secret": { - "name": "shared_secret", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "api_keys_user_id_users_xata_id_fk": { - "name": "api_keys_user_id_users_xata_id_fk", - "tableFrom": "api_keys", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_albums": { - "name": "artist_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_albums_artist_id_artists_xata_id_fk": { - "name": "artist_albums_artist_id_artists_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_albums_album_id_albums_xata_id_fk": { - "name": "artist_albums_album_id_albums_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_tracks": { - "name": "artist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_tracks_artist_id_artists_xata_id_fk": { - "name": "artist_tracks_artist_id_artists_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_tracks_track_id_tracks_xata_id_fk": { - "name": "artist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artists": { - "name": "artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "biography": { - "name": "biography", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "born": { - "name": "born", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "born_in": { - "name": "born_in", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "died": { - "name": "died", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genres": { - "name": "genres", - "type": "text[]", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "artists_sha256_unique": { - "name": "artists_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "artists_uri_unique": { - "name": "artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_accounts": { - "name": "dropbox_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_accounts_user_id_users_xata_id_fk": { - "name": "dropbox_accounts_user_id_users_xata_id_fk", - "tableFrom": "dropbox_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_accounts_email_unique": { - "name": "dropbox_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_directories": { - "name": "dropbox_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_directories_parent_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_directories_parent_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_directories", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_directories_file_id_unique": { - "name": "dropbox_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_paths": { - "name": "dropbox_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_paths_directory_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_paths_directory_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_paths", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_paths_file_id_unique": { - "name": "dropbox_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_tokens": { - "name": "dropbox_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox": { - "name": "dropbox", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_token_id": { - "name": "dropbox_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_user_id_users_xata_id_fk": { - "name": "dropbox_user_id_users_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk": { - "name": "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "dropbox_tokens", - "columnsFrom": [ - "dropbox_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_accounts": { - "name": "google_drive_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_accounts_user_id_users_xata_id_fk": { - "name": "google_drive_accounts_user_id_users_xata_id_fk", - "tableFrom": "google_drive_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_accounts_email_unique": { - "name": "google_drive_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_directories": { - "name": "google_drive_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_directories_parent_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_directories_parent_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_directories", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_directories_file_id_unique": { - "name": "google_drive_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_paths": { - "name": "google_drive_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_paths_directory_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_paths_directory_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_paths", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_paths_file_id_unique": { - "name": "google_drive_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_tokens": { - "name": "google_drive_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive": { - "name": "google_drive", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "google_drive_token_id": { - "name": "google_drive_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk": { - "name": "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "google_drive_tokens", - "columnsFrom": [ - "google_drive_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "google_drive_user_id_users_xata_id_fk": { - "name": "google_drive_user_id_users_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.loved_tracks": { - "name": "loved_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "loved_tracks_user_id_users_xata_id_fk": { - "name": "loved_tracks_user_id_users_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "loved_tracks_track_id_tracks_xata_id_fk": { - "name": "loved_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "loved_tracks_uri_unique": { - "name": "loved_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlist_tracks": { - "name": "playlist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlist_tracks_playlist_id_playlists_xata_id_fk": { - "name": "playlist_tracks_playlist_id_playlists_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "playlist_tracks_track_id_tracks_xata_id_fk": { - "name": "playlist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlists": { - "name": "playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_by": { - "name": "created_by", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlists_created_by_users_xata_id_fk": { - "name": "playlists_created_by_users_xata_id_fk", - "tableFrom": "playlists", - "tableTo": "users", - "columnsFrom": [ - "created_by" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "playlists_uri_unique": { - "name": "playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.profile_shouts": { - "name": "profile_shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "profile_shouts_user_id_users_xata_id_fk": { - "name": "profile_shouts_user_id_users_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "profile_shouts_shout_id_shouts_xata_id_fk": { - "name": "profile_shouts_shout_id_shouts_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.queue_tracks": { - "name": "queue_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "position": { - "name": "position", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_uri": { - "name": "file_uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": true, - "default": 0 - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "queue_tracks_user_id_users_xata_id_fk": { - "name": "queue_tracks_user_id_users_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "queue_tracks_track_id_tracks_xata_id_fk": { - "name": "queue_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.scrobbles": { - "name": "scrobbles", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "timestamp": { - "name": "timestamp", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "scrobbles_user_id_users_xata_id_fk": { - "name": "scrobbles_user_id_users_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_track_id_tracks_xata_id_fk": { - "name": "scrobbles_track_id_tracks_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_album_id_albums_xata_id_fk": { - "name": "scrobbles_album_id_albums_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_artist_id_artists_xata_id_fk": { - "name": "scrobbles_artist_id_artists_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "scrobbles_uri_unique": { - "name": "scrobbles_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_likes": { - "name": "shout_likes", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "shout_likes_user_id_users_xata_id_fk": { - "name": "shout_likes_user_id_users_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_likes_shout_id_shouts_xata_id_fk": { - "name": "shout_likes_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shout_likes_uri_unique": { - "name": "shout_likes_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_reports": { - "name": "shout_reports", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shout_reports_user_id_users_xata_id_fk": { - "name": "shout_reports_user_id_users_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_reports_shout_id_shouts_xata_id_fk": { - "name": "shout_reports_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shouts": { - "name": "shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "content": { - "name": "content", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scrobble_id": { - "name": "scrobble_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "author_id": { - "name": "author_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shouts_track_id_tracks_xata_id_fk": { - "name": "shouts_track_id_tracks_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_artist_id_users_xata_id_fk": { - "name": "shouts_artist_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_album_id_albums_xata_id_fk": { - "name": "shouts_album_id_albums_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_scrobble_id_scrobbles_xata_id_fk": { - "name": "shouts_scrobble_id_scrobbles_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "scrobbles", - "columnsFrom": [ - "scrobble_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_author_id_users_xata_id_fk": { - "name": "shouts_author_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "author_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_parent_id_shouts_xata_id_fk": { - "name": "shouts_parent_id_shouts_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "shouts", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shouts_uri_unique": { - "name": "shouts_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_accounts": { - "name": "spotify_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_accounts_user_id_users_xata_id_fk": { - "name": "spotify_accounts_user_id_users_xata_id_fk", - "tableFrom": "spotify_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_tokens": { - "name": "spotify_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_tokens_user_id_users_xata_id_fk": { - "name": "spotify_tokens_user_id_users_xata_id_fk", - "tableFrom": "spotify_tokens", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.tracks": { - "name": "tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_artist": { - "name": "album_artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album": { - "name": "album", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_number": { - "name": "track_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "duration": { - "name": "duration", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "mb_id": { - "name": "mb_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "disc_number": { - "name": "disc_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "lyrics": { - "name": "lyrics", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "composer": { - "name": "composer", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genre": { - "name": "genre", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "label": { - "name": "label", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "copyright_message": { - "name": "copyright_message", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_uri": { - "name": "album_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "tracks_mb_id_unique": { - "name": "tracks_mb_id_unique", - "nullsNotDistinct": false, - "columns": [ - "mb_id" - ] - }, - "tracks_youtube_link_unique": { - "name": "tracks_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "tracks_spotify_link_unique": { - "name": "tracks_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "tracks_apple_music_link_unique": { - "name": "tracks_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "tracks_tidal_link_unique": { - "name": "tracks_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "tracks_sha256_unique": { - "name": "tracks_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "tracks_uri_unique": { - "name": "tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_albums": { - "name": "user_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_albums_user_id_users_xata_id_fk": { - "name": "user_albums_user_id_users_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_albums_album_id_albums_xata_id_fk": { - "name": "user_albums_album_id_albums_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_albums_uri_unique": { - "name": "user_albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_artists": { - "name": "user_artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_artists_user_id_users_xata_id_fk": { - "name": "user_artists_user_id_users_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_artists_artist_id_artists_xata_id_fk": { - "name": "user_artists_artist_id_artists_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_artists_uri_unique": { - "name": "user_artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_playlists": { - "name": "user_playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_playlists_user_id_users_xata_id_fk": { - "name": "user_playlists_user_id_users_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_playlists_playlist_id_tracks_xata_id_fk": { - "name": "user_playlists_playlist_id_tracks_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "tracks", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_playlists_uri_unique": { - "name": "user_playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_tracks": { - "name": "user_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_tracks_user_id_users_xata_id_fk": { - "name": "user_tracks_user_id_users_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_tracks_track_id_tracks_xata_id_fk": { - "name": "user_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_tracks_uri_unique": { - "name": "user_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "did": { - "name": "did", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "display_name": { - "name": "display_name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "handle": { - "name": "handle", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "avatar": { - "name": "avatar", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_did_unique": { - "name": "users_did_unique", - "nullsNotDistinct": false, - "columns": [ - "did" - ] - }, - "users_handle_unique": { - "name": "users_handle_unique", - "nullsNotDistinct": false, - "columns": [ - "handle" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.webscrobblers": { - "name": "webscrobblers", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uuid": { - "name": "uuid", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "webscrobblers_user_id_users_xata_id_fk": { - "name": "webscrobblers_user_id_users_xata_id_fk", - "tableFrom": "webscrobblers", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "roles": {}, - "policies": {}, - "views": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} \ No newline at end of file diff --git a/apps/api/drizzle/meta/0002_snapshot.json b/apps/api/drizzle/meta/0002_snapshot.json deleted file mode 100644 index 9b803123..00000000 --- a/apps/api/drizzle/meta/0002_snapshot.json +++ /dev/null @@ -1,3132 +0,0 @@ -{ - "id": "3ef49661-fdf0-4245-8943-ff69567a09b9", - "prevId": "6ebb9775-b900-418c-bbd8-b704571a20d5", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.album_tracks": { - "name": "album_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "album_tracks_album_id_albums_xata_id_fk": { - "name": "album_tracks_album_id_albums_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "album_tracks_track_id_tracks_xata_id_fk": { - "name": "album_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.albums": { - "name": "albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "release_date": { - "name": "release_date", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "year": { - "name": "year", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "albums_uri_unique": { - "name": "albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - }, - "albums_apple_music_link_unique": { - "name": "albums_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "albums_spotify_link_unique": { - "name": "albums_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "albums_tidal_link_unique": { - "name": "albums_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "albums_youtube_link_unique": { - "name": "albums_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "albums_sha256_unique": { - "name": "albums_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.api_keys": { - "name": "api_keys", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "api_key": { - "name": "api_key", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shared_secret": { - "name": "shared_secret", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "api_keys_user_id_users_xata_id_fk": { - "name": "api_keys_user_id_users_xata_id_fk", - "tableFrom": "api_keys", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_albums": { - "name": "artist_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_albums_artist_id_artists_xata_id_fk": { - "name": "artist_albums_artist_id_artists_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_albums_album_id_albums_xata_id_fk": { - "name": "artist_albums_album_id_albums_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_tracks": { - "name": "artist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_tracks_artist_id_artists_xata_id_fk": { - "name": "artist_tracks_artist_id_artists_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_tracks_track_id_tracks_xata_id_fk": { - "name": "artist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artists": { - "name": "artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "biography": { - "name": "biography", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "born": { - "name": "born", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "born_in": { - "name": "born_in", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "died": { - "name": "died", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genres": { - "name": "genres", - "type": "text[]", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "artists_sha256_unique": { - "name": "artists_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "artists_uri_unique": { - "name": "artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_accounts": { - "name": "dropbox_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_accounts_user_id_users_xata_id_fk": { - "name": "dropbox_accounts_user_id_users_xata_id_fk", - "tableFrom": "dropbox_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_accounts_email_unique": { - "name": "dropbox_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_directories": { - "name": "dropbox_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_directories_parent_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_directories_parent_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_directories", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_directories_file_id_unique": { - "name": "dropbox_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_paths": { - "name": "dropbox_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_paths_directory_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_paths_directory_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_paths", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_paths_file_id_unique": { - "name": "dropbox_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_tokens": { - "name": "dropbox_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox": { - "name": "dropbox", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_token_id": { - "name": "dropbox_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_user_id_users_xata_id_fk": { - "name": "dropbox_user_id_users_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk": { - "name": "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "dropbox_tokens", - "columnsFrom": [ - "dropbox_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_accounts": { - "name": "google_drive_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_accounts_user_id_users_xata_id_fk": { - "name": "google_drive_accounts_user_id_users_xata_id_fk", - "tableFrom": "google_drive_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_accounts_email_unique": { - "name": "google_drive_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_directories": { - "name": "google_drive_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_directories_parent_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_directories_parent_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_directories", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_directories_file_id_unique": { - "name": "google_drive_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_paths": { - "name": "google_drive_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_paths_directory_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_paths_directory_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_paths", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_paths_file_id_unique": { - "name": "google_drive_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_tokens": { - "name": "google_drive_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive": { - "name": "google_drive", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "google_drive_token_id": { - "name": "google_drive_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk": { - "name": "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "google_drive_tokens", - "columnsFrom": [ - "google_drive_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "google_drive_user_id_users_xata_id_fk": { - "name": "google_drive_user_id_users_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.loved_tracks": { - "name": "loved_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "loved_tracks_user_id_users_xata_id_fk": { - "name": "loved_tracks_user_id_users_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "loved_tracks_track_id_tracks_xata_id_fk": { - "name": "loved_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "loved_tracks_uri_unique": { - "name": "loved_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlist_tracks": { - "name": "playlist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlist_tracks_playlist_id_playlists_xata_id_fk": { - "name": "playlist_tracks_playlist_id_playlists_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "playlist_tracks_track_id_tracks_xata_id_fk": { - "name": "playlist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlists": { - "name": "playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_by": { - "name": "created_by", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlists_created_by_users_xata_id_fk": { - "name": "playlists_created_by_users_xata_id_fk", - "tableFrom": "playlists", - "tableTo": "users", - "columnsFrom": [ - "created_by" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "playlists_uri_unique": { - "name": "playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.profile_shouts": { - "name": "profile_shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "profile_shouts_user_id_users_xata_id_fk": { - "name": "profile_shouts_user_id_users_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "profile_shouts_shout_id_shouts_xata_id_fk": { - "name": "profile_shouts_shout_id_shouts_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.queue_tracks": { - "name": "queue_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "position": { - "name": "position", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_uri": { - "name": "file_uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": true, - "default": 0 - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "queue_tracks_user_id_users_xata_id_fk": { - "name": "queue_tracks_user_id_users_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "queue_tracks_track_id_tracks_xata_id_fk": { - "name": "queue_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.scrobbles": { - "name": "scrobbles", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "timestamp": { - "name": "timestamp", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "scrobbles_user_id_users_xata_id_fk": { - "name": "scrobbles_user_id_users_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_track_id_tracks_xata_id_fk": { - "name": "scrobbles_track_id_tracks_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_album_id_albums_xata_id_fk": { - "name": "scrobbles_album_id_albums_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_artist_id_artists_xata_id_fk": { - "name": "scrobbles_artist_id_artists_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "scrobbles_uri_unique": { - "name": "scrobbles_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_likes": { - "name": "shout_likes", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "shout_likes_user_id_users_xata_id_fk": { - "name": "shout_likes_user_id_users_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_likes_shout_id_shouts_xata_id_fk": { - "name": "shout_likes_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shout_likes_uri_unique": { - "name": "shout_likes_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_reports": { - "name": "shout_reports", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shout_reports_user_id_users_xata_id_fk": { - "name": "shout_reports_user_id_users_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_reports_shout_id_shouts_xata_id_fk": { - "name": "shout_reports_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shouts": { - "name": "shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "content": { - "name": "content", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scrobble_id": { - "name": "scrobble_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "author_id": { - "name": "author_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shouts_track_id_tracks_xata_id_fk": { - "name": "shouts_track_id_tracks_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_artist_id_users_xata_id_fk": { - "name": "shouts_artist_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_album_id_albums_xata_id_fk": { - "name": "shouts_album_id_albums_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_scrobble_id_scrobbles_xata_id_fk": { - "name": "shouts_scrobble_id_scrobbles_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "scrobbles", - "columnsFrom": [ - "scrobble_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_author_id_users_xata_id_fk": { - "name": "shouts_author_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "author_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_parent_id_shouts_xata_id_fk": { - "name": "shouts_parent_id_shouts_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "shouts", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shouts_uri_unique": { - "name": "shouts_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_accounts": { - "name": "spotify_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_accounts_user_id_users_xata_id_fk": { - "name": "spotify_accounts_user_id_users_xata_id_fk", - "tableFrom": "spotify_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_tokens": { - "name": "spotify_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_tokens_user_id_users_xata_id_fk": { - "name": "spotify_tokens_user_id_users_xata_id_fk", - "tableFrom": "spotify_tokens", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.tracks": { - "name": "tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_artist": { - "name": "album_artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album": { - "name": "album", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_number": { - "name": "track_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "duration": { - "name": "duration", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "mb_id": { - "name": "mb_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "disc_number": { - "name": "disc_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "lyrics": { - "name": "lyrics", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "composer": { - "name": "composer", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genre": { - "name": "genre", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "label": { - "name": "label", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "copyright_message": { - "name": "copyright_message", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_uri": { - "name": "album_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "tracks_mb_id_unique": { - "name": "tracks_mb_id_unique", - "nullsNotDistinct": false, - "columns": [ - "mb_id" - ] - }, - "tracks_youtube_link_unique": { - "name": "tracks_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "tracks_spotify_link_unique": { - "name": "tracks_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "tracks_apple_music_link_unique": { - "name": "tracks_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "tracks_tidal_link_unique": { - "name": "tracks_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "tracks_sha256_unique": { - "name": "tracks_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "tracks_uri_unique": { - "name": "tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_albums": { - "name": "user_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_albums_user_id_users_xata_id_fk": { - "name": "user_albums_user_id_users_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_albums_album_id_albums_xata_id_fk": { - "name": "user_albums_album_id_albums_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_albums_uri_unique": { - "name": "user_albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_artists": { - "name": "user_artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_artists_user_id_users_xata_id_fk": { - "name": "user_artists_user_id_users_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_artists_artist_id_artists_xata_id_fk": { - "name": "user_artists_artist_id_artists_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_artists_uri_unique": { - "name": "user_artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_playlists": { - "name": "user_playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_playlists_user_id_users_xata_id_fk": { - "name": "user_playlists_user_id_users_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_playlists_playlist_id_playlists_xata_id_fk": { - "name": "user_playlists_playlist_id_playlists_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_playlists_uri_unique": { - "name": "user_playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_tracks": { - "name": "user_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_tracks_user_id_users_xata_id_fk": { - "name": "user_tracks_user_id_users_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_tracks_track_id_tracks_xata_id_fk": { - "name": "user_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_tracks_uri_unique": { - "name": "user_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "did": { - "name": "did", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "display_name": { - "name": "display_name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "handle": { - "name": "handle", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "avatar": { - "name": "avatar", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_did_unique": { - "name": "users_did_unique", - "nullsNotDistinct": false, - "columns": [ - "did" - ] - }, - "users_handle_unique": { - "name": "users_handle_unique", - "nullsNotDistinct": false, - "columns": [ - "handle" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.webscrobblers": { - "name": "webscrobblers", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uuid": { - "name": "uuid", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "webscrobblers_user_id_users_xata_id_fk": { - "name": "webscrobblers_user_id_users_xata_id_fk", - "tableFrom": "webscrobblers", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "roles": {}, - "policies": {}, - "views": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} \ No newline at end of file diff --git a/apps/api/drizzle/meta/0003_snapshot.json b/apps/api/drizzle/meta/0003_snapshot.json deleted file mode 100644 index 5332dcd9..00000000 --- a/apps/api/drizzle/meta/0003_snapshot.json +++ /dev/null @@ -1,3166 +0,0 @@ -{ - "id": "015093fe-a66e-4ec3-b5b6-5466c6266a39", - "prevId": "3ef49661-fdf0-4245-8943-ff69567a09b9", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.album_tracks": { - "name": "album_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "album_tracks_album_id_albums_xata_id_fk": { - "name": "album_tracks_album_id_albums_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "album_tracks_track_id_tracks_xata_id_fk": { - "name": "album_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.albums": { - "name": "albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "release_date": { - "name": "release_date", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "year": { - "name": "year", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "albums_uri_unique": { - "name": "albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - }, - "albums_apple_music_link_unique": { - "name": "albums_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "albums_spotify_link_unique": { - "name": "albums_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "albums_tidal_link_unique": { - "name": "albums_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "albums_youtube_link_unique": { - "name": "albums_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "albums_sha256_unique": { - "name": "albums_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.api_keys": { - "name": "api_keys", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "api_key": { - "name": "api_key", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shared_secret": { - "name": "shared_secret", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "api_keys_user_id_users_xata_id_fk": { - "name": "api_keys_user_id_users_xata_id_fk", - "tableFrom": "api_keys", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_albums": { - "name": "artist_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_albums_artist_id_artists_xata_id_fk": { - "name": "artist_albums_artist_id_artists_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_albums_album_id_albums_xata_id_fk": { - "name": "artist_albums_album_id_albums_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_tracks": { - "name": "artist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_tracks_artist_id_artists_xata_id_fk": { - "name": "artist_tracks_artist_id_artists_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_tracks_track_id_tracks_xata_id_fk": { - "name": "artist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artists": { - "name": "artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "biography": { - "name": "biography", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "born": { - "name": "born", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "born_in": { - "name": "born_in", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "died": { - "name": "died", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genres": { - "name": "genres", - "type": "text[]", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "artists_sha256_unique": { - "name": "artists_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "artists_uri_unique": { - "name": "artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_accounts": { - "name": "dropbox_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_accounts_user_id_users_xata_id_fk": { - "name": "dropbox_accounts_user_id_users_xata_id_fk", - "tableFrom": "dropbox_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_accounts_email_unique": { - "name": "dropbox_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_directories": { - "name": "dropbox_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_directories_parent_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_directories_parent_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_directories", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_directories_file_id_unique": { - "name": "dropbox_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_paths": { - "name": "dropbox_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_paths_directory_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_paths_directory_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_paths", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_paths_file_id_unique": { - "name": "dropbox_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_tokens": { - "name": "dropbox_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox": { - "name": "dropbox", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_token_id": { - "name": "dropbox_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_user_id_users_xata_id_fk": { - "name": "dropbox_user_id_users_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk": { - "name": "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "dropbox_tokens", - "columnsFrom": [ - "dropbox_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_accounts": { - "name": "google_drive_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_accounts_user_id_users_xata_id_fk": { - "name": "google_drive_accounts_user_id_users_xata_id_fk", - "tableFrom": "google_drive_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_accounts_email_unique": { - "name": "google_drive_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_directories": { - "name": "google_drive_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_directories_parent_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_directories_parent_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_directories", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_directories_file_id_unique": { - "name": "google_drive_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_paths": { - "name": "google_drive_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_paths_directory_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_paths_directory_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_paths", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_paths_file_id_unique": { - "name": "google_drive_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_tokens": { - "name": "google_drive_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive": { - "name": "google_drive", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "google_drive_token_id": { - "name": "google_drive_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk": { - "name": "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "google_drive_tokens", - "columnsFrom": [ - "google_drive_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "google_drive_user_id_users_xata_id_fk": { - "name": "google_drive_user_id_users_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.loved_tracks": { - "name": "loved_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "loved_tracks_user_id_users_xata_id_fk": { - "name": "loved_tracks_user_id_users_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "loved_tracks_track_id_tracks_xata_id_fk": { - "name": "loved_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "loved_tracks_uri_unique": { - "name": "loved_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlist_tracks": { - "name": "playlist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlist_tracks_playlist_id_playlists_xata_id_fk": { - "name": "playlist_tracks_playlist_id_playlists_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "playlist_tracks_track_id_tracks_xata_id_fk": { - "name": "playlist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlists": { - "name": "playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_by": { - "name": "created_by", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlists_created_by_users_xata_id_fk": { - "name": "playlists_created_by_users_xata_id_fk", - "tableFrom": "playlists", - "tableTo": "users", - "columnsFrom": [ - "created_by" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "playlists_uri_unique": { - "name": "playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.profile_shouts": { - "name": "profile_shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "profile_shouts_user_id_users_xata_id_fk": { - "name": "profile_shouts_user_id_users_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "profile_shouts_shout_id_shouts_xata_id_fk": { - "name": "profile_shouts_shout_id_shouts_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.queue_tracks": { - "name": "queue_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "position": { - "name": "position", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_uri": { - "name": "file_uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": true, - "default": 0 - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "queue_tracks_user_id_users_xata_id_fk": { - "name": "queue_tracks_user_id_users_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "queue_tracks_track_id_tracks_xata_id_fk": { - "name": "queue_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.scrobbles": { - "name": "scrobbles", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "timestamp": { - "name": "timestamp", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "scrobbles_user_id_users_xata_id_fk": { - "name": "scrobbles_user_id_users_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_track_id_tracks_xata_id_fk": { - "name": "scrobbles_track_id_tracks_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_album_id_albums_xata_id_fk": { - "name": "scrobbles_album_id_albums_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_artist_id_artists_xata_id_fk": { - "name": "scrobbles_artist_id_artists_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "scrobbles_uri_unique": { - "name": "scrobbles_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_likes": { - "name": "shout_likes", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "shout_likes_user_id_users_xata_id_fk": { - "name": "shout_likes_user_id_users_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_likes_shout_id_shouts_xata_id_fk": { - "name": "shout_likes_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shout_likes_uri_unique": { - "name": "shout_likes_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_reports": { - "name": "shout_reports", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shout_reports_user_id_users_xata_id_fk": { - "name": "shout_reports_user_id_users_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_reports_shout_id_shouts_xata_id_fk": { - "name": "shout_reports_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shouts": { - "name": "shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "content": { - "name": "content", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scrobble_id": { - "name": "scrobble_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "author_id": { - "name": "author_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shouts_track_id_tracks_xata_id_fk": { - "name": "shouts_track_id_tracks_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_artist_id_users_xata_id_fk": { - "name": "shouts_artist_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_album_id_albums_xata_id_fk": { - "name": "shouts_album_id_albums_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_scrobble_id_scrobbles_xata_id_fk": { - "name": "shouts_scrobble_id_scrobbles_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "scrobbles", - "columnsFrom": [ - "scrobble_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_author_id_users_xata_id_fk": { - "name": "shouts_author_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "author_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_parent_id_shouts_xata_id_fk": { - "name": "shouts_parent_id_shouts_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "shouts", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shouts_uri_unique": { - "name": "shouts_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_accounts": { - "name": "spotify_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_accounts_user_id_users_xata_id_fk": { - "name": "spotify_accounts_user_id_users_xata_id_fk", - "tableFrom": "spotify_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_tokens": { - "name": "spotify_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_tokens_user_id_users_xata_id_fk": { - "name": "spotify_tokens_user_id_users_xata_id_fk", - "tableFrom": "spotify_tokens", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.tracks": { - "name": "tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_artist": { - "name": "album_artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album": { - "name": "album", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_number": { - "name": "track_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "duration": { - "name": "duration", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "mb_id": { - "name": "mb_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "disc_number": { - "name": "disc_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "lyrics": { - "name": "lyrics", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "composer": { - "name": "composer", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genre": { - "name": "genre", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "label": { - "name": "label", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "copyright_message": { - "name": "copyright_message", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_uri": { - "name": "album_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "tracks_mb_id_unique": { - "name": "tracks_mb_id_unique", - "nullsNotDistinct": false, - "columns": [ - "mb_id" - ] - }, - "tracks_youtube_link_unique": { - "name": "tracks_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "tracks_spotify_link_unique": { - "name": "tracks_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "tracks_apple_music_link_unique": { - "name": "tracks_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "tracks_tidal_link_unique": { - "name": "tracks_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "tracks_sha256_unique": { - "name": "tracks_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "tracks_uri_unique": { - "name": "tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_albums": { - "name": "user_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_albums_user_id_users_xata_id_fk": { - "name": "user_albums_user_id_users_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_albums_album_id_albums_xata_id_fk": { - "name": "user_albums_album_id_albums_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_albums_uri_unique": { - "name": "user_albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_artists": { - "name": "user_artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_artists_user_id_users_xata_id_fk": { - "name": "user_artists_user_id_users_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_artists_artist_id_artists_xata_id_fk": { - "name": "user_artists_artist_id_artists_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_artists_uri_unique": { - "name": "user_artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_playlists": { - "name": "user_playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_playlists_user_id_users_xata_id_fk": { - "name": "user_playlists_user_id_users_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_playlists_playlist_id_playlists_xata_id_fk": { - "name": "user_playlists_playlist_id_playlists_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_playlists_uri_unique": { - "name": "user_playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_tracks": { - "name": "user_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_tracks_user_id_users_xata_id_fk": { - "name": "user_tracks_user_id_users_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_tracks_track_id_tracks_xata_id_fk": { - "name": "user_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_tracks_uri_unique": { - "name": "user_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "did": { - "name": "did", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "display_name": { - "name": "display_name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "handle": { - "name": "handle", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "avatar": { - "name": "avatar", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_did_unique": { - "name": "users_did_unique", - "nullsNotDistinct": false, - "columns": [ - "did" - ] - }, - "users_handle_unique": { - "name": "users_handle_unique", - "nullsNotDistinct": false, - "columns": [ - "handle" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.webscrobblers": { - "name": "webscrobblers", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uuid": { - "name": "uuid", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "webscrobblers_user_id_users_xata_id_fk": { - "name": "webscrobblers_user_id_users_xata_id_fk", - "tableFrom": "webscrobblers", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "roles": {}, - "policies": {}, - "views": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} \ No newline at end of file diff --git a/apps/api/drizzle/meta/0004_snapshot.json b/apps/api/drizzle/meta/0004_snapshot.json deleted file mode 100644 index b62dc52b..00000000 --- a/apps/api/drizzle/meta/0004_snapshot.json +++ /dev/null @@ -1,3323 +0,0 @@ -{ - "id": "3294c136-37d7-4c61-8633-26d17c05a059", - "prevId": "015093fe-a66e-4ec3-b5b6-5466c6266a39", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.album_tracks": { - "name": "album_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "album_tracks_album_id_albums_xata_id_fk": { - "name": "album_tracks_album_id_albums_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "album_tracks_track_id_tracks_xata_id_fk": { - "name": "album_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.albums": { - "name": "albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "release_date": { - "name": "release_date", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "year": { - "name": "year", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "albums_uri_unique": { - "name": "albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - }, - "albums_apple_music_link_unique": { - "name": "albums_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "albums_spotify_link_unique": { - "name": "albums_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "albums_tidal_link_unique": { - "name": "albums_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "albums_youtube_link_unique": { - "name": "albums_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "albums_sha256_unique": { - "name": "albums_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.api_keys": { - "name": "api_keys", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "api_key": { - "name": "api_key", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shared_secret": { - "name": "shared_secret", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "api_keys_user_id_users_xata_id_fk": { - "name": "api_keys_user_id_users_xata_id_fk", - "tableFrom": "api_keys", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_albums": { - "name": "artist_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_albums_artist_id_artists_xata_id_fk": { - "name": "artist_albums_artist_id_artists_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_albums_album_id_albums_xata_id_fk": { - "name": "artist_albums_album_id_albums_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_tracks": { - "name": "artist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_tracks_artist_id_artists_xata_id_fk": { - "name": "artist_tracks_artist_id_artists_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_tracks_track_id_tracks_xata_id_fk": { - "name": "artist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artists": { - "name": "artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "biography": { - "name": "biography", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "born": { - "name": "born", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "born_in": { - "name": "born_in", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "died": { - "name": "died", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genres": { - "name": "genres", - "type": "text[]", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "artists_sha256_unique": { - "name": "artists_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "artists_uri_unique": { - "name": "artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_accounts": { - "name": "dropbox_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_accounts_user_id_users_xata_id_fk": { - "name": "dropbox_accounts_user_id_users_xata_id_fk", - "tableFrom": "dropbox_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_accounts_email_unique": { - "name": "dropbox_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_directories": { - "name": "dropbox_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_directories_parent_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_directories_parent_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_directories", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_directories_file_id_unique": { - "name": "dropbox_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_paths": { - "name": "dropbox_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_paths_directory_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_paths_directory_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_paths", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_paths_file_id_unique": { - "name": "dropbox_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_tokens": { - "name": "dropbox_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox": { - "name": "dropbox", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_token_id": { - "name": "dropbox_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_user_id_users_xata_id_fk": { - "name": "dropbox_user_id_users_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk": { - "name": "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "dropbox_tokens", - "columnsFrom": [ - "dropbox_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.feeds": { - "name": "feeds", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "display_name": { - "name": "display_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "did": { - "name": "did", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "feeds_user_id_users_xata_id_fk": { - "name": "feeds_user_id_users_xata_id_fk", - "tableFrom": "feeds", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "feeds_did_unique": { - "name": "feeds_did_unique", - "nullsNotDistinct": false, - "columns": [ - "did" - ] - }, - "feeds_uri_unique": { - "name": "feeds_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_accounts": { - "name": "google_drive_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_accounts_user_id_users_xata_id_fk": { - "name": "google_drive_accounts_user_id_users_xata_id_fk", - "tableFrom": "google_drive_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_accounts_email_unique": { - "name": "google_drive_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_directories": { - "name": "google_drive_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_directories_parent_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_directories_parent_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_directories", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_directories_file_id_unique": { - "name": "google_drive_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_paths": { - "name": "google_drive_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_paths_directory_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_paths_directory_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_paths", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_paths_file_id_unique": { - "name": "google_drive_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_tokens": { - "name": "google_drive_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive": { - "name": "google_drive", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "google_drive_token_id": { - "name": "google_drive_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk": { - "name": "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "google_drive_tokens", - "columnsFrom": [ - "google_drive_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "google_drive_user_id_users_xata_id_fk": { - "name": "google_drive_user_id_users_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.loved_tracks": { - "name": "loved_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "loved_tracks_user_id_users_xata_id_fk": { - "name": "loved_tracks_user_id_users_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "loved_tracks_track_id_tracks_xata_id_fk": { - "name": "loved_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "loved_tracks_uri_unique": { - "name": "loved_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlist_tracks": { - "name": "playlist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlist_tracks_playlist_id_playlists_xata_id_fk": { - "name": "playlist_tracks_playlist_id_playlists_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "playlist_tracks_track_id_tracks_xata_id_fk": { - "name": "playlist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlists": { - "name": "playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_by": { - "name": "created_by", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlists_created_by_users_xata_id_fk": { - "name": "playlists_created_by_users_xata_id_fk", - "tableFrom": "playlists", - "tableTo": "users", - "columnsFrom": [ - "created_by" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "playlists_uri_unique": { - "name": "playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.profile_shouts": { - "name": "profile_shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "profile_shouts_user_id_users_xata_id_fk": { - "name": "profile_shouts_user_id_users_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "profile_shouts_shout_id_shouts_xata_id_fk": { - "name": "profile_shouts_shout_id_shouts_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.queue_tracks": { - "name": "queue_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "position": { - "name": "position", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_uri": { - "name": "file_uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": true, - "default": 0 - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "queue_tracks_user_id_users_xata_id_fk": { - "name": "queue_tracks_user_id_users_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "queue_tracks_track_id_tracks_xata_id_fk": { - "name": "queue_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.scrobbles": { - "name": "scrobbles", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "timestamp": { - "name": "timestamp", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "scrobbles_user_id_users_xata_id_fk": { - "name": "scrobbles_user_id_users_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_track_id_tracks_xata_id_fk": { - "name": "scrobbles_track_id_tracks_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_album_id_albums_xata_id_fk": { - "name": "scrobbles_album_id_albums_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_artist_id_artists_xata_id_fk": { - "name": "scrobbles_artist_id_artists_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "scrobbles_uri_unique": { - "name": "scrobbles_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_likes": { - "name": "shout_likes", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "shout_likes_user_id_users_xata_id_fk": { - "name": "shout_likes_user_id_users_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_likes_shout_id_shouts_xata_id_fk": { - "name": "shout_likes_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shout_likes_uri_unique": { - "name": "shout_likes_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_reports": { - "name": "shout_reports", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shout_reports_user_id_users_xata_id_fk": { - "name": "shout_reports_user_id_users_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_reports_shout_id_shouts_xata_id_fk": { - "name": "shout_reports_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shouts": { - "name": "shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "content": { - "name": "content", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scrobble_id": { - "name": "scrobble_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "author_id": { - "name": "author_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shouts_track_id_tracks_xata_id_fk": { - "name": "shouts_track_id_tracks_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_artist_id_users_xata_id_fk": { - "name": "shouts_artist_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_album_id_albums_xata_id_fk": { - "name": "shouts_album_id_albums_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_scrobble_id_scrobbles_xata_id_fk": { - "name": "shouts_scrobble_id_scrobbles_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "scrobbles", - "columnsFrom": [ - "scrobble_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_author_id_users_xata_id_fk": { - "name": "shouts_author_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "author_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_parent_id_shouts_xata_id_fk": { - "name": "shouts_parent_id_shouts_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "shouts", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shouts_uri_unique": { - "name": "shouts_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_accounts": { - "name": "spotify_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "spotify_app_id": { - "name": "spotify_app_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_accounts_user_id_users_xata_id_fk": { - "name": "spotify_accounts_user_id_users_xata_id_fk", - "tableFrom": "spotify_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_apps": { - "name": "spotify_apps", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "spotify_app_id": { - "name": "spotify_app_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_tokens": { - "name": "spotify_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "spotify_app_id": { - "name": "spotify_app_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_tokens_user_id_users_xata_id_fk": { - "name": "spotify_tokens_user_id_users_xata_id_fk", - "tableFrom": "spotify_tokens", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.tracks": { - "name": "tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_artist": { - "name": "album_artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album": { - "name": "album", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_number": { - "name": "track_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "duration": { - "name": "duration", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "mb_id": { - "name": "mb_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "disc_number": { - "name": "disc_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "lyrics": { - "name": "lyrics", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "composer": { - "name": "composer", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genre": { - "name": "genre", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "label": { - "name": "label", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "copyright_message": { - "name": "copyright_message", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_uri": { - "name": "album_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "tracks_mb_id_unique": { - "name": "tracks_mb_id_unique", - "nullsNotDistinct": false, - "columns": [ - "mb_id" - ] - }, - "tracks_youtube_link_unique": { - "name": "tracks_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "tracks_spotify_link_unique": { - "name": "tracks_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "tracks_apple_music_link_unique": { - "name": "tracks_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "tracks_tidal_link_unique": { - "name": "tracks_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "tracks_sha256_unique": { - "name": "tracks_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "tracks_uri_unique": { - "name": "tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_albums": { - "name": "user_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_albums_user_id_users_xata_id_fk": { - "name": "user_albums_user_id_users_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_albums_album_id_albums_xata_id_fk": { - "name": "user_albums_album_id_albums_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_albums_uri_unique": { - "name": "user_albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_artists": { - "name": "user_artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_artists_user_id_users_xata_id_fk": { - "name": "user_artists_user_id_users_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_artists_artist_id_artists_xata_id_fk": { - "name": "user_artists_artist_id_artists_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_artists_uri_unique": { - "name": "user_artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_playlists": { - "name": "user_playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_playlists_user_id_users_xata_id_fk": { - "name": "user_playlists_user_id_users_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_playlists_playlist_id_playlists_xata_id_fk": { - "name": "user_playlists_playlist_id_playlists_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_playlists_uri_unique": { - "name": "user_playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_tracks": { - "name": "user_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_tracks_user_id_users_xata_id_fk": { - "name": "user_tracks_user_id_users_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_tracks_track_id_tracks_xata_id_fk": { - "name": "user_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_tracks_uri_unique": { - "name": "user_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "did": { - "name": "did", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "display_name": { - "name": "display_name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "handle": { - "name": "handle", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "avatar": { - "name": "avatar", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_did_unique": { - "name": "users_did_unique", - "nullsNotDistinct": false, - "columns": [ - "did" - ] - }, - "users_handle_unique": { - "name": "users_handle_unique", - "nullsNotDistinct": false, - "columns": [ - "handle" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.webscrobblers": { - "name": "webscrobblers", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uuid": { - "name": "uuid", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "webscrobblers_user_id_users_xata_id_fk": { - "name": "webscrobblers_user_id_users_xata_id_fk", - "tableFrom": "webscrobblers", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "roles": {}, - "policies": {}, - "views": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} \ No newline at end of file diff --git a/apps/api/drizzle/meta/0005_snapshot.json b/apps/api/drizzle/meta/0005_snapshot.json deleted file mode 100644 index 9237b201..00000000 --- a/apps/api/drizzle/meta/0005_snapshot.json +++ /dev/null @@ -1,3335 +0,0 @@ -{ - "id": "b4f141d3-3e14-4aaf-b3f1-b3165d009289", - "prevId": "3294c136-37d7-4c61-8633-26d17c05a059", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.album_tracks": { - "name": "album_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "album_tracks_album_id_albums_xata_id_fk": { - "name": "album_tracks_album_id_albums_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "album_tracks_track_id_tracks_xata_id_fk": { - "name": "album_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.albums": { - "name": "albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "release_date": { - "name": "release_date", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "year": { - "name": "year", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "albums_uri_unique": { - "name": "albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - }, - "albums_apple_music_link_unique": { - "name": "albums_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "albums_spotify_link_unique": { - "name": "albums_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "albums_tidal_link_unique": { - "name": "albums_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "albums_youtube_link_unique": { - "name": "albums_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "albums_sha256_unique": { - "name": "albums_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.api_keys": { - "name": "api_keys", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "api_key": { - "name": "api_key", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shared_secret": { - "name": "shared_secret", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "api_keys_user_id_users_xata_id_fk": { - "name": "api_keys_user_id_users_xata_id_fk", - "tableFrom": "api_keys", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_albums": { - "name": "artist_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_albums_artist_id_artists_xata_id_fk": { - "name": "artist_albums_artist_id_artists_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_albums_album_id_albums_xata_id_fk": { - "name": "artist_albums_album_id_albums_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_tracks": { - "name": "artist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_tracks_artist_id_artists_xata_id_fk": { - "name": "artist_tracks_artist_id_artists_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_tracks_track_id_tracks_xata_id_fk": { - "name": "artist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artists": { - "name": "artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "biography": { - "name": "biography", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "born": { - "name": "born", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "born_in": { - "name": "born_in", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "died": { - "name": "died", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genres": { - "name": "genres", - "type": "text[]", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "artists_sha256_unique": { - "name": "artists_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "artists_uri_unique": { - "name": "artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_accounts": { - "name": "dropbox_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_accounts_user_id_users_xata_id_fk": { - "name": "dropbox_accounts_user_id_users_xata_id_fk", - "tableFrom": "dropbox_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_accounts_email_unique": { - "name": "dropbox_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_directories": { - "name": "dropbox_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_directories_parent_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_directories_parent_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_directories", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_directories_file_id_unique": { - "name": "dropbox_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_paths": { - "name": "dropbox_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_paths_directory_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_paths_directory_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_paths", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_paths_file_id_unique": { - "name": "dropbox_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_tokens": { - "name": "dropbox_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox": { - "name": "dropbox", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_token_id": { - "name": "dropbox_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_user_id_users_xata_id_fk": { - "name": "dropbox_user_id_users_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk": { - "name": "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "dropbox_tokens", - "columnsFrom": [ - "dropbox_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.feeds": { - "name": "feeds", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "display_name": { - "name": "display_name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "did": { - "name": "did", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "avatar": { - "name": "avatar", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "feeds_user_id_users_xata_id_fk": { - "name": "feeds_user_id_users_xata_id_fk", - "tableFrom": "feeds", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "feeds_did_unique": { - "name": "feeds_did_unique", - "nullsNotDistinct": false, - "columns": [ - "did" - ] - }, - "feeds_uri_unique": { - "name": "feeds_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_accounts": { - "name": "google_drive_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_accounts_user_id_users_xata_id_fk": { - "name": "google_drive_accounts_user_id_users_xata_id_fk", - "tableFrom": "google_drive_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_accounts_email_unique": { - "name": "google_drive_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_directories": { - "name": "google_drive_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_directories_parent_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_directories_parent_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_directories", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_directories_file_id_unique": { - "name": "google_drive_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_paths": { - "name": "google_drive_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_paths_directory_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_paths_directory_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_paths", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_paths_file_id_unique": { - "name": "google_drive_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_tokens": { - "name": "google_drive_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive": { - "name": "google_drive", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "google_drive_token_id": { - "name": "google_drive_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk": { - "name": "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "google_drive_tokens", - "columnsFrom": [ - "google_drive_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "google_drive_user_id_users_xata_id_fk": { - "name": "google_drive_user_id_users_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.loved_tracks": { - "name": "loved_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "loved_tracks_user_id_users_xata_id_fk": { - "name": "loved_tracks_user_id_users_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "loved_tracks_track_id_tracks_xata_id_fk": { - "name": "loved_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "loved_tracks_uri_unique": { - "name": "loved_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlist_tracks": { - "name": "playlist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlist_tracks_playlist_id_playlists_xata_id_fk": { - "name": "playlist_tracks_playlist_id_playlists_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "playlist_tracks_track_id_tracks_xata_id_fk": { - "name": "playlist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlists": { - "name": "playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_by": { - "name": "created_by", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlists_created_by_users_xata_id_fk": { - "name": "playlists_created_by_users_xata_id_fk", - "tableFrom": "playlists", - "tableTo": "users", - "columnsFrom": [ - "created_by" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "playlists_uri_unique": { - "name": "playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.profile_shouts": { - "name": "profile_shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "profile_shouts_user_id_users_xata_id_fk": { - "name": "profile_shouts_user_id_users_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "profile_shouts_shout_id_shouts_xata_id_fk": { - "name": "profile_shouts_shout_id_shouts_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.queue_tracks": { - "name": "queue_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "position": { - "name": "position", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_uri": { - "name": "file_uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": true, - "default": 0 - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "queue_tracks_user_id_users_xata_id_fk": { - "name": "queue_tracks_user_id_users_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "queue_tracks_track_id_tracks_xata_id_fk": { - "name": "queue_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.scrobbles": { - "name": "scrobbles", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "timestamp": { - "name": "timestamp", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "scrobbles_user_id_users_xata_id_fk": { - "name": "scrobbles_user_id_users_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_track_id_tracks_xata_id_fk": { - "name": "scrobbles_track_id_tracks_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_album_id_albums_xata_id_fk": { - "name": "scrobbles_album_id_albums_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_artist_id_artists_xata_id_fk": { - "name": "scrobbles_artist_id_artists_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "scrobbles_uri_unique": { - "name": "scrobbles_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_likes": { - "name": "shout_likes", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "shout_likes_user_id_users_xata_id_fk": { - "name": "shout_likes_user_id_users_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_likes_shout_id_shouts_xata_id_fk": { - "name": "shout_likes_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shout_likes_uri_unique": { - "name": "shout_likes_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_reports": { - "name": "shout_reports", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shout_reports_user_id_users_xata_id_fk": { - "name": "shout_reports_user_id_users_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_reports_shout_id_shouts_xata_id_fk": { - "name": "shout_reports_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shouts": { - "name": "shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "content": { - "name": "content", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scrobble_id": { - "name": "scrobble_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "author_id": { - "name": "author_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shouts_track_id_tracks_xata_id_fk": { - "name": "shouts_track_id_tracks_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_artist_id_users_xata_id_fk": { - "name": "shouts_artist_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_album_id_albums_xata_id_fk": { - "name": "shouts_album_id_albums_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_scrobble_id_scrobbles_xata_id_fk": { - "name": "shouts_scrobble_id_scrobbles_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "scrobbles", - "columnsFrom": [ - "scrobble_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_author_id_users_xata_id_fk": { - "name": "shouts_author_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "author_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_parent_id_shouts_xata_id_fk": { - "name": "shouts_parent_id_shouts_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "shouts", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shouts_uri_unique": { - "name": "shouts_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_accounts": { - "name": "spotify_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "spotify_app_id": { - "name": "spotify_app_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_accounts_user_id_users_xata_id_fk": { - "name": "spotify_accounts_user_id_users_xata_id_fk", - "tableFrom": "spotify_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_apps": { - "name": "spotify_apps", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "spotify_app_id": { - "name": "spotify_app_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "spotify_secret": { - "name": "spotify_secret", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_tokens": { - "name": "spotify_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "spotify_app_id": { - "name": "spotify_app_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_tokens_user_id_users_xata_id_fk": { - "name": "spotify_tokens_user_id_users_xata_id_fk", - "tableFrom": "spotify_tokens", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.tracks": { - "name": "tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_artist": { - "name": "album_artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album": { - "name": "album", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_number": { - "name": "track_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "duration": { - "name": "duration", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "mb_id": { - "name": "mb_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "disc_number": { - "name": "disc_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "lyrics": { - "name": "lyrics", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "composer": { - "name": "composer", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genre": { - "name": "genre", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "label": { - "name": "label", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "copyright_message": { - "name": "copyright_message", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_uri": { - "name": "album_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "tracks_mb_id_unique": { - "name": "tracks_mb_id_unique", - "nullsNotDistinct": false, - "columns": [ - "mb_id" - ] - }, - "tracks_youtube_link_unique": { - "name": "tracks_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "tracks_spotify_link_unique": { - "name": "tracks_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "tracks_apple_music_link_unique": { - "name": "tracks_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "tracks_tidal_link_unique": { - "name": "tracks_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "tracks_sha256_unique": { - "name": "tracks_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "tracks_uri_unique": { - "name": "tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_albums": { - "name": "user_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_albums_user_id_users_xata_id_fk": { - "name": "user_albums_user_id_users_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_albums_album_id_albums_xata_id_fk": { - "name": "user_albums_album_id_albums_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_albums_uri_unique": { - "name": "user_albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_artists": { - "name": "user_artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_artists_user_id_users_xata_id_fk": { - "name": "user_artists_user_id_users_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_artists_artist_id_artists_xata_id_fk": { - "name": "user_artists_artist_id_artists_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_artists_uri_unique": { - "name": "user_artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_playlists": { - "name": "user_playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_playlists_user_id_users_xata_id_fk": { - "name": "user_playlists_user_id_users_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_playlists_playlist_id_playlists_xata_id_fk": { - "name": "user_playlists_playlist_id_playlists_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_playlists_uri_unique": { - "name": "user_playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_tracks": { - "name": "user_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_tracks_user_id_users_xata_id_fk": { - "name": "user_tracks_user_id_users_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_tracks_track_id_tracks_xata_id_fk": { - "name": "user_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_tracks_uri_unique": { - "name": "user_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "did": { - "name": "did", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "display_name": { - "name": "display_name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "handle": { - "name": "handle", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "avatar": { - "name": "avatar", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_did_unique": { - "name": "users_did_unique", - "nullsNotDistinct": false, - "columns": [ - "did" - ] - }, - "users_handle_unique": { - "name": "users_handle_unique", - "nullsNotDistinct": false, - "columns": [ - "handle" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.webscrobblers": { - "name": "webscrobblers", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uuid": { - "name": "uuid", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "webscrobblers_user_id_users_xata_id_fk": { - "name": "webscrobblers_user_id_users_xata_id_fk", - "tableFrom": "webscrobblers", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "roles": {}, - "policies": {}, - "views": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} \ No newline at end of file diff --git a/apps/api/drizzle/meta/0006_snapshot.json b/apps/api/drizzle/meta/0006_snapshot.json deleted file mode 100644 index cabc6f61..00000000 --- a/apps/api/drizzle/meta/0006_snapshot.json +++ /dev/null @@ -1,3238 +0,0 @@ -{ - "id": "876823a6-883c-4fec-9072-9ec67f483c8d", - "prevId": "b4f141d3-3e14-4aaf-b3f1-b3165d009289", - "version": "7", - "dialect": "postgresql", - "tables": { - "public.album_tracks": { - "name": "album_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "album_tracks_album_id_albums_xata_id_fk": { - "name": "album_tracks_album_id_albums_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "album_tracks_track_id_tracks_xata_id_fk": { - "name": "album_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "album_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.albums": { - "name": "albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "release_date": { - "name": "release_date", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "year": { - "name": "year", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "albums_uri_unique": { - "name": "albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - }, - "albums_apple_music_link_unique": { - "name": "albums_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "albums_spotify_link_unique": { - "name": "albums_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "albums_tidal_link_unique": { - "name": "albums_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "albums_youtube_link_unique": { - "name": "albums_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "albums_sha256_unique": { - "name": "albums_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.api_keys": { - "name": "api_keys", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "api_key": { - "name": "api_key", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shared_secret": { - "name": "shared_secret", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "api_keys_user_id_users_xata_id_fk": { - "name": "api_keys_user_id_users_xata_id_fk", - "tableFrom": "api_keys", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_albums": { - "name": "artist_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_albums_artist_id_artists_xata_id_fk": { - "name": "artist_albums_artist_id_artists_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_albums_album_id_albums_xata_id_fk": { - "name": "artist_albums_album_id_albums_xata_id_fk", - "tableFrom": "artist_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artist_tracks": { - "name": "artist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "artist_tracks_artist_id_artists_xata_id_fk": { - "name": "artist_tracks_artist_id_artists_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "artist_tracks_track_id_tracks_xata_id_fk": { - "name": "artist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "artist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.artists": { - "name": "artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "biography": { - "name": "biography", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "born": { - "name": "born", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "born_in": { - "name": "born_in", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "died": { - "name": "died", - "type": "timestamp", - "primaryKey": false, - "notNull": false - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genres": { - "name": "genres", - "type": "text[]", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "artists_sha256_unique": { - "name": "artists_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "artists_uri_unique": { - "name": "artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_accounts": { - "name": "dropbox_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_accounts_user_id_users_xata_id_fk": { - "name": "dropbox_accounts_user_id_users_xata_id_fk", - "tableFrom": "dropbox_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_accounts_email_unique": { - "name": "dropbox_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_directories": { - "name": "dropbox_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_directories_parent_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_directories_parent_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_directories", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_directories_file_id_unique": { - "name": "dropbox_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_paths": { - "name": "dropbox_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_id": { - "name": "dropbox_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_paths_directory_id_dropbox_directories_xata_id_fk": { - "name": "dropbox_paths_directory_id_dropbox_directories_xata_id_fk", - "tableFrom": "dropbox_paths", - "tableTo": "dropbox_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "dropbox_paths_file_id_unique": { - "name": "dropbox_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox_tokens": { - "name": "dropbox_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.dropbox": { - "name": "dropbox", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "dropbox_token_id": { - "name": "dropbox_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "dropbox_user_id_users_xata_id_fk": { - "name": "dropbox_user_id_users_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk": { - "name": "dropbox_dropbox_token_id_dropbox_tokens_xata_id_fk", - "tableFrom": "dropbox", - "tableTo": "dropbox_tokens", - "columnsFrom": [ - "dropbox_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_accounts": { - "name": "google_drive_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_accounts_user_id_users_xata_id_fk": { - "name": "google_drive_accounts_user_id_users_xata_id_fk", - "tableFrom": "google_drive_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_accounts_email_unique": { - "name": "google_drive_accounts_email_unique", - "nullsNotDistinct": false, - "columns": [ - "email" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_directories": { - "name": "google_drive_directories", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "path": { - "name": "path", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_directories_parent_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_directories_parent_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_directories", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_directories_file_id_unique": { - "name": "google_drive_directories_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_paths": { - "name": "google_drive_paths", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "google_drive_id": { - "name": "google_drive_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "directory_id": { - "name": "directory_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "file_id": { - "name": "file_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_paths_directory_id_google_drive_directories_xata_id_fk": { - "name": "google_drive_paths_directory_id_google_drive_directories_xata_id_fk", - "tableFrom": "google_drive_paths", - "tableTo": "google_drive_directories", - "columnsFrom": [ - "directory_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "google_drive_paths_file_id_unique": { - "name": "google_drive_paths_file_id_unique", - "nullsNotDistinct": false, - "columns": [ - "file_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive_tokens": { - "name": "google_drive_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.google_drive": { - "name": "google_drive", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "google_drive_token_id": { - "name": "google_drive_token_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk": { - "name": "google_drive_google_drive_token_id_google_drive_tokens_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "google_drive_tokens", - "columnsFrom": [ - "google_drive_token_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "google_drive_user_id_users_xata_id_fk": { - "name": "google_drive_user_id_users_xata_id_fk", - "tableFrom": "google_drive", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.loved_tracks": { - "name": "loved_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "loved_tracks_user_id_users_xata_id_fk": { - "name": "loved_tracks_user_id_users_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "loved_tracks_track_id_tracks_xata_id_fk": { - "name": "loved_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "loved_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "loved_tracks_uri_unique": { - "name": "loved_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlist_tracks": { - "name": "playlist_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlist_tracks_playlist_id_playlists_xata_id_fk": { - "name": "playlist_tracks_playlist_id_playlists_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "playlist_tracks_track_id_tracks_xata_id_fk": { - "name": "playlist_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "playlist_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.playlists": { - "name": "playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "picture": { - "name": "picture", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "created_by": { - "name": "created_by", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "playlists_created_by_users_xata_id_fk": { - "name": "playlists_created_by_users_xata_id_fk", - "tableFrom": "playlists", - "tableTo": "users", - "columnsFrom": [ - "created_by" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "playlists_uri_unique": { - "name": "playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.profile_shouts": { - "name": "profile_shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "profile_shouts_user_id_users_xata_id_fk": { - "name": "profile_shouts_user_id_users_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "profile_shouts_shout_id_shouts_xata_id_fk": { - "name": "profile_shouts_shout_id_shouts_xata_id_fk", - "tableFrom": "profile_shouts", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.queue_tracks": { - "name": "queue_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "position": { - "name": "position", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "file_uri": { - "name": "file_uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": true, - "default": 0 - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "queue_tracks_user_id_users_xata_id_fk": { - "name": "queue_tracks_user_id_users_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "queue_tracks_track_id_tracks_xata_id_fk": { - "name": "queue_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "queue_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.scrobbles": { - "name": "scrobbles", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "timestamp": { - "name": "timestamp", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "scrobbles_user_id_users_xata_id_fk": { - "name": "scrobbles_user_id_users_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_track_id_tracks_xata_id_fk": { - "name": "scrobbles_track_id_tracks_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_album_id_albums_xata_id_fk": { - "name": "scrobbles_album_id_albums_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "scrobbles_artist_id_artists_xata_id_fk": { - "name": "scrobbles_artist_id_artists_xata_id_fk", - "tableFrom": "scrobbles", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "scrobbles_uri_unique": { - "name": "scrobbles_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_likes": { - "name": "shout_likes", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "shout_likes_user_id_users_xata_id_fk": { - "name": "shout_likes_user_id_users_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_likes_shout_id_shouts_xata_id_fk": { - "name": "shout_likes_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_likes", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shout_likes_uri_unique": { - "name": "shout_likes_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shout_reports": { - "name": "shout_reports", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "shout_id": { - "name": "shout_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shout_reports_user_id_users_xata_id_fk": { - "name": "shout_reports_user_id_users_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shout_reports_shout_id_shouts_xata_id_fk": { - "name": "shout_reports_shout_id_shouts_xata_id_fk", - "tableFrom": "shout_reports", - "tableTo": "shouts", - "columnsFrom": [ - "shout_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.shouts": { - "name": "shouts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "content": { - "name": "content", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "scrobble_id": { - "name": "scrobble_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "author_id": { - "name": "author_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "parent_id": { - "name": "parent_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "shouts_track_id_tracks_xata_id_fk": { - "name": "shouts_track_id_tracks_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_artist_id_users_xata_id_fk": { - "name": "shouts_artist_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_album_id_albums_xata_id_fk": { - "name": "shouts_album_id_albums_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_scrobble_id_scrobbles_xata_id_fk": { - "name": "shouts_scrobble_id_scrobbles_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "scrobbles", - "columnsFrom": [ - "scrobble_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_author_id_users_xata_id_fk": { - "name": "shouts_author_id_users_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "users", - "columnsFrom": [ - "author_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "shouts_parent_id_shouts_xata_id_fk": { - "name": "shouts_parent_id_shouts_xata_id_fk", - "tableFrom": "shouts", - "tableTo": "shouts", - "columnsFrom": [ - "parent_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "shouts_uri_unique": { - "name": "shouts_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_accounts": { - "name": "spotify_accounts", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "email": { - "name": "email", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "is_beta_user": { - "name": "is_beta_user", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": false - }, - "spotify_app_id": { - "name": "spotify_app_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_accounts_user_id_users_xata_id_fk": { - "name": "spotify_accounts_user_id_users_xata_id_fk", - "tableFrom": "spotify_accounts", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_apps": { - "name": "spotify_apps", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "spotify_app_id": { - "name": "spotify_app_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "spotify_secret": { - "name": "spotify_secret", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "spotify_apps_spotify_app_id_unique": { - "name": "spotify_apps_spotify_app_id_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_app_id" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.spotify_tokens": { - "name": "spotify_tokens", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "access_token": { - "name": "access_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "refresh_token": { - "name": "refresh_token", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "spotify_app_id": { - "name": "spotify_app_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "spotify_tokens_user_id_users_xata_id_fk": { - "name": "spotify_tokens_user_id_users_xata_id_fk", - "tableFrom": "spotify_tokens", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.tracks": { - "name": "tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "title": { - "name": "title", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist": { - "name": "artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_artist": { - "name": "album_artist", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_art": { - "name": "album_art", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album": { - "name": "album", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_number": { - "name": "track_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "duration": { - "name": "duration", - "type": "integer", - "primaryKey": false, - "notNull": true - }, - "mb_id": { - "name": "mb_id", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "youtube_link": { - "name": "youtube_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "spotify_link": { - "name": "spotify_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "apple_music_link": { - "name": "apple_music_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "tidal_link": { - "name": "tidal_link", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "sha256": { - "name": "sha256", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "disc_number": { - "name": "disc_number", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "lyrics": { - "name": "lyrics", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "composer": { - "name": "composer", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "genre": { - "name": "genre", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "label": { - "name": "label", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "copyright_message": { - "name": "copyright_message", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "album_uri": { - "name": "album_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "artist_uri": { - "name": "artist_uri", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "tracks_mb_id_unique": { - "name": "tracks_mb_id_unique", - "nullsNotDistinct": false, - "columns": [ - "mb_id" - ] - }, - "tracks_youtube_link_unique": { - "name": "tracks_youtube_link_unique", - "nullsNotDistinct": false, - "columns": [ - "youtube_link" - ] - }, - "tracks_spotify_link_unique": { - "name": "tracks_spotify_link_unique", - "nullsNotDistinct": false, - "columns": [ - "spotify_link" - ] - }, - "tracks_apple_music_link_unique": { - "name": "tracks_apple_music_link_unique", - "nullsNotDistinct": false, - "columns": [ - "apple_music_link" - ] - }, - "tracks_tidal_link_unique": { - "name": "tracks_tidal_link_unique", - "nullsNotDistinct": false, - "columns": [ - "tidal_link" - ] - }, - "tracks_sha256_unique": { - "name": "tracks_sha256_unique", - "nullsNotDistinct": false, - "columns": [ - "sha256" - ] - }, - "tracks_uri_unique": { - "name": "tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_albums": { - "name": "user_albums", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "album_id": { - "name": "album_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_albums_user_id_users_xata_id_fk": { - "name": "user_albums_user_id_users_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_albums_album_id_albums_xata_id_fk": { - "name": "user_albums_album_id_albums_xata_id_fk", - "tableFrom": "user_albums", - "tableTo": "albums", - "columnsFrom": [ - "album_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_albums_uri_unique": { - "name": "user_albums_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_artists": { - "name": "user_artists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "artist_id": { - "name": "artist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - } - }, - "indexes": {}, - "foreignKeys": { - "user_artists_user_id_users_xata_id_fk": { - "name": "user_artists_user_id_users_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_artists_artist_id_artists_xata_id_fk": { - "name": "user_artists_artist_id_artists_xata_id_fk", - "tableFrom": "user_artists", - "tableTo": "artists", - "columnsFrom": [ - "artist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_artists_uri_unique": { - "name": "user_artists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_playlists": { - "name": "user_playlists", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "playlist_id": { - "name": "playlist_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_playlists_user_id_users_xata_id_fk": { - "name": "user_playlists_user_id_users_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_playlists_playlist_id_playlists_xata_id_fk": { - "name": "user_playlists_playlist_id_playlists_xata_id_fk", - "tableFrom": "user_playlists", - "tableTo": "playlists", - "columnsFrom": [ - "playlist_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_playlists_uri_unique": { - "name": "user_playlists_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.user_tracks": { - "name": "user_tracks", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "track_id": { - "name": "track_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - }, - "uri": { - "name": "uri", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "scrobbles": { - "name": "scrobbles", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": { - "user_tracks_user_id_users_xata_id_fk": { - "name": "user_tracks_user_id_users_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - }, - "user_tracks_track_id_tracks_xata_id_fk": { - "name": "user_tracks_track_id_tracks_xata_id_fk", - "tableFrom": "user_tracks", - "tableTo": "tracks", - "columnsFrom": [ - "track_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "user_tracks_uri_unique": { - "name": "user_tracks_uri_unique", - "nullsNotDistinct": false, - "columns": [ - "uri" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.users": { - "name": "users", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "did": { - "name": "did", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "display_name": { - "name": "display_name", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "handle": { - "name": "handle", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "avatar": { - "name": "avatar", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_version": { - "name": "xata_version", - "type": "integer", - "primaryKey": false, - "notNull": false - } - }, - "indexes": {}, - "foreignKeys": {}, - "compositePrimaryKeys": {}, - "uniqueConstraints": { - "users_did_unique": { - "name": "users_did_unique", - "nullsNotDistinct": false, - "columns": [ - "did" - ] - }, - "users_handle_unique": { - "name": "users_handle_unique", - "nullsNotDistinct": false, - "columns": [ - "handle" - ] - } - }, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - }, - "public.webscrobblers": { - "name": "webscrobblers", - "schema": "", - "columns": { - "xata_id": { - "name": "xata_id", - "type": "text", - "primaryKey": true, - "notNull": true, - "default": "xata_id()" - }, - "name": { - "name": "name", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "uuid": { - "name": "uuid", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "description": { - "name": "description", - "type": "text", - "primaryKey": false, - "notNull": false - }, - "enabled": { - "name": "enabled", - "type": "boolean", - "primaryKey": false, - "notNull": true, - "default": true - }, - "user_id": { - "name": "user_id", - "type": "text", - "primaryKey": false, - "notNull": true - }, - "xata_createdat": { - "name": "xata_createdat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - }, - "xata_updatedat": { - "name": "xata_updatedat", - "type": "timestamp", - "primaryKey": false, - "notNull": true, - "default": "now()" - } - }, - "indexes": {}, - "foreignKeys": { - "webscrobblers_user_id_users_xata_id_fk": { - "name": "webscrobblers_user_id_users_xata_id_fk", - "tableFrom": "webscrobblers", - "tableTo": "users", - "columnsFrom": [ - "user_id" - ], - "columnsTo": [ - "xata_id" - ], - "onDelete": "no action", - "onUpdate": "no action" - } - }, - "compositePrimaryKeys": {}, - "uniqueConstraints": {}, - "policies": {}, - "checkConstraints": {}, - "isRLSEnabled": false - } - }, - "enums": {}, - "schemas": {}, - "sequences": {}, - "roles": {}, - "policies": {}, - "views": {}, - "_meta": { - "columns": {}, - "schemas": {}, - "tables": {} - } -} \ No newline at end of file diff --git a/apps/api/drizzle/meta/_journal.json b/apps/api/drizzle/meta/_journal.json index 26c93873..e0e437f6 100644 --- a/apps/api/drizzle/meta/_journal.json +++ b/apps/api/drizzle/meta/_journal.json @@ -5,50 +5,8 @@ { "idx": 0, "version": "7", - "when": 1759744201158, - "tag": "0000_left_swordsman", - "breakpoints": true - }, - { - "idx": 1, - "version": "7", - "when": 1759746264036, - "tag": "0001_fluffy_epoch", - "breakpoints": true - }, - { - "idx": 2, - "version": "7", - "when": 1759747596050, - "tag": "0002_sweet_randall_flagg", - "breakpoints": true - }, - { - "idx": 3, - "version": "7", - "when": 1759819936859, - "tag": "0003_same_rocket_racer", - "breakpoints": true - }, - { - "idx": 4, - "version": "7", - "when": 1761572359505, - "tag": "0004_long_zzzax", - "breakpoints": true - }, - { - "idx": 5, - "version": "7", - "when": 1761625200550, - "tag": "0005_same_hydra", - "breakpoints": true - }, - { - "idx": 6, - "version": "7", - "when": 1761704981354, - "tag": "0006_slow_bulldozer", + "when": 1766859854227, + "tag": "0000_puzzling_lockheed", "breakpoints": true } ] diff --git a/apps/api/package.json b/apps/api/package.json index 4510ff51..cc68855b 100644 --- a/apps/api/package.json +++ b/apps/api/package.json @@ -26,7 +26,8 @@ "format": "biome format src", "lint": "biome lint src", "feed": "tsx ./src/scripts/feed.ts", - "dedup": "bun ./src/scripts/dedup.ts" + "dedup": "bun ./src/scripts/dedup.ts", + "seed:feed": "tsx ./src/scripts/seed-feed.ts" }, "dependencies": { "@atproto/api": "^0.13.31", diff --git a/apps/api/src/scripts/seed-feed.ts b/apps/api/src/scripts/seed-feed.ts new file mode 100644 index 00000000..e69de29b -- 2.51.2