{
  "formatVersion": 1,
  "database": {
    "version": 3,
    "identityHash": "3cb9aaa3295b9e461cb94dfc708258ed",
    "entities": [
      {
        "tableName": "servers",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `name` TEXT NOT NULL, `currentServerAddressId` TEXT, `currentUserId` TEXT, PRIMARY KEY(`id`))",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "name",
            "columnName": "name",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "currentServerAddressId",
            "columnName": "currentServerAddressId",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "currentUserId",
            "columnName": "currentUserId",
            "affinity": "TEXT",
            "notNull": false
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "id"
          ]
        },
        "indices": [],
        "foreignKeys": []
      },
      {
        "tableName": "serverAddresses",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `serverId` TEXT NOT NULL, `address` TEXT NOT NULL, PRIMARY KEY(`id`), FOREIGN KEY(`serverId`) REFERENCES `servers`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "serverId",
            "columnName": "serverId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "address",
            "columnName": "address",
            "affinity": "TEXT",
            "notNull": true
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "id"
          ]
        },
        "indices": [
          {
            "name": "index_serverAddresses_serverId",
            "unique": false,
            "columnNames": [
              "serverId"
            ],
            "orders": [],
            "createSql": "CREATE INDEX IF NOT EXISTS `index_serverAddresses_serverId` ON `${TABLE_NAME}` (`serverId`)"
          }
        ],
        "foreignKeys": [
          {
            "table": "servers",
            "onDelete": "CASCADE",
            "onUpdate": "NO ACTION",
            "columns": [
              "serverId"
            ],
            "referencedColumns": [
              "id"
            ]
          }
        ]
      },
      {
        "tableName": "users",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `name` TEXT NOT NULL, `serverId` TEXT NOT NULL, `accessToken` TEXT, PRIMARY KEY(`id`), FOREIGN KEY(`serverId`) REFERENCES `servers`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "name",
            "columnName": "name",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "serverId",
            "columnName": "serverId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "accessToken",
            "columnName": "accessToken",
            "affinity": "TEXT",
            "notNull": false
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "id"
          ]
        },
        "indices": [
          {
            "name": "index_users_serverId",
            "unique": false,
            "columnNames": [
              "serverId"
            ],
            "orders": [],
            "createSql": "CREATE INDEX IF NOT EXISTS `index_users_serverId` ON `${TABLE_NAME}` (`serverId`)"
          }
        ],
        "foreignKeys": [
          {
            "table": "servers",
            "onDelete": "CASCADE",
            "onUpdate": "NO ACTION",
            "columns": [
              "serverId"
            ],
            "referencedColumns": [
              "id"
            ]
          }
        ]
      },
      {
        "tableName": "movies",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `serverId` TEXT, `name` TEXT NOT NULL, `originalTitle` TEXT, `overview` TEXT NOT NULL, `runtimeTicks` INTEGER NOT NULL, `premiereDate` INTEGER, `communityRating` REAL, `officialRating` TEXT, `status` TEXT NOT NULL, `productionYear` INTEGER, `endDate` INTEGER, PRIMARY KEY(`id`))",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "serverId",
            "columnName": "serverId",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "name",
            "columnName": "name",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "originalTitle",
            "columnName": "originalTitle",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "overview",
            "columnName": "overview",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "runtimeTicks",
            "columnName": "runtimeTicks",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "premiereDate",
            "columnName": "premiereDate",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "communityRating",
            "columnName": "communityRating",
            "affinity": "REAL",
            "notNull": false
          },
          {
            "fieldPath": "officialRating",
            "columnName": "officialRating",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "status",
            "columnName": "status",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "productionYear",
            "columnName": "productionYear",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "endDate",
            "columnName": "endDate",
            "affinity": "INTEGER",
            "notNull": false
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "id"
          ]
        },
        "indices": [],
        "foreignKeys": []
      },
      {
        "tableName": "shows",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `serverId` TEXT, `name` TEXT NOT NULL, `originalTitle` TEXT, `overview` TEXT NOT NULL, `runtimeTicks` INTEGER NOT NULL, `communityRating` REAL, `officialRating` TEXT, `status` TEXT NOT NULL, `productionYear` INTEGER, `endDate` INTEGER, PRIMARY KEY(`id`))",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "serverId",
            "columnName": "serverId",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "name",
            "columnName": "name",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "originalTitle",
            "columnName": "originalTitle",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "overview",
            "columnName": "overview",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "runtimeTicks",
            "columnName": "runtimeTicks",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "communityRating",
            "columnName": "communityRating",
            "affinity": "REAL",
            "notNull": false
          },
          {
            "fieldPath": "officialRating",
            "columnName": "officialRating",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "status",
            "columnName": "status",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "productionYear",
            "columnName": "productionYear",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "endDate",
            "columnName": "endDate",
            "affinity": "INTEGER",
            "notNull": false
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "id"
          ]
        },
        "indices": [],
        "foreignKeys": []
      },
      {
        "tableName": "seasons",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `seriesId` TEXT NOT NULL, `name` TEXT NOT NULL, `seriesName` TEXT NOT NULL, `overview` TEXT NOT NULL, `indexNumber` INTEGER NOT NULL, PRIMARY KEY(`id`), FOREIGN KEY(`seriesId`) REFERENCES `shows`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "seriesId",
            "columnName": "seriesId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "name",
            "columnName": "name",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "seriesName",
            "columnName": "seriesName",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "overview",
            "columnName": "overview",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "indexNumber",
            "columnName": "indexNumber",
            "affinity": "INTEGER",
            "notNull": true
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "id"
          ]
        },
        "indices": [
          {
            "name": "index_seasons_seriesId",
            "unique": false,
            "columnNames": [
              "seriesId"
            ],
            "orders": [],
            "createSql": "CREATE INDEX IF NOT EXISTS `index_seasons_seriesId` ON `${TABLE_NAME}` (`seriesId`)"
          }
        ],
        "foreignKeys": [
          {
            "table": "shows",
            "onDelete": "CASCADE",
            "onUpdate": "NO ACTION",
            "columns": [
              "seriesId"
            ],
            "referencedColumns": [
              "id"
            ]
          }
        ]
      },
      {
        "tableName": "episodes",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `serverId` TEXT, `seasonId` TEXT NOT NULL, `seriesId` TEXT NOT NULL, `name` TEXT NOT NULL, `seriesName` TEXT NOT NULL, `overview` TEXT NOT NULL, `indexNumber` INTEGER NOT NULL, `indexNumberEnd` INTEGER, `parentIndexNumber` INTEGER NOT NULL, `runtimeTicks` INTEGER NOT NULL, `premiereDate` INTEGER, `communityRating` REAL, PRIMARY KEY(`id`), FOREIGN KEY(`seasonId`) REFERENCES `seasons`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE , FOREIGN KEY(`seriesId`) REFERENCES `shows`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "serverId",
            "columnName": "serverId",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "seasonId",
            "columnName": "seasonId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "seriesId",
            "columnName": "seriesId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "name",
            "columnName": "name",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "seriesName",
            "columnName": "seriesName",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "overview",
            "columnName": "overview",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "indexNumber",
            "columnName": "indexNumber",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "indexNumberEnd",
            "columnName": "indexNumberEnd",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "parentIndexNumber",
            "columnName": "parentIndexNumber",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "runtimeTicks",
            "columnName": "runtimeTicks",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "premiereDate",
            "columnName": "premiereDate",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "communityRating",
            "columnName": "communityRating",
            "affinity": "REAL",
            "notNull": false
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "id"
          ]
        },
        "indices": [
          {
            "name": "index_episodes_seasonId",
            "unique": false,
            "columnNames": [
              "seasonId"
            ],
            "orders": [],
            "createSql": "CREATE INDEX IF NOT EXISTS `index_episodes_seasonId` ON `${TABLE_NAME}` (`seasonId`)"
          },
          {
            "name": "index_episodes_seriesId",
            "unique": false,
            "columnNames": [
              "seriesId"
            ],
            "orders": [],
            "createSql": "CREATE INDEX IF NOT EXISTS `index_episodes_seriesId` ON `${TABLE_NAME}` (`seriesId`)"
          }
        ],
        "foreignKeys": [
          {
            "table": "seasons",
            "onDelete": "CASCADE",
            "onUpdate": "NO ACTION",
            "columns": [
              "seasonId"
            ],
            "referencedColumns": [
              "id"
            ]
          },
          {
            "table": "shows",
            "onDelete": "CASCADE",
            "onUpdate": "NO ACTION",
            "columns": [
              "seriesId"
            ],
            "referencedColumns": [
              "id"
            ]
          }
        ]
      },
      {
        "tableName": "sources",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `itemId` TEXT NOT NULL, `name` TEXT NOT NULL, `type` TEXT NOT NULL, `path` TEXT NOT NULL, `downloadId` INTEGER, PRIMARY KEY(`id`))",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "itemId",
            "columnName": "itemId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "name",
            "columnName": "name",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "type",
            "columnName": "type",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "path",
            "columnName": "path",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "downloadId",
            "columnName": "downloadId",
            "affinity": "INTEGER",
            "notNull": false
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "id"
          ]
        },
        "indices": [],
        "foreignKeys": []
      },
      {
        "tableName": "mediastreams",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `sourceId` TEXT NOT NULL, `title` TEXT NOT NULL, `displayTitle` TEXT, `language` TEXT NOT NULL, `type` TEXT NOT NULL, `codec` TEXT NOT NULL, `isExternal` INTEGER NOT NULL, `path` TEXT NOT NULL, `channelLayout` TEXT, `videoRangeType` TEXT, `height` INTEGER, `width` INTEGER, `videoDoViTitle` TEXT, `downloadId` INTEGER, PRIMARY KEY(`id`))",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "sourceId",
            "columnName": "sourceId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "title",
            "columnName": "title",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "displayTitle",
            "columnName": "displayTitle",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "language",
            "columnName": "language",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "type",
            "columnName": "type",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "codec",
            "columnName": "codec",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "isExternal",
            "columnName": "isExternal",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "path",
            "columnName": "path",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "channelLayout",
            "columnName": "channelLayout",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "videoRangeType",
            "columnName": "videoRangeType",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "height",
            "columnName": "height",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "width",
            "columnName": "width",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "videoDoViTitle",
            "columnName": "videoDoViTitle",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "downloadId",
            "columnName": "downloadId",
            "affinity": "INTEGER",
            "notNull": false
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "id"
          ]
        },
        "indices": [],
        "foreignKeys": []
      },
      {
        "tableName": "trickPlayManifests",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`itemId` TEXT NOT NULL, `version` TEXT NOT NULL, `resolution` INTEGER NOT NULL, PRIMARY KEY(`itemId`))",
        "fields": [
          {
            "fieldPath": "itemId",
            "columnName": "itemId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "version",
            "columnName": "version",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "resolution",
            "columnName": "resolution",
            "affinity": "INTEGER",
            "notNull": true
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "itemId"
          ]
        },
        "indices": [],
        "foreignKeys": []
      },
      {
        "tableName": "intros",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`itemId` TEXT NOT NULL, `start` REAL NOT NULL, `end` REAL NOT NULL, `showAt` REAL NOT NULL, `hideAt` REAL NOT NULL, PRIMARY KEY(`itemId`))",
        "fields": [
          {
            "fieldPath": "itemId",
            "columnName": "itemId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "start",
            "columnName": "start",
            "affinity": "REAL",
            "notNull": true
          },
          {
            "fieldPath": "end",
            "columnName": "end",
            "affinity": "REAL",
            "notNull": true
          },
          {
            "fieldPath": "showAt",
            "columnName": "showAt",
            "affinity": "REAL",
            "notNull": true
          },
          {
            "fieldPath": "hideAt",
            "columnName": "hideAt",
            "affinity": "REAL",
            "notNull": true
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "itemId"
          ]
        },
        "indices": [],
        "foreignKeys": []
      },
      {
        "tableName": "userdata",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`userId` TEXT NOT NULL, `itemId` TEXT NOT NULL, `played` INTEGER NOT NULL, `favorite` INTEGER NOT NULL, `playbackPositionTicks` INTEGER NOT NULL, `toBeSynced` INTEGER NOT NULL, PRIMARY KEY(`userId`, `itemId`))",
        "fields": [
          {
            "fieldPath": "userId",
            "columnName": "userId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "itemId",
            "columnName": "itemId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "played",
            "columnName": "played",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "favorite",
            "columnName": "favorite",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "playbackPositionTicks",
            "columnName": "playbackPositionTicks",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "toBeSynced",
            "columnName": "toBeSynced",
            "affinity": "INTEGER",
            "notNull": true
          }
        ],
        "primaryKey": {
          "autoGenerate": false,
          "columnNames": [
            "userId",
            "itemId"
          ]
        },
        "indices": [],
        "foreignKeys": []
      }
    ],
    "views": [],
    "setupQueries": [
      "CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)",
      "INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, '3cb9aaa3295b9e461cb94dfc708258ed')"
    ]
  }
}