@drfed/models 0.0.0-stage → 0.1.0-dev.554

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (132) hide show
  1. package/LICENSE +661 -0
  2. package/README.md +230 -2
  3. package/dist/activity-delivery.d.mts +111 -0
  4. package/dist/activity-delivery.d.mts.map +1 -0
  5. package/dist/activity-delivery.mjs +240 -0
  6. package/dist/activity-delivery.mjs.map +1 -0
  7. package/dist/db-DtcLuISw.d.mts +3098 -0
  8. package/dist/db-DtcLuISw.d.mts.map +1 -0
  9. package/dist/db.d.mts +2 -0
  10. package/dist/db.mjs +3 -0
  11. package/dist/email.d.mts +39 -0
  12. package/dist/email.d.mts.map +1 -0
  13. package/dist/email.mjs +12 -0
  14. package/dist/email.mjs.map +1 -0
  15. package/dist/index.d.mts +14 -0
  16. package/dist/index.mjs +18 -0
  17. package/dist/instance.d.mts +11 -0
  18. package/dist/instance.d.mts.map +1 -0
  19. package/dist/instance.mjs +21 -0
  20. package/dist/instance.mjs.map +1 -0
  21. package/dist/key.d.mts +2 -0
  22. package/dist/key.mjs +86 -0
  23. package/dist/key.mjs.map +1 -0
  24. package/dist/login.d.mts +49 -0
  25. package/dist/login.d.mts.map +1 -0
  26. package/dist/login.mjs +71 -0
  27. package/dist/login.mjs.map +1 -0
  28. package/dist/migrate.d.mts +46 -0
  29. package/dist/migrate.d.mts.map +1 -0
  30. package/dist/migrate.mjs +58 -0
  31. package/dist/migrate.mjs.map +1 -0
  32. package/dist/migration-manifest.d.mts +39 -0
  33. package/dist/migration-manifest.d.mts.map +1 -0
  34. package/dist/migration-manifest.mjs +77 -0
  35. package/dist/migration-manifest.mjs.map +1 -0
  36. package/dist/migration-session-B4xHeU_a.d.mts +56 -0
  37. package/dist/migration-session-B4xHeU_a.d.mts.map +1 -0
  38. package/dist/migration-session.d.mts +2 -0
  39. package/dist/migration-session.mjs +204 -0
  40. package/dist/migration-session.mjs.map +1 -0
  41. package/dist/migration-snapshot-OM5jQN1-.mjs +69 -0
  42. package/dist/migration-snapshot-OM5jQN1-.mjs.map +1 -0
  43. package/dist/migration-state.d.mts +41 -0
  44. package/dist/migration-state.d.mts.map +1 -0
  45. package/dist/migration-state.mjs +155 -0
  46. package/dist/migration-state.mjs.map +1 -0
  47. package/dist/migrations-manifest.json +109 -0
  48. package/dist/pglite-preparation.d.mts +23 -0
  49. package/dist/pglite-preparation.d.mts.map +1 -0
  50. package/dist/pglite-preparation.mjs +77 -0
  51. package/dist/pglite-preparation.mjs.map +1 -0
  52. package/dist/pglite-store.d.mts +29 -0
  53. package/dist/pglite-store.d.mts.map +1 -0
  54. package/dist/pglite-store.mjs +117 -0
  55. package/dist/pglite-store.mjs.map +1 -0
  56. package/dist/relations.d.mts +2 -0
  57. package/dist/relations.mjs +307 -0
  58. package/dist/relations.mjs.map +1 -0
  59. package/dist/resource.d.mts +50 -0
  60. package/dist/resource.d.mts.map +1 -0
  61. package/dist/resource.mjs +123 -0
  62. package/dist/resource.mjs.map +1 -0
  63. package/dist/rolldown-runtime-D7D4PA-g.mjs +13 -0
  64. package/dist/schema.d.mts +2 -0
  65. package/dist/schema.mjs +495 -0
  66. package/dist/schema.mjs.map +1 -0
  67. package/dist/slug.d.mts +28 -0
  68. package/dist/slug.d.mts.map +1 -0
  69. package/dist/slug.mjs +55 -0
  70. package/dist/slug.mjs.map +1 -0
  71. package/dist/text.d.mts +10 -0
  72. package/dist/text.d.mts.map +1 -0
  73. package/dist/text.mjs +11 -0
  74. package/dist/text.mjs.map +1 -0
  75. package/dist/uuid-CKMzlIND.d.mts +26 -0
  76. package/dist/uuid-CKMzlIND.d.mts.map +1 -0
  77. package/dist/uuid.d.mts +2 -0
  78. package/dist/uuid.mjs +28 -0
  79. package/dist/uuid.mjs.map +1 -0
  80. package/drizzle/20260622021748_init/migration.sql +25 -0
  81. package/drizzle/20260622021748_init/snapshot.json +246 -0
  82. package/drizzle/20260623162238_dear_felicia_hardy/migration.sql +5 -0
  83. package/drizzle/20260623162238_dear_felicia_hardy/snapshot.json +321 -0
  84. package/drizzle/20260624094817_lethal_sinister_six/migration.sql +2 -0
  85. package/drizzle/20260624094817_lethal_sinister_six/snapshot.json +347 -0
  86. package/drizzle/20260716000333_email_auth/migration.sql +20 -0
  87. package/drizzle/20260716000333_email_auth/snapshot.json +575 -0
  88. package/drizzle/20260723065002_chief_colleen_wing/migration.sql +2 -0
  89. package/drizzle/20260723065002_chief_colleen_wing/snapshot.json +595 -0
  90. package/drizzle/20260802205417_separate-instance-local-remote/migration.sql +26 -0
  91. package/drizzle/20260802205417_separate-instance-local-remote/snapshot.json +768 -0
  92. package/drizzle/20260804061119_instances-local-remote-constraint/migration.sql +7 -0
  93. package/drizzle/20260804061119_instances-local-remote-constraint/snapshot.json +843 -0
  94. package/drizzle/20260818080259_dark_night_thrasher/migration.sql +15 -0
  95. package/drizzle/20260818080259_dark_night_thrasher/snapshot.json +722 -0
  96. package/drizzle/20260821072150_merge_remote_actors/migration.sql +54 -0
  97. package/drizzle/20260821072150_merge_remote_actors/snapshot.json +1312 -0
  98. package/drizzle/20260906052949_rename_followees_to_following/migration.sql +2 -0
  99. package/drizzle/20260906052949_rename_followees_to_following/snapshot.json +1315 -0
  100. package/drizzle/20260908062446_rename_login_tokens_to_login_challenges/migration.sql +1 -0
  101. package/drizzle/20260908062446_rename_login_tokens_to_login_challenges/snapshot.json +1312 -0
  102. package/drizzle/20260908065945_simplify_login_challenges/migration.sql +7 -0
  103. package/drizzle/20260908065945_simplify_login_challenges/snapshot.json +1290 -0
  104. package/drizzle/20260915061356_tighten_slug_constraint/migration.sql +12 -0
  105. package/drizzle/20260915061356_tighten_slug_constraint/snapshot.json +1290 -0
  106. package/drizzle/20260915063339_widen_instance_host/migration.sql +1 -0
  107. package/drizzle/20260915063339_widen_instance_host/snapshot.json +1290 -0
  108. package/drizzle/20260916085902_add_objects_activities_and_resources/migration.sql +110 -0
  109. package/drizzle/20260916085902_add_objects_activities_and_resources/snapshot.json +2263 -0
  110. package/drizzle/20260917163517_order_local_outbox_items/migration.sql +22 -0
  111. package/drizzle/20260917163517_order_local_outbox_items/snapshot.json +2263 -0
  112. package/drizzle/20260918071839_add_activity_object_index/migration.sql +1 -0
  113. package/drizzle/20260918071839_add_activity_object_index/snapshot.json +2298 -0
  114. package/drizzle/20261006061745_add_activity_deliveries_and_keys/migration.sql +106 -0
  115. package/drizzle/20261006061745_add_activity_deliveries_and_keys/snapshot.json +3538 -0
  116. package/drizzle/20261006085045_snake_case_columns/migration.sql +42 -0
  117. package/drizzle/20261006085045_snake_case_columns/snapshot.json +3570 -0
  118. package/drizzle/20261006122653_local_actor_keys/migration.sql +11 -0
  119. package/drizzle/20261006122653_local_actor_keys/snapshot.json +3627 -0
  120. package/drizzle/20261010044954_link_activity_deliveries_to_activities/migration.sql +8 -0
  121. package/drizzle/20261010044954_link_activity_deliveries_to_activities/snapshot.json +3714 -0
  122. package/drizzle/20261010073134_check_inbound_activity_link/migration.sql +1 -0
  123. package/drizzle/20261010073134_check_inbound_activity_link/snapshot.json +3721 -0
  124. package/drizzle/20261010104304_record_object_activity/migration.sql +3 -0
  125. package/drizzle/20261010104304_record_object_activity/snapshot.json +3756 -0
  126. package/drizzle/20261010111648_record_delivery_snapshot/migration.sql +29 -0
  127. package/drizzle/20261010111648_record_delivery_snapshot/snapshot.json +3769 -0
  128. package/drizzle/20261011144453_record_object_snapshot/migration.sql +10 -0
  129. package/drizzle/20261011144453_record_object_snapshot/snapshot.json +3808 -0
  130. package/drizzle/20261011192718_record_actor_followers/migration.sql +1 -0
  131. package/drizzle/20261011192718_record_actor_followers/snapshot.json +3821 -0
  132. package/package.json +193 -3
