Skip to content
File

Blob: drizzle/meta/0000_snapshot.json

json374 lines
1{
2 "version": "6",
3 "dialect": "sqlite",
4 "id": "535868c2-6e11-401e-8d00-2399693a5d60",
5 "prevId": "00000000-0000-0000-0000-000000000000",
6 "tables": {
7 "attachments": {
8 "name": "attachments",
9 "columns": {
10 "id": {
11 "name": "id",
12 "type": "text",
13 "primaryKey": true,
14 "notNull": true,
15 "autoincrement": false
16 },
17 "email_id": {
18 "name": "email_id",
19 "type": "text",
20 "primaryKey": false,
21 "notNull": true,
22 "autoincrement": false
23 },
24 "filename": {
25 "name": "filename",
26 "type": "text",
27 "primaryKey": false,
28 "notNull": false,
29 "autoincrement": false
30 },
31 "content_type": {
32 "name": "content_type",
33 "type": "text",
34 "primaryKey": false,
35 "notNull": false,
36 "autoincrement": false
37 },
38 "size_bytes": {
39 "name": "size_bytes",
40 "type": "integer",
41 "primaryKey": false,
42 "notNull": false,
43 "autoincrement": false,
44 "default": 0
45 },
46 "storage_key": {
47 "name": "storage_key",
48 "type": "text",
49 "primaryKey": false,
50 "notNull": true,
51 "autoincrement": false
52 }
53 },
54 "indexes": {
55 "idx_attachments_email": {
56 "name": "idx_attachments_email",
57 "columns": [
58 "email_id"
59 ],
60 "isUnique": false
61 }
62 },
63 "foreignKeys": {
64 "attachments_email_id_emails_id_fk": {
65 "name": "attachments_email_id_emails_id_fk",
66 "tableFrom": "attachments",
67 "tableTo": "emails",
68 "columnsFrom": [
69 "email_id"
70 ],
71 "columnsTo": [
72 "id"
73 ],
74 "onDelete": "cascade",
75 "onUpdate": "no action"
76 }
77 },
78 "compositePrimaryKeys": {},
79 "uniqueConstraints": {},
80 "checkConstraints": {}
81 },
82 "domains": {
83 "name": "domains",
84 "columns": {
85 "id": {
86 "name": "id",
87 "type": "text",
88 "primaryKey": true,
89 "notNull": true,
90 "autoincrement": false
91 },
92 "domain": {
93 "name": "domain",
94 "type": "text",
95 "primaryKey": false,
96 "notNull": true,
97 "autoincrement": false
98 },
99 "is_active": {
100 "name": "is_active",
101 "type": "integer",
102 "primaryKey": false,
103 "notNull": true,
104 "autoincrement": false,
105 "default": true
106 },
107 "created_at": {
108 "name": "created_at",
109 "type": "integer",
110 "primaryKey": false,
111 "notNull": true,
112 "autoincrement": false,
113 "default": "(unixepoch() * 1000)"
114 }
115 },
116 "indexes": {
117 "domains_domain_unique": {
118 "name": "domains_domain_unique",
119 "columns": [
120 "domain"
121 ],
122 "isUnique": true
123 },
124 "idx_domains_active": {
125 "name": "idx_domains_active",
126 "columns": [
127 "is_active"
128 ],
129 "isUnique": false
130 }
131 },
132 "foreignKeys": {},
133 "compositePrimaryKeys": {},
134 "uniqueConstraints": {},
135 "checkConstraints": {}
136 },
137 "emails": {
138 "name": "emails",
139 "columns": {
140 "id": {
141 "name": "id",
142 "type": "text",
143 "primaryKey": true,
144 "notNull": true,
145 "autoincrement": false
146 },
147 "inbox_id": {
148 "name": "inbox_id",
149 "type": "text",
150 "primaryKey": false,
151 "notNull": true,
152 "autoincrement": false
153 },
154 "recipient_address": {
155 "name": "recipient_address",
156 "type": "text",
157 "primaryKey": false,
158 "notNull": true,
159 "autoincrement": false,
160 "default": "''"
161 },
162 "from_address": {
163 "name": "from_address",
164 "type": "text",
165 "primaryKey": false,
166 "notNull": true,
167 "autoincrement": false
168 },
169 "from_name": {
170 "name": "from_name",
171 "type": "text",
172 "primaryKey": false,
173 "notNull": false,
174 "autoincrement": false
175 },
176 "subject": {
177 "name": "subject",
178 "type": "text",
179 "primaryKey": false,
180 "notNull": false,
181 "autoincrement": false,
182 "default": "'(no subject)'"
183 },
184 "received_at": {
185 "name": "received_at",
186 "type": "integer",
187 "primaryKey": false,
188 "notNull": true,
189 "autoincrement": false,
190 "default": "(unixepoch() * 1000)"
191 },
192 "is_read": {
193 "name": "is_read",
194 "type": "integer",
195 "primaryKey": false,
196 "notNull": true,
197 "autoincrement": false,
198 "default": false
199 },
200 "size_bytes": {
201 "name": "size_bytes",
202 "type": "integer",
203 "primaryKey": false,
204 "notNull": false,
205 "autoincrement": false,
206 "default": 0
207 },
208 "has_attachments": {
209 "name": "has_attachments",
210 "type": "integer",
211 "primaryKey": false,
212 "notNull": true,
213 "autoincrement": false,
214 "default": false
215 },
216 "body_key": {
217 "name": "body_key",
218 "type": "text",
219 "primaryKey": false,
220 "notNull": false,
221 "autoincrement": false
222 }
223 },
224 "indexes": {
225 "idx_emails_inbox_received_id": {
226 "name": "idx_emails_inbox_received_id",
227 "columns": [
228 "inbox_id",
229 "received_at",
230 "id"
231 ],
232 "isUnique": false
233 }
234 },
235 "foreignKeys": {
236 "emails_inbox_id_inboxes_id_fk": {
237 "name": "emails_inbox_id_inboxes_id_fk",
238 "tableFrom": "emails",
239 "tableTo": "inboxes",
240 "columnsFrom": [
241 "inbox_id"
242 ],
243 "columnsTo": [
244 "id"
245 ],
246 "onDelete": "cascade",
247 "onUpdate": "no action"
248 }
249 },
250 "compositePrimaryKeys": {},
251 "uniqueConstraints": {},
252 "checkConstraints": {}
253 },
254 "inboxes": {
255 "name": "inboxes",
256 "columns": {
257 "id": {
258 "name": "id",
259 "type": "text",
260 "primaryKey": true,
261 "notNull": true,
262 "autoincrement": false
263 },
264 "local_part": {
265 "name": "local_part",
266 "type": "text",
267 "primaryKey": false,
268 "notNull": true,
269 "autoincrement": false
270 },
271 "domain": {
272 "name": "domain",
273 "type": "text",
274 "primaryKey": false,
275 "notNull": true,
276 "autoincrement": false
277 },
278 "full_address": {
279 "name": "full_address",
280 "type": "text",
281 "primaryKey": false,
282 "notNull": true,
283 "autoincrement": false
284 },
285 "is_permanent": {
286 "name": "is_permanent",
287 "type": "integer",
288 "primaryKey": false,
289 "notNull": true,
290 "autoincrement": false,
291 "default": false
292 },
293 "created_at": {
294 "name": "created_at",
295 "type": "integer",
296 "primaryKey": false,
297 "notNull": true,
298 "autoincrement": false,
299 "default": "(unixepoch() * 1000)"
300 },
301 "expires_at": {
302 "name": "expires_at",
303 "type": "integer",
304 "primaryKey": false,
305 "notNull": false,
306 "autoincrement": false
307 }
308 },
309 "indexes": {
310 "inboxes_full_address_unique": {
311 "name": "inboxes_full_address_unique",
312 "columns": [
313 "full_address"
314 ],
315 "isUnique": true
316 },
317 "idx_inboxes_local_domain": {
318 "name": "idx_inboxes_local_domain",
319 "columns": [
320 "local_part",
321 "domain"
322 ],
323 "isUnique": true
324 },
325 "idx_inboxes_domain": {
326 "name": "idx_inboxes_domain",
327 "columns": [
328 "domain"
329 ],
330 "isUnique": false
331 },
332 "idx_inboxes_permanent_expires": {
333 "name": "idx_inboxes_permanent_expires",
334 "columns": [
335 "is_permanent",
336 "expires_at"
337 ],
338 "isUnique": false
339 },
340 "idx_inboxes_permanent_created": {
341 "name": "idx_inboxes_permanent_created",
342 "columns": [
343 "is_permanent",
344 "created_at"
345 ],
346 "isUnique": false
347 },
348 "idx_inboxes_permanent_domain_local": {
349 "name": "idx_inboxes_permanent_domain_local",
350 "columns": [
351 "is_permanent",
352 "domain",
353 "local_part"
354 ],
355 "isUnique": false
356 }
357 },
358 "foreignKeys": {},
359 "compositePrimaryKeys": {},
360 "uniqueConstraints": {},
361 "checkConstraints": {}
362 }
363 },
364 "views": {},
365 "enums": {},
366 "_meta": {
367 "schemas": {},
368 "tables": {},
369 "columns": {}
370 },
371 "internal": {
372 "indexes": {}
373 }
374}