// using System; using System.Collections.Generic; using Iceshrimp.Backend.Core.Database; using Iceshrimp.Backend.Core.Database.Tables; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Storage.ValueConversion; using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata; #nullable disable namespace Iceshrimp.Backend.Core.Database.Migrations { [DbContext(typeof(DatabaseContext))] partial class DatabaseContextModelSnapshot : ModelSnapshot { protected override void BuildModel(ModelBuilder modelBuilder) { #pragma warning disable 612, 618 modelBuilder .HasAnnotation("ProductVersion", "8.0.10") .HasAnnotation("Relational:MaxIdentifierLength", 63); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "antenna_src_enum", new[] { "home", "all", "users", "list", "group", "instances" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "filter_action_enum", new[] { "warn", "hide" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "filter_context_enum", new[] { "home", "lists", "threads", "notifications", "accounts", "public" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "job_status", new[] { "queued", "delayed", "running", "completed", "failed" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "marker_type_enum", new[] { "home", "notifications" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "note_visibility_enum", new[] { "public", "home", "followers", "specified" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "notification_type_enum", new[] { "follow", "mention", "reply", "renote", "quote", "like", "reaction", "pollVote", "pollEnded", "receiveFollowRequest", "followRequestAccepted", "groupInvited", "app", "edit", "bite" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "page_visibility_enum", new[] { "public", "followers", "specified" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "push_subscription_policy_enum", new[] { "all", "followed", "follower", "none" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "relay_status_enum", new[] { "requesting", "accepted", "rejected" }); NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "user_profile_ffvisibility_enum", new[] { "public", "followers", "private" }); NpgsqlModelBuilderExtensions.HasPostgresExtension(modelBuilder, "pg_trgm"); NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.AbuseUserReport", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("AssigneeId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("assigneeId"); b.Property("Comment") .IsRequired() .HasMaxLength(2048) .HasColumnType("character varying(2048)") .HasColumnName("comment"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the AbuseUserReport."); b.Property("Forwarded") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("forwarded"); b.Property("ReporterHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("reporterHost") .HasComment("[Denormalized]"); b.Property("ReporterId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("reporterId"); b.Property("Resolved") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("resolved"); b.Property("TargetUserHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("targetUserHost") .HasComment("[Denormalized]"); b.Property("TargetUserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("targetUserId"); b.HasKey("Id"); b.HasIndex("AssigneeId"); b.HasIndex("CreatedAt"); b.HasIndex("ReporterHost"); b.HasIndex("ReporterId"); b.HasIndex("Resolved"); b.HasIndex("TargetUserHost"); b.HasIndex("TargetUserId"); b.ToTable("abuse_user_report"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.AllowedInstance", b => { b.Property("Host") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("host"); b.Property("IsImported") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("imported"); b.HasKey("Host"); b.ToTable("allowed_instance"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Announcement", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Announcement."); b.Property("ImageUrl") .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("imageUrl"); b.Property("IsGoodNews") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isGoodNews"); b.Property("ShowPopup") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("showPopup"); b.Property("Text") .IsRequired() .HasMaxLength(8192) .HasColumnType("character varying(8192)") .HasColumnName("text"); b.Property("Title") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("title"); b.Property("UpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("updatedAt") .HasComment("The updated date of the Announcement."); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.ToTable("announcement"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.AnnouncementRead", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("AnnouncementId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("announcementId"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the AnnouncementRead."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("AnnouncementId"); b.HasIndex("UserId"); b.HasIndex("UserId", "AnnouncementId") .IsUnique(); b.ToTable("announcement_read"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Antenna", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CaseSensitive") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("caseSensitive"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Antenna."); b.Property>>("ExcludeKeywords") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("excludeKeywords") .HasDefaultValueSql("'[]'::jsonb"); b.Property("Expression") .HasMaxLength(2048) .HasColumnType("character varying(2048)") .HasColumnName("expression"); b.Property>("Instances") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("instances") .HasDefaultValueSql("'[]'::jsonb"); b.Property>>("Keywords") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("keywords") .HasDefaultValueSql("'[]'::jsonb"); b.Property("Name") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name") .HasComment("The name of the Antenna."); b.Property("Notify") .HasColumnType("boolean") .HasColumnName("notify"); b.Property("Source") .HasColumnType("antenna_src_enum") .HasColumnName("src"); b.Property("UserGroupMemberId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userGroupMemberId"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The owner ID."); b.Property("UserListId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userListId"); b.Property>("Users") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(1024)[]") .HasColumnName("users") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("WithFile") .HasColumnType("boolean") .HasColumnName("withFile"); b.Property("WithReplies") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("withReplies"); b.HasKey("Id"); b.HasIndex("UserGroupMemberId"); b.HasIndex("UserId"); b.HasIndex("UserListId"); b.ToTable("antenna"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.AttestationChallenge", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("UserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.Property("Challenge") .IsRequired() .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("challenge") .HasComment("Hex-encoded sha256 hash of the challenge."); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The date challenge was created for expiry purposes."); b.Property("RegistrationChallenge") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("registrationChallenge") .HasComment("Indicates that the challenge is only for registration purposes if true to prevent the challenge for being used as authentication."); b.HasKey("Id", "UserId"); b.HasIndex("Challenge"); b.HasIndex("UserId"); b.ToTable("attestation_challenge"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Bite", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.Property("TargetBiteId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("targetBiteId"); b.Property("TargetNoteId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("targetNoteId"); b.Property("TargetUserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("targetUserId"); b.Property("Uri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("uri"); b.Property("UserHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("userHost"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("TargetBiteId"); b.HasIndex("TargetNoteId"); b.HasIndex("TargetUserId"); b.HasIndex("Uri"); b.HasIndex("UserHost"); b.HasIndex("UserId"); b.ToTable("bite"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.BlockedInstance", b => { b.Property("Host") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("host"); b.Property("IsImported") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("imported"); b.Property("Reason") .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("reason"); b.HasKey("Host"); b.ToTable("blocked_instance"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Blocking", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("BlockeeId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("blockeeId") .HasComment("The blockee user ID."); b.Property("BlockerId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("blockerId") .HasComment("The blocker user ID."); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Blocking."); b.HasKey("Id"); b.HasIndex("BlockeeId"); b.HasIndex("BlockerId"); b.HasIndex("CreatedAt"); b.HasIndex("BlockerId", "BlockeeId") .IsUnique(); b.ToTable("blocking"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.CacheEntry", b => { b.Property("Key") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("key"); b.Property("Expiry") .HasColumnType("timestamp with time zone") .HasColumnName("expiry"); b.Property("Ttl") .HasColumnType("interval") .HasColumnName("ttl"); b.Property("Value") .HasColumnType("text") .HasColumnName("value"); b.HasKey("Key"); b.HasIndex("Expiry"); b.ToTable("cache_store"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Channel", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("BannerId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("bannerId") .HasComment("The ID of banner Channel."); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Channel."); b.Property("Description") .HasMaxLength(2048) .HasColumnType("character varying(2048)") .HasColumnName("description") .HasComment("The description of the Channel."); b.Property("LastNotedAt") .HasColumnType("timestamp with time zone") .HasColumnName("lastNotedAt"); b.Property("Name") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name") .HasComment("The name of the Channel."); b.Property("NotesCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("notesCount") .HasComment("The count of notes."); b.Property("UserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The owner ID."); b.Property("UsersCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("usersCount") .HasComment("The count of users."); b.HasKey("Id"); b.HasIndex("BannerId"); b.HasIndex("CreatedAt"); b.HasIndex("LastNotedAt"); b.HasIndex("NotesCount"); b.HasIndex("UserId"); b.HasIndex("UsersCount"); b.ToTable("channel"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.ChannelFollowing", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the ChannelFollowing."); b.Property("FolloweeId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("followeeId") .HasComment("The followee channel ID."); b.Property("FollowerId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("followerId") .HasComment("The follower user ID."); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("FolloweeId"); b.HasIndex("FollowerId"); b.HasIndex("FollowerId", "FolloweeId") .IsUnique(); b.ToTable("channel_following"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.ChannelNotePin", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("ChannelId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("channelId"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the ChannelNotePin."); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.HasKey("Id"); b.HasIndex("ChannelId"); b.HasIndex("NoteId"); b.HasIndex("ChannelId", "NoteId") .IsUnique(); b.ToTable("channel_note_pin"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Clip", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Clip."); b.Property("Description") .HasMaxLength(2048) .HasColumnType("character varying(2048)") .HasColumnName("description") .HasComment("The description of the Clip."); b.Property("IsPublic") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isPublic"); b.Property("Name") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name") .HasComment("The name of the Clip."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The owner ID."); b.HasKey("Id"); b.HasIndex("UserId"); b.ToTable("clip"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.ClipNote", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("ClipId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("clipId") .HasComment("The clip ID."); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId") .HasComment("The note ID."); b.HasKey("Id"); b.HasIndex("ClipId"); b.HasIndex("NoteId"); b.HasIndex("NoteId", "ClipId") .IsUnique(); b.ToTable("clip_note"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.DriveFile", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("AccessKey") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("accessKey"); b.Property("Blurhash") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("blurhash") .HasComment("The BlurHash string."); b.Property("Comment") .HasColumnType("text") .HasColumnName("comment") .HasComment("The comment of the DriveFile."); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the DriveFile."); b.Property("FolderId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("folderId") .HasComment("The parent folder ID. If null, it means the DriveFile is located in root."); b.Property("IsLink") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isLink") .HasComment("Whether the DriveFile is direct link to remote server."); b.Property("IsSensitive") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isSensitive") .HasComment("Whether the DriveFile is NSFW."); b.Property("Name") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("name") .HasComment("The file name of the DriveFile."); b.Property("Properties") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("properties") .HasDefaultValueSql("'{}'::jsonb") .HasComment("The any properties of the DriveFile. For example, it includes image width/height."); b.Property("PublicAccessKey") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("webpublicAccessKey"); b.Property("PublicMimeType") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("webpublicType"); b.Property("PublicUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("webpublicUrl") .HasComment("The URL of the webpublic of the DriveFile."); b.Property>("RequestHeaders") .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("requestHeaders") .HasDefaultValueSql("'{}'::jsonb"); b.Property("RequestIp") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("requestIp"); b.Property("Sha256") .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("sha256") .HasComment("The SHA256 hash of the DriveFile."); b.Property("Size") .HasColumnType("integer") .HasColumnName("size") .HasComment("The file size (bytes) of the DriveFile."); b.Property("Src") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("src"); b.Property("StoredInternal") .HasColumnType("boolean") .HasColumnName("storedInternal"); b.Property("ThumbnailAccessKey") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("thumbnailAccessKey"); b.Property("ThumbnailMimeType") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("thumbnailType"); b.Property("ThumbnailUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("thumbnailUrl") .HasComment("The URL of the thumbnail of the DriveFile."); b.Property("Type") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("type") .HasComment("The content type (MIME) of the DriveFile."); b.Property("Uri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("uri") .HasComment("The URI of the DriveFile. it will be null when the DriveFile is local."); b.Property("Url") .IsRequired() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("url") .HasComment("The URL of the DriveFile."); b.Property("UserHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("userHost") .HasComment("The host of owner. It will be null if the user in local."); b.Property("UserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The owner ID."); b.HasKey("Id"); b.HasIndex("AccessKey"); b.HasIndex("CreatedAt"); b.HasIndex("FolderId"); b.HasIndex("IsLink"); b.HasIndex("IsSensitive"); b.HasIndex("PublicAccessKey"); b.HasIndex("Sha256"); b.HasIndex("ThumbnailAccessKey"); b.HasIndex("Type"); b.HasIndex("Uri"); b.HasIndex("UserHost"); b.HasIndex("UserId"); b.HasIndex("UserId", "FolderId", "Id"); b.ToTable("drive_file"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.DriveFolder", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the DriveFolder."); b.Property("Name") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name") .HasComment("The name of the DriveFolder."); b.Property("ParentId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("parentId") .HasComment("The parent folder ID. If null, it means the DriveFolder is located in root."); b.Property("UserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The owner ID."); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("ParentId"); b.HasIndex("UserId"); b.ToTable("drive_folder"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Emoji", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property>("Aliases") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(128)[]") .HasColumnName("aliases") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("Category") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("category"); b.Property("Height") .HasColumnType("integer") .HasColumnName("height") .HasComment("Image height"); b.Property("Host") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("host"); b.Property("License") .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("license"); b.Property("Name") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name"); b.Property("OriginalUrl") .IsRequired() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("originalUrl"); b.Property("PublicUrl") .IsRequired() .ValueGeneratedOnAdd() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("publicUrl") .HasDefaultValueSql("''::character varying"); b.Property("Sensitive") .HasColumnType("boolean") .HasColumnName("sensitive"); b.Property("Type") .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("type"); b.Property("UpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("updatedAt"); b.Property("Uri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("uri"); b.Property("Width") .HasColumnType("integer") .HasColumnName("width") .HasComment("Image width"); b.HasKey("Id"); b.HasIndex("Host"); b.HasIndex("Name"); b.HasIndex("Name", "Host") .IsUnique(); b.ToTable("emoji"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Filter", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("bigint") .HasColumnName("id"); NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); b.Property("Action") .HasColumnType("filter_action_enum") .HasColumnName("action"); b.Property>("Contexts") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("filter_context_enum[]") .HasColumnName("contexts") .HasDefaultValueSql("'{}'::public.filter_context_enum[]"); b.Property("Expiry") .HasColumnType("timestamp with time zone") .HasColumnName("expiry"); b.Property>("Keywords") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("text[]") .HasColumnName("keywords") .HasDefaultValueSql("'{}'::varchar[]"); b.Property("Name") .IsRequired() .HasColumnType("text") .HasColumnName("name"); b.Property("user_id") .HasColumnType("character varying(32)"); b.HasKey("Id"); b.HasIndex("user_id"); b.ToTable("filter"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.FollowRequest", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the FollowRequest."); b.Property("FolloweeHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followeeHost") .HasComment("[Denormalized]"); b.Property("FolloweeId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("followeeId") .HasComment("The followee user ID."); b.Property("FolloweeInbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followeeInbox") .HasComment("[Denormalized]"); b.Property("FolloweeSharedInbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followeeSharedInbox") .HasComment("[Denormalized]"); b.Property("FollowerHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followerHost") .HasComment("[Denormalized]"); b.Property("FollowerId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("followerId") .HasComment("The follower user ID."); b.Property("FollowerInbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followerInbox") .HasComment("[Denormalized]"); b.Property("FollowerSharedInbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followerSharedInbox") .HasComment("[Denormalized]"); b.Property("RelationshipId") .HasColumnType("uuid") .HasColumnName("relationshipId"); b.Property("RequestId") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("requestId") .HasComment("id of Follow Activity."); b.HasKey("Id"); b.HasIndex("FolloweeId"); b.HasIndex("FollowerId"); b.HasIndex("FollowerId", "FolloweeId") .IsUnique(); b.ToTable("follow_request"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Following", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Following."); b.Property("FolloweeHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followeeHost") .HasComment("[Denormalized]"); b.Property("FolloweeId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("followeeId") .HasComment("The followee user ID."); b.Property("FolloweeInbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followeeInbox") .HasComment("[Denormalized]"); b.Property("FolloweeSharedInbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followeeSharedInbox") .HasComment("[Denormalized]"); b.Property("FollowerHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followerHost") .HasComment("[Denormalized]"); b.Property("FollowerId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("followerId") .HasComment("The follower user ID."); b.Property("FollowerInbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followerInbox") .HasComment("[Denormalized]"); b.Property("FollowerSharedInbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followerSharedInbox") .HasComment("[Denormalized]"); b.Property("RelationshipId") .HasColumnType("uuid") .HasColumnName("relationshipId"); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("FolloweeHost"); b.HasIndex("FolloweeId"); b.HasIndex("FollowerHost"); b.HasIndex("FollowerId"); b.HasIndex("FollowerId", "FolloweeId") .IsUnique(); b.ToTable("following"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.GalleryLike", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.Property("PostId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("postId"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("PostId"); b.HasIndex("UserId"); b.HasIndex("UserId", "PostId") .IsUnique(); b.ToTable("gallery_like"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.GalleryPost", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the GalleryPost."); b.Property("Description") .HasMaxLength(2048) .HasColumnType("character varying(2048)") .HasColumnName("description"); b.Property>("FileIds") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(32)[]") .HasColumnName("fileIds") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("IsSensitive") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isSensitive") .HasComment("Whether the post is sensitive."); b.Property("LikedCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("likedCount"); b.Property>("Tags") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(128)[]") .HasColumnName("tags") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("Title") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("title"); b.Property("UpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("updatedAt") .HasComment("The updated date of the GalleryPost."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The ID of author."); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("FileIds"); b.HasIndex("IsSensitive"); b.HasIndex("LikedCount"); b.HasIndex("Tags"); b.HasIndex("UpdatedAt"); b.HasIndex("UserId"); b.ToTable("gallery_post"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Hashtag", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("Name") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name"); b.HasKey("Id"); b.HasIndex("Name") .IsUnique(); b.ToTable("hashtag"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Instance", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CaughtAt") .HasColumnType("timestamp with time zone") .HasColumnName("caughtAt") .HasComment("The caught date of the Instance."); b.Property("Description") .HasMaxLength(4096) .HasColumnType("character varying(4096)") .HasColumnName("description"); b.Property("FaviconUrl") .HasMaxLength(4096) .HasColumnType("character varying(4096)") .HasColumnName("faviconUrl"); b.Property("Host") .IsRequired() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("host") .HasComment("The host of the Instance."); b.Property("IconUrl") .HasMaxLength(4096) .HasColumnType("character varying(4096)") .HasColumnName("iconUrl"); b.Property("IncomingFollows") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("incomingFollows"); b.Property("InfoUpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("infoUpdatedAt"); b.Property("IsNotResponding") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isNotResponding"); b.Property("IsSuspended") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isSuspended"); b.Property("LastCommunicatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("lastCommunicatedAt"); b.Property("LatestRequestReceivedAt") .HasColumnType("timestamp with time zone") .HasColumnName("latestRequestReceivedAt"); b.Property("LatestRequestSentAt") .HasColumnType("timestamp with time zone") .HasColumnName("latestRequestSentAt"); b.Property("LatestStatus") .HasColumnType("integer") .HasColumnName("latestStatus"); b.Property("MaintainerEmail") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("maintainerEmail"); b.Property("MaintainerName") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("maintainerName"); b.Property("Name") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("name"); b.Property("NotesCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("notesCount") .HasComment("The count of the notes of the Instance."); b.Property("OpenRegistrations") .HasColumnType("boolean") .HasColumnName("openRegistrations"); b.Property("OutgoingFollows") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("outgoingFollows"); b.Property("SoftwareName") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("softwareName") .HasComment("The software of the Instance."); b.Property("SoftwareVersion") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("softwareVersion"); b.Property("ThemeColor") .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("themeColor"); b.Property("UsersCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("usersCount") .HasComment("The count of the users of the Instance."); b.HasKey("Id"); b.HasIndex("CaughtAt"); b.HasIndex("Host") .IsUnique(); b.HasIndex("IncomingFollows"); b.HasIndex("IsSuspended"); b.HasIndex("OutgoingFollows"); b.ToTable("instance"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Job", b => { b.Property("Id") .HasColumnType("uuid") .HasColumnName("id"); b.Property("Data") .IsRequired() .HasColumnType("text") .HasColumnName("data"); b.Property("DelayedUntil") .HasColumnType("timestamp with time zone") .HasColumnName("delayed_until"); b.Property("Exception") .HasColumnType("text") .HasColumnName("exception"); b.Property("ExceptionMessage") .HasColumnType("text") .HasColumnName("exception_message"); b.Property("ExceptionSource") .HasColumnType("text") .HasColumnName("exception_source"); b.Property("FinishedAt") .HasColumnType("timestamp with time zone") .HasColumnName("finished_at"); b.Property("Mutex") .HasColumnType("text") .HasColumnName("mutex"); b.Property("Queue") .IsRequired() .HasColumnType("text") .HasColumnName("queue"); b.Property("QueuedAt") .ValueGeneratedOnAdd() .HasColumnType("timestamp with time zone") .HasColumnName("queued_at") .HasDefaultValueSql("now()"); b.Property("RetryCount") .HasColumnType("integer") .HasColumnName("retry_count"); b.Property("StackTrace") .HasColumnType("text") .HasColumnName("stack_trace"); b.Property("StartedAt") .HasColumnType("timestamp with time zone") .HasColumnName("started_at"); b.Property("Status") .ValueGeneratedOnAdd() .HasColumnType("job_status") .HasDefaultValue(Job.JobStatus.Queued) .HasColumnName("status"); b.HasKey("Id"); b.HasIndex("DelayedUntil"); b.HasIndex("FinishedAt"); b.HasIndex("Mutex") .IsUnique(); b.HasIndex("Queue"); b.HasIndex("Status"); b.ToTable("jobs"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Marker", b => { b.Property("UserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.Property("Type") .HasMaxLength(32) .HasColumnType("marker_type_enum") .HasColumnName("type"); b.Property("LastUpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("lastUpdated"); b.Property("Position") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("position"); b.Property("Version") .IsConcurrencyToken() .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("version"); b.HasKey("UserId", "Type"); b.HasIndex("UserId"); b.ToTable("marker"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.MessagingMessage", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the MessagingMessage."); b.Property("FileId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("fileId"); b.Property("GroupId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("groupId") .HasComment("The recipient group ID."); b.Property("IsRead") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isRead"); b.Property>("Reads") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(32)[]") .HasColumnName("reads") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("RecipientId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("recipientId") .HasComment("The recipient user ID."); b.Property("Text") .HasMaxLength(4096) .HasColumnType("character varying(4096)") .HasColumnName("text"); b.Property("Uri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("uri"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The sender user ID."); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("FileId"); b.HasIndex("GroupId"); b.HasIndex("RecipientId"); b.HasIndex("UserId"); b.ToTable("messaging_message"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Meta", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property>("AllowedHosts") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("allowedHosts") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("AutofollowedAccount") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("autofollowedAccount"); b.Property("BackgroundImageUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("backgroundImageUrl"); b.Property("BannerUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("bannerUrl"); b.Property>("BlockedHosts") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("blockedHosts") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("CacheRemoteFiles") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("cacheRemoteFiles"); b.Property>("CustomMotd") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("customMOTD") .HasDefaultValueSql("'{}'::character varying[]"); b.Property>("CustomSplashIcons") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("customSplashIcons") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("DeeplAuthKey") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("deeplAuthKey"); b.Property("DeeplIsPro") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("deeplIsPro"); b.Property("DefaultDarkTheme") .HasMaxLength(8192) .HasColumnType("character varying(8192)") .HasColumnName("defaultDarkTheme"); b.Property("DefaultLightTheme") .HasMaxLength(8192) .HasColumnType("character varying(8192)") .HasColumnName("defaultLightTheme"); b.Property("DefaultReaction") .IsRequired() .ValueGeneratedOnAdd() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("defaultReaction") .HasDefaultValueSql("'⭐'::character varying"); b.Property("Description") .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("description"); b.Property("DisableGlobalTimeline") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("disableGlobalTimeline"); b.Property("DisableLocalTimeline") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("disableLocalTimeline"); b.Property("DisableRecommendedTimeline") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("disableRecommendedTimeline"); b.Property("DisableRegistration") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("disableRegistration"); b.Property("DiscordClientId") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("discordClientId"); b.Property("DiscordClientSecret") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("discordClientSecret"); b.Property("DonationLink") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("donationLink"); b.Property("Email") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("email"); b.Property("EmailRequiredForSignup") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("emailRequiredForSignup"); b.Property("EnableActiveEmailValidation") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("enableActiveEmailValidation"); b.Property("EnableDiscordIntegration") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("enableDiscordIntegration"); b.Property("EnableEmail") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("enableEmail"); b.Property("EnableGithubIntegration") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("enableGithubIntegration"); b.Property("EnableHcaptcha") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("enableHcaptcha"); b.Property("EnableIdenticonGeneration") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("enableIdenticonGeneration"); b.Property("EnableIpLogging") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("enableIpLogging"); b.Property("EnableRecaptcha") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("enableRecaptcha"); b.Property("EnableServerMachineStats") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("enableServerMachineStats"); b.Property("ErrorImageUrl") .ValueGeneratedOnAdd() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("errorImageUrl") .HasDefaultValueSql("'/static-assets/badges/error.png'::character varying"); b.Property>("ExperimentalFeatures") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("experimentalFeatures") .HasDefaultValueSql("'{}'::jsonb"); b.Property("FeedbackUrl") .ValueGeneratedOnAdd() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("feedbackUrl") .HasDefaultValueSql("'https://iceshrimp.dev/iceshrimp/iceshrimp/issues/new'::character varying"); b.Property("GithubClientId") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("githubClientId"); b.Property("GithubClientSecret") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("githubClientSecret"); b.Property("HcaptchaSecretKey") .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("hcaptchaSecretKey"); b.Property("HcaptchaSiteKey") .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("hcaptchaSiteKey"); b.Property>("HiddenTags") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("hiddenTags") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("IconUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("iconUrl"); b.Property>("Langs") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(64)[]") .HasColumnName("langs") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("LibreTranslateApiKey") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("libreTranslateApiKey"); b.Property("LibreTranslateApiUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("libreTranslateApiUrl"); b.Property("LocalDriveCapacityMb") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(1024) .HasColumnName("localDriveCapacityMb") .HasComment("Drive capacity of a local user (MB)"); b.Property("LogoImageUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("logoImageUrl"); b.Property("MaintainerEmail") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("maintainerEmail"); b.Property("MaintainerName") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("maintainerName"); b.Property("MascotImageUrl") .ValueGeneratedOnAdd() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("mascotImageUrl") .HasDefaultValueSql("'/static-assets/badges/info.png'::character varying"); b.Property("Name") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name"); b.Property("ObjectStorageAccessKey") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("objectStorageAccessKey"); b.Property("ObjectStorageBaseUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("objectStorageBaseUrl"); b.Property("ObjectStorageBucket") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("objectStorageBucket"); b.Property("ObjectStorageEndpoint") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("objectStorageEndpoint"); b.Property("ObjectStoragePort") .HasColumnType("integer") .HasColumnName("objectStoragePort"); b.Property("ObjectStoragePrefix") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("objectStoragePrefix"); b.Property("ObjectStorageRegion") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("objectStorageRegion"); b.Property("ObjectStorageS3ForcePathStyle") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("objectStorageS3ForcePathStyle"); b.Property("ObjectStorageSecretKey") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("objectStorageSecretKey"); b.Property("ObjectStorageSetPublicRead") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("objectStorageSetPublicRead"); b.Property("ObjectStorageUseProxy") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("objectStorageUseProxy"); b.Property("ObjectStorageUseSsl") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("objectStorageUseSSL"); b.Property("PinnedClipId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("pinnedClipId"); b.Property>("PinnedPages") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(512)[]") .HasColumnName("pinnedPages") .HasDefaultValueSql("'{/featured,/channels,/explore,/pages,/about-iceshrimp}'::character varying[]"); b.Property>("PinnedUsers") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("pinnedUsers") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("PrivateMode") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("privateMode"); b.Property("RecaptchaSecretKey") .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("recaptchaSecretKey"); b.Property("RecaptchaSiteKey") .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("recaptchaSiteKey"); b.Property>("RecommendedInstances") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("recommendedInstances") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("RemoteDriveCapacityMb") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(32) .HasColumnName("remoteDriveCapacityMb") .HasComment("Drive capacity of a remote user (MB)"); b.Property("RepositoryUrl") .IsRequired() .ValueGeneratedOnAdd() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("repositoryUrl") .HasDefaultValueSql("'https://iceshrimp.dev/iceshrimp/iceshrimp'::character varying"); b.Property("SecureMode") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("secureMode"); b.Property>("SilencedHosts") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("silencedHosts") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("SmtpHost") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("smtpHost"); b.Property("SmtpPass") .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("smtpPass"); b.Property("SmtpPort") .HasColumnType("integer") .HasColumnName("smtpPort"); b.Property("SmtpSecure") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("smtpSecure"); b.Property("SmtpUser") .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("smtpUser"); b.Property("SummalyProxy") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("summalyProxy"); b.Property("SwPrivateKey") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("swPrivateKey"); b.Property("SwPublicKey") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("swPublicKey"); b.Property("ThemeColor") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("themeColor"); b.Property("ToSurl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("ToSUrl"); b.Property("UseObjectStorage") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("useObjectStorage"); b.HasKey("Id"); b.ToTable("meta"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.MetaStoreEntry", b => { b.Property("Key") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("key"); b.Property("Value") .HasColumnType("text") .HasColumnName("value"); b.HasKey("Key"); b.HasIndex("Key", "Value"); b.ToTable("meta_store"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.ModerationLog", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the ModerationLog."); b.Property("Info") .IsRequired() .HasColumnType("jsonb") .HasColumnName("info"); b.Property("Type") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("type"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("UserId"); b.ToTable("moderation_log"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Muting", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Muting."); b.Property("ExpiresAt") .HasColumnType("timestamp with time zone") .HasColumnName("expiresAt"); b.Property("MuteeId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("muteeId") .HasComment("The mutee user ID."); b.Property("MuterId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("muterId") .HasComment("The muter user ID."); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("ExpiresAt"); b.HasIndex("MuteeId"); b.HasIndex("MuterId"); b.HasIndex("MuterId", "MuteeId") .IsUnique(); b.ToTable("muting"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Note", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property>("AttachedFileTypes") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("attachedFileTypes") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("ChannelId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("channelId") .HasComment("The ID of source channel."); b.Property("CombinedAltText") .HasColumnType("text") .HasColumnName("combinedAltText"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Note."); b.Property("Cw") .HasColumnType("text") .HasColumnName("cw"); b.Property>("Emojis") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(128)[]") .HasColumnName("emojis") .HasDefaultValueSql("'{}'::character varying[]"); b.Property>("FileIds") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(32)[]") .HasColumnName("fileIds") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("HasPoll") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("hasPoll"); b.Property("LikeCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("likeCount"); b.Property("LocalOnly") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("localOnly"); b.Property("MastoReplyUserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("mastoReplyUserId"); b.Property>("MentionedRemoteUsers") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("mentionedRemoteUsers") .HasDefaultValueSql("'[]'::jsonb"); b.Property>("Mentions") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(32)[]") .HasColumnName("mentions") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("Name") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("name"); b.Property>("Reactions") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("reactions") .HasDefaultValueSql("'{}'::jsonb"); b.Property("RenoteCount") .ValueGeneratedOnAdd() .HasColumnType("smallint") .HasDefaultValue((short)0) .HasColumnName("renoteCount"); b.Property("RenoteId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("renoteId") .HasComment("The ID of renote target."); b.Property("RenoteUri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("renoteUri") .HasComment("The URI of the renote target, if it couldn't be resolved at time of ingestion."); b.Property("RenoteUserHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("renoteUserHost") .HasComment("[Denormalized]"); b.Property("RenoteUserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("renoteUserId") .HasComment("[Denormalized]"); b.Property("RepliesCollection") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("repliesCollection"); b.Property("RepliesCount") .ValueGeneratedOnAdd() .HasColumnType("smallint") .HasDefaultValue((short)0) .HasColumnName("repliesCount"); b.Property("RepliesFetchedAt") .HasColumnType("timestamp with time zone") .HasColumnName("repliesFetchedAt"); b.Property("ReplyId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("replyId") .HasComment("The ID of reply target."); b.Property("ReplyUri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("replyUri") .HasComment("The URI of the reply target, if it couldn't be resolved at time of ingestion."); b.Property("ReplyUserHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("replyUserHost") .HasComment("[Denormalized]"); b.Property("ReplyUserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("replyUserId") .HasComment("[Denormalized]"); b.Property("Score") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("score"); b.Property>("Tags") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(128)[]") .HasColumnName("tags") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("Text") .HasColumnType("text") .HasColumnName("text"); b.Property("ThreadId") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("threadId"); b.Property("UpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("updatedAt") .HasComment("The updated date of the Note."); b.Property("Uri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("uri") .HasComment("The URI of a note. it will be null when the note is local."); b.Property("Url") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("url") .HasComment("The human readable url of a note. it will be null when the note is local."); b.Property("UserHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("userHost") .HasComment("[Denormalized]"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The ID of author."); b.Property("Visibility") .HasColumnType("note_visibility_enum") .HasColumnName("visibility"); b.Property>("VisibleUserIds") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(32)[]") .HasColumnName("visibleUserIds") .HasDefaultValueSql("'{}'::character varying[]"); b.HasKey("Id"); b.HasIndex("AttachedFileTypes"); b.HasIndex("ChannelId"); b.HasIndex("CreatedAt"); b.HasIndex("FileIds"); b.HasIndex("Mentions"); b.HasIndex("RenoteId"); b.HasIndex("RenoteUri"); b.HasIndex("ReplyId"); b.HasIndex("ReplyUri"); b.HasIndex("Tags"); b.HasIndex("ThreadId"); b.HasIndex("Uri") .IsUnique(); b.HasIndex("Url"); b.HasIndex("UserHost"); b.HasIndex("UserId"); b.HasIndex("Visibility"); b.HasIndex("VisibleUserIds"); b.HasIndex("CreatedAt", "UserId"); b.HasIndex("Id", "UserHost"); b.HasIndex("UserId", "Id"); b.HasIndex(new[] { "CombinedAltText" }, "GIN_TRGM_note_combined_alt_text"); NpgsqlIndexBuilderExtensions.HasMethod(b.HasIndex(new[] { "CombinedAltText" }, "GIN_TRGM_note_combined_alt_text"), "gin"); NpgsqlIndexBuilderExtensions.HasOperators(b.HasIndex(new[] { "CombinedAltText" }, "GIN_TRGM_note_combined_alt_text"), new[] { "gin_trgm_ops" }); b.HasIndex(new[] { "Cw" }, "GIN_TRGM_note_cw"); NpgsqlIndexBuilderExtensions.HasMethod(b.HasIndex(new[] { "Cw" }, "GIN_TRGM_note_cw"), "gin"); NpgsqlIndexBuilderExtensions.HasOperators(b.HasIndex(new[] { "Cw" }, "GIN_TRGM_note_cw"), new[] { "gin_trgm_ops" }); b.HasIndex(new[] { "Text" }, "GIN_TRGM_note_text"); NpgsqlIndexBuilderExtensions.HasMethod(b.HasIndex(new[] { "Text" }, "GIN_TRGM_note_text"), "gin"); NpgsqlIndexBuilderExtensions.HasOperators(b.HasIndex(new[] { "Text" }, "GIN_TRGM_note_text"), new[] { "gin_trgm_ops" }); b.HasIndex(new[] { "Mentions" }, "GIN_note_mentions"); NpgsqlIndexBuilderExtensions.HasMethod(b.HasIndex(new[] { "Mentions" }, "GIN_note_mentions"), "gin"); b.HasIndex(new[] { "Tags" }, "GIN_note_tags"); NpgsqlIndexBuilderExtensions.HasMethod(b.HasIndex(new[] { "Tags" }, "GIN_note_tags"), "gin"); b.HasIndex(new[] { "VisibleUserIds" }, "GIN_note_visibleUserIds"); NpgsqlIndexBuilderExtensions.HasMethod(b.HasIndex(new[] { "VisibleUserIds" }, "GIN_note_visibleUserIds"), "gin"); b.ToTable("note"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteBookmark", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the NoteBookmark."); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("NoteId"); b.HasIndex("UserId"); b.HasIndex("UserId", "NoteId") .IsUnique(); b.ToTable("note_bookmark"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteEdit", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("Cw") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("cw"); b.Property>("FileIds") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(32)[]") .HasColumnName("fileIds") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId") .HasComment("The ID of note."); b.Property("Text") .HasColumnType("text") .HasColumnName("text"); b.Property("UpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("updatedAt") .HasComment("The updated date of the Note."); b.HasKey("Id"); b.HasIndex("NoteId"); b.ToTable("note_edit"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteLike", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("NoteId"); b.HasIndex("UserId"); b.HasIndex("UserId", "NoteId") .IsUnique(); b.ToTable("note_like"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteReaction", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the NoteReaction."); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property("Reaction") .IsRequired() .HasMaxLength(260) .HasColumnType("character varying(260)") .HasColumnName("reaction"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("NoteId"); b.HasIndex("UserId"); b.HasIndex("UserId", "NoteId", "Reaction") .IsUnique(); b.ToTable("note_reaction"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteThread", b => { b.Property("Id") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("id"); b.Property("BackfilledAt") .HasColumnType("timestamp with time zone") .HasColumnName("backfilledAt"); b.HasKey("Id"); b.ToTable("note_thread"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteThreadMuting", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.Property("ThreadId") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("threadId"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("ThreadId"); b.HasIndex("UserId"); b.HasIndex("UserId", "ThreadId") .IsUnique(); b.ToTable("note_thread_muting"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteUnread", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("IsMentioned") .HasColumnType("boolean") .HasColumnName("isMentioned"); b.Property("IsSpecified") .HasColumnType("boolean") .HasColumnName("isSpecified"); b.Property("NoteChannelId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteChannelId") .HasComment("[Denormalized]"); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property("NoteUserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteUserId") .HasComment("[Denormalized]"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("IsMentioned"); b.HasIndex("IsSpecified"); b.HasIndex("NoteChannelId"); b.HasIndex("NoteId"); b.HasIndex("NoteUserId"); b.HasIndex("UserId"); b.HasIndex("UserId", "NoteId") .IsUnique(); b.ToTable("note_unread"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteWatching", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the NoteWatching."); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId") .HasComment("The target Note ID."); b.Property("NoteUserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteUserId") .HasComment("[Denormalized]"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The watcher ID."); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("NoteId"); b.HasIndex("NoteUserId"); b.HasIndex("UserId"); b.HasIndex("UserId", "NoteId") .IsUnique(); b.ToTable("note_watching"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Notification", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("AppAccessTokenId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("appAccessTokenId"); b.Property("BiteId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("biteId"); b.Property("Choice") .HasColumnType("integer") .HasColumnName("choice"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Notification."); b.Property("CustomBody") .HasMaxLength(2048) .HasColumnType("character varying(2048)") .HasColumnName("customBody"); b.Property("CustomHeader") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("customHeader"); b.Property("CustomIcon") .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("customIcon"); b.Property("FollowRequestId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("followRequestId"); b.Property("IsRead") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isRead") .HasComment("Whether the notification was read."); b.Property("MastoId") .ValueGeneratedOnAdd() .HasColumnType("bigint") .HasColumnName("masto_id"); NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("MastoId")); b.Property("NoteId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property("NotifieeId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("notifieeId") .HasComment("The ID of recipient user of the Notification."); b.Property("NotifierId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("notifierId") .HasComment("The ID of sender user of the Notification."); b.Property("Reaction") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("reaction"); b.Property("Type") .HasColumnType("notification_type_enum") .HasColumnName("type") .HasComment("The type of the Notification."); b.Property("UserGroupInvitationId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userGroupInvitationId"); b.HasKey("Id"); b.HasIndex("AppAccessTokenId"); b.HasIndex("BiteId"); b.HasIndex("CreatedAt"); b.HasIndex("FollowRequestId"); b.HasIndex("IsRead"); b.HasIndex("MastoId"); b.HasIndex("NoteId"); b.HasIndex("NotifieeId"); b.HasIndex("NotifierId"); b.HasIndex("Type"); b.HasIndex("UserGroupInvitationId"); b.ToTable("notification"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.OauthApp", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("ClientId") .IsRequired() .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("clientId") .HasComment("The client id of the OAuth application"); b.Property("ClientSecret") .IsRequired() .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("clientSecret") .HasComment("The client secret of the OAuth application"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the OAuth application"); b.Property("Name") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name") .HasComment("The name of the OAuth application"); b.Property>("RedirectUris") .IsRequired() .HasColumnType("character varying(512)[]") .HasColumnName("redirectUris") .HasComment("The redirect URIs of the OAuth application"); b.Property>("Scopes") .IsRequired() .HasColumnType("character varying(64)[]") .HasColumnName("scopes") .HasComment("The scopes requested by the OAuth application"); b.Property("Website") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("website") .HasComment("The website of the OAuth application"); b.HasKey("Id"); b.HasIndex("ClientId") .IsUnique(); b.ToTable("oauth_app"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.OauthToken", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("Active") .HasColumnType("boolean") .HasColumnName("active") .HasComment("Whether or not the token has been activated"); b.Property("AppId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("appId"); b.Property("AutoDetectQuotes") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("autoDetectQuotes") .HasComment("Whether the backend should automatically detect quote posts coming from this client"); b.Property("Code") .IsRequired() .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("code") .HasComment("The auth code for the OAuth token"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the OAuth token"); b.Property("IsPleroma") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isPleroma") .HasComment("Whether Pleroma or Akkoma specific behavior should be enabled for this client"); b.Property("LastActiveDate") .HasColumnType("timestamp with time zone") .HasColumnName("lastActiveDate"); b.Property("RedirectUri") .IsRequired() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("redirectUri") .HasComment("The redirect URI of the OAuth token"); b.Property>("Scopes") .IsRequired() .HasColumnType("character varying(64)[]") .HasColumnName("scopes") .HasComment("The scopes requested by the OAuth token"); b.Property("SupportsHtmlFormatting") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("supportsHtmlFormatting") .HasComment("Whether the client supports HTML inline formatting (bold, italic, strikethrough, ...)"); b.Property("Token") .IsRequired() .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("token") .HasComment("The OAuth token"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("AppId"); b.HasIndex("Code"); b.HasIndex("Token"); b.HasIndex("UserId"); b.ToTable("oauth_token"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Page", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("AlignCenter") .HasColumnType("boolean") .HasColumnName("alignCenter"); b.Property("Content") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("content") .HasDefaultValueSql("'[]'::jsonb"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Page."); b.Property("EyeCatchingImageId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("eyeCatchingImageId"); b.Property("Font") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("font"); b.Property("HideTitleWhenPinned") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("hideTitleWhenPinned"); b.Property("IsPublic") .HasColumnType("boolean") .HasColumnName("isPublic"); b.Property("LikedCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("likedCount"); b.Property("Name") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("name"); b.Property("Script") .IsRequired() .ValueGeneratedOnAdd() .HasMaxLength(16384) .HasColumnType("character varying(16384)") .HasColumnName("script") .HasDefaultValueSql("''::character varying"); b.Property("Summary") .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("summary"); b.Property("Title") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("title"); b.Property("UpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("updatedAt") .HasComment("The updated date of the Page."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The ID of author."); b.Property("Variables") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("variables") .HasDefaultValueSql("'[]'::jsonb"); b.Property("Visibility") .HasColumnType("page_visibility_enum") .HasColumnName("visibility"); b.Property>("VisibleUserIds") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(32)[]") .HasColumnName("visibleUserIds") .HasDefaultValueSql("'{}'::character varying[]"); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("EyeCatchingImageId"); b.HasIndex("Name"); b.HasIndex("UpdatedAt"); b.HasIndex("UserId"); b.HasIndex("VisibleUserIds"); b.HasIndex("UserId", "Name") .IsUnique(); b.ToTable("page"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PageLike", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.Property("PageId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("pageId"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("PageId"); b.HasIndex("UserId"); b.HasIndex("UserId", "PageId") .IsUnique(); b.ToTable("page_like"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PasswordResetRequest", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.Property("Token") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("token"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("Token") .IsUnique(); b.HasIndex("UserId"); b.ToTable("password_reset_request"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PluginStoreEntry", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("uuid") .HasColumnName("id"); b.Property("Data") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("data") .HasDefaultValueSql("'{}'::jsonb") .HasComment("The plugin-specific data object"); b.Property("Name") .IsRequired() .HasColumnType("text") .HasColumnName("name"); b.HasKey("Id"); b.HasIndex("Id"); b.ToTable("plugin_store"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PolicyConfiguration", b => { b.Property("Name") .HasColumnType("text") .HasColumnName("name"); b.Property("Data") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("data") .HasDefaultValueSql("'{}'::jsonb") .HasComment("The plugin-specific data object"); b.HasKey("Name"); b.ToTable("policy_configuration"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Poll", b => { b.Property("NoteId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property>("Choices") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(256)[]") .HasColumnName("choices") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("ExpiresAt") .HasColumnType("timestamp with time zone") .HasColumnName("expiresAt"); b.Property("Multiple") .HasColumnType("boolean") .HasColumnName("multiple"); b.Property("NoteVisibility") .HasColumnType("note_visibility_enum") .HasColumnName("noteVisibility") .HasComment("[Denormalized]"); b.Property("UserHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("userHost") .HasComment("[Denormalized]"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("[Denormalized]"); b.Property("VotersCount") .HasColumnType("integer") .HasColumnName("votersCount"); b.Property>("Votes") .IsRequired() .HasColumnType("integer[]") .HasColumnName("votes"); b.HasKey("NoteId"); b.HasIndex("UserHost"); b.HasIndex("UserId"); b.ToTable("poll"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PollVote", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("Choice") .HasColumnType("integer") .HasColumnName("choice"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the PollVote."); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("NoteId"); b.HasIndex("UserId"); b.HasIndex("UserId", "NoteId", "Choice") .IsUnique(); b.ToTable("poll_vote"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PromoNote", b => { b.Property("NoteId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property("ExpiresAt") .HasColumnType("timestamp with time zone") .HasColumnName("expiresAt"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("[Denormalized]"); b.HasKey("NoteId"); b.HasIndex("UserId"); b.ToTable("promo_note"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PromoRead", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the PromoRead."); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("NoteId"); b.HasIndex("UserId"); b.HasIndex("UserId", "NoteId") .IsUnique(); b.ToTable("promo_read"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PushSubscription", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("AuthSecret") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("auth"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.Property("Endpoint") .IsRequired() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("endpoint"); b.Property("OauthTokenId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("oauthTokenId"); b.Property("Policy") .ValueGeneratedOnAdd() .HasColumnType("push_subscription_policy_enum") .HasDefaultValue(PushSubscription.PushPolicy.All) .HasColumnName("policy"); b.Property("PublicKey") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("publickey"); b.Property>("Types") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(32)[]") .HasColumnName("types") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("OauthTokenId") .IsUnique(); b.HasIndex("UserId"); b.ToTable("push_subscription"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.RegistrationInvite", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("Code") .IsRequired() .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("code"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.HasKey("Id"); b.HasIndex("Code") .IsUnique(); b.ToTable("registration_invite"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.RegistryItem", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the RegistryItem."); b.Property("Domain") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("domain"); b.Property("Key") .IsRequired() .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("key") .HasComment("The key of the RegistryItem."); b.Property>("Scope") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(1024)[]") .HasColumnName("scope") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("UpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("updatedAt") .HasComment("The updated date of the RegistryItem."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The owner ID."); b.Property("Value") .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("value") .HasDefaultValueSql("'{}'::jsonb") .HasComment("The value of the RegistryItem."); b.HasKey("Id"); b.HasIndex("Domain"); b.HasIndex("Scope"); b.HasIndex("UserId"); b.ToTable("registry_item"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Relay", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("Inbox") .IsRequired() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("inbox"); b.Property("Status") .HasColumnType("relay_status_enum") .HasColumnName("status"); b.HasKey("Id"); b.HasIndex("Inbox") .IsUnique(); b.ToTable("relay"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.RenoteMuting", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Muting."); b.Property("MuteeId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("muteeId") .HasComment("The mutee user ID."); b.Property("MuterId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("muterId") .HasComment("The muter user ID."); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("MuteeId"); b.HasIndex("MuterId"); b.HasIndex("MuterId", "MuteeId") .IsUnique(); b.ToTable("renote_muting"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Session", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("Active") .HasColumnType("boolean") .HasColumnName("active") .HasComment("Whether or not the token has been activated (i.e. 2fa has been confirmed)"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the OAuth token"); b.Property("LastActiveDate") .HasColumnType("timestamp with time zone") .HasColumnName("lastActiveDate"); b.Property("Token") .IsRequired() .HasMaxLength(64) .HasColumnType("character varying(64)") .HasColumnName("token") .HasComment("The authorization token"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("Token"); b.HasIndex("UserId"); b.ToTable("session"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.SwSubscription", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("AuthSecret") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("auth"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.Property("Endpoint") .IsRequired() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("endpoint"); b.Property("PublicKey") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("publickey"); b.Property("SendReadMessage") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("sendReadMessage"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("UserId"); b.ToTable("sw_subscription"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UsedUsername", b => { b.Property("Username") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("username"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.HasKey("Username"); b.ToTable("used_username"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.User", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property>("AlsoKnownAs") .HasColumnType("text[]") .HasColumnName("alsoKnownAs") .HasComment("URIs the user is known as too"); b.Property("AvatarBlurhash") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("avatarBlurhash") .HasComment("The blurhash of the avatar DriveFile"); b.Property("AvatarId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("avatarId") .HasComment("The ID of avatar DriveFile."); b.Property("AvatarUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("avatarUrl") .HasComment("The URL of the avatar DriveFile"); b.Property("BannerBlurhash") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("bannerBlurhash") .HasComment("The blurhash of the banner DriveFile"); b.Property("BannerId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("bannerId") .HasComment("The ID of banner DriveFile."); b.Property("BannerUrl") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("bannerUrl") .HasComment("The URL of the banner DriveFile"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the User."); b.Property("DisplayName") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name") .HasComment("The name of the User."); b.Property("DriveCapacityOverrideMb") .HasColumnType("integer") .HasColumnName("driveCapacityOverrideMb") .HasComment("Overrides user drive capacity limit"); b.Property>("Emojis") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(128)[]") .HasColumnName("emojis") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("Featured") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("featured") .HasComment("The featured URL of the User. It will be null if the origin of the user is local."); b.Property("FollowersCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("followersCount") .HasComment("The count of followers."); b.Property("FollowersUri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("followersUri") .HasComment("The URI of the user Follower Collection. It will be null if the origin of the user is local."); b.Property("FollowingCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("followingCount") .HasComment("The count of following."); b.Property("Host") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("host") .HasComment("The host of the User. It will be null if the origin of the user is local."); b.Property("Inbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("inbox") .HasComment("The inbox URL of the User. It will be null if the origin of the user is local."); b.Property("IsAdmin") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isAdmin") .HasComment("Whether the User is the admin."); b.Property("IsBot") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isBot") .HasComment("Whether the User is a bot."); b.Property("IsCat") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isCat") .HasComment("Whether the User is a cat."); b.Property("IsDeleted") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isDeleted") .HasComment("Whether the User is deleted."); b.Property("IsExplorable") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("isExplorable") .HasComment("Whether the User is explorable."); b.Property("IsLocked") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isLocked") .HasComment("Whether the User is locked."); b.Property("IsModerator") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isModerator") .HasComment("Whether the User is a moderator."); b.Property("IsRelayActor") .HasColumnType("boolean") .HasColumnName("isRelayActor"); b.Property("IsSilenced") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isSilenced") .HasComment("Whether the User is silenced."); b.Property("IsSuspended") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isSuspended") .HasComment("Whether the User is suspended."); b.Property("IsSystemUser") .HasColumnType("boolean") .HasColumnName("isSystem"); b.Property("LastActiveDate") .HasColumnType("timestamp with time zone") .HasColumnName("lastActiveDate"); b.Property("LastFetchedAt") .HasColumnType("timestamp with time zone") .HasColumnName("lastFetchedAt"); b.Property("MovedToUri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("movedToUri") .HasComment("The URI of the new account of the User"); b.Property("NotesCount") .ValueGeneratedOnAdd() .HasColumnType("integer") .HasDefaultValue(0) .HasColumnName("notesCount") .HasComment("The count of notes."); b.Property("SharedInbox") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("sharedInbox") .HasComment("The sharedInbox URL of the User. It will be null if the origin of the user is local."); b.Property("SpeakAsCat") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("speakAsCat") .HasComment("Whether to speak as a cat if isCat."); b.Property("SplitDomainResolved") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("splitDomainResolved"); b.Property>("Tags") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(128)[]") .HasColumnName("tags") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("UpdatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("updatedAt") .HasComment("The updated date of the User."); b.Property("Uri") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("uri") .HasComment("The URI of the User. It will be null if the origin of the user is local."); b.Property("Username") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("username") .HasComment("The username of the User."); b.Property("UsernameLower") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("usernameLower") .HasComment("The username (lowercased) of the User."); b.HasKey("Id"); b.HasIndex("AvatarId") .IsUnique(); b.HasIndex("BannerId") .IsUnique(); b.HasIndex("CreatedAt"); b.HasIndex("Host"); b.HasIndex("IsAdmin"); b.HasIndex("IsExplorable"); b.HasIndex("IsModerator"); b.HasIndex("IsSuspended"); b.HasIndex("LastActiveDate"); b.HasIndex("Tags"); b.HasIndex("UpdatedAt"); b.HasIndex("Uri"); b.HasIndex("UsernameLower"); b.HasIndex("UsernameLower", "Host") .IsUnique(); b.ToTable("user"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserGroup", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the UserGroup."); b.Property("IsPrivate") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("isPrivate"); b.Property("Name") .IsRequired() .HasMaxLength(256) .HasColumnType("character varying(256)") .HasColumnName("name"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The ID of owner."); b.HasKey("Id"); b.HasIndex("CreatedAt"); b.HasIndex("UserId"); b.ToTable("user_group"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserGroupInvitation", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the UserGroupInvitation."); b.Property("UserGroupId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userGroupId") .HasComment("The group ID."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The user ID."); b.HasKey("Id"); b.HasIndex("UserGroupId"); b.HasIndex("UserId"); b.HasIndex("UserId", "UserGroupId") .IsUnique(); b.ToTable("user_group_invitation"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserGroupMember", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the UserGroupMember."); b.Property("UserGroupId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userGroupId") .HasComment("The group ID."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The user ID."); b.HasKey("Id"); b.HasIndex("UserGroupId"); b.HasIndex("UserId"); b.HasIndex("UserId", "UserGroupId") .IsUnique(); b.ToTable("user_group_member"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserKeypair", b => { b.Property("UserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.Property("PrivateKey") .IsRequired() .HasMaxLength(4096) .HasColumnType("character varying(4096)") .HasColumnName("privateKey"); b.Property("PublicKey") .IsRequired() .HasMaxLength(4096) .HasColumnType("character varying(4096)") .HasColumnName("publicKey"); b.HasKey("UserId"); b.ToTable("user_keypair"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserList", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the UserList."); b.Property("HideFromHomeTl") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("hideFromHomeTl") .HasComment("Whether posts from list members should be hidden from the home timeline."); b.Property("Name") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name") .HasComment("The name of the UserList."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The owner ID."); b.HasKey("Id"); b.HasIndex("UserId"); b.ToTable("user_list"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserListMember", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the UserListMember."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The user ID."); b.Property("UserListId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userListId") .HasComment("The list ID."); b.HasKey("Id"); b.HasIndex("UserId"); b.HasIndex("UserListId"); b.HasIndex("UserId", "UserListId") .IsUnique(); b.ToTable("user_list_member"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserNotePin", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the UserNotePins."); b.Property("NoteId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("noteId"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("NoteId"); b.HasIndex("UserId"); b.HasIndex("UserId", "NoteId") .IsUnique(); b.ToTable("user_note_pin"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserPending", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("Code") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("code"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt"); b.Property("Email") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("email"); b.Property("Password") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("password"); b.Property("Username") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("username"); b.HasKey("Id"); b.HasIndex("Code") .IsUnique(); b.ToTable("user_pending"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserProfile", b => { b.Property("UserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.Property("Birthday") .HasMaxLength(10) .HasColumnType("character(10)") .HasColumnName("birthday") .IsFixedLength() .HasComment("The birthday (YYYY-MM-DD) of the User."); b.Property("Description") .HasMaxLength(2048) .HasColumnType("character varying(2048)") .HasColumnName("description") .HasComment("The description (bio) of the User."); b.Property("FFVisibility") .ValueGeneratedOnAdd() .HasColumnType("user_profile_ffvisibility_enum") .HasDefaultValue(UserProfile.UserProfileFFVisibility.Public) .HasColumnName("ffVisibility"); b.Property("Fields") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("fields") .HasDefaultValueSql("'[]'::jsonb"); b.Property("Lang") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("lang"); b.Property("Location") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("location") .HasComment("The location of the User."); b.Property>("Mentions") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("jsonb") .HasColumnName("mentions") .HasDefaultValueSql("'[]'::jsonb"); b.Property("MentionsResolved") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("mentionsResolved"); b.Property("ModerationNote") .IsRequired() .ValueGeneratedOnAdd() .HasMaxLength(8192) .HasColumnType("character varying(8192)") .HasColumnName("moderationNote") .HasDefaultValueSql("''::character varying"); b.Property("PinnedPageId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("pinnedPageId"); b.Property("Url") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("url") .HasComment("Remote URL of the user."); b.Property("UserHost") .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("userHost") .HasComment("[Denormalized]"); b.HasKey("UserId"); b.HasIndex("PinnedPageId") .IsUnique(); b.HasIndex("UserHost"); b.ToTable("user_profile"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserPublickey", b => { b.Property("UserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.Property("KeyId") .IsRequired() .HasMaxLength(512) .HasColumnType("character varying(512)") .HasColumnName("keyId"); b.Property("KeyPem") .IsRequired() .HasMaxLength(4096) .HasColumnType("character varying(4096)") .HasColumnName("keyPem"); b.HasKey("UserId"); b.HasIndex("KeyId") .IsUnique(); b.ToTable("user_publickey"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserSecurityKey", b => { b.Property("Id") .HasColumnType("character varying") .HasColumnName("id") .HasComment("Variable-length id given to navigator.credentials.get()"); b.Property("LastUsed") .HasColumnType("timestamp with time zone") .HasColumnName("lastUsed") .HasComment("The date of the last time the UserSecurityKey was successfully validated."); b.Property("Name") .IsRequired() .HasMaxLength(30) .HasColumnType("character varying(30)") .HasColumnName("name") .HasComment("User-defined name for this key"); b.Property("PublicKey") .IsRequired() .HasColumnType("character varying") .HasColumnName("publicKey") .HasComment("Variable-length public key used to verify attestations (hex-encoded)."); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.HasKey("Id"); b.HasIndex("PublicKey"); b.HasIndex("UserId"); b.ToTable("user_security_key"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserSettings", b => { b.Property("UserId") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId"); b.Property("AlwaysMarkSensitive") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("alwaysMarkNsfw"); b.Property("AutoAcceptFollowed") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("autoAcceptFollowed"); b.Property("DefaultNoteVisibility") .ValueGeneratedOnAdd() .HasColumnType("note_visibility_enum") .HasDefaultValue(Note.NoteVisibility.Public) .HasColumnName("defaultNoteVisibility"); b.Property("DefaultRenoteVisibility") .ValueGeneratedOnAdd() .HasColumnType("note_visibility_enum") .HasDefaultValue(Note.NoteVisibility.Public) .HasColumnName("defaultRenoteVisibility"); b.Property("Email") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("email"); b.Property("EmailVerified") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("emailVerified"); b.Property("FilterInaccessible") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("filterInaccessible"); b.Property("Password") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("password"); b.Property("PrivateMode") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("privateMode"); b.Property("TwoFactorEnabled") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(false) .HasColumnName("twoFactorEnabled"); b.Property("TwoFactorSecret") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("twoFactorSecret"); b.Property("TwoFactorTempSecret") .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("twoFactorTempSecret"); b.HasKey("UserId"); b.ToTable("user_settings"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Webhook", b => { b.Property("Id") .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("id"); b.Property("Active") .ValueGeneratedOnAdd() .HasColumnType("boolean") .HasDefaultValue(true) .HasColumnName("active"); b.Property("CreatedAt") .HasColumnType("timestamp with time zone") .HasColumnName("createdAt") .HasComment("The created date of the Antenna."); b.Property("LatestSentAt") .HasColumnType("timestamp with time zone") .HasColumnName("latestSentAt"); b.Property("LatestStatus") .HasColumnType("integer") .HasColumnName("latestStatus"); b.Property("Name") .IsRequired() .HasMaxLength(128) .HasColumnType("character varying(128)") .HasColumnName("name") .HasComment("The name of the Antenna."); b.Property>("On") .IsRequired() .ValueGeneratedOnAdd() .HasColumnType("character varying(128)[]") .HasColumnName("on") .HasDefaultValueSql("'{}'::character varying[]"); b.Property("Secret") .IsRequired() .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("secret"); b.Property("Url") .IsRequired() .HasMaxLength(1024) .HasColumnType("character varying(1024)") .HasColumnName("url"); b.Property("UserId") .IsRequired() .HasMaxLength(32) .HasColumnType("character varying(32)") .HasColumnName("userId") .HasComment("The owner ID."); b.HasKey("Id"); b.HasIndex("Active"); b.HasIndex("On"); b.HasIndex("UserId"); b.ToTable("webhook"); }); modelBuilder.Entity("Microsoft.AspNetCore.DataProtection.EntityFrameworkCore.DataProtectionKey", b => { b.Property("Id") .ValueGeneratedOnAdd() .HasColumnType("integer"); NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property("Id")); b.Property("FriendlyName") .HasColumnType("text"); b.Property("Xml") .HasColumnType("text"); b.HasKey("Id"); b.ToTable("data_protection_keys", (string)null); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.AbuseUserReport", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Assignee") .WithMany("AbuseUserReportAssignees") .HasForeignKey("AssigneeId") .OnDelete(DeleteBehavior.SetNull); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Reporter") .WithMany("AbuseUserReportReporters") .HasForeignKey("ReporterId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "TargetUser") .WithMany("AbuseUserReportTargetUsers") .HasForeignKey("TargetUserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Assignee"); b.Navigation("Reporter"); b.Navigation("TargetUser"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.AnnouncementRead", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Announcement", "Announcement") .WithMany("AnnouncementReads") .HasForeignKey("AnnouncementId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("AnnouncementReads") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Announcement"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Antenna", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.UserGroupMember", "UserGroupMember") .WithMany("Antennas") .HasForeignKey("UserGroupMemberId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("Antennas") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.UserList", "UserList") .WithMany("Antennas") .HasForeignKey("UserListId") .OnDelete(DeleteBehavior.Cascade); b.Navigation("User"); b.Navigation("UserGroupMember"); b.Navigation("UserList"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.AttestationChallenge", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("AttestationChallenges") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Bite", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Bite", "TargetBite") .WithMany() .HasForeignKey("TargetBiteId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "TargetNote") .WithMany() .HasForeignKey("TargetNoteId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "TargetUser") .WithMany() .HasForeignKey("TargetUserId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany() .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("TargetBite"); b.Navigation("TargetNote"); b.Navigation("TargetUser"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Blocking", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Blockee") .WithMany("IncomingBlocks") .HasForeignKey("BlockeeId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Blocker") .WithMany("OutgoingBlocks") .HasForeignKey("BlockerId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Blockee"); b.Navigation("Blocker"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Channel", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.DriveFile", "Banner") .WithMany("Channels") .HasForeignKey("BannerId") .OnDelete(DeleteBehavior.SetNull); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("Channels") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.SetNull); b.Navigation("Banner"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.ChannelFollowing", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Channel", "Followee") .WithMany("ChannelFollowings") .HasForeignKey("FolloweeId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Follower") .WithMany("ChannelFollowings") .HasForeignKey("FollowerId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Followee"); b.Navigation("Follower"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.ChannelNotePin", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Channel", "Channel") .WithMany("ChannelNotePins") .HasForeignKey("ChannelId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("ChannelNotePins") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Channel"); b.Navigation("Note"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Clip", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("Clips") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.ClipNote", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Clip", "Clip") .WithMany("ClipNotes") .HasForeignKey("ClipId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("ClipNotes") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Clip"); b.Navigation("Note"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.DriveFile", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.DriveFolder", "Folder") .WithMany("DriveFiles") .HasForeignKey("FolderId") .OnDelete(DeleteBehavior.SetNull); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("DriveFiles") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.SetNull); b.Navigation("Folder"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.DriveFolder", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.DriveFolder", "Parent") .WithMany("InverseParent") .HasForeignKey("ParentId") .OnDelete(DeleteBehavior.SetNull); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("DriveFolders") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade); b.Navigation("Parent"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Filter", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("Filters") .HasForeignKey("user_id") .OnDelete(DeleteBehavior.Cascade); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.FollowRequest", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Followee") .WithMany("IncomingFollowRequests") .HasForeignKey("FolloweeId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Follower") .WithMany("OutgoingFollowRequests") .HasForeignKey("FollowerId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Followee"); b.Navigation("Follower"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Following", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Followee") .WithMany("IncomingFollowRelationships") .HasForeignKey("FolloweeId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Follower") .WithMany("OutgoingFollowRelationships") .HasForeignKey("FollowerId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Followee"); b.Navigation("Follower"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.GalleryLike", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.GalleryPost", "Post") .WithMany("GalleryLikes") .HasForeignKey("PostId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("GalleryLikes") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Post"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.GalleryPost", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("GalleryPosts") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Marker", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("Markers") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.MessagingMessage", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.DriveFile", "File") .WithMany("MessagingMessages") .HasForeignKey("FileId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.UserGroup", "Group") .WithMany("MessagingMessages") .HasForeignKey("GroupId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Recipient") .WithMany("MessagingMessageRecipients") .HasForeignKey("RecipientId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("MessagingMessageUsers") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("File"); b.Navigation("Group"); b.Navigation("Recipient"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.ModerationLog", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("ModerationLogs") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Muting", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Mutee") .WithMany("IncomingMutes") .HasForeignKey("MuteeId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Muter") .WithMany("OutgoingMutes") .HasForeignKey("MuterId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Mutee"); b.Navigation("Muter"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Note", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Channel", "Channel") .WithMany("Notes") .HasForeignKey("ChannelId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Renote") .WithMany("InverseRenote") .HasForeignKey("RenoteId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Reply") .WithMany("InverseReply") .HasForeignKey("ReplyId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.NoteThread", "Thread") .WithMany("Notes") .HasForeignKey("ThreadId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("Notes") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Channel"); b.Navigation("Renote"); b.Navigation("Reply"); b.Navigation("Thread"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteBookmark", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("NoteBookmarks") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("NoteBookmarks") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteEdit", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("NoteEdits") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteLike", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("NoteLikes") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("NoteLikes") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteReaction", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("NoteReactions") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("NoteReactions") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteThreadMuting", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.NoteThread", "Thread") .WithMany("NoteThreadMutings") .HasForeignKey("ThreadId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("NoteThreadMutings") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Thread"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteUnread", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("NoteUnreads") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("NoteUnreads") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteWatching", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("NoteWatchings") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("NoteWatchings") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Notification", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Bite", "Bite") .WithMany() .HasForeignKey("BiteId"); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.FollowRequest", "FollowRequest") .WithMany("Notifications") .HasForeignKey("FollowRequestId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("Notifications") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Notifiee") .WithMany("NotificationNotifiees") .HasForeignKey("NotifieeId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Notifier") .WithMany("NotificationNotifiers") .HasForeignKey("NotifierId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.UserGroupInvitation", "UserGroupInvitation") .WithMany("Notifications") .HasForeignKey("UserGroupInvitationId") .OnDelete(DeleteBehavior.Cascade); b.Navigation("Bite"); b.Navigation("FollowRequest"); b.Navigation("Note"); b.Navigation("Notifiee"); b.Navigation("Notifier"); b.Navigation("UserGroupInvitation"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.OauthToken", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.OauthApp", "App") .WithMany("OauthTokens") .HasForeignKey("AppId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("OauthTokens") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("App"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Page", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.DriveFile", "EyeCatchingImage") .WithMany("Pages") .HasForeignKey("EyeCatchingImageId") .OnDelete(DeleteBehavior.Cascade); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("Pages") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("EyeCatchingImage"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PageLike", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Page", "Page") .WithMany("PageLikes") .HasForeignKey("PageId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("PageLikes") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Page"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PasswordResetRequest", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("PasswordResetRequests") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Poll", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithOne("Poll") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.Poll", "NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PollVote", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("PollVotes") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("PollVotes") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PromoNote", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithOne("PromoNote") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.PromoNote", "NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PromoRead", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("PromoReads") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("PromoReads") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.PushSubscription", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.OauthToken", "OauthToken") .WithOne("PushSubscription") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.PushSubscription", "OauthTokenId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("PushSubscriptions") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("OauthToken"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.RegistryItem", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("RegistryItems") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.RenoteMuting", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Mutee") .WithMany("RenoteMutingMutees") .HasForeignKey("MuteeId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "Muter") .WithMany("RenoteMutingMuters") .HasForeignKey("MuterId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Mutee"); b.Navigation("Muter"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Session", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("Sessions") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.SwSubscription", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("SwSubscriptions") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.User", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.DriveFile", "Avatar") .WithOne("UserAvatar") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.User", "AvatarId") .OnDelete(DeleteBehavior.SetNull); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.DriveFile", "Banner") .WithOne("UserBanner") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.User", "BannerId") .OnDelete(DeleteBehavior.SetNull); b.Navigation("Avatar"); b.Navigation("Banner"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserGroup", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("UserGroups") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserGroupInvitation", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.UserGroup", "UserGroup") .WithMany("UserGroupInvitations") .HasForeignKey("UserGroupId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("UserGroupInvitations") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); b.Navigation("UserGroup"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserGroupMember", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.UserGroup", "UserGroup") .WithMany("UserGroupMembers") .HasForeignKey("UserGroupId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("UserGroupMemberships") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); b.Navigation("UserGroup"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserKeypair", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithOne("UserKeypair") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.UserKeypair", "UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserList", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("UserLists") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserListMember", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("UserListMembers") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.UserList", "UserList") .WithMany("UserListMembers") .HasForeignKey("UserListId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); b.Navigation("UserList"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserNotePin", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Note", "Note") .WithMany("UserNotePins") .HasForeignKey("NoteId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("UserNotePins") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("Note"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserProfile", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.Page", "PinnedPage") .WithOne("UserProfile") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.UserProfile", "PinnedPageId") .OnDelete(DeleteBehavior.SetNull); b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithOne("UserProfile") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.UserProfile", "UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("PinnedPage"); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserPublickey", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithOne("UserPublickey") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.UserPublickey", "UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserSecurityKey", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("UserSecurityKeys") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserSettings", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithOne("UserSettings") .HasForeignKey("Iceshrimp.Backend.Core.Database.Tables.UserSettings", "UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Webhook", b => { b.HasOne("Iceshrimp.Backend.Core.Database.Tables.User", "User") .WithMany("Webhooks") .HasForeignKey("UserId") .OnDelete(DeleteBehavior.Cascade) .IsRequired(); b.Navigation("User"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Announcement", b => { b.Navigation("AnnouncementReads"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Channel", b => { b.Navigation("ChannelFollowings"); b.Navigation("ChannelNotePins"); b.Navigation("Notes"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Clip", b => { b.Navigation("ClipNotes"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.DriveFile", b => { b.Navigation("Channels"); b.Navigation("MessagingMessages"); b.Navigation("Pages"); b.Navigation("UserAvatar"); b.Navigation("UserBanner"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.DriveFolder", b => { b.Navigation("DriveFiles"); b.Navigation("InverseParent"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.FollowRequest", b => { b.Navigation("Notifications"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.GalleryPost", b => { b.Navigation("GalleryLikes"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Note", b => { b.Navigation("ChannelNotePins"); b.Navigation("ClipNotes"); b.Navigation("InverseRenote"); b.Navigation("InverseReply"); b.Navigation("NoteBookmarks"); b.Navigation("NoteEdits"); b.Navigation("NoteLikes"); b.Navigation("NoteReactions"); b.Navigation("NoteUnreads"); b.Navigation("NoteWatchings"); b.Navigation("Notifications"); b.Navigation("Poll"); b.Navigation("PollVotes"); b.Navigation("PromoNote"); b.Navigation("PromoReads"); b.Navigation("UserNotePins"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.NoteThread", b => { b.Navigation("NoteThreadMutings"); b.Navigation("Notes"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.OauthApp", b => { b.Navigation("OauthTokens"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.OauthToken", b => { b.Navigation("PushSubscription"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.Page", b => { b.Navigation("PageLikes"); b.Navigation("UserProfile"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.User", b => { b.Navigation("AbuseUserReportAssignees"); b.Navigation("AbuseUserReportReporters"); b.Navigation("AbuseUserReportTargetUsers"); b.Navigation("AnnouncementReads"); b.Navigation("Antennas"); b.Navigation("AttestationChallenges"); b.Navigation("ChannelFollowings"); b.Navigation("Channels"); b.Navigation("Clips"); b.Navigation("DriveFiles"); b.Navigation("DriveFolders"); b.Navigation("Filters"); b.Navigation("GalleryLikes"); b.Navigation("GalleryPosts"); b.Navigation("IncomingBlocks"); b.Navigation("IncomingFollowRelationships"); b.Navigation("IncomingFollowRequests"); b.Navigation("IncomingMutes"); b.Navigation("Markers"); b.Navigation("MessagingMessageRecipients"); b.Navigation("MessagingMessageUsers"); b.Navigation("ModerationLogs"); b.Navigation("NoteBookmarks"); b.Navigation("NoteLikes"); b.Navigation("NoteReactions"); b.Navigation("NoteThreadMutings"); b.Navigation("NoteUnreads"); b.Navigation("NoteWatchings"); b.Navigation("Notes"); b.Navigation("NotificationNotifiees"); b.Navigation("NotificationNotifiers"); b.Navigation("OauthTokens"); b.Navigation("OutgoingBlocks"); b.Navigation("OutgoingFollowRelationships"); b.Navigation("OutgoingFollowRequests"); b.Navigation("OutgoingMutes"); b.Navigation("PageLikes"); b.Navigation("Pages"); b.Navigation("PasswordResetRequests"); b.Navigation("PollVotes"); b.Navigation("PromoReads"); b.Navigation("PushSubscriptions"); b.Navigation("RegistryItems"); b.Navigation("RenoteMutingMutees"); b.Navigation("RenoteMutingMuters"); b.Navigation("Sessions"); b.Navigation("SwSubscriptions"); b.Navigation("UserGroupInvitations"); b.Navigation("UserGroupMemberships"); b.Navigation("UserGroups"); b.Navigation("UserKeypair"); b.Navigation("UserListMembers"); b.Navigation("UserLists"); b.Navigation("UserNotePins"); b.Navigation("UserProfile"); b.Navigation("UserPublickey"); b.Navigation("UserSecurityKeys"); b.Navigation("UserSettings"); b.Navigation("Webhooks"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserGroup", b => { b.Navigation("MessagingMessages"); b.Navigation("UserGroupInvitations"); b.Navigation("UserGroupMembers"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserGroupInvitation", b => { b.Navigation("Notifications"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserGroupMember", b => { b.Navigation("Antennas"); }); modelBuilder.Entity("Iceshrimp.Backend.Core.Database.Tables.UserList", b => { b.Navigation("Antennas"); b.Navigation("UserListMembers"); }); #pragma warning restore 612, 618 } } }