@synoikia/core 0.1.0 → 0.2.0

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.
@@ -0,0 +1,2354 @@
1
+ {
2
+ "version": "6",
3
+ "dialect": "sqlite",
4
+ "id": "5c6be4dd-6336-4294-ad79-3d53e25036f6",
5
+ "prevId": "403b0df6-8543-47a5-8380-3dc57cc740af",
6
+ "tables": {
7
+ "approval_links": {
8
+ "name": "approval_links",
9
+ "columns": {
10
+ "token_hash": {
11
+ "name": "token_hash",
12
+ "type": "text",
13
+ "primaryKey": true,
14
+ "notNull": true,
15
+ "autoincrement": false
16
+ },
17
+ "approval_id": {
18
+ "name": "approval_id",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true,
22
+ "autoincrement": false
23
+ },
24
+ "action": {
25
+ "name": "action",
26
+ "type": "text",
27
+ "primaryKey": false,
28
+ "notNull": true,
29
+ "autoincrement": false
30
+ },
31
+ "expires_at": {
32
+ "name": "expires_at",
33
+ "type": "integer",
34
+ "primaryKey": false,
35
+ "notNull": true,
36
+ "autoincrement": false
37
+ },
38
+ "used_at": {
39
+ "name": "used_at",
40
+ "type": "integer",
41
+ "primaryKey": false,
42
+ "notNull": false,
43
+ "autoincrement": false
44
+ }
45
+ },
46
+ "indexes": {},
47
+ "foreignKeys": {
48
+ "approval_links_approval_id_pending_approvals_id_fk": {
49
+ "name": "approval_links_approval_id_pending_approvals_id_fk",
50
+ "tableFrom": "approval_links",
51
+ "tableTo": "pending_approvals",
52
+ "columnsFrom": [
53
+ "approval_id"
54
+ ],
55
+ "columnsTo": [
56
+ "id"
57
+ ],
58
+ "onDelete": "cascade",
59
+ "onUpdate": "no action"
60
+ }
61
+ },
62
+ "compositePrimaryKeys": {},
63
+ "uniqueConstraints": {},
64
+ "checkConstraints": {}
65
+ },
66
+ "audit_log": {
67
+ "name": "audit_log",
68
+ "columns": {
69
+ "id": {
70
+ "name": "id",
71
+ "type": "integer",
72
+ "primaryKey": true,
73
+ "notNull": true,
74
+ "autoincrement": true
75
+ },
76
+ "at": {
77
+ "name": "at",
78
+ "type": "integer",
79
+ "primaryKey": false,
80
+ "notNull": true,
81
+ "autoincrement": false
82
+ },
83
+ "kind": {
84
+ "name": "kind",
85
+ "type": "text",
86
+ "primaryKey": false,
87
+ "notNull": true,
88
+ "autoincrement": false
89
+ },
90
+ "instance_id": {
91
+ "name": "instance_id",
92
+ "type": "text",
93
+ "primaryKey": false,
94
+ "notNull": false,
95
+ "autoincrement": false
96
+ },
97
+ "operation_key": {
98
+ "name": "operation_key",
99
+ "type": "text",
100
+ "primaryKey": false,
101
+ "notNull": false,
102
+ "autoincrement": false
103
+ },
104
+ "classification": {
105
+ "name": "classification",
106
+ "type": "text",
107
+ "primaryKey": false,
108
+ "notNull": false,
109
+ "autoincrement": false
110
+ },
111
+ "decision": {
112
+ "name": "decision",
113
+ "type": "text",
114
+ "primaryKey": false,
115
+ "notNull": false,
116
+ "autoincrement": false
117
+ },
118
+ "actor_kind": {
119
+ "name": "actor_kind",
120
+ "type": "text",
121
+ "primaryKey": false,
122
+ "notNull": true,
123
+ "autoincrement": false
124
+ },
125
+ "actor_id": {
126
+ "name": "actor_id",
127
+ "type": "text",
128
+ "primaryKey": false,
129
+ "notNull": false,
130
+ "autoincrement": false
131
+ },
132
+ "decided_by": {
133
+ "name": "decided_by",
134
+ "type": "text",
135
+ "primaryKey": false,
136
+ "notNull": false,
137
+ "autoincrement": false
138
+ },
139
+ "decided_via": {
140
+ "name": "decided_via",
141
+ "type": "text",
142
+ "primaryKey": false,
143
+ "notNull": false,
144
+ "autoincrement": false
145
+ },
146
+ "params": {
147
+ "name": "params",
148
+ "type": "text",
149
+ "primaryKey": false,
150
+ "notNull": false,
151
+ "autoincrement": false
152
+ },
153
+ "resolved_targets": {
154
+ "name": "resolved_targets",
155
+ "type": "text",
156
+ "primaryKey": false,
157
+ "notNull": false,
158
+ "autoincrement": false
159
+ },
160
+ "result_status": {
161
+ "name": "result_status",
162
+ "type": "text",
163
+ "primaryKey": false,
164
+ "notNull": false,
165
+ "autoincrement": false
166
+ },
167
+ "duration_ms": {
168
+ "name": "duration_ms",
169
+ "type": "integer",
170
+ "primaryKey": false,
171
+ "notNull": false,
172
+ "autoincrement": false
173
+ },
174
+ "detail": {
175
+ "name": "detail",
176
+ "type": "text",
177
+ "primaryKey": false,
178
+ "notNull": false,
179
+ "autoincrement": false
180
+ }
181
+ },
182
+ "indexes": {
183
+ "audit_at_idx": {
184
+ "name": "audit_at_idx",
185
+ "columns": [
186
+ "at"
187
+ ],
188
+ "isUnique": false
189
+ },
190
+ "audit_instance_at_idx": {
191
+ "name": "audit_instance_at_idx",
192
+ "columns": [
193
+ "instance_id",
194
+ "at"
195
+ ],
196
+ "isUnique": false
197
+ }
198
+ },
199
+ "foreignKeys": {},
200
+ "compositePrimaryKeys": {},
201
+ "uniqueConstraints": {},
202
+ "checkConstraints": {}
203
+ },
204
+ "guides": {
205
+ "name": "guides",
206
+ "columns": {
207
+ "id": {
208
+ "name": "id",
209
+ "type": "text",
210
+ "primaryKey": true,
211
+ "notNull": true,
212
+ "autoincrement": false
213
+ },
214
+ "instance_id": {
215
+ "name": "instance_id",
216
+ "type": "text",
217
+ "primaryKey": false,
218
+ "notNull": true,
219
+ "autoincrement": false
220
+ },
221
+ "operation_id": {
222
+ "name": "operation_id",
223
+ "type": "text",
224
+ "primaryKey": false,
225
+ "notNull": true,
226
+ "autoincrement": false
227
+ },
228
+ "version": {
229
+ "name": "version",
230
+ "type": "text",
231
+ "primaryKey": false,
232
+ "notNull": true,
233
+ "autoincrement": false
234
+ },
235
+ "content": {
236
+ "name": "content",
237
+ "type": "text",
238
+ "primaryKey": false,
239
+ "notNull": true,
240
+ "autoincrement": false
241
+ },
242
+ "fetched_at": {
243
+ "name": "fetched_at",
244
+ "type": "integer",
245
+ "primaryKey": false,
246
+ "notNull": true,
247
+ "autoincrement": false
248
+ }
249
+ },
250
+ "indexes": {},
251
+ "foreignKeys": {
252
+ "guides_instance_id_plugin_instances_id_fk": {
253
+ "name": "guides_instance_id_plugin_instances_id_fk",
254
+ "tableFrom": "guides",
255
+ "tableTo": "plugin_instances",
256
+ "columnsFrom": [
257
+ "instance_id"
258
+ ],
259
+ "columnsTo": [
260
+ "id"
261
+ ],
262
+ "onDelete": "cascade",
263
+ "onUpdate": "no action"
264
+ },
265
+ "guides_operation_id_operations_id_fk": {
266
+ "name": "guides_operation_id_operations_id_fk",
267
+ "tableFrom": "guides",
268
+ "tableTo": "operations",
269
+ "columnsFrom": [
270
+ "operation_id"
271
+ ],
272
+ "columnsTo": [
273
+ "id"
274
+ ],
275
+ "onDelete": "cascade",
276
+ "onUpdate": "no action"
277
+ }
278
+ },
279
+ "compositePrimaryKeys": {},
280
+ "uniqueConstraints": {},
281
+ "checkConstraints": {}
282
+ },
283
+ "mcp_tokens": {
284
+ "name": "mcp_tokens",
285
+ "columns": {
286
+ "id": {
287
+ "name": "id",
288
+ "type": "text",
289
+ "primaryKey": true,
290
+ "notNull": true,
291
+ "autoincrement": false
292
+ },
293
+ "name": {
294
+ "name": "name",
295
+ "type": "text",
296
+ "primaryKey": false,
297
+ "notNull": true,
298
+ "autoincrement": false
299
+ },
300
+ "token_hash": {
301
+ "name": "token_hash",
302
+ "type": "text",
303
+ "primaryKey": false,
304
+ "notNull": true,
305
+ "autoincrement": false
306
+ },
307
+ "scope": {
308
+ "name": "scope",
309
+ "type": "text",
310
+ "primaryKey": false,
311
+ "notNull": true,
312
+ "autoincrement": false
313
+ },
314
+ "access": {
315
+ "name": "access",
316
+ "type": "text",
317
+ "primaryKey": false,
318
+ "notNull": true,
319
+ "autoincrement": false,
320
+ "default": "'read'"
321
+ },
322
+ "created_by": {
323
+ "name": "created_by",
324
+ "type": "text",
325
+ "primaryKey": false,
326
+ "notNull": false,
327
+ "autoincrement": false
328
+ },
329
+ "created_at": {
330
+ "name": "created_at",
331
+ "type": "integer",
332
+ "primaryKey": false,
333
+ "notNull": true,
334
+ "autoincrement": false,
335
+ "default": "(unixepoch() * 1000)"
336
+ },
337
+ "expires_at": {
338
+ "name": "expires_at",
339
+ "type": "integer",
340
+ "primaryKey": false,
341
+ "notNull": false,
342
+ "autoincrement": false
343
+ },
344
+ "last_used_at": {
345
+ "name": "last_used_at",
346
+ "type": "integer",
347
+ "primaryKey": false,
348
+ "notNull": false,
349
+ "autoincrement": false
350
+ },
351
+ "revoked_at": {
352
+ "name": "revoked_at",
353
+ "type": "integer",
354
+ "primaryKey": false,
355
+ "notNull": false,
356
+ "autoincrement": false
357
+ }
358
+ },
359
+ "indexes": {
360
+ "mcp_tokens_token_hash_unique": {
361
+ "name": "mcp_tokens_token_hash_unique",
362
+ "columns": [
363
+ "token_hash"
364
+ ],
365
+ "isUnique": true
366
+ }
367
+ },
368
+ "foreignKeys": {
369
+ "mcp_tokens_created_by_users_id_fk": {
370
+ "name": "mcp_tokens_created_by_users_id_fk",
371
+ "tableFrom": "mcp_tokens",
372
+ "tableTo": "users",
373
+ "columnsFrom": [
374
+ "created_by"
375
+ ],
376
+ "columnsTo": [
377
+ "id"
378
+ ],
379
+ "onDelete": "no action",
380
+ "onUpdate": "no action"
381
+ }
382
+ },
383
+ "compositePrimaryKeys": {},
384
+ "uniqueConstraints": {},
385
+ "checkConstraints": {}
386
+ },
387
+ "notifier_channels": {
388
+ "name": "notifier_channels",
389
+ "columns": {
390
+ "id": {
391
+ "name": "id",
392
+ "type": "text",
393
+ "primaryKey": true,
394
+ "notNull": true,
395
+ "autoincrement": false
396
+ },
397
+ "kind": {
398
+ "name": "kind",
399
+ "type": "text",
400
+ "primaryKey": false,
401
+ "notNull": true,
402
+ "autoincrement": false
403
+ },
404
+ "name": {
405
+ "name": "name",
406
+ "type": "text",
407
+ "primaryKey": false,
408
+ "notNull": true,
409
+ "autoincrement": false
410
+ },
411
+ "config": {
412
+ "name": "config",
413
+ "type": "text",
414
+ "primaryKey": false,
415
+ "notNull": true,
416
+ "autoincrement": false
417
+ },
418
+ "secrets_enc": {
419
+ "name": "secrets_enc",
420
+ "type": "blob",
421
+ "primaryKey": false,
422
+ "notNull": false,
423
+ "autoincrement": false
424
+ },
425
+ "events": {
426
+ "name": "events",
427
+ "type": "text",
428
+ "primaryKey": false,
429
+ "notNull": true,
430
+ "autoincrement": false
431
+ },
432
+ "instance_filter": {
433
+ "name": "instance_filter",
434
+ "type": "text",
435
+ "primaryKey": false,
436
+ "notNull": false,
437
+ "autoincrement": false
438
+ },
439
+ "enabled": {
440
+ "name": "enabled",
441
+ "type": "integer",
442
+ "primaryKey": false,
443
+ "notNull": true,
444
+ "autoincrement": false,
445
+ "default": true
446
+ },
447
+ "last_sent_at": {
448
+ "name": "last_sent_at",
449
+ "type": "integer",
450
+ "primaryKey": false,
451
+ "notNull": false,
452
+ "autoincrement": false
453
+ },
454
+ "last_error": {
455
+ "name": "last_error",
456
+ "type": "text",
457
+ "primaryKey": false,
458
+ "notNull": false,
459
+ "autoincrement": false
460
+ }
461
+ },
462
+ "indexes": {},
463
+ "foreignKeys": {},
464
+ "compositePrimaryKeys": {},
465
+ "uniqueConstraints": {},
466
+ "checkConstraints": {}
467
+ },
468
+ "oauth_clients": {
469
+ "name": "oauth_clients",
470
+ "columns": {
471
+ "id": {
472
+ "name": "id",
473
+ "type": "text",
474
+ "primaryKey": true,
475
+ "notNull": true,
476
+ "autoincrement": false
477
+ },
478
+ "client_id": {
479
+ "name": "client_id",
480
+ "type": "text",
481
+ "primaryKey": false,
482
+ "notNull": true,
483
+ "autoincrement": false
484
+ },
485
+ "client_secret_hash": {
486
+ "name": "client_secret_hash",
487
+ "type": "text",
488
+ "primaryKey": false,
489
+ "notNull": false,
490
+ "autoincrement": false
491
+ },
492
+ "name": {
493
+ "name": "name",
494
+ "type": "text",
495
+ "primaryKey": false,
496
+ "notNull": true,
497
+ "autoincrement": false
498
+ },
499
+ "redirect_uris": {
500
+ "name": "redirect_uris",
501
+ "type": "text",
502
+ "primaryKey": false,
503
+ "notNull": true,
504
+ "autoincrement": false
505
+ },
506
+ "registered_via": {
507
+ "name": "registered_via",
508
+ "type": "text",
509
+ "primaryKey": false,
510
+ "notNull": true,
511
+ "autoincrement": false
512
+ },
513
+ "created_at": {
514
+ "name": "created_at",
515
+ "type": "integer",
516
+ "primaryKey": false,
517
+ "notNull": true,
518
+ "autoincrement": false,
519
+ "default": "(unixepoch() * 1000)"
520
+ },
521
+ "revoked_at": {
522
+ "name": "revoked_at",
523
+ "type": "integer",
524
+ "primaryKey": false,
525
+ "notNull": false,
526
+ "autoincrement": false
527
+ }
528
+ },
529
+ "indexes": {
530
+ "oauth_clients_client_id_unique": {
531
+ "name": "oauth_clients_client_id_unique",
532
+ "columns": [
533
+ "client_id"
534
+ ],
535
+ "isUnique": true
536
+ }
537
+ },
538
+ "foreignKeys": {},
539
+ "compositePrimaryKeys": {},
540
+ "uniqueConstraints": {},
541
+ "checkConstraints": {}
542
+ },
543
+ "oauth_codes": {
544
+ "name": "oauth_codes",
545
+ "columns": {
546
+ "code_hash": {
547
+ "name": "code_hash",
548
+ "type": "text",
549
+ "primaryKey": true,
550
+ "notNull": true,
551
+ "autoincrement": false
552
+ },
553
+ "grant_id": {
554
+ "name": "grant_id",
555
+ "type": "text",
556
+ "primaryKey": false,
557
+ "notNull": true,
558
+ "autoincrement": false
559
+ },
560
+ "code_challenge": {
561
+ "name": "code_challenge",
562
+ "type": "text",
563
+ "primaryKey": false,
564
+ "notNull": true,
565
+ "autoincrement": false
566
+ },
567
+ "redirect_uri": {
568
+ "name": "redirect_uri",
569
+ "type": "text",
570
+ "primaryKey": false,
571
+ "notNull": true,
572
+ "autoincrement": false
573
+ },
574
+ "resources": {
575
+ "name": "resources",
576
+ "type": "text",
577
+ "primaryKey": false,
578
+ "notNull": true,
579
+ "autoincrement": false
580
+ },
581
+ "expires_at": {
582
+ "name": "expires_at",
583
+ "type": "integer",
584
+ "primaryKey": false,
585
+ "notNull": true,
586
+ "autoincrement": false
587
+ },
588
+ "used_at": {
589
+ "name": "used_at",
590
+ "type": "integer",
591
+ "primaryKey": false,
592
+ "notNull": false,
593
+ "autoincrement": false
594
+ }
595
+ },
596
+ "indexes": {},
597
+ "foreignKeys": {
598
+ "oauth_codes_grant_id_oauth_grants_id_fk": {
599
+ "name": "oauth_codes_grant_id_oauth_grants_id_fk",
600
+ "tableFrom": "oauth_codes",
601
+ "tableTo": "oauth_grants",
602
+ "columnsFrom": [
603
+ "grant_id"
604
+ ],
605
+ "columnsTo": [
606
+ "id"
607
+ ],
608
+ "onDelete": "cascade",
609
+ "onUpdate": "no action"
610
+ }
611
+ },
612
+ "compositePrimaryKeys": {},
613
+ "uniqueConstraints": {},
614
+ "checkConstraints": {}
615
+ },
616
+ "oauth_grants": {
617
+ "name": "oauth_grants",
618
+ "columns": {
619
+ "id": {
620
+ "name": "id",
621
+ "type": "text",
622
+ "primaryKey": true,
623
+ "notNull": true,
624
+ "autoincrement": false
625
+ },
626
+ "client_id": {
627
+ "name": "client_id",
628
+ "type": "text",
629
+ "primaryKey": false,
630
+ "notNull": true,
631
+ "autoincrement": false
632
+ },
633
+ "user_id": {
634
+ "name": "user_id",
635
+ "type": "text",
636
+ "primaryKey": false,
637
+ "notNull": true,
638
+ "autoincrement": false
639
+ },
640
+ "resources": {
641
+ "name": "resources",
642
+ "type": "text",
643
+ "primaryKey": false,
644
+ "notNull": true,
645
+ "autoincrement": false
646
+ },
647
+ "instance_ids": {
648
+ "name": "instance_ids",
649
+ "type": "text",
650
+ "primaryKey": false,
651
+ "notNull": false,
652
+ "autoincrement": false
653
+ },
654
+ "access": {
655
+ "name": "access",
656
+ "type": "text",
657
+ "primaryKey": false,
658
+ "notNull": true,
659
+ "autoincrement": false,
660
+ "default": "'read'"
661
+ },
662
+ "created_at": {
663
+ "name": "created_at",
664
+ "type": "integer",
665
+ "primaryKey": false,
666
+ "notNull": true,
667
+ "autoincrement": false,
668
+ "default": "(unixepoch() * 1000)"
669
+ },
670
+ "revoked_at": {
671
+ "name": "revoked_at",
672
+ "type": "integer",
673
+ "primaryKey": false,
674
+ "notNull": false,
675
+ "autoincrement": false
676
+ }
677
+ },
678
+ "indexes": {},
679
+ "foreignKeys": {
680
+ "oauth_grants_client_id_oauth_clients_id_fk": {
681
+ "name": "oauth_grants_client_id_oauth_clients_id_fk",
682
+ "tableFrom": "oauth_grants",
683
+ "tableTo": "oauth_clients",
684
+ "columnsFrom": [
685
+ "client_id"
686
+ ],
687
+ "columnsTo": [
688
+ "id"
689
+ ],
690
+ "onDelete": "cascade",
691
+ "onUpdate": "no action"
692
+ },
693
+ "oauth_grants_user_id_users_id_fk": {
694
+ "name": "oauth_grants_user_id_users_id_fk",
695
+ "tableFrom": "oauth_grants",
696
+ "tableTo": "users",
697
+ "columnsFrom": [
698
+ "user_id"
699
+ ],
700
+ "columnsTo": [
701
+ "id"
702
+ ],
703
+ "onDelete": "cascade",
704
+ "onUpdate": "no action"
705
+ }
706
+ },
707
+ "compositePrimaryKeys": {},
708
+ "uniqueConstraints": {},
709
+ "checkConstraints": {}
710
+ },
711
+ "oauth_tokens": {
712
+ "name": "oauth_tokens",
713
+ "columns": {
714
+ "token_hash": {
715
+ "name": "token_hash",
716
+ "type": "text",
717
+ "primaryKey": true,
718
+ "notNull": true,
719
+ "autoincrement": false
720
+ },
721
+ "grant_id": {
722
+ "name": "grant_id",
723
+ "type": "text",
724
+ "primaryKey": false,
725
+ "notNull": true,
726
+ "autoincrement": false
727
+ },
728
+ "kind": {
729
+ "name": "kind",
730
+ "type": "text",
731
+ "primaryKey": false,
732
+ "notNull": true,
733
+ "autoincrement": false
734
+ },
735
+ "family_id": {
736
+ "name": "family_id",
737
+ "type": "text",
738
+ "primaryKey": false,
739
+ "notNull": true,
740
+ "autoincrement": false
741
+ },
742
+ "resources": {
743
+ "name": "resources",
744
+ "type": "text",
745
+ "primaryKey": false,
746
+ "notNull": true,
747
+ "autoincrement": false
748
+ },
749
+ "expires_at": {
750
+ "name": "expires_at",
751
+ "type": "integer",
752
+ "primaryKey": false,
753
+ "notNull": true,
754
+ "autoincrement": false
755
+ },
756
+ "revoked_at": {
757
+ "name": "revoked_at",
758
+ "type": "integer",
759
+ "primaryKey": false,
760
+ "notNull": false,
761
+ "autoincrement": false
762
+ }
763
+ },
764
+ "indexes": {},
765
+ "foreignKeys": {
766
+ "oauth_tokens_grant_id_oauth_grants_id_fk": {
767
+ "name": "oauth_tokens_grant_id_oauth_grants_id_fk",
768
+ "tableFrom": "oauth_tokens",
769
+ "tableTo": "oauth_grants",
770
+ "columnsFrom": [
771
+ "grant_id"
772
+ ],
773
+ "columnsTo": [
774
+ "id"
775
+ ],
776
+ "onDelete": "cascade",
777
+ "onUpdate": "no action"
778
+ }
779
+ },
780
+ "compositePrimaryKeys": {},
781
+ "uniqueConstraints": {},
782
+ "checkConstraints": {}
783
+ },
784
+ "oidc_config": {
785
+ "name": "oidc_config",
786
+ "columns": {
787
+ "id": {
788
+ "name": "id",
789
+ "type": "integer",
790
+ "primaryKey": true,
791
+ "notNull": true,
792
+ "autoincrement": false
793
+ },
794
+ "issuer": {
795
+ "name": "issuer",
796
+ "type": "text",
797
+ "primaryKey": false,
798
+ "notNull": true,
799
+ "autoincrement": false
800
+ },
801
+ "client_id": {
802
+ "name": "client_id",
803
+ "type": "text",
804
+ "primaryKey": false,
805
+ "notNull": true,
806
+ "autoincrement": false
807
+ },
808
+ "client_secret_enc": {
809
+ "name": "client_secret_enc",
810
+ "type": "blob",
811
+ "primaryKey": false,
812
+ "notNull": false,
813
+ "autoincrement": false
814
+ },
815
+ "scopes": {
816
+ "name": "scopes",
817
+ "type": "text",
818
+ "primaryKey": false,
819
+ "notNull": true,
820
+ "autoincrement": false,
821
+ "default": "'openid email profile'"
822
+ },
823
+ "allow_policy": {
824
+ "name": "allow_policy",
825
+ "type": "text",
826
+ "primaryKey": false,
827
+ "notNull": false,
828
+ "autoincrement": false
829
+ },
830
+ "auto_provision": {
831
+ "name": "auto_provision",
832
+ "type": "integer",
833
+ "primaryKey": false,
834
+ "notNull": true,
835
+ "autoincrement": false,
836
+ "default": false
837
+ },
838
+ "enabled": {
839
+ "name": "enabled",
840
+ "type": "integer",
841
+ "primaryKey": false,
842
+ "notNull": true,
843
+ "autoincrement": false,
844
+ "default": false
845
+ }
846
+ },
847
+ "indexes": {},
848
+ "foreignKeys": {},
849
+ "compositePrimaryKeys": {},
850
+ "uniqueConstraints": {},
851
+ "checkConstraints": {}
852
+ },
853
+ "operation_group_aliases": {
854
+ "name": "operation_group_aliases",
855
+ "columns": {
856
+ "instance_id": {
857
+ "name": "instance_id",
858
+ "type": "text",
859
+ "primaryKey": false,
860
+ "notNull": true,
861
+ "autoincrement": false
862
+ },
863
+ "plugin_group": {
864
+ "name": "plugin_group",
865
+ "type": "text",
866
+ "primaryKey": false,
867
+ "notNull": true,
868
+ "autoincrement": false
869
+ },
870
+ "group_key": {
871
+ "name": "group_key",
872
+ "type": "text",
873
+ "primaryKey": false,
874
+ "notNull": true,
875
+ "autoincrement": false
876
+ }
877
+ },
878
+ "indexes": {
879
+ "operation_group_aliases_idx": {
880
+ "name": "operation_group_aliases_idx",
881
+ "columns": [
882
+ "instance_id",
883
+ "plugin_group"
884
+ ],
885
+ "isUnique": true
886
+ }
887
+ },
888
+ "foreignKeys": {
889
+ "operation_group_aliases_instance_id_plugin_instances_id_fk": {
890
+ "name": "operation_group_aliases_instance_id_plugin_instances_id_fk",
891
+ "tableFrom": "operation_group_aliases",
892
+ "tableTo": "plugin_instances",
893
+ "columnsFrom": [
894
+ "instance_id"
895
+ ],
896
+ "columnsTo": [
897
+ "id"
898
+ ],
899
+ "onDelete": "cascade",
900
+ "onUpdate": "no action"
901
+ }
902
+ },
903
+ "compositePrimaryKeys": {},
904
+ "uniqueConstraints": {},
905
+ "checkConstraints": {}
906
+ },
907
+ "operation_groups": {
908
+ "name": "operation_groups",
909
+ "columns": {
910
+ "id": {
911
+ "name": "id",
912
+ "type": "text",
913
+ "primaryKey": true,
914
+ "notNull": true,
915
+ "autoincrement": false
916
+ },
917
+ "instance_id": {
918
+ "name": "instance_id",
919
+ "type": "text",
920
+ "primaryKey": false,
921
+ "notNull": true,
922
+ "autoincrement": false
923
+ },
924
+ "key": {
925
+ "name": "key",
926
+ "type": "text",
927
+ "primaryKey": false,
928
+ "notNull": true,
929
+ "autoincrement": false
930
+ },
931
+ "label": {
932
+ "name": "label",
933
+ "type": "text",
934
+ "primaryKey": false,
935
+ "notNull": true,
936
+ "autoincrement": false
937
+ },
938
+ "level": {
939
+ "name": "level",
940
+ "type": "text",
941
+ "primaryKey": false,
942
+ "notNull": true,
943
+ "autoincrement": false,
944
+ "default": "'read'"
945
+ },
946
+ "level_changed_at": {
947
+ "name": "level_changed_at",
948
+ "type": "integer",
949
+ "primaryKey": false,
950
+ "notNull": false,
951
+ "autoincrement": false
952
+ },
953
+ "level_changed_by": {
954
+ "name": "level_changed_by",
955
+ "type": "text",
956
+ "primaryKey": false,
957
+ "notNull": false,
958
+ "autoincrement": false
959
+ },
960
+ "first_seen_at": {
961
+ "name": "first_seen_at",
962
+ "type": "integer",
963
+ "primaryKey": false,
964
+ "notNull": true,
965
+ "autoincrement": false
966
+ },
967
+ "stale": {
968
+ "name": "stale",
969
+ "type": "integer",
970
+ "primaryKey": false,
971
+ "notNull": true,
972
+ "autoincrement": false,
973
+ "default": false
974
+ }
975
+ },
976
+ "indexes": {
977
+ "operation_groups_instance_key_idx": {
978
+ "name": "operation_groups_instance_key_idx",
979
+ "columns": [
980
+ "instance_id",
981
+ "key"
982
+ ],
983
+ "isUnique": true
984
+ }
985
+ },
986
+ "foreignKeys": {
987
+ "operation_groups_instance_id_plugin_instances_id_fk": {
988
+ "name": "operation_groups_instance_id_plugin_instances_id_fk",
989
+ "tableFrom": "operation_groups",
990
+ "tableTo": "plugin_instances",
991
+ "columnsFrom": [
992
+ "instance_id"
993
+ ],
994
+ "columnsTo": [
995
+ "id"
996
+ ],
997
+ "onDelete": "cascade",
998
+ "onUpdate": "no action"
999
+ },
1000
+ "operation_groups_level_changed_by_users_id_fk": {
1001
+ "name": "operation_groups_level_changed_by_users_id_fk",
1002
+ "tableFrom": "operation_groups",
1003
+ "tableTo": "users",
1004
+ "columnsFrom": [
1005
+ "level_changed_by"
1006
+ ],
1007
+ "columnsTo": [
1008
+ "id"
1009
+ ],
1010
+ "onDelete": "no action",
1011
+ "onUpdate": "no action"
1012
+ }
1013
+ },
1014
+ "compositePrimaryKeys": {},
1015
+ "uniqueConstraints": {},
1016
+ "checkConstraints": {}
1017
+ },
1018
+ "operations": {
1019
+ "name": "operations",
1020
+ "columns": {
1021
+ "id": {
1022
+ "name": "id",
1023
+ "type": "text",
1024
+ "primaryKey": true,
1025
+ "notNull": true,
1026
+ "autoincrement": false
1027
+ },
1028
+ "instance_id": {
1029
+ "name": "instance_id",
1030
+ "type": "text",
1031
+ "primaryKey": false,
1032
+ "notNull": true,
1033
+ "autoincrement": false
1034
+ },
1035
+ "key": {
1036
+ "name": "key",
1037
+ "type": "text",
1038
+ "primaryKey": false,
1039
+ "notNull": true,
1040
+ "autoincrement": false
1041
+ },
1042
+ "display_name": {
1043
+ "name": "display_name",
1044
+ "type": "text",
1045
+ "primaryKey": false,
1046
+ "notNull": false,
1047
+ "autoincrement": false
1048
+ },
1049
+ "kind": {
1050
+ "name": "kind",
1051
+ "type": "text",
1052
+ "primaryKey": false,
1053
+ "notNull": true,
1054
+ "autoincrement": false
1055
+ },
1056
+ "plugin_group": {
1057
+ "name": "plugin_group",
1058
+ "type": "text",
1059
+ "primaryKey": false,
1060
+ "notNull": true,
1061
+ "autoincrement": false
1062
+ },
1063
+ "group_id": {
1064
+ "name": "group_id",
1065
+ "type": "text",
1066
+ "primaryKey": false,
1067
+ "notNull": true,
1068
+ "autoincrement": false
1069
+ },
1070
+ "tag": {
1071
+ "name": "tag",
1072
+ "type": "text",
1073
+ "primaryKey": false,
1074
+ "notNull": false,
1075
+ "autoincrement": false
1076
+ },
1077
+ "classification": {
1078
+ "name": "classification",
1079
+ "type": "text",
1080
+ "primaryKey": false,
1081
+ "notNull": true,
1082
+ "autoincrement": false
1083
+ },
1084
+ "classification_source": {
1085
+ "name": "classification_source",
1086
+ "type": "text",
1087
+ "primaryKey": false,
1088
+ "notNull": true,
1089
+ "autoincrement": false
1090
+ },
1091
+ "inferred_classification": {
1092
+ "name": "inferred_classification",
1093
+ "type": "text",
1094
+ "primaryKey": false,
1095
+ "notNull": true,
1096
+ "autoincrement": false
1097
+ },
1098
+ "inferred_reason": {
1099
+ "name": "inferred_reason",
1100
+ "type": "text",
1101
+ "primaryKey": false,
1102
+ "notNull": true,
1103
+ "autoincrement": false
1104
+ },
1105
+ "locked": {
1106
+ "name": "locked",
1107
+ "type": "integer",
1108
+ "primaryKey": false,
1109
+ "notNull": true,
1110
+ "autoincrement": false,
1111
+ "default": false
1112
+ },
1113
+ "level_override": {
1114
+ "name": "level_override",
1115
+ "type": "text",
1116
+ "primaryKey": false,
1117
+ "notNull": false,
1118
+ "autoincrement": false
1119
+ },
1120
+ "write_acknowledged": {
1121
+ "name": "write_acknowledged",
1122
+ "type": "integer",
1123
+ "primaryKey": false,
1124
+ "notNull": true,
1125
+ "autoincrement": false,
1126
+ "default": false
1127
+ },
1128
+ "acknowledged_at": {
1129
+ "name": "acknowledged_at",
1130
+ "type": "integer",
1131
+ "primaryKey": false,
1132
+ "notNull": false,
1133
+ "autoincrement": false
1134
+ },
1135
+ "acknowledged_by": {
1136
+ "name": "acknowledged_by",
1137
+ "type": "text",
1138
+ "primaryKey": false,
1139
+ "notNull": false,
1140
+ "autoincrement": false
1141
+ },
1142
+ "typed_confirmation": {
1143
+ "name": "typed_confirmation",
1144
+ "type": "integer",
1145
+ "primaryKey": false,
1146
+ "notNull": true,
1147
+ "autoincrement": false,
1148
+ "default": false
1149
+ },
1150
+ "attestation_required": {
1151
+ "name": "attestation_required",
1152
+ "type": "integer",
1153
+ "primaryKey": false,
1154
+ "notNull": true,
1155
+ "autoincrement": false,
1156
+ "default": false
1157
+ },
1158
+ "attestation_waived": {
1159
+ "name": "attestation_waived",
1160
+ "type": "integer",
1161
+ "primaryKey": false,
1162
+ "notNull": true,
1163
+ "autoincrement": false,
1164
+ "default": false
1165
+ },
1166
+ "needs_review": {
1167
+ "name": "needs_review",
1168
+ "type": "integer",
1169
+ "primaryKey": false,
1170
+ "notNull": true,
1171
+ "autoincrement": false,
1172
+ "default": false
1173
+ },
1174
+ "match_profile": {
1175
+ "name": "match_profile",
1176
+ "type": "text",
1177
+ "primaryKey": false,
1178
+ "notNull": false,
1179
+ "autoincrement": false
1180
+ },
1181
+ "params_schema": {
1182
+ "name": "params_schema",
1183
+ "type": "text",
1184
+ "primaryKey": false,
1185
+ "notNull": false,
1186
+ "autoincrement": false
1187
+ },
1188
+ "docs": {
1189
+ "name": "docs",
1190
+ "type": "text",
1191
+ "primaryKey": false,
1192
+ "notNull": false,
1193
+ "autoincrement": false
1194
+ },
1195
+ "first_seen_at": {
1196
+ "name": "first_seen_at",
1197
+ "type": "integer",
1198
+ "primaryKey": false,
1199
+ "notNull": true,
1200
+ "autoincrement": false
1201
+ },
1202
+ "last_seen_at": {
1203
+ "name": "last_seen_at",
1204
+ "type": "integer",
1205
+ "primaryKey": false,
1206
+ "notNull": true,
1207
+ "autoincrement": false
1208
+ },
1209
+ "stale": {
1210
+ "name": "stale",
1211
+ "type": "integer",
1212
+ "primaryKey": false,
1213
+ "notNull": true,
1214
+ "autoincrement": false,
1215
+ "default": false
1216
+ }
1217
+ },
1218
+ "indexes": {
1219
+ "operations_instance_key_idx": {
1220
+ "name": "operations_instance_key_idx",
1221
+ "columns": [
1222
+ "instance_id",
1223
+ "key"
1224
+ ],
1225
+ "isUnique": true
1226
+ },
1227
+ "operations_group_idx": {
1228
+ "name": "operations_group_idx",
1229
+ "columns": [
1230
+ "group_id"
1231
+ ],
1232
+ "isUnique": false
1233
+ }
1234
+ },
1235
+ "foreignKeys": {
1236
+ "operations_instance_id_plugin_instances_id_fk": {
1237
+ "name": "operations_instance_id_plugin_instances_id_fk",
1238
+ "tableFrom": "operations",
1239
+ "tableTo": "plugin_instances",
1240
+ "columnsFrom": [
1241
+ "instance_id"
1242
+ ],
1243
+ "columnsTo": [
1244
+ "id"
1245
+ ],
1246
+ "onDelete": "cascade",
1247
+ "onUpdate": "no action"
1248
+ },
1249
+ "operations_group_id_operation_groups_id_fk": {
1250
+ "name": "operations_group_id_operation_groups_id_fk",
1251
+ "tableFrom": "operations",
1252
+ "tableTo": "operation_groups",
1253
+ "columnsFrom": [
1254
+ "group_id"
1255
+ ],
1256
+ "columnsTo": [
1257
+ "id"
1258
+ ],
1259
+ "onDelete": "no action",
1260
+ "onUpdate": "no action"
1261
+ },
1262
+ "operations_acknowledged_by_users_id_fk": {
1263
+ "name": "operations_acknowledged_by_users_id_fk",
1264
+ "tableFrom": "operations",
1265
+ "tableTo": "users",
1266
+ "columnsFrom": [
1267
+ "acknowledged_by"
1268
+ ],
1269
+ "columnsTo": [
1270
+ "id"
1271
+ ],
1272
+ "onDelete": "no action",
1273
+ "onUpdate": "no action"
1274
+ }
1275
+ },
1276
+ "compositePrimaryKeys": {},
1277
+ "uniqueConstraints": {},
1278
+ "checkConstraints": {}
1279
+ },
1280
+ "pending_approvals": {
1281
+ "name": "pending_approvals",
1282
+ "columns": {
1283
+ "id": {
1284
+ "name": "id",
1285
+ "type": "text",
1286
+ "primaryKey": true,
1287
+ "notNull": true,
1288
+ "autoincrement": false
1289
+ },
1290
+ "instance_id": {
1291
+ "name": "instance_id",
1292
+ "type": "text",
1293
+ "primaryKey": false,
1294
+ "notNull": true,
1295
+ "autoincrement": false
1296
+ },
1297
+ "operation_id": {
1298
+ "name": "operation_id",
1299
+ "type": "text",
1300
+ "primaryKey": false,
1301
+ "notNull": true,
1302
+ "autoincrement": false
1303
+ },
1304
+ "params_display": {
1305
+ "name": "params_display",
1306
+ "type": "text",
1307
+ "primaryKey": false,
1308
+ "notNull": false,
1309
+ "autoincrement": false
1310
+ },
1311
+ "params_hash": {
1312
+ "name": "params_hash",
1313
+ "type": "text",
1314
+ "primaryKey": false,
1315
+ "notNull": true,
1316
+ "autoincrement": false
1317
+ },
1318
+ "resolved_targets": {
1319
+ "name": "resolved_targets",
1320
+ "type": "text",
1321
+ "primaryKey": false,
1322
+ "notNull": false,
1323
+ "autoincrement": false
1324
+ },
1325
+ "summary": {
1326
+ "name": "summary",
1327
+ "type": "text",
1328
+ "primaryKey": false,
1329
+ "notNull": true,
1330
+ "autoincrement": false
1331
+ },
1332
+ "confirm_literal": {
1333
+ "name": "confirm_literal",
1334
+ "type": "text",
1335
+ "primaryKey": false,
1336
+ "notNull": false,
1337
+ "autoincrement": false
1338
+ },
1339
+ "diff": {
1340
+ "name": "diff",
1341
+ "type": "text",
1342
+ "primaryKey": false,
1343
+ "notNull": false,
1344
+ "autoincrement": false
1345
+ },
1346
+ "expected_hash": {
1347
+ "name": "expected_hash",
1348
+ "type": "text",
1349
+ "primaryKey": false,
1350
+ "notNull": false,
1351
+ "autoincrement": false
1352
+ },
1353
+ "client_kind": {
1354
+ "name": "client_kind",
1355
+ "type": "text",
1356
+ "primaryKey": false,
1357
+ "notNull": false,
1358
+ "autoincrement": false
1359
+ },
1360
+ "client_id": {
1361
+ "name": "client_id",
1362
+ "type": "text",
1363
+ "primaryKey": false,
1364
+ "notNull": false,
1365
+ "autoincrement": false
1366
+ },
1367
+ "mcp_session_id": {
1368
+ "name": "mcp_session_id",
1369
+ "type": "text",
1370
+ "primaryKey": false,
1371
+ "notNull": false,
1372
+ "autoincrement": false
1373
+ },
1374
+ "requested_at": {
1375
+ "name": "requested_at",
1376
+ "type": "integer",
1377
+ "primaryKey": false,
1378
+ "notNull": true,
1379
+ "autoincrement": false
1380
+ },
1381
+ "expires_at": {
1382
+ "name": "expires_at",
1383
+ "type": "integer",
1384
+ "primaryKey": false,
1385
+ "notNull": true,
1386
+ "autoincrement": false
1387
+ },
1388
+ "status": {
1389
+ "name": "status",
1390
+ "type": "text",
1391
+ "primaryKey": false,
1392
+ "notNull": true,
1393
+ "autoincrement": false,
1394
+ "default": "'pending'"
1395
+ },
1396
+ "decided_by": {
1397
+ "name": "decided_by",
1398
+ "type": "text",
1399
+ "primaryKey": false,
1400
+ "notNull": false,
1401
+ "autoincrement": false
1402
+ },
1403
+ "decided_via": {
1404
+ "name": "decided_via",
1405
+ "type": "text",
1406
+ "primaryKey": false,
1407
+ "notNull": false,
1408
+ "autoincrement": false
1409
+ },
1410
+ "decided_at": {
1411
+ "name": "decided_at",
1412
+ "type": "integer",
1413
+ "primaryKey": false,
1414
+ "notNull": false,
1415
+ "autoincrement": false
1416
+ }
1417
+ },
1418
+ "indexes": {},
1419
+ "foreignKeys": {
1420
+ "pending_approvals_instance_id_plugin_instances_id_fk": {
1421
+ "name": "pending_approvals_instance_id_plugin_instances_id_fk",
1422
+ "tableFrom": "pending_approvals",
1423
+ "tableTo": "plugin_instances",
1424
+ "columnsFrom": [
1425
+ "instance_id"
1426
+ ],
1427
+ "columnsTo": [
1428
+ "id"
1429
+ ],
1430
+ "onDelete": "no action",
1431
+ "onUpdate": "no action"
1432
+ },
1433
+ "pending_approvals_operation_id_operations_id_fk": {
1434
+ "name": "pending_approvals_operation_id_operations_id_fk",
1435
+ "tableFrom": "pending_approvals",
1436
+ "tableTo": "operations",
1437
+ "columnsFrom": [
1438
+ "operation_id"
1439
+ ],
1440
+ "columnsTo": [
1441
+ "id"
1442
+ ],
1443
+ "onDelete": "no action",
1444
+ "onUpdate": "no action"
1445
+ }
1446
+ },
1447
+ "compositePrimaryKeys": {},
1448
+ "uniqueConstraints": {},
1449
+ "checkConstraints": {}
1450
+ },
1451
+ "plugin_instances": {
1452
+ "name": "plugin_instances",
1453
+ "columns": {
1454
+ "id": {
1455
+ "name": "id",
1456
+ "type": "text",
1457
+ "primaryKey": true,
1458
+ "notNull": true,
1459
+ "autoincrement": false
1460
+ },
1461
+ "plugin_id": {
1462
+ "name": "plugin_id",
1463
+ "type": "text",
1464
+ "primaryKey": false,
1465
+ "notNull": true,
1466
+ "autoincrement": false
1467
+ },
1468
+ "slug": {
1469
+ "name": "slug",
1470
+ "type": "text",
1471
+ "primaryKey": false,
1472
+ "notNull": true,
1473
+ "autoincrement": false
1474
+ },
1475
+ "display_name": {
1476
+ "name": "display_name",
1477
+ "type": "text",
1478
+ "primaryKey": false,
1479
+ "notNull": true,
1480
+ "autoincrement": false
1481
+ },
1482
+ "enabled": {
1483
+ "name": "enabled",
1484
+ "type": "integer",
1485
+ "primaryKey": false,
1486
+ "notNull": true,
1487
+ "autoincrement": false,
1488
+ "default": true
1489
+ },
1490
+ "config": {
1491
+ "name": "config",
1492
+ "type": "text",
1493
+ "primaryKey": false,
1494
+ "notNull": true,
1495
+ "autoincrement": false,
1496
+ "default": "'{}'"
1497
+ },
1498
+ "secrets_enc": {
1499
+ "name": "secrets_enc",
1500
+ "type": "blob",
1501
+ "primaryKey": false,
1502
+ "notNull": false,
1503
+ "autoincrement": false
1504
+ },
1505
+ "auth_mode": {
1506
+ "name": "auth_mode",
1507
+ "type": "text",
1508
+ "primaryKey": false,
1509
+ "notNull": false,
1510
+ "autoincrement": false
1511
+ },
1512
+ "settings": {
1513
+ "name": "settings",
1514
+ "type": "text",
1515
+ "primaryKey": false,
1516
+ "notNull": true,
1517
+ "autoincrement": false,
1518
+ "default": "'{}'"
1519
+ },
1520
+ "status": {
1521
+ "name": "status",
1522
+ "type": "text",
1523
+ "primaryKey": false,
1524
+ "notNull": true,
1525
+ "autoincrement": false,
1526
+ "default": "'stopped'"
1527
+ },
1528
+ "status_error": {
1529
+ "name": "status_error",
1530
+ "type": "text",
1531
+ "primaryKey": false,
1532
+ "notNull": false,
1533
+ "autoincrement": false
1534
+ },
1535
+ "upstream_version": {
1536
+ "name": "upstream_version",
1537
+ "type": "text",
1538
+ "primaryKey": false,
1539
+ "notNull": false,
1540
+ "autoincrement": false
1541
+ },
1542
+ "source_ref": {
1543
+ "name": "source_ref",
1544
+ "type": "text",
1545
+ "primaryKey": false,
1546
+ "notNull": false,
1547
+ "autoincrement": false
1548
+ },
1549
+ "last_synced_at": {
1550
+ "name": "last_synced_at",
1551
+ "type": "integer",
1552
+ "primaryKey": false,
1553
+ "notNull": false,
1554
+ "autoincrement": false
1555
+ },
1556
+ "last_sync_status": {
1557
+ "name": "last_sync_status",
1558
+ "type": "text",
1559
+ "primaryKey": false,
1560
+ "notNull": false,
1561
+ "autoincrement": false
1562
+ },
1563
+ "created_at": {
1564
+ "name": "created_at",
1565
+ "type": "integer",
1566
+ "primaryKey": false,
1567
+ "notNull": true,
1568
+ "autoincrement": false,
1569
+ "default": "(unixepoch() * 1000)"
1570
+ }
1571
+ },
1572
+ "indexes": {
1573
+ "plugin_instances_slug_unique": {
1574
+ "name": "plugin_instances_slug_unique",
1575
+ "columns": [
1576
+ "slug"
1577
+ ],
1578
+ "isUnique": true
1579
+ }
1580
+ },
1581
+ "foreignKeys": {
1582
+ "plugin_instances_plugin_id_plugins_id_fk": {
1583
+ "name": "plugin_instances_plugin_id_plugins_id_fk",
1584
+ "tableFrom": "plugin_instances",
1585
+ "tableTo": "plugins",
1586
+ "columnsFrom": [
1587
+ "plugin_id"
1588
+ ],
1589
+ "columnsTo": [
1590
+ "id"
1591
+ ],
1592
+ "onDelete": "no action",
1593
+ "onUpdate": "no action"
1594
+ }
1595
+ },
1596
+ "compositePrimaryKeys": {},
1597
+ "uniqueConstraints": {},
1598
+ "checkConstraints": {}
1599
+ },
1600
+ "plugin_repos": {
1601
+ "name": "plugin_repos",
1602
+ "columns": {
1603
+ "id": {
1604
+ "name": "id",
1605
+ "type": "text",
1606
+ "primaryKey": true,
1607
+ "notNull": true,
1608
+ "autoincrement": false
1609
+ },
1610
+ "url": {
1611
+ "name": "url",
1612
+ "type": "text",
1613
+ "primaryKey": false,
1614
+ "notNull": true,
1615
+ "autoincrement": false
1616
+ },
1617
+ "name": {
1618
+ "name": "name",
1619
+ "type": "text",
1620
+ "primaryKey": false,
1621
+ "notNull": false,
1622
+ "autoincrement": false
1623
+ },
1624
+ "signing_mode": {
1625
+ "name": "signing_mode",
1626
+ "type": "text",
1627
+ "primaryKey": false,
1628
+ "notNull": true,
1629
+ "autoincrement": false
1630
+ },
1631
+ "public_key": {
1632
+ "name": "public_key",
1633
+ "type": "text",
1634
+ "primaryKey": false,
1635
+ "notNull": false,
1636
+ "autoincrement": false
1637
+ },
1638
+ "key_fingerprint": {
1639
+ "name": "key_fingerprint",
1640
+ "type": "text",
1641
+ "primaryKey": false,
1642
+ "notNull": false,
1643
+ "autoincrement": false
1644
+ },
1645
+ "key_status": {
1646
+ "name": "key_status",
1647
+ "type": "text",
1648
+ "primaryKey": false,
1649
+ "notNull": true,
1650
+ "autoincrement": false,
1651
+ "default": "'ok'"
1652
+ },
1653
+ "index_cache": {
1654
+ "name": "index_cache",
1655
+ "type": "text",
1656
+ "primaryKey": false,
1657
+ "notNull": false,
1658
+ "autoincrement": false
1659
+ },
1660
+ "last_fetched_at": {
1661
+ "name": "last_fetched_at",
1662
+ "type": "integer",
1663
+ "primaryKey": false,
1664
+ "notNull": false,
1665
+ "autoincrement": false
1666
+ },
1667
+ "last_fetch_error": {
1668
+ "name": "last_fetch_error",
1669
+ "type": "text",
1670
+ "primaryKey": false,
1671
+ "notNull": false,
1672
+ "autoincrement": false
1673
+ }
1674
+ },
1675
+ "indexes": {
1676
+ "plugin_repos_url_unique": {
1677
+ "name": "plugin_repos_url_unique",
1678
+ "columns": [
1679
+ "url"
1680
+ ],
1681
+ "isUnique": true
1682
+ }
1683
+ },
1684
+ "foreignKeys": {},
1685
+ "compositePrimaryKeys": {},
1686
+ "uniqueConstraints": {},
1687
+ "checkConstraints": {}
1688
+ },
1689
+ "plugins": {
1690
+ "name": "plugins",
1691
+ "columns": {
1692
+ "id": {
1693
+ "name": "id",
1694
+ "type": "text",
1695
+ "primaryKey": true,
1696
+ "notNull": true,
1697
+ "autoincrement": false
1698
+ },
1699
+ "plugin_id": {
1700
+ "name": "plugin_id",
1701
+ "type": "text",
1702
+ "primaryKey": false,
1703
+ "notNull": true,
1704
+ "autoincrement": false
1705
+ },
1706
+ "version": {
1707
+ "name": "version",
1708
+ "type": "text",
1709
+ "primaryKey": false,
1710
+ "notNull": true,
1711
+ "autoincrement": false
1712
+ },
1713
+ "source": {
1714
+ "name": "source",
1715
+ "type": "text",
1716
+ "primaryKey": false,
1717
+ "notNull": true,
1718
+ "autoincrement": false
1719
+ },
1720
+ "repo_id": {
1721
+ "name": "repo_id",
1722
+ "type": "text",
1723
+ "primaryKey": false,
1724
+ "notNull": false,
1725
+ "autoincrement": false
1726
+ },
1727
+ "path": {
1728
+ "name": "path",
1729
+ "type": "text",
1730
+ "primaryKey": false,
1731
+ "notNull": true,
1732
+ "autoincrement": false
1733
+ },
1734
+ "sha256": {
1735
+ "name": "sha256",
1736
+ "type": "text",
1737
+ "primaryKey": false,
1738
+ "notNull": false,
1739
+ "autoincrement": false
1740
+ },
1741
+ "signature_verified": {
1742
+ "name": "signature_verified",
1743
+ "type": "integer",
1744
+ "primaryKey": false,
1745
+ "notNull": true,
1746
+ "autoincrement": false,
1747
+ "default": false
1748
+ },
1749
+ "manifest": {
1750
+ "name": "manifest",
1751
+ "type": "text",
1752
+ "primaryKey": false,
1753
+ "notNull": true,
1754
+ "autoincrement": false
1755
+ },
1756
+ "status": {
1757
+ "name": "status",
1758
+ "type": "text",
1759
+ "primaryKey": false,
1760
+ "notNull": true,
1761
+ "autoincrement": false
1762
+ },
1763
+ "status_error": {
1764
+ "name": "status_error",
1765
+ "type": "text",
1766
+ "primaryKey": false,
1767
+ "notNull": false,
1768
+ "autoincrement": false
1769
+ },
1770
+ "enabled": {
1771
+ "name": "enabled",
1772
+ "type": "integer",
1773
+ "primaryKey": false,
1774
+ "notNull": true,
1775
+ "autoincrement": false,
1776
+ "default": false
1777
+ },
1778
+ "created_at": {
1779
+ "name": "created_at",
1780
+ "type": "integer",
1781
+ "primaryKey": false,
1782
+ "notNull": true,
1783
+ "autoincrement": false,
1784
+ "default": "(unixepoch() * 1000)"
1785
+ }
1786
+ },
1787
+ "indexes": {
1788
+ "plugins_plugin_id_unique": {
1789
+ "name": "plugins_plugin_id_unique",
1790
+ "columns": [
1791
+ "plugin_id"
1792
+ ],
1793
+ "isUnique": true
1794
+ }
1795
+ },
1796
+ "foreignKeys": {
1797
+ "plugins_repo_id_plugin_repos_id_fk": {
1798
+ "name": "plugins_repo_id_plugin_repos_id_fk",
1799
+ "tableFrom": "plugins",
1800
+ "tableTo": "plugin_repos",
1801
+ "columnsFrom": [
1802
+ "repo_id"
1803
+ ],
1804
+ "columnsTo": [
1805
+ "id"
1806
+ ],
1807
+ "onDelete": "no action",
1808
+ "onUpdate": "no action"
1809
+ }
1810
+ },
1811
+ "compositePrimaryKeys": {},
1812
+ "uniqueConstraints": {},
1813
+ "checkConstraints": {}
1814
+ },
1815
+ "pre_approval_hits": {
1816
+ "name": "pre_approval_hits",
1817
+ "columns": {
1818
+ "id": {
1819
+ "name": "id",
1820
+ "type": "integer",
1821
+ "primaryKey": true,
1822
+ "notNull": true,
1823
+ "autoincrement": true
1824
+ },
1825
+ "rule_id": {
1826
+ "name": "rule_id",
1827
+ "type": "text",
1828
+ "primaryKey": false,
1829
+ "notNull": true,
1830
+ "autoincrement": false
1831
+ },
1832
+ "occurred_at": {
1833
+ "name": "occurred_at",
1834
+ "type": "integer",
1835
+ "primaryKey": false,
1836
+ "notNull": true,
1837
+ "autoincrement": false
1838
+ }
1839
+ },
1840
+ "indexes": {
1841
+ "hits_rule_time_idx": {
1842
+ "name": "hits_rule_time_idx",
1843
+ "columns": [
1844
+ "rule_id",
1845
+ "occurred_at"
1846
+ ],
1847
+ "isUnique": false
1848
+ }
1849
+ },
1850
+ "foreignKeys": {
1851
+ "pre_approval_hits_rule_id_pre_approval_rules_id_fk": {
1852
+ "name": "pre_approval_hits_rule_id_pre_approval_rules_id_fk",
1853
+ "tableFrom": "pre_approval_hits",
1854
+ "tableTo": "pre_approval_rules",
1855
+ "columnsFrom": [
1856
+ "rule_id"
1857
+ ],
1858
+ "columnsTo": [
1859
+ "id"
1860
+ ],
1861
+ "onDelete": "cascade",
1862
+ "onUpdate": "no action"
1863
+ }
1864
+ },
1865
+ "compositePrimaryKeys": {},
1866
+ "uniqueConstraints": {},
1867
+ "checkConstraints": {}
1868
+ },
1869
+ "pre_approval_rules": {
1870
+ "name": "pre_approval_rules",
1871
+ "columns": {
1872
+ "id": {
1873
+ "name": "id",
1874
+ "type": "text",
1875
+ "primaryKey": true,
1876
+ "notNull": true,
1877
+ "autoincrement": false
1878
+ },
1879
+ "instance_id": {
1880
+ "name": "instance_id",
1881
+ "type": "text",
1882
+ "primaryKey": false,
1883
+ "notNull": true,
1884
+ "autoincrement": false
1885
+ },
1886
+ "operation_id": {
1887
+ "name": "operation_id",
1888
+ "type": "text",
1889
+ "primaryKey": false,
1890
+ "notNull": true,
1891
+ "autoincrement": false
1892
+ },
1893
+ "match": {
1894
+ "name": "match",
1895
+ "type": "text",
1896
+ "primaryKey": false,
1897
+ "notNull": true,
1898
+ "autoincrement": false,
1899
+ "default": "'[]'"
1900
+ },
1901
+ "rate_limit": {
1902
+ "name": "rate_limit",
1903
+ "type": "integer",
1904
+ "primaryKey": false,
1905
+ "notNull": false,
1906
+ "autoincrement": false
1907
+ },
1908
+ "window_seconds": {
1909
+ "name": "window_seconds",
1910
+ "type": "integer",
1911
+ "primaryKey": false,
1912
+ "notNull": false,
1913
+ "autoincrement": false
1914
+ },
1915
+ "expires_at": {
1916
+ "name": "expires_at",
1917
+ "type": "integer",
1918
+ "primaryKey": false,
1919
+ "notNull": false,
1920
+ "autoincrement": false
1921
+ },
1922
+ "reason": {
1923
+ "name": "reason",
1924
+ "type": "text",
1925
+ "primaryKey": false,
1926
+ "notNull": true,
1927
+ "autoincrement": false
1928
+ },
1929
+ "enabled": {
1930
+ "name": "enabled",
1931
+ "type": "integer",
1932
+ "primaryKey": false,
1933
+ "notNull": true,
1934
+ "autoincrement": false,
1935
+ "default": true
1936
+ },
1937
+ "created_by": {
1938
+ "name": "created_by",
1939
+ "type": "text",
1940
+ "primaryKey": false,
1941
+ "notNull": false,
1942
+ "autoincrement": false
1943
+ },
1944
+ "created_at": {
1945
+ "name": "created_at",
1946
+ "type": "integer",
1947
+ "primaryKey": false,
1948
+ "notNull": true,
1949
+ "autoincrement": false,
1950
+ "default": "(unixepoch() * 1000)"
1951
+ },
1952
+ "updated_at": {
1953
+ "name": "updated_at",
1954
+ "type": "integer",
1955
+ "primaryKey": false,
1956
+ "notNull": false,
1957
+ "autoincrement": false
1958
+ },
1959
+ "last_triggered_at": {
1960
+ "name": "last_triggered_at",
1961
+ "type": "integer",
1962
+ "primaryKey": false,
1963
+ "notNull": false,
1964
+ "autoincrement": false
1965
+ },
1966
+ "strict_miss_at": {
1967
+ "name": "strict_miss_at",
1968
+ "type": "integer",
1969
+ "primaryKey": false,
1970
+ "notNull": false,
1971
+ "autoincrement": false
1972
+ }
1973
+ },
1974
+ "indexes": {},
1975
+ "foreignKeys": {
1976
+ "pre_approval_rules_instance_id_plugin_instances_id_fk": {
1977
+ "name": "pre_approval_rules_instance_id_plugin_instances_id_fk",
1978
+ "tableFrom": "pre_approval_rules",
1979
+ "tableTo": "plugin_instances",
1980
+ "columnsFrom": [
1981
+ "instance_id"
1982
+ ],
1983
+ "columnsTo": [
1984
+ "id"
1985
+ ],
1986
+ "onDelete": "cascade",
1987
+ "onUpdate": "no action"
1988
+ },
1989
+ "pre_approval_rules_operation_id_operations_id_fk": {
1990
+ "name": "pre_approval_rules_operation_id_operations_id_fk",
1991
+ "tableFrom": "pre_approval_rules",
1992
+ "tableTo": "operations",
1993
+ "columnsFrom": [
1994
+ "operation_id"
1995
+ ],
1996
+ "columnsTo": [
1997
+ "id"
1998
+ ],
1999
+ "onDelete": "no action",
2000
+ "onUpdate": "no action"
2001
+ },
2002
+ "pre_approval_rules_created_by_users_id_fk": {
2003
+ "name": "pre_approval_rules_created_by_users_id_fk",
2004
+ "tableFrom": "pre_approval_rules",
2005
+ "tableTo": "users",
2006
+ "columnsFrom": [
2007
+ "created_by"
2008
+ ],
2009
+ "columnsTo": [
2010
+ "id"
2011
+ ],
2012
+ "onDelete": "no action",
2013
+ "onUpdate": "no action"
2014
+ }
2015
+ },
2016
+ "compositePrimaryKeys": {},
2017
+ "uniqueConstraints": {},
2018
+ "checkConstraints": {}
2019
+ },
2020
+ "registry_entries": {
2021
+ "name": "registry_entries",
2022
+ "columns": {
2023
+ "id": {
2024
+ "name": "id",
2025
+ "type": "text",
2026
+ "primaryKey": true,
2027
+ "notNull": true,
2028
+ "autoincrement": false
2029
+ },
2030
+ "instance_id": {
2031
+ "name": "instance_id",
2032
+ "type": "text",
2033
+ "primaryKey": false,
2034
+ "notNull": true,
2035
+ "autoincrement": false
2036
+ },
2037
+ "kind": {
2038
+ "name": "kind",
2039
+ "type": "text",
2040
+ "primaryKey": false,
2041
+ "notNull": true,
2042
+ "autoincrement": false
2043
+ },
2044
+ "ext_id": {
2045
+ "name": "ext_id",
2046
+ "type": "text",
2047
+ "primaryKey": false,
2048
+ "notNull": true,
2049
+ "autoincrement": false
2050
+ },
2051
+ "name": {
2052
+ "name": "name",
2053
+ "type": "text",
2054
+ "primaryKey": false,
2055
+ "notNull": true,
2056
+ "autoincrement": false
2057
+ },
2058
+ "parent_ext_id": {
2059
+ "name": "parent_ext_id",
2060
+ "type": "text",
2061
+ "primaryKey": false,
2062
+ "notNull": false,
2063
+ "autoincrement": false
2064
+ },
2065
+ "scopes": {
2066
+ "name": "scopes",
2067
+ "type": "text",
2068
+ "primaryKey": false,
2069
+ "notNull": false,
2070
+ "autoincrement": false
2071
+ },
2072
+ "attrs": {
2073
+ "name": "attrs",
2074
+ "type": "text",
2075
+ "primaryKey": false,
2076
+ "notNull": false,
2077
+ "autoincrement": false
2078
+ },
2079
+ "stale": {
2080
+ "name": "stale",
2081
+ "type": "integer",
2082
+ "primaryKey": false,
2083
+ "notNull": true,
2084
+ "autoincrement": false,
2085
+ "default": false
2086
+ },
2087
+ "last_synced_at": {
2088
+ "name": "last_synced_at",
2089
+ "type": "integer",
2090
+ "primaryKey": false,
2091
+ "notNull": true,
2092
+ "autoincrement": false
2093
+ }
2094
+ },
2095
+ "indexes": {
2096
+ "registry_instance_kind_ext_idx": {
2097
+ "name": "registry_instance_kind_ext_idx",
2098
+ "columns": [
2099
+ "instance_id",
2100
+ "kind",
2101
+ "ext_id"
2102
+ ],
2103
+ "isUnique": true
2104
+ }
2105
+ },
2106
+ "foreignKeys": {
2107
+ "registry_entries_instance_id_plugin_instances_id_fk": {
2108
+ "name": "registry_entries_instance_id_plugin_instances_id_fk",
2109
+ "tableFrom": "registry_entries",
2110
+ "tableTo": "plugin_instances",
2111
+ "columnsFrom": [
2112
+ "instance_id"
2113
+ ],
2114
+ "columnsTo": [
2115
+ "id"
2116
+ ],
2117
+ "onDelete": "cascade",
2118
+ "onUpdate": "no action"
2119
+ }
2120
+ },
2121
+ "compositePrimaryKeys": {},
2122
+ "uniqueConstraints": {},
2123
+ "checkConstraints": {}
2124
+ },
2125
+ "sessions": {
2126
+ "name": "sessions",
2127
+ "columns": {
2128
+ "id_hash": {
2129
+ "name": "id_hash",
2130
+ "type": "text",
2131
+ "primaryKey": true,
2132
+ "notNull": true,
2133
+ "autoincrement": false
2134
+ },
2135
+ "user_id": {
2136
+ "name": "user_id",
2137
+ "type": "text",
2138
+ "primaryKey": false,
2139
+ "notNull": true,
2140
+ "autoincrement": false
2141
+ },
2142
+ "kind": {
2143
+ "name": "kind",
2144
+ "type": "text",
2145
+ "primaryKey": false,
2146
+ "notNull": true,
2147
+ "autoincrement": false
2148
+ },
2149
+ "created_at": {
2150
+ "name": "created_at",
2151
+ "type": "integer",
2152
+ "primaryKey": false,
2153
+ "notNull": true,
2154
+ "autoincrement": false,
2155
+ "default": "(unixepoch() * 1000)"
2156
+ },
2157
+ "last_seen_at": {
2158
+ "name": "last_seen_at",
2159
+ "type": "integer",
2160
+ "primaryKey": false,
2161
+ "notNull": true,
2162
+ "autoincrement": false
2163
+ },
2164
+ "expires_at": {
2165
+ "name": "expires_at",
2166
+ "type": "integer",
2167
+ "primaryKey": false,
2168
+ "notNull": true,
2169
+ "autoincrement": false
2170
+ },
2171
+ "ip": {
2172
+ "name": "ip",
2173
+ "type": "text",
2174
+ "primaryKey": false,
2175
+ "notNull": false,
2176
+ "autoincrement": false
2177
+ },
2178
+ "user_agent": {
2179
+ "name": "user_agent",
2180
+ "type": "text",
2181
+ "primaryKey": false,
2182
+ "notNull": false,
2183
+ "autoincrement": false
2184
+ }
2185
+ },
2186
+ "indexes": {
2187
+ "sessions_user_idx": {
2188
+ "name": "sessions_user_idx",
2189
+ "columns": [
2190
+ "user_id"
2191
+ ],
2192
+ "isUnique": false
2193
+ }
2194
+ },
2195
+ "foreignKeys": {
2196
+ "sessions_user_id_users_id_fk": {
2197
+ "name": "sessions_user_id_users_id_fk",
2198
+ "tableFrom": "sessions",
2199
+ "tableTo": "users",
2200
+ "columnsFrom": [
2201
+ "user_id"
2202
+ ],
2203
+ "columnsTo": [
2204
+ "id"
2205
+ ],
2206
+ "onDelete": "cascade",
2207
+ "onUpdate": "no action"
2208
+ }
2209
+ },
2210
+ "compositePrimaryKeys": {},
2211
+ "uniqueConstraints": {},
2212
+ "checkConstraints": {}
2213
+ },
2214
+ "settings": {
2215
+ "name": "settings",
2216
+ "columns": {
2217
+ "key": {
2218
+ "name": "key",
2219
+ "type": "text",
2220
+ "primaryKey": true,
2221
+ "notNull": true,
2222
+ "autoincrement": false
2223
+ },
2224
+ "value": {
2225
+ "name": "value",
2226
+ "type": "text",
2227
+ "primaryKey": false,
2228
+ "notNull": true,
2229
+ "autoincrement": false
2230
+ }
2231
+ },
2232
+ "indexes": {},
2233
+ "foreignKeys": {},
2234
+ "compositePrimaryKeys": {},
2235
+ "uniqueConstraints": {},
2236
+ "checkConstraints": {}
2237
+ },
2238
+ "users": {
2239
+ "name": "users",
2240
+ "columns": {
2241
+ "id": {
2242
+ "name": "id",
2243
+ "type": "text",
2244
+ "primaryKey": true,
2245
+ "notNull": true,
2246
+ "autoincrement": false
2247
+ },
2248
+ "username": {
2249
+ "name": "username",
2250
+ "type": "text",
2251
+ "primaryKey": false,
2252
+ "notNull": true,
2253
+ "autoincrement": false
2254
+ },
2255
+ "password_hash": {
2256
+ "name": "password_hash",
2257
+ "type": "text",
2258
+ "primaryKey": false,
2259
+ "notNull": false,
2260
+ "autoincrement": false
2261
+ },
2262
+ "totp_secret_enc": {
2263
+ "name": "totp_secret_enc",
2264
+ "type": "blob",
2265
+ "primaryKey": false,
2266
+ "notNull": false,
2267
+ "autoincrement": false
2268
+ },
2269
+ "totp_enabled": {
2270
+ "name": "totp_enabled",
2271
+ "type": "integer",
2272
+ "primaryKey": false,
2273
+ "notNull": true,
2274
+ "autoincrement": false,
2275
+ "default": false
2276
+ },
2277
+ "totp_last_step": {
2278
+ "name": "totp_last_step",
2279
+ "type": "integer",
2280
+ "primaryKey": false,
2281
+ "notNull": false,
2282
+ "autoincrement": false
2283
+ },
2284
+ "recovery_codes_hash": {
2285
+ "name": "recovery_codes_hash",
2286
+ "type": "text",
2287
+ "primaryKey": false,
2288
+ "notNull": false,
2289
+ "autoincrement": false
2290
+ },
2291
+ "oidc_issuer": {
2292
+ "name": "oidc_issuer",
2293
+ "type": "text",
2294
+ "primaryKey": false,
2295
+ "notNull": false,
2296
+ "autoincrement": false
2297
+ },
2298
+ "oidc_subject": {
2299
+ "name": "oidc_subject",
2300
+ "type": "text",
2301
+ "primaryKey": false,
2302
+ "notNull": false,
2303
+ "autoincrement": false
2304
+ },
2305
+ "created_at": {
2306
+ "name": "created_at",
2307
+ "type": "integer",
2308
+ "primaryKey": false,
2309
+ "notNull": true,
2310
+ "autoincrement": false,
2311
+ "default": "(unixepoch() * 1000)"
2312
+ },
2313
+ "last_login_at": {
2314
+ "name": "last_login_at",
2315
+ "type": "integer",
2316
+ "primaryKey": false,
2317
+ "notNull": false,
2318
+ "autoincrement": false
2319
+ },
2320
+ "disabled": {
2321
+ "name": "disabled",
2322
+ "type": "integer",
2323
+ "primaryKey": false,
2324
+ "notNull": true,
2325
+ "autoincrement": false,
2326
+ "default": false
2327
+ }
2328
+ },
2329
+ "indexes": {
2330
+ "users_username_unique": {
2331
+ "name": "users_username_unique",
2332
+ "columns": [
2333
+ "username"
2334
+ ],
2335
+ "isUnique": true
2336
+ }
2337
+ },
2338
+ "foreignKeys": {},
2339
+ "compositePrimaryKeys": {},
2340
+ "uniqueConstraints": {},
2341
+ "checkConstraints": {}
2342
+ }
2343
+ },
2344
+ "views": {},
2345
+ "enums": {},
2346
+ "_meta": {
2347
+ "schemas": {},
2348
+ "tables": {},
2349
+ "columns": {}
2350
+ },
2351
+ "internal": {
2352
+ "indexes": {}
2353
+ }
2354
+ }