"createSql":"CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `uuid` TEXT NOT NULL, `name` TEXT NOT NULL, `email` TEXT NOT NULL, `account` INTEGER NOT NULL, `display` TEXT, `color` INTEGER, `signature` TEXT, `host` TEXT NOT NULL, `starttls` INTEGER NOT NULL, `insecure` INTEGER NOT NULL, `dnssec` INTEGER NOT NULL, `dane` INTEGER NOT NULL, `port` INTEGER NOT NULL, `auth_type` INTEGER NOT NULL, `provider` TEXT, `user` TEXT NOT NULL, `password` TEXT NOT NULL, `certificate` INTEGER NOT NULL, `certificate_alias` TEXT, `realm` TEXT, `fingerprint` TEXT, `use_ip` INTEGER NOT NULL, `ehlo` TEXT, `synchronize` INTEGER NOT NULL, `primary` INTEGER NOT NULL, `self` INTEGER NOT NULL, `sender_extra` INTEGER NOT NULL, `sender_extra_name` INTEGER NOT NULL, `reply_extra_name` INTEGER NOT NULL, `sender_extra_regex` TEXT, `replyto` TEXT, `cc` TEXT, `bcc` TEXT, `internal` TEXT, `uri` TEXT, `unicode` INTEGER NOT NULL, `octetmime` INTEGER NOT NULL, `plain_only` INTEGER NOT NULL, `sign_default` INTEGER NOT NULL, `encrypt_default` INTEGER NOT NULL, `encrypt` INTEGER NOT NULL, `receipt_type` INTEGER, `delivery_receipt` INTEGER NOT NULL, `read_receipt` INTEGER NOT NULL, `sensitivity` INTEGER NOT NULL, `store_sent` INTEGER NOT NULL, `sent_folder` INTEGER, `sign_key` INTEGER, `sign_key_alias` TEXT, `tbd` INTEGER, `state` TEXT, `error` TEXT, `last_connected` INTEGER, `max_size` INTEGER, `last_modified` INTEGER, FOREIGN KEY(`account`) REFERENCES `account`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
"createSql":"CREATE UNIQUE INDEX IF NOT EXISTS `index_attachment_message_sequence_subsequence` ON `${TABLE_NAME}` (`message`, `sequence`, `subsequence`)"
},
{
"name":"index_attachment_message_cid",
"unique":false,
"columnNames":[
"message",
"cid"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_attachment_message_cid` ON `${TABLE_NAME}` (`message`, `cid`)"
}
],
"foreignKeys":[
{
"table":"message",
"onDelete":"CASCADE",
"onUpdate":"NO ACTION",
"columns":[
"message"
],
"referencedColumns":[
"id"
]
}
]
},
{
"tableName":"operation",
"createSql":"CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `account` INTEGER, `folder` INTEGER NOT NULL, `message` INTEGER, `name` TEXT NOT NULL, `args` TEXT NOT NULL, `created` INTEGER NOT NULL, `tries` INTEGER NOT NULL, `state` TEXT, `error` TEXT, FOREIGN KEY(`folder`) REFERENCES `folder`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE , FOREIGN KEY(`message`) REFERENCES `message`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
"fields":[
{
"fieldPath":"id",
"columnName":"id",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"account",
"columnName":"account",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"folder",
"columnName":"folder",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"message",
"columnName":"message",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"name",
"columnName":"name",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"args",
"columnName":"args",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"created",
"columnName":"created",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"tries",
"columnName":"tries",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"state",
"columnName":"state",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"error",
"columnName":"error",
"affinity":"TEXT",
"notNull":false
}
],
"primaryKey":{
"columnNames":[
"id"
],
"autoGenerate":true
},
"indices":[
{
"name":"index_operation_account",
"unique":false,
"columnNames":[
"account"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_operation_account` ON `${TABLE_NAME}` (`account`)"
},
{
"name":"index_operation_folder",
"unique":false,
"columnNames":[
"folder"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_operation_folder` ON `${TABLE_NAME}` (`folder`)"
},
{
"name":"index_operation_message",
"unique":false,
"columnNames":[
"message"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_operation_message` ON `${TABLE_NAME}` (`message`)"
},
{
"name":"index_operation_name",
"unique":false,
"columnNames":[
"name"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_operation_name` ON `${TABLE_NAME}` (`name`)"
},
{
"name":"index_operation_state",
"unique":false,
"columnNames":[
"state"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_operation_state` ON `${TABLE_NAME}` (`state`)"
}
],
"foreignKeys":[
{
"table":"folder",
"onDelete":"CASCADE",
"onUpdate":"NO ACTION",
"columns":[
"folder"
],
"referencedColumns":[
"id"
]
},
{
"table":"message",
"onDelete":"CASCADE",
"onUpdate":"NO ACTION",
"columns":[
"message"
],
"referencedColumns":[
"id"
]
}
]
},
{
"tableName":"contact",
"createSql":"CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `account` INTEGER NOT NULL, `identity` INTEGER, `folder` INTEGER, `type` INTEGER NOT NULL, `email` TEXT NOT NULL, `name` TEXT, `group` TEXT, `avatar` TEXT, `times_contacted` INTEGER NOT NULL, `first_contacted` INTEGER NOT NULL, `last_contacted` INTEGER NOT NULL, `state` INTEGER NOT NULL, FOREIGN KEY(`account`) REFERENCES `account`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
"fields":[
{
"fieldPath":"id",
"columnName":"id",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"account",
"columnName":"account",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"identity",
"columnName":"identity",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"folder",
"columnName":"folder",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"type",
"columnName":"type",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"email",
"columnName":"email",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"name",
"columnName":"name",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"group",
"columnName":"group",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"avatar",
"columnName":"avatar",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"times_contacted",
"columnName":"times_contacted",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"first_contacted",
"columnName":"first_contacted",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"last_contacted",
"columnName":"last_contacted",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"state",
"columnName":"state",
"affinity":"INTEGER",
"notNull":true
}
],
"primaryKey":{
"columnNames":[
"id"
],
"autoGenerate":true
},
"indices":[
{
"name":"index_contact_account_type_email",
"unique":true,
"columnNames":[
"account",
"type",
"email"
],
"orders":[],
"createSql":"CREATE UNIQUE INDEX IF NOT EXISTS `index_contact_account_type_email` ON `${TABLE_NAME}` (`account`, `type`, `email`)"
},
{
"name":"index_contact_email",
"unique":false,
"columnNames":[
"email"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_contact_email` ON `${TABLE_NAME}` (`email`)"
},
{
"name":"index_contact_name",
"unique":false,
"columnNames":[
"name"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_contact_name` ON `${TABLE_NAME}` (`name`)"
},
{
"name":"index_contact_avatar",
"unique":false,
"columnNames":[
"avatar"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_contact_avatar` ON `${TABLE_NAME}` (`avatar`)"
},
{
"name":"index_contact_times_contacted",
"unique":false,
"columnNames":[
"times_contacted"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_contact_times_contacted` ON `${TABLE_NAME}` (`times_contacted`)"
},
{
"name":"index_contact_last_contacted",
"unique":false,
"columnNames":[
"last_contacted"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_contact_last_contacted` ON `${TABLE_NAME}` (`last_contacted`)"
},
{
"name":"index_contact_state",
"unique":false,
"columnNames":[
"state"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_contact_state` ON `${TABLE_NAME}` (`state`)"
}
],
"foreignKeys":[
{
"table":"account",
"onDelete":"CASCADE",
"onUpdate":"NO ACTION",
"columns":[
"account"
],
"referencedColumns":[
"id"
]
}
]
},
{
"tableName":"certificate",
"createSql":"CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `fingerprint` TEXT NOT NULL, `intermediate` INTEGER NOT NULL, `email` TEXT NOT NULL, `subject` TEXT, `after` INTEGER, `before` INTEGER, `data` TEXT NOT NULL)",
"fields":[
{
"fieldPath":"id",
"columnName":"id",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"fingerprint",
"columnName":"fingerprint",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"intermediate",
"columnName":"intermediate",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"email",
"columnName":"email",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"subject",
"columnName":"subject",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"after",
"columnName":"after",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"before",
"columnName":"before",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"data",
"columnName":"data",
"affinity":"TEXT",
"notNull":true
}
],
"primaryKey":{
"columnNames":[
"id"
],
"autoGenerate":true
},
"indices":[
{
"name":"index_certificate_fingerprint_email",
"unique":true,
"columnNames":[
"fingerprint",
"email"
],
"orders":[],
"createSql":"CREATE UNIQUE INDEX IF NOT EXISTS `index_certificate_fingerprint_email` ON `${TABLE_NAME}` (`fingerprint`, `email`)"
},
{
"name":"index_certificate_email",
"unique":false,
"columnNames":[
"email"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_certificate_email` ON `${TABLE_NAME}` (`email`)"
}
],
"foreignKeys":[]
},
{
"tableName":"answer",
"createSql":"CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `uuid` TEXT NOT NULL, `name` TEXT NOT NULL, `label` TEXT, `group` TEXT, `standard` INTEGER NOT NULL, `receipt` INTEGER NOT NULL, `favorite` INTEGER NOT NULL, `snippet` INTEGER NOT NULL, `hide` INTEGER NOT NULL, `external` INTEGER NOT NULL, `color` INTEGER, `text` TEXT NOT NULL, `applied` INTEGER NOT NULL, `last_applied` INTEGER)",
"fields":[
{
"fieldPath":"id",
"columnName":"id",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"uuid",
"columnName":"uuid",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"name",
"columnName":"name",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"label",
"columnName":"label",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"group",
"columnName":"group",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"standard",
"columnName":"standard",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"receipt",
"columnName":"receipt",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"favorite",
"columnName":"favorite",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"snippet",
"columnName":"snippet",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"hide",
"columnName":"hide",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"external",
"columnName":"external",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"color",
"columnName":"color",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"text",
"columnName":"text",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"applied",
"columnName":"applied",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"last_applied",
"columnName":"last_applied",
"affinity":"INTEGER",
"notNull":false
}
],
"primaryKey":{
"columnNames":[
"id"
],
"autoGenerate":true
},
"indices":[
{
"name":"index_answer_label",
"unique":true,
"columnNames":[
"label"
],
"orders":[],
"createSql":"CREATE UNIQUE INDEX IF NOT EXISTS `index_answer_label` ON `${TABLE_NAME}` (`label`)"
}
],
"foreignKeys":[]
},
{
"tableName":"rule",
"createSql":"CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `uuid` TEXT NOT NULL, `folder` INTEGER NOT NULL, `name` TEXT NOT NULL, `group` TEXT, `order` INTEGER NOT NULL, `enabled` INTEGER NOT NULL, `daily` INTEGER NOT NULL, `stop` INTEGER NOT NULL, `condition` TEXT NOT NULL, `action` TEXT NOT NULL, `applied` INTEGER NOT NULL, `last_applied` INTEGER, FOREIGN KEY(`folder`) REFERENCES `folder`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE )",
"fields":[
{
"fieldPath":"id",
"columnName":"id",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"uuid",
"columnName":"uuid",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"folder",
"columnName":"folder",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"name",
"columnName":"name",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"group",
"columnName":"group",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"order",
"columnName":"order",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"enabled",
"columnName":"enabled",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"daily",
"columnName":"daily",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"stop",
"columnName":"stop",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"condition",
"columnName":"condition",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"action",
"columnName":"action",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"applied",
"columnName":"applied",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"last_applied",
"columnName":"last_applied",
"affinity":"INTEGER",
"notNull":false
}
],
"primaryKey":{
"columnNames":[
"id"
],
"autoGenerate":true
},
"indices":[
{
"name":"index_rule_folder",
"unique":false,
"columnNames":[
"folder"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_rule_folder` ON `${TABLE_NAME}` (`folder`)"
},
{
"name":"index_rule_order",
"unique":false,
"columnNames":[
"order"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_rule_order` ON `${TABLE_NAME}` (`order`)"
}
],
"foreignKeys":[
{
"table":"folder",
"onDelete":"CASCADE",
"onUpdate":"NO ACTION",
"columns":[
"folder"
],
"referencedColumns":[
"id"
]
}
]
},
{
"tableName":"search",
"createSql":"CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `account_uuid` TEXT, `folder_name` TEXT, `name` TEXT NOT NULL, `order` INTEGER, `color` INTEGER, `data` TEXT NOT NULL)",
"fields":[
{
"fieldPath":"id",
"columnName":"id",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"account_uuid",
"columnName":"account_uuid",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"folder_name",
"columnName":"folder_name",
"affinity":"TEXT",
"notNull":false
},
{
"fieldPath":"name",
"columnName":"name",
"affinity":"TEXT",
"notNull":true
},
{
"fieldPath":"order",
"columnName":"order",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"color",
"columnName":"color",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"data",
"columnName":"data",
"affinity":"TEXT",
"notNull":true
}
],
"primaryKey":{
"columnNames":[
"id"
],
"autoGenerate":true
},
"indices":[],
"foreignKeys":[]
},
{
"tableName":"log",
"createSql":"CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `time` INTEGER NOT NULL, `type` INTEGER NOT NULL, `thread` INTEGER, `account` INTEGER, `folder` INTEGER, `message` INTEGER, `data` TEXT NOT NULL)",
"fields":[
{
"fieldPath":"id",
"columnName":"id",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"time",
"columnName":"time",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"type",
"columnName":"type",
"affinity":"INTEGER",
"notNull":true
},
{
"fieldPath":"thread",
"columnName":"thread",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"account",
"columnName":"account",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"folder",
"columnName":"folder",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"message",
"columnName":"message",
"affinity":"INTEGER",
"notNull":false
},
{
"fieldPath":"data",
"columnName":"data",
"affinity":"TEXT",
"notNull":true
}
],
"primaryKey":{
"columnNames":[
"id"
],
"autoGenerate":true
},
"indices":[
{
"name":"index_log_time",
"unique":false,
"columnNames":[
"time"
],
"orders":[],
"createSql":"CREATE INDEX IF NOT EXISTS `index_log_time` ON `${TABLE_NAME}` (`time`)"
}
],
"foreignKeys":[]
}
],
"views":[
{
"viewName":"account_view",
"createSql":"CREATE VIEW `${VIEW_NAME}` AS SELECT id, pop, name, category, color, synchronize, notify, summary, leave_deleted, auto_seen, created FROM account"
},
{
"viewName":"identity_view",
"createSql":"CREATE VIEW `${VIEW_NAME}` AS SELECT id, name, email, account, display, color, synchronize FROM identity"
},
{
"viewName":"folder_view",
"createSql":"CREATE VIEW `${VIEW_NAME}` AS SELECT id, account, name, type, inherited_type, display, color, unified, notify, read_only FROM folder"
}
],
"setupQueries":[
"CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)",