@@ -0,0 +1,843 @@
1
+ {
2
+ "version": "8",
3
+ "dialect": "postgres",
4
+ "id": "c40a9b41-e120-4f01-865b-68583fbb921c",
5
+ "prevIds": ["08f1dfcb-1110-4550-9777-36d017ecfb10"],
6
+ "ddl": [
7
+ {
8
+ "values": ["Local", "Remote"],
9
+ "name": "location",
10
+ "entityType": "enums",
11
+ "schema": "public"
12
+ },
13
+ {
14
+ "isRlsEnabled": false,
15
+ "name": "accounts",
16
+ "entityType": "tables",
17
+ "schema": "public"
18
+ },
19
+ {
20
+ "isRlsEnabled": false,
21
+ "name": "instance_members",
22
+ "entityType": "tables",
23
+ "schema": "public"
24
+ },
25
+ {
26
+ "isRlsEnabled": false,
27
+ "name": "instances",
28
+ "entityType": "tables",
29
+ "schema": "public"
30
+ },
31
+ {
32
+ "isRlsEnabled": false,
33
+ "name": "local_instances",
34
+ "entityType": "tables",
35
+ "schema": "public"
36
+ },
37
+ {
38
+ "isRlsEnabled": false,
39
+ "name": "login_tokens",
40
+ "entityType": "tables",
41
+ "schema": "public"
42
+ },
43
+ {
44
+ "isRlsEnabled": false,
45
+ "name": "remote_instances",
46
+ "entityType": "tables",
47
+ "schema": "public"
48
+ },
49
+ {
50
+ "isRlsEnabled": false,
51
+ "name": "sessions",
52
+ "entityType": "tables",
53
+ "schema": "public"
54
+ },
55
+ {
56
+ "type": "uuid",
57
+ "typeSchema": null,
58
+ "notNull": true,
59
+ "dimensions": 0,
60
+ "default": null,
61
+ "generated": null,
62
+ "identity": null,
63
+ "name": "id",
64
+ "entityType": "columns",
65
+ "schema": "public",
66
+ "table": "accounts"
67
+ },
68
+ {
69
+ "type": "varchar(255)",
70
+ "typeSchema": null,
71
+ "notNull": true,
72
+ "dimensions": 0,
73
+ "default": null,
74
+ "generated": null,
75
+ "identity": null,
76
+ "name": "email",
77
+ "entityType": "columns",
78
+ "schema": "public",
79
+ "table": "accounts"
80
+ },
81
+ {
82
+ "type": "varchar(100)",
83
+ "typeSchema": null,
84
+ "notNull": true,
85
+ "dimensions": 0,
86
+ "default": null,
87
+ "generated": null,
88
+ "identity": null,
89
+ "name": "name",
90
+ "entityType": "columns",
91
+ "schema": "public",
92
+ "table": "accounts"
93
+ },
94
+ {
95
+ "type": "integer",
96
+ "typeSchema": null,
97
+ "notNull": true,
98
+ "dimensions": 0,
99
+ "default": "10",
100
+ "generated": null,
101
+ "identity": null,
102
+ "name": "max_instances",
103
+ "entityType": "columns",
104
+ "schema": "public",
105
+ "table": "accounts"
106
+ },
107
+ {
108
+ "type": "boolean",
109
+ "typeSchema": null,
110
+ "notNull": true,
111
+ "dimensions": 0,
112
+ "default": "false",
113
+ "generated": null,
114
+ "identity": null,
115
+ "name": "admin",
116
+ "entityType": "columns",
117
+ "schema": "public",
118
+ "table": "accounts"
119
+ },
120
+ {
121
+ "type": "timestamp with time zone",
122
+ "typeSchema": null,
123
+ "notNull": true,
124
+ "dimensions": 0,
125
+ "default": "CURRENT_TIMESTAMP",
126
+ "generated": null,
127
+ "identity": null,
128
+ "name": "created",
129
+ "entityType": "columns",
130
+ "schema": "public",
131
+ "table": "accounts"
132
+ },
133
+ {
134
+ "type": "uuid",
135
+ "typeSchema": null,
136
+ "notNull": true,
137
+ "dimensions": 0,
138
+ "default": null,
139
+ "generated": null,
140
+ "identity": null,
141
+ "name": "accountId",
142
+ "entityType": "columns",
143
+ "schema": "public",
144
+ "table": "instance_members"
145
+ },
146
+ {
147
+ "type": "uuid",
148
+ "typeSchema": null,
149
+ "notNull": true,
150
+ "dimensions": 0,
151
+ "default": null,
152
+ "generated": null,
153
+ "identity": null,
154
+ "name": "instanceId",
155
+ "entityType": "columns",
156
+ "schema": "public",
157
+ "table": "instance_members"
158
+ },
159
+ {
160
+ "type": "boolean",
161
+ "typeSchema": null,
162
+ "notNull": true,
163
+ "dimensions": 0,
164
+ "default": "false",
165
+ "generated": null,
166
+ "identity": null,
167
+ "name": "admin",
168
+ "entityType": "columns",
169
+ "schema": "public",
170
+ "table": "instance_members"
171
+ },
172
+ {
173
+ "type": "timestamp with time zone",
174
+ "typeSchema": null,
175
+ "notNull": false,
176
+ "dimensions": 0,
177
+ "default": null,
178
+ "generated": null,
179
+ "identity": null,
180
+ "name": "accepted",
181
+ "entityType": "columns",
182
+ "schema": "public",
183
+ "table": "instance_members"
184
+ },
185
+ {
186
+ "type": "timestamp with time zone",
187
+ "typeSchema": null,
188
+ "notNull": true,
189
+ "dimensions": 0,
190
+ "default": "CURRENT_TIMESTAMP",
191
+ "generated": null,
192
+ "identity": null,
193
+ "name": "created",
194
+ "entityType": "columns",
195
+ "schema": "public",
196
+ "table": "instance_members"
197
+ },
198
+ {
199
+ "type": "uuid",
200
+ "typeSchema": null,
201
+ "notNull": true,
202
+ "dimensions": 0,
203
+ "default": null,
204
+ "generated": null,
205
+ "identity": null,
206
+ "name": "id",
207
+ "entityType": "columns",
208
+ "schema": "public",
209
+ "table": "instances"
210
+ },
211
+ {
212
+ "type": "location",
213
+ "typeSchema": "public",
214
+ "notNull": true,
215
+ "dimensions": 0,
216
+ "default": null,
217
+ "generated": null,
218
+ "identity": null,
219
+ "name": "location",
220
+ "entityType": "columns",
221
+ "schema": "public",
222
+ "table": "instances"
223
+ },
224
+ {
225
+ "type": "timestamp with time zone",
226
+ "typeSchema": null,
227
+ "notNull": true,
228
+ "dimensions": 0,
229
+ "default": "CURRENT_TIMESTAMP",
230
+ "generated": null,
231
+ "identity": null,
232
+ "name": "created",
233
+ "entityType": "columns",
234
+ "schema": "public",
235
+ "table": "instances"
236
+ },
237
+ {
238
+ "type": "uuid",
239
+ "typeSchema": null,
240
+ "notNull": true,
241
+ "dimensions": 0,
242
+ "default": null,
243
+ "generated": null,
244
+ "identity": null,
245
+ "name": "id",
246
+ "entityType": "columns",
247
+ "schema": "public",
248
+ "table": "local_instances"
249
+ },
250
+ {
251
+ "type": "varchar(63)",
252
+ "typeSchema": null,
253
+ "notNull": true,
254
+ "dimensions": 0,
255
+ "default": null,
256
+ "generated": null,
257
+ "identity": null,
258
+ "name": "slug",
259
+ "entityType": "columns",
260
+ "schema": "public",
261
+ "table": "local_instances"
262
+ },
263
+ {
264
+ "type": "timestamp with time zone",
265
+ "typeSchema": null,
266
+ "notNull": true,
267
+ "dimensions": 0,
268
+ "default": null,
269
+ "generated": null,
270
+ "identity": null,
271
+ "name": "expires",
272
+ "entityType": "columns",
273
+ "schema": "public",
274
+ "table": "local_instances"
275
+ },
276
+ {
277
+ "type": "integer",
278
+ "typeSchema": null,
279
+ "notNull": true,
280
+ "dimensions": 0,
281
+ "default": "10",
282
+ "generated": null,
283
+ "identity": null,
284
+ "name": "maxActors",
285
+ "entityType": "columns",
286
+ "schema": "public",
287
+ "table": "local_instances"
288
+ },
289
+ {
290
+ "type": "location",
291
+ "typeSchema": "public",
292
+ "notNull": true,
293
+ "dimensions": 0,
294
+ "default": "'Local'",
295
+ "generated": null,
296
+ "identity": null,
297
+ "name": "location",
298
+ "entityType": "columns",
299
+ "schema": "public",
300
+ "table": "local_instances"
301
+ },
302
+ {
303
+ "type": "uuid",
304
+ "typeSchema": null,
305
+ "notNull": true,
306
+ "dimensions": 0,
307
+ "default": null,
308
+ "generated": null,
309
+ "identity": null,
310
+ "name": "id",
311
+ "entityType": "columns",
312
+ "schema": "public",
313
+ "table": "login_tokens"
314
+ },
315
+ {
316
+ "type": "uuid",
317
+ "typeSchema": null,
318
+ "notNull": true,
319
+ "dimensions": 0,
320
+ "default": null,
321
+ "generated": null,
322
+ "identity": null,
323
+ "name": "accountId",
324
+ "entityType": "columns",
325
+ "schema": "public",
326
+ "table": "login_tokens"
327
+ },
328
+ {
329
+ "type": "varchar(64)",
330
+ "typeSchema": null,
331
+ "notNull": true,
332
+ "dimensions": 0,
333
+ "default": null,
334
+ "generated": null,
335
+ "identity": null,
336
+ "name": "tokenHash",
337
+ "entityType": "columns",
338
+ "schema": "public",
339
+ "table": "login_tokens"
340
+ },
341
+ {
342
+ "type": "varchar(64)",
343
+ "typeSchema": null,
344
+ "notNull": true,
345
+ "dimensions": 0,
346
+ "default": null,
347
+ "generated": null,
348
+ "identity": null,
349
+ "name": "codeHash",
350
+ "entityType": "columns",
351
+ "schema": "public",
352
+ "table": "login_tokens"
353
+ },
354
+ {
355
+ "type": "timestamp with time zone",
356
+ "typeSchema": null,
357
+ "notNull": true,
358
+ "dimensions": 0,
359
+ "default": "CURRENT_TIMESTAMP",
360
+ "generated": null,
361
+ "identity": null,
362
+ "name": "created",
363
+ "entityType": "columns",
364
+ "schema": "public",
365
+ "table": "login_tokens"
366
+ },
367
+ {
368
+ "type": "timestamp with time zone",
369
+ "typeSchema": null,
370
+ "notNull": true,
371
+ "dimensions": 0,
372
+ "default": "CURRENT_TIMESTAMP + INTERVAL '15 minutes'",
373
+ "generated": null,
374
+ "identity": null,
375
+ "name": "expires",
376
+ "entityType": "columns",
377
+ "schema": "public",
378
+ "table": "login_tokens"
379
+ },
380
+ {
381
+ "type": "timestamp with time zone",
382
+ "typeSchema": null,
383
+ "notNull": false,
384
+ "dimensions": 0,
385
+ "default": null,
386
+ "generated": null,
387
+ "identity": null,
388
+ "name": "consumed",
389
+ "entityType": "columns",
390
+ "schema": "public",
391
+ "table": "login_tokens"
392
+ },
393
+ {
394
+ "type": "uuid",
395
+ "typeSchema": null,
396
+ "notNull": true,
397
+ "dimensions": 0,
398
+ "default": null,
399
+ "generated": null,
400
+ "identity": null,
401
+ "name": "id",
402
+ "entityType": "columns",
403
+ "schema": "public",
404
+ "table": "remote_instances"
405
+ },
406
+ {
407
+ "type": "varchar(100)",
408
+ "typeSchema": null,
409
+ "notNull": true,
410
+ "dimensions": 0,
411
+ "default": null,
412
+ "generated": null,
413
+ "identity": null,
414
+ "name": "host",
415
+ "entityType": "columns",
416
+ "schema": "public",
417
+ "table": "remote_instances"
418
+ },
419
+ {
420
+ "type": "text",
421
+ "typeSchema": null,
422
+ "notNull": false,
423
+ "dimensions": 0,
424
+ "default": null,
425
+ "generated": null,
426
+ "identity": null,
427
+ "name": "nodeInfoUrl",
428
+ "entityType": "columns",
429
+ "schema": "public",
430
+ "table": "remote_instances"
431
+ },
432
+ {
433
+ "type": "text",
434
+ "typeSchema": null,
435
+ "notNull": false,
436
+ "dimensions": 0,
437
+ "default": null,
438
+ "generated": null,
439
+ "identity": null,
440
+ "name": "software",
441
+ "entityType": "columns",
442
+ "schema": "public",
443
+ "table": "remote_instances"
444
+ },
445
+ {
446
+ "type": "text",
447
+ "typeSchema": null,
448
+ "notNull": false,
449
+ "dimensions": 0,
450
+ "default": null,
451
+ "generated": null,
452
+ "identity": null,
453
+ "name": "softwareVersion",
454
+ "entityType": "columns",
455
+ "schema": "public",
456
+ "table": "remote_instances"
457
+ },
458
+ {
459
+ "type": "location",
460
+ "typeSchema": "public",
461
+ "notNull": true,
462
+ "dimensions": 0,
463
+ "default": "'Remote'",
464
+ "generated": null,
465
+ "identity": null,
466
+ "name": "location",
467
+ "entityType": "columns",
468
+ "schema": "public",
469
+ "table": "remote_instances"
470
+ },
471
+ {
472
+ "type": "uuid",
473
+ "typeSchema": null,
474
+ "notNull": true,
475
+ "dimensions": 0,
476
+ "default": null,
477
+ "generated": null,
478
+ "identity": null,
479
+ "name": "id",
480
+ "entityType": "columns",
481
+ "schema": "public",
482
+ "table": "sessions"
483
+ },
484
+ {
485
+ "type": "uuid",
486
+ "typeSchema": null,
487
+ "notNull": true,
488
+ "dimensions": 0,
489
+ "default": null,
490
+ "generated": null,
491
+ "identity": null,
492
+ "name": "accountId",
493
+ "entityType": "columns",
494
+ "schema": "public",
495
+ "table": "sessions"
496
+ },
497
+ {
498
+ "type": "varchar(64)",
499
+ "typeSchema": null,
500
+ "notNull": true,
501
+ "dimensions": 0,
502
+ "default": null,
503
+ "generated": null,
504
+ "identity": null,
505
+ "name": "tokenHash",
506
+ "entityType": "columns",
507
+ "schema": "public",
508
+ "table": "sessions"
509
+ },
510
+ {
511
+ "type": "timestamp with time zone",
512
+ "typeSchema": null,
513
+ "notNull": true,
514
+ "dimensions": 0,
515
+ "default": "CURRENT_TIMESTAMP",
516
+ "generated": null,
517
+ "identity": null,
518
+ "name": "created",
519
+ "entityType": "columns",
520
+ "schema": "public",
521
+ "table": "sessions"
522
+ },
523
+ {
524
+ "type": "timestamp with time zone",
525
+ "typeSchema": null,
526
+ "notNull": true,
527
+ "dimensions": 0,
528
+ "default": "CURRENT_TIMESTAMP + INTERVAL '1 month'",
529
+ "generated": null,
530
+ "identity": null,
531
+ "name": "expires",
532
+ "entityType": "columns",
533
+ "schema": "public",
534
+ "table": "sessions"
535
+ },
536
+ {
537
+ "nameExplicit": false,
538
+ "columns": [
539
+ {
540
+ "value": "accountId",
541
+ "isExpression": false,
542
+ "asc": true,
543
+ "nullsFirst": false,
544
+ "opclass": null
545
+ }
546
+ ],
547
+ "isUnique": false,
548
+ "where": "\"accepted\" IS NOT NULL",
549
+ "with": "",
550
+ "method": "btree",
551
+ "concurrently": false,
552
+ "name": "instance_members_accountId_index",
553
+ "entityType": "indexes",
554
+ "schema": "public",
555
+ "table": "instance_members"
556
+ },
557
+ {
558
+ "nameExplicit": false,
559
+ "columns": [
560
+ {
561
+ "value": "instanceId",
562
+ "isExpression": false,
563
+ "asc": true,
564
+ "nullsFirst": false,
565
+ "opclass": null
566
+ }
567
+ ],
568
+ "isUnique": false,
569
+ "where": "\"accepted\" IS NOT NULL",
570
+ "with": "",
571
+ "method": "btree",
572
+ "concurrently": false,
573
+ "name": "instance_members_instanceId_index",
574
+ "entityType": "indexes",
575
+ "schema": "public",
576
+ "table": "instance_members"
577
+ },
578
+ {
579
+ "nameExplicit": false,
580
+ "columns": ["accountId"],
581
+ "schemaTo": "public",
582
+ "tableTo": "accounts",
583
+ "columnsTo": ["id"],
584
+ "onUpdate": "NO ACTION",
585
+ "onDelete": "NO ACTION",
586
+ "name": "instance_members_accountId_accounts_id_fkey",
587
+ "entityType": "fks",
588
+ "schema": "public",
589
+ "table": "instance_members"
590
+ },
591
+ {
592
+ "nameExplicit": false,
593
+ "columns": ["instanceId"],
594
+ "schemaTo": "public",
595
+ "tableTo": "instances",
596
+ "columnsTo": ["id"],
597
+ "onUpdate": "NO ACTION",
598
+ "onDelete": "NO ACTION",
599
+ "name": "instance_members_instanceId_instances_id_fkey",
600
+ "entityType": "fks",
601
+ "schema": "public",
602
+ "table": "instance_members"
603
+ },
604
+ {
605
+ "nameExplicit": false,
606
+ "columns": ["id"],
607
+ "schemaTo": "public",
608
+ "tableTo": "instances",
609
+ "columnsTo": ["id"],
610
+ "onUpdate": "NO ACTION",
611
+ "onDelete": "CASCADE",
612
+ "name": "local_instances_id_instances_id_fkey",
613
+ "entityType": "fks",
614
+ "schema": "public",
615
+ "table": "local_instances"
616
+ },
617
+ {
618
+ "nameExplicit": true,
619
+ "columns": ["id", "location"],
620
+ "schemaTo": "public",
621
+ "tableTo": "instances",
622
+ "columnsTo": ["id", "location"],
623
+ "onUpdate": "NO ACTION",
624
+ "onDelete": "CASCADE",
625
+ "name": "local_instance_fk",
626
+ "entityType": "fks",
627
+ "schema": "public",
628
+ "table": "local_instances"
629
+ },
630
+ {
631
+ "nameExplicit": false,
632
+ "columns": ["accountId"],
633
+ "schemaTo": "public",
634
+ "tableTo": "accounts",
635
+ "columnsTo": ["id"],
636
+ "onUpdate": "NO ACTION",
637
+ "onDelete": "CASCADE",
638
+ "name": "login_tokens_accountId_accounts_id_fkey",
639
+ "entityType": "fks",
640
+ "schema": "public",
641
+ "table": "login_tokens"
642
+ },
643
+ {
644
+ "nameExplicit": false,
645
+ "columns": ["id"],
646
+ "schemaTo": "public",
647
+ "tableTo": "instances",
648
+ "columnsTo": ["id"],
649
+ "onUpdate": "NO ACTION",
650
+ "onDelete": "CASCADE",
651
+ "name": "remote_instances_id_instances_id_fkey",
652
+ "entityType": "fks",
653
+ "schema": "public",
654
+ "table": "remote_instances"
655
+ },
656
+ {
657
+ "nameExplicit": true,
658
+ "columns": ["id", "location"],
659
+ "schemaTo": "public",
660
+ "tableTo": "instances",
661
+ "columnsTo": ["id", "location"],
662
+ "onUpdate": "NO ACTION",
663
+ "onDelete": "CASCADE",
664
+ "name": "remote_instance_fk",
665
+ "entityType": "fks",
666
+ "schema": "public",
667
+ "table": "remote_instances"
668
+ },
669
+ {
670
+ "nameExplicit": false,
671
+ "columns": ["accountId"],
672
+ "schemaTo": "public",
673
+ "tableTo": "accounts",
674
+ "columnsTo": ["id"],
675
+ "onUpdate": "NO ACTION",
676
+ "onDelete": "CASCADE",
677
+ "name": "sessions_accountId_accounts_id_fkey",
678
+ "entityType": "fks",
679
+ "schema": "public",
680
+ "table": "sessions"
681
+ },
682
+ {
683
+ "columns": ["instanceId", "accountId"],
684
+ "nameExplicit": false,
685
+ "name": "instance_members_pkey",
686
+ "entityType": "pks",
687
+ "schema": "public",
688
+ "table": "instance_members"
689
+ },
690
+ {
691
+ "columns": ["id"],
692
+ "nameExplicit": false,
693
+ "name": "accounts_pkey",
694
+ "schema": "public",
695
+ "table": "accounts",
696
+ "entityType": "pks"
697
+ },
698
+ {
699
+ "columns": ["id"],
700
+ "nameExplicit": false,
701
+ "name": "instances_pkey",
702
+ "schema": "public",
703
+ "table": "instances",
704
+ "entityType": "pks"
705
+ },
706
+ {
707
+ "columns": ["id"],
708
+ "nameExplicit": false,
709
+ "name": "local_instances_pkey",
710
+ "schema": "public",
711
+ "table": "local_instances",
712
+ "entityType": "pks"
713
+ },
714
+ {
715
+ "columns": ["id"],
716
+ "nameExplicit": false,
717
+ "name": "login_tokens_pkey",
718
+ "schema": "public",
719
+ "table": "login_tokens",
720
+ "entityType": "pks"
721
+ },
722
+ {
723
+ "columns": ["id"],
724
+ "nameExplicit": false,
725
+ "name": "remote_instances_pkey",
726
+ "schema": "public",
727
+ "table": "remote_instances",
728
+ "entityType": "pks"
729
+ },
730
+ {
731
+ "columns": ["id"],
732
+ "nameExplicit": false,
733
+ "name": "sessions_pkey",
734
+ "schema": "public",
735
+ "table": "sessions",
736
+ "entityType": "pks"
737
+ },
738
+ {
739
+ "nameExplicit": true,
740
+ "columns": ["id", "location"],
741
+ "nullsNotDistinct": false,
742
+ "name": "instances_id_location_key",
743
+ "entityType": "uniques",
744
+ "schema": "public",
745
+ "table": "instances"
746
+ },
747
+ {
748
+ "nameExplicit": false,
749
+ "columns": ["email"],
750
+ "nullsNotDistinct": false,
751
+ "name": "accounts_email_key",
752
+ "schema": "public",
753
+ "table": "accounts",
754
+ "entityType": "uniques"
755
+ },
756
+ {
757
+ "nameExplicit": false,
758
+ "columns": ["slug"],
759
+ "nullsNotDistinct": false,
760
+ "name": "local_instances_slug_key",
761
+ "schema": "public",
762
+ "table": "local_instances",
763
+ "entityType": "uniques"
764
+ },
765
+ {
766
+ "nameExplicit": false,
767
+ "columns": ["tokenHash"],
768
+ "nullsNotDistinct": false,
769
+ "name": "login_tokens_tokenHash_key",
770
+ "schema": "public",
771
+ "table": "login_tokens",
772
+ "entityType": "uniques"
773
+ },
774
+ {
775
+ "nameExplicit": false,
776
+ "columns": ["host"],
777
+ "nullsNotDistinct": false,
778
+ "name": "remote_instances_host_key",
779
+ "schema": "public",
780
+ "table": "remote_instances",
781
+ "entityType": "uniques"
782
+ },
783
+ {
784
+ "nameExplicit": false,
785
+ "columns": ["tokenHash"],
786
+ "nullsNotDistinct": false,
787
+ "name": "sessions_tokenHash_key",
788
+ "schema": "public",
789
+ "table": "sessions",
790
+ "entityType": "uniques"
791
+ },
792
+ {
793
+ "value": "\"email\" ~ '^[^@]+@[^@]+\\.[^@]+$'",
794
+ "name": "accounts_email_check",
795
+ "entityType": "checks",
796
+ "schema": "public",
797
+ "table": "accounts"
798
+ },
799
+ {
800
+ "value": "\"max_instances\" >= 0",
801
+ "name": "accounts_max_instances_check",
802
+ "entityType": "checks",
803
+ "schema": "public",
804
+ "table": "accounts"
805
+ },
806
+ {
807
+ "value": "trim(both from \"name\") <> ''",
808
+ "name": "accounts_name_check",
809
+ "entityType": "checks",
810
+ "schema": "public",
811
+ "table": "accounts"
812
+ },
813
+ {
814
+ "value": "\"slug\" ~ '^[a-z0-9-]{4,63}$'",
815
+ "name": "instances_slug_check",
816
+ "entityType": "checks",
817
+ "schema": "public",
818
+ "table": "local_instances"
819
+ },
820
+ {
821
+ "value": "\"maxActors\" > 0",
822
+ "name": "instances_max_actors_check",
823
+ "entityType": "checks",
824
+ "schema": "public",
825
+ "table": "local_instances"
826
+ },
827
+ {
828
+ "value": "\"location\" = 'Local'",
829
+ "name": "local_check",
830
+ "entityType": "checks",
831
+ "schema": "public",
832
+ "table": "local_instances"
833
+ },
834
+ {
835
+ "value": "\"location\" = 'Remote'",
836
+ "name": "remote_check",
837
+ "entityType": "checks",
838
+ "schema": "public",
839
+ "table": "remote_instances"
840
+ }
841
+ ],
842
+ "renames": []
843
+ }