{
  "formatVersion": 1,
  "database": {
    "version": 3,
    "identityHash": "06359a8c2943365dd094bc5dff210203",
    "entities": [
      {
        "tableName": "users",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `username` TEXT, `name` TEXT, `status` TEXT NOT NULL, `utcOffset` REAL, PRIMARY KEY(`id`))",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "username",
            "columnName": "username",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "name",
            "columnName": "name",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "status",
            "columnName": "status",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "utcOffset",
            "columnName": "utcOffset",
            "affinity": "REAL",
            "notNull": false
          }
        ],
        "primaryKey": {
          "columnNames": [
            "id"
          ],
          "autoGenerate": false
        },
        "indices": [
          {
            "name": "index_users_username",
            "unique": false,
            "columnNames": [
              "username"
            ],
            "createSql": "CREATE  INDEX `index_users_username` ON `${TABLE_NAME}` (`username`)"
          }
        ],
        "foreignKeys": []
      },
      {
        "tableName": "chatrooms",
        "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` TEXT NOT NULL, `subscriptionId` TEXT NOT NULL, `type` TEXT NOT NULL, `name` TEXT NOT NULL, `fullname` TEXT, `userId` TEXT, `ownerId` TEXT, `readonly` INTEGER, `isDefault` INTEGER, `favorite` INTEGER, `open` INTEGER NOT NULL, `alert` INTEGER NOT NULL, `unread` INTEGER NOT NULL, `userMentions` INTEGER, `groupMentions` INTEGER, `updatedAt` INTEGER, `timestamp` INTEGER, `lastSeen` INTEGER, `lastMessageText` TEXT, `lastMessageUserId` TEXT, `lastMessageTimestamp` INTEGER, PRIMARY KEY(`id`), FOREIGN KEY(`ownerId`) REFERENCES `users`(`id`) ON UPDATE NO ACTION ON DELETE NO ACTION , FOREIGN KEY(`userId`) REFERENCES `users`(`id`) ON UPDATE NO ACTION ON DELETE NO ACTION , FOREIGN KEY(`lastMessageUserId`) REFERENCES `users`(`id`) ON UPDATE NO ACTION ON DELETE NO ACTION )",
        "fields": [
          {
            "fieldPath": "id",
            "columnName": "id",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "subscriptionId",
            "columnName": "subscriptionId",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "type",
            "columnName": "type",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "name",
            "columnName": "name",
            "affinity": "TEXT",
            "notNull": true
          },
          {
            "fieldPath": "fullname",
            "columnName": "fullname",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "userId",
            "columnName": "userId",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "ownerId",
            "columnName": "ownerId",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "readonly",
            "columnName": "readonly",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "isDefault",
            "columnName": "isDefault",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "favorite",
            "columnName": "favorite",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "open",
            "columnName": "open",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "alert",
            "columnName": "alert",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "unread",
            "columnName": "unread",
            "affinity": "INTEGER",
            "notNull": true
          },
          {
            "fieldPath": "userMentions",
            "columnName": "userMentions",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "groupMentions",
            "columnName": "groupMentions",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "updatedAt",
            "columnName": "updatedAt",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "timestamp",
            "columnName": "timestamp",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "lastSeen",
            "columnName": "lastSeen",
            "affinity": "INTEGER",
            "notNull": false
          },
          {
            "fieldPath": "lastMessageText",
            "columnName": "lastMessageText",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "lastMessageUserId",
            "columnName": "lastMessageUserId",
            "affinity": "TEXT",
            "notNull": false
          },
          {
            "fieldPath": "lastMessageTimestamp",
            "columnName": "lastMessageTimestamp",
            "affinity": "INTEGER",
            "notNull": false
          }
        ],
        "primaryKey": {
          "columnNames": [
            "id"
          ],
          "autoGenerate": false
        },
        "indices": [
          {
            "name": "index_chatrooms_userId",
            "unique": false,
            "columnNames": [
              "userId"
            ],
            "createSql": "CREATE  INDEX `index_chatrooms_userId` ON `${TABLE_NAME}` (`userId`)"
          },
          {
            "name": "index_chatrooms_ownerId",
            "unique": false,
            "columnNames": [
              "ownerId"
            ],
            "createSql": "CREATE  INDEX `index_chatrooms_ownerId` ON `${TABLE_NAME}` (`ownerId`)"
          },
          {
            "name": "index_chatrooms_subscriptionId",
            "unique": true,
            "columnNames": [
              "subscriptionId"
            ],
            "createSql": "CREATE UNIQUE INDEX `index_chatrooms_subscriptionId` ON `${TABLE_NAME}` (`subscriptionId`)"
          },
          {
            "name": "index_chatrooms_updatedAt",
            "unique": false,
            "columnNames": [
              "updatedAt"
            ],
            "createSql": "CREATE  INDEX `index_chatrooms_updatedAt` ON `${TABLE_NAME}` (`updatedAt`)"
          }
        ],
        "foreignKeys": [
          {
            "table": "users",
            "onDelete": "NO ACTION",
            "onUpdate": "NO ACTION",
            "columns": [
              "ownerId"
            ],
            "referencedColumns": [
              "id"
            ]
          },
          {
            "table": "users",
            "onDelete": "NO ACTION",
            "onUpdate": "NO ACTION",
            "columns": [
              "userId"
            ],
            "referencedColumns": [
              "id"
            ]
          },
          {
            "table": "users",
            "onDelete": "NO ACTION",
            "onUpdate": "NO ACTION",
            "columns": [
              "lastMessageUserId"
            ],
            "referencedColumns": [
              "id"
            ]
          }
        ]
      }
    ],
    "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, \"06359a8c2943365dd094bc5dff210203\")"
    ]
  }
}