@morpho-dev/router 0.10.0 → 0.11.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,1652 @@
1
+ {
2
+ "id": "415f72a1-908b-47c2-93a1-2e8eda8d65c4",
3
+ "prevId": "aea37d9e-1472-41f0-83bd-66ac1e454aeb",
4
+ "version": "7",
5
+ "dialect": "postgresql",
6
+ "tables": {
7
+ "router_v1.12.callbacks": {
8
+ "name": "callbacks",
9
+ "schema": "router_v1.12",
10
+ "columns": {
11
+ "id": {
12
+ "name": "id",
13
+ "type": "varchar(66)",
14
+ "primaryKey": true,
15
+ "notNull": true
16
+ },
17
+ "position_chain_id": {
18
+ "name": "position_chain_id",
19
+ "type": "bigint",
20
+ "primaryKey": false,
21
+ "notNull": true
22
+ },
23
+ "position_contract": {
24
+ "name": "position_contract",
25
+ "type": "varchar(66)",
26
+ "primaryKey": false,
27
+ "notNull": true
28
+ },
29
+ "position_user": {
30
+ "name": "position_user",
31
+ "type": "varchar(42)",
32
+ "primaryKey": false,
33
+ "notNull": true
34
+ },
35
+ "position_type_id": {
36
+ "name": "position_type_id",
37
+ "type": "integer",
38
+ "primaryKey": false,
39
+ "notNull": true
40
+ },
41
+ "amount": {
42
+ "name": "amount",
43
+ "type": "numeric(78, 0)",
44
+ "primaryKey": false,
45
+ "notNull": false
46
+ }
47
+ },
48
+ "indexes": {},
49
+ "foreignKeys": {
50
+ "callbacks_position_type_id_position_types_id_fk": {
51
+ "name": "callbacks_position_type_id_position_types_id_fk",
52
+ "tableFrom": "callbacks",
53
+ "tableTo": "position_types",
54
+ "schemaTo": "router_v1.12",
55
+ "columnsFrom": ["position_type_id"],
56
+ "columnsTo": ["id"],
57
+ "onDelete": "no action",
58
+ "onUpdate": "no action"
59
+ }
60
+ },
61
+ "compositePrimaryKeys": {},
62
+ "uniqueConstraints": {},
63
+ "policies": {},
64
+ "checkConstraints": {},
65
+ "isRLSEnabled": false
66
+ },
67
+ "router_v1.12.chains": {
68
+ "name": "chains",
69
+ "schema": "router_v1.12",
70
+ "columns": {
71
+ "chain_id": {
72
+ "name": "chain_id",
73
+ "type": "bigint",
74
+ "primaryKey": false,
75
+ "notNull": true
76
+ },
77
+ "block_number": {
78
+ "name": "block_number",
79
+ "type": "bigint",
80
+ "primaryKey": false,
81
+ "notNull": true
82
+ },
83
+ "epoch": {
84
+ "name": "epoch",
85
+ "type": "numeric(78, 0)",
86
+ "primaryKey": false,
87
+ "notNull": true,
88
+ "default": "'0'"
89
+ },
90
+ "updated_at": {
91
+ "name": "updated_at",
92
+ "type": "timestamp",
93
+ "primaryKey": false,
94
+ "notNull": true,
95
+ "default": "now()"
96
+ }
97
+ },
98
+ "indexes": {
99
+ "chains_chain_id_idx": {
100
+ "name": "chains_chain_id_idx",
101
+ "columns": [
102
+ {
103
+ "expression": "chain_id",
104
+ "isExpression": false,
105
+ "asc": true,
106
+ "nulls": "last"
107
+ }
108
+ ],
109
+ "isUnique": true,
110
+ "concurrently": false,
111
+ "method": "btree",
112
+ "with": {}
113
+ }
114
+ },
115
+ "foreignKeys": {},
116
+ "compositePrimaryKeys": {},
117
+ "uniqueConstraints": {},
118
+ "policies": {},
119
+ "checkConstraints": {},
120
+ "isRLSEnabled": false
121
+ },
122
+ "router_v1.12.collectors": {
123
+ "name": "collectors",
124
+ "schema": "router_v1.12",
125
+ "columns": {
126
+ "chain_id": {
127
+ "name": "chain_id",
128
+ "type": "bigint",
129
+ "primaryKey": false,
130
+ "notNull": true
131
+ },
132
+ "name": {
133
+ "name": "name",
134
+ "type": "text",
135
+ "primaryKey": false,
136
+ "notNull": true
137
+ },
138
+ "block_number": {
139
+ "name": "block_number",
140
+ "type": "bigint",
141
+ "primaryKey": false,
142
+ "notNull": true
143
+ },
144
+ "epoch": {
145
+ "name": "epoch",
146
+ "type": "numeric(78, 0)",
147
+ "primaryKey": false,
148
+ "notNull": true,
149
+ "default": "'0'"
150
+ },
151
+ "updated_at": {
152
+ "name": "updated_at",
153
+ "type": "timestamp",
154
+ "primaryKey": false,
155
+ "notNull": true,
156
+ "default": "now()"
157
+ }
158
+ },
159
+ "indexes": {
160
+ "collectors_chain_name_idx": {
161
+ "name": "collectors_chain_name_idx",
162
+ "columns": [
163
+ {
164
+ "expression": "chain_id",
165
+ "isExpression": false,
166
+ "asc": true,
167
+ "nulls": "last"
168
+ },
169
+ {
170
+ "expression": "name",
171
+ "isExpression": false,
172
+ "asc": true,
173
+ "nulls": "last"
174
+ }
175
+ ],
176
+ "isUnique": true,
177
+ "concurrently": false,
178
+ "method": "btree",
179
+ "with": {}
180
+ }
181
+ },
182
+ "foreignKeys": {
183
+ "collectors_chain_id_chains_chain_id_fk": {
184
+ "name": "collectors_chain_id_chains_chain_id_fk",
185
+ "tableFrom": "collectors",
186
+ "tableTo": "chains",
187
+ "schemaTo": "router_v1.12",
188
+ "columnsFrom": ["chain_id"],
189
+ "columnsTo": ["chain_id"],
190
+ "onDelete": "no action",
191
+ "onUpdate": "no action"
192
+ }
193
+ },
194
+ "compositePrimaryKeys": {},
195
+ "uniqueConstraints": {},
196
+ "policies": {},
197
+ "checkConstraints": {},
198
+ "isRLSEnabled": false
199
+ },
200
+ "router_v1.12.consumed_events": {
201
+ "name": "consumed_events",
202
+ "schema": "router_v1.12",
203
+ "columns": {
204
+ "event_id": {
205
+ "name": "event_id",
206
+ "type": "varchar(128)",
207
+ "primaryKey": true,
208
+ "notNull": true
209
+ },
210
+ "chain_id": {
211
+ "name": "chain_id",
212
+ "type": "bigint",
213
+ "primaryKey": false,
214
+ "notNull": true
215
+ },
216
+ "maker": {
217
+ "name": "maker",
218
+ "type": "varchar(42)",
219
+ "primaryKey": false,
220
+ "notNull": true
221
+ },
222
+ "group": {
223
+ "name": "group",
224
+ "type": "varchar(66)",
225
+ "primaryKey": false,
226
+ "notNull": true
227
+ },
228
+ "amount": {
229
+ "name": "amount",
230
+ "type": "numeric(78, 0)",
231
+ "primaryKey": false,
232
+ "notNull": true
233
+ },
234
+ "block_number": {
235
+ "name": "block_number",
236
+ "type": "bigint",
237
+ "primaryKey": false,
238
+ "notNull": true
239
+ },
240
+ "created_at": {
241
+ "name": "created_at",
242
+ "type": "timestamp",
243
+ "primaryKey": false,
244
+ "notNull": true,
245
+ "default": "now()"
246
+ }
247
+ },
248
+ "indexes": {
249
+ "consumed_events_group_idx": {
250
+ "name": "consumed_events_group_idx",
251
+ "columns": [
252
+ {
253
+ "expression": "chain_id",
254
+ "isExpression": false,
255
+ "asc": true,
256
+ "nulls": "last"
257
+ },
258
+ {
259
+ "expression": "maker",
260
+ "isExpression": false,
261
+ "asc": true,
262
+ "nulls": "last"
263
+ },
264
+ {
265
+ "expression": "group",
266
+ "isExpression": false,
267
+ "asc": true,
268
+ "nulls": "last"
269
+ }
270
+ ],
271
+ "isUnique": false,
272
+ "concurrently": false,
273
+ "method": "btree",
274
+ "with": {}
275
+ },
276
+ "consumed_events_block_number_idx": {
277
+ "name": "consumed_events_block_number_idx",
278
+ "columns": [
279
+ {
280
+ "expression": "block_number",
281
+ "isExpression": false,
282
+ "asc": true,
283
+ "nulls": "last"
284
+ }
285
+ ],
286
+ "isUnique": false,
287
+ "concurrently": false,
288
+ "method": "btree",
289
+ "with": {}
290
+ }
291
+ },
292
+ "foreignKeys": {
293
+ "consumed_events_groups_fk": {
294
+ "name": "consumed_events_groups_fk",
295
+ "tableFrom": "consumed_events",
296
+ "tableTo": "groups",
297
+ "schemaTo": "router_v1.12",
298
+ "columnsFrom": ["chain_id", "maker", "group"],
299
+ "columnsTo": ["chain_id", "maker", "group"],
300
+ "onDelete": "cascade",
301
+ "onUpdate": "no action"
302
+ }
303
+ },
304
+ "compositePrimaryKeys": {},
305
+ "uniqueConstraints": {},
306
+ "policies": {},
307
+ "checkConstraints": {},
308
+ "isRLSEnabled": false
309
+ },
310
+ "router_v1.12.groups": {
311
+ "name": "groups",
312
+ "schema": "router_v1.12",
313
+ "columns": {
314
+ "chain_id": {
315
+ "name": "chain_id",
316
+ "type": "bigint",
317
+ "primaryKey": false,
318
+ "notNull": true
319
+ },
320
+ "maker": {
321
+ "name": "maker",
322
+ "type": "varchar(42)",
323
+ "primaryKey": false,
324
+ "notNull": true
325
+ },
326
+ "group": {
327
+ "name": "group",
328
+ "type": "varchar(66)",
329
+ "primaryKey": false,
330
+ "notNull": true
331
+ },
332
+ "consumed": {
333
+ "name": "consumed",
334
+ "type": "numeric(78, 0)",
335
+ "primaryKey": false,
336
+ "notNull": true
337
+ },
338
+ "block_number": {
339
+ "name": "block_number",
340
+ "type": "bigint",
341
+ "primaryKey": false,
342
+ "notNull": true
343
+ },
344
+ "updated_at": {
345
+ "name": "updated_at",
346
+ "type": "timestamp",
347
+ "primaryKey": false,
348
+ "notNull": true,
349
+ "default": "now()"
350
+ }
351
+ },
352
+ "indexes": {
353
+ "groups_chain_id_maker_group_consumed_idx": {
354
+ "name": "groups_chain_id_maker_group_consumed_idx",
355
+ "columns": [
356
+ {
357
+ "expression": "chain_id",
358
+ "isExpression": false,
359
+ "asc": true,
360
+ "nulls": "last"
361
+ },
362
+ {
363
+ "expression": "maker",
364
+ "isExpression": false,
365
+ "asc": true,
366
+ "nulls": "last"
367
+ },
368
+ {
369
+ "expression": "group",
370
+ "isExpression": false,
371
+ "asc": true,
372
+ "nulls": "last"
373
+ },
374
+ {
375
+ "expression": "consumed",
376
+ "isExpression": false,
377
+ "asc": true,
378
+ "nulls": "last"
379
+ }
380
+ ],
381
+ "isUnique": false,
382
+ "concurrently": false,
383
+ "method": "btree",
384
+ "with": {}
385
+ }
386
+ },
387
+ "foreignKeys": {},
388
+ "compositePrimaryKeys": {
389
+ "groups_pk": {
390
+ "name": "groups_pk",
391
+ "columns": ["chain_id", "maker", "group"]
392
+ }
393
+ },
394
+ "uniqueConstraints": {},
395
+ "policies": {},
396
+ "checkConstraints": {},
397
+ "isRLSEnabled": false
398
+ },
399
+ "router_v1.12.lots": {
400
+ "name": "lots",
401
+ "schema": "router_v1.12",
402
+ "columns": {
403
+ "chain_id": {
404
+ "name": "chain_id",
405
+ "type": "bigint",
406
+ "primaryKey": false,
407
+ "notNull": true
408
+ },
409
+ "user": {
410
+ "name": "user",
411
+ "type": "varchar(42)",
412
+ "primaryKey": false,
413
+ "notNull": true
414
+ },
415
+ "contract": {
416
+ "name": "contract",
417
+ "type": "varchar(66)",
418
+ "primaryKey": false,
419
+ "notNull": true
420
+ },
421
+ "group": {
422
+ "name": "group",
423
+ "type": "varchar(66)",
424
+ "primaryKey": false,
425
+ "notNull": true
426
+ },
427
+ "obligation_id": {
428
+ "name": "obligation_id",
429
+ "type": "varchar(66)",
430
+ "primaryKey": false,
431
+ "notNull": true
432
+ },
433
+ "lower": {
434
+ "name": "lower",
435
+ "type": "numeric(78, 0)",
436
+ "primaryKey": false,
437
+ "notNull": true
438
+ },
439
+ "upper": {
440
+ "name": "upper",
441
+ "type": "numeric(78, 0)",
442
+ "primaryKey": false,
443
+ "notNull": true
444
+ }
445
+ },
446
+ "indexes": {},
447
+ "foreignKeys": {
448
+ "lots_lots_positions_fk": {
449
+ "name": "lots_lots_positions_fk",
450
+ "tableFrom": "lots",
451
+ "tableTo": "lots_positions",
452
+ "schemaTo": "router_v1.12",
453
+ "columnsFrom": ["chain_id", "contract", "user"],
454
+ "columnsTo": ["chain_id", "contract", "user"],
455
+ "onDelete": "cascade",
456
+ "onUpdate": "no action"
457
+ },
458
+ "lots_groups_fk": {
459
+ "name": "lots_groups_fk",
460
+ "tableFrom": "lots",
461
+ "tableTo": "groups",
462
+ "schemaTo": "router_v1.12",
463
+ "columnsFrom": ["chain_id", "user", "group"],
464
+ "columnsTo": ["chain_id", "maker", "group"],
465
+ "onDelete": "cascade",
466
+ "onUpdate": "no action"
467
+ }
468
+ },
469
+ "compositePrimaryKeys": {
470
+ "lots_pk": {
471
+ "name": "lots_pk",
472
+ "columns": ["chain_id", "user", "contract", "group", "obligation_id"]
473
+ }
474
+ },
475
+ "uniqueConstraints": {},
476
+ "policies": {},
477
+ "checkConstraints": {},
478
+ "isRLSEnabled": false
479
+ },
480
+ "router_v1.12.lots_positions": {
481
+ "name": "lots_positions",
482
+ "schema": "router_v1.12",
483
+ "columns": {
484
+ "chain_id": {
485
+ "name": "chain_id",
486
+ "type": "bigint",
487
+ "primaryKey": false,
488
+ "notNull": true
489
+ },
490
+ "contract": {
491
+ "name": "contract",
492
+ "type": "varchar(66)",
493
+ "primaryKey": false,
494
+ "notNull": true
495
+ },
496
+ "user": {
497
+ "name": "user",
498
+ "type": "varchar(42)",
499
+ "primaryKey": false,
500
+ "notNull": true
501
+ },
502
+ "position_type_id": {
503
+ "name": "position_type_id",
504
+ "type": "integer",
505
+ "primaryKey": false,
506
+ "notNull": true
507
+ }
508
+ },
509
+ "indexes": {},
510
+ "foreignKeys": {
511
+ "lots_positions_position_type_id_position_types_id_fk": {
512
+ "name": "lots_positions_position_type_id_position_types_id_fk",
513
+ "tableFrom": "lots_positions",
514
+ "tableTo": "position_types",
515
+ "schemaTo": "router_v1.12",
516
+ "columnsFrom": ["position_type_id"],
517
+ "columnsTo": ["id"],
518
+ "onDelete": "no action",
519
+ "onUpdate": "no action"
520
+ }
521
+ },
522
+ "compositePrimaryKeys": {
523
+ "lots_positions_pk": {
524
+ "name": "lots_positions_pk",
525
+ "columns": ["chain_id", "contract", "user"]
526
+ }
527
+ },
528
+ "uniqueConstraints": {},
529
+ "policies": {},
530
+ "checkConstraints": {},
531
+ "isRLSEnabled": false
532
+ },
533
+ "router_v1.12.merkle_paths": {
534
+ "name": "merkle_paths",
535
+ "schema": "router_v1.12",
536
+ "columns": {
537
+ "offer_hash": {
538
+ "name": "offer_hash",
539
+ "type": "varchar(66)",
540
+ "primaryKey": false,
541
+ "notNull": true
542
+ },
543
+ "obligation_id": {
544
+ "name": "obligation_id",
545
+ "type": "varchar(66)",
546
+ "primaryKey": false,
547
+ "notNull": true
548
+ },
549
+ "tree_root": {
550
+ "name": "tree_root",
551
+ "type": "varchar(66)",
552
+ "primaryKey": false,
553
+ "notNull": true
554
+ },
555
+ "proof_nodes": {
556
+ "name": "proof_nodes",
557
+ "type": "text",
558
+ "primaryKey": false,
559
+ "notNull": true
560
+ },
561
+ "created_at": {
562
+ "name": "created_at",
563
+ "type": "timestamp",
564
+ "primaryKey": false,
565
+ "notNull": true,
566
+ "default": "now()"
567
+ }
568
+ },
569
+ "indexes": {
570
+ "merkle_paths_tree_root_idx": {
571
+ "name": "merkle_paths_tree_root_idx",
572
+ "columns": [
573
+ {
574
+ "expression": "tree_root",
575
+ "isExpression": false,
576
+ "asc": true,
577
+ "nulls": "last"
578
+ }
579
+ ],
580
+ "isUnique": false,
581
+ "concurrently": false,
582
+ "method": "btree",
583
+ "with": {}
584
+ }
585
+ },
586
+ "foreignKeys": {
587
+ "merkle_paths_tree_root_trees_root_fk": {
588
+ "name": "merkle_paths_tree_root_trees_root_fk",
589
+ "tableFrom": "merkle_paths",
590
+ "tableTo": "trees",
591
+ "schemaTo": "router_v1.12",
592
+ "columnsFrom": ["tree_root"],
593
+ "columnsTo": ["root"],
594
+ "onDelete": "cascade",
595
+ "onUpdate": "no action"
596
+ },
597
+ "merkle_paths_offer_fk": {
598
+ "name": "merkle_paths_offer_fk",
599
+ "tableFrom": "merkle_paths",
600
+ "tableTo": "offers",
601
+ "schemaTo": "router_v1.12",
602
+ "columnsFrom": ["offer_hash", "obligation_id"],
603
+ "columnsTo": ["hash", "obligation_id"],
604
+ "onDelete": "cascade",
605
+ "onUpdate": "no action"
606
+ }
607
+ },
608
+ "compositePrimaryKeys": {
609
+ "merkle_paths_pk": {
610
+ "name": "merkle_paths_pk",
611
+ "columns": ["offer_hash", "obligation_id"]
612
+ }
613
+ },
614
+ "uniqueConstraints": {},
615
+ "policies": {},
616
+ "checkConstraints": {},
617
+ "isRLSEnabled": false
618
+ },
619
+ "router_v1.12.obligation_collaterals_v2": {
620
+ "name": "obligation_collaterals_v2",
621
+ "schema": "router_v1.12",
622
+ "columns": {
623
+ "obligation_key": {
624
+ "name": "obligation_key",
625
+ "type": "varchar(66)",
626
+ "primaryKey": false,
627
+ "notNull": true
628
+ },
629
+ "asset": {
630
+ "name": "asset",
631
+ "type": "varchar(42)",
632
+ "primaryKey": false,
633
+ "notNull": true
634
+ },
635
+ "oracle_address": {
636
+ "name": "oracle_address",
637
+ "type": "varchar(42)",
638
+ "primaryKey": false,
639
+ "notNull": true
640
+ },
641
+ "lltv": {
642
+ "name": "lltv",
643
+ "type": "bigint",
644
+ "primaryKey": false,
645
+ "notNull": true
646
+ },
647
+ "collateral_index": {
648
+ "name": "collateral_index",
649
+ "type": "integer",
650
+ "primaryKey": false,
651
+ "notNull": true
652
+ },
653
+ "updated_at": {
654
+ "name": "updated_at",
655
+ "type": "timestamp",
656
+ "primaryKey": false,
657
+ "notNull": true,
658
+ "default": "now()"
659
+ }
660
+ },
661
+ "indexes": {
662
+ "obligation_collaterals_v2_obligation_key_idx": {
663
+ "name": "obligation_collaterals_v2_obligation_key_idx",
664
+ "columns": [
665
+ {
666
+ "expression": "obligation_key",
667
+ "isExpression": false,
668
+ "asc": true,
669
+ "nulls": "last"
670
+ }
671
+ ],
672
+ "isUnique": false,
673
+ "concurrently": false,
674
+ "method": "btree",
675
+ "with": {}
676
+ },
677
+ "obligation_collaterals_v2_oracle_address_idx": {
678
+ "name": "obligation_collaterals_v2_oracle_address_idx",
679
+ "columns": [
680
+ {
681
+ "expression": "oracle_address",
682
+ "isExpression": false,
683
+ "asc": true,
684
+ "nulls": "last"
685
+ }
686
+ ],
687
+ "isUnique": false,
688
+ "concurrently": false,
689
+ "method": "btree",
690
+ "with": {}
691
+ }
692
+ },
693
+ "foreignKeys": {
694
+ "obligation_collaterals_v2_obligation_key_obligations_obligation_key_fk": {
695
+ "name": "obligation_collaterals_v2_obligation_key_obligations_obligation_key_fk",
696
+ "tableFrom": "obligation_collaterals_v2",
697
+ "tableTo": "obligations",
698
+ "schemaTo": "router_v1.12",
699
+ "columnsFrom": ["obligation_key"],
700
+ "columnsTo": ["obligation_key"],
701
+ "onDelete": "cascade",
702
+ "onUpdate": "no action"
703
+ }
704
+ },
705
+ "compositePrimaryKeys": {
706
+ "obligation_collaterals_v2_pk": {
707
+ "name": "obligation_collaterals_v2_pk",
708
+ "columns": ["obligation_key", "asset"]
709
+ }
710
+ },
711
+ "uniqueConstraints": {},
712
+ "policies": {},
713
+ "checkConstraints": {},
714
+ "isRLSEnabled": false
715
+ },
716
+ "router_v1.12.obligation_id_keys": {
717
+ "name": "obligation_id_keys",
718
+ "schema": "router_v1.12",
719
+ "columns": {
720
+ "obligation_id": {
721
+ "name": "obligation_id",
722
+ "type": "varchar(66)",
723
+ "primaryKey": true,
724
+ "notNull": true
725
+ },
726
+ "obligation_key": {
727
+ "name": "obligation_key",
728
+ "type": "varchar(66)",
729
+ "primaryKey": false,
730
+ "notNull": true
731
+ },
732
+ "chain_id": {
733
+ "name": "chain_id",
734
+ "type": "bigint",
735
+ "primaryKey": false,
736
+ "notNull": true
737
+ },
738
+ "morpho_v2": {
739
+ "name": "morpho_v2",
740
+ "type": "varchar(42)",
741
+ "primaryKey": false,
742
+ "notNull": true
743
+ }
744
+ },
745
+ "indexes": {
746
+ "obligation_id_keys_obligation_key_idx": {
747
+ "name": "obligation_id_keys_obligation_key_idx",
748
+ "columns": [
749
+ {
750
+ "expression": "obligation_key",
751
+ "isExpression": false,
752
+ "asc": true,
753
+ "nulls": "last"
754
+ }
755
+ ],
756
+ "isUnique": false,
757
+ "concurrently": false,
758
+ "method": "btree",
759
+ "with": {}
760
+ },
761
+ "obligation_id_keys_chain_id_idx": {
762
+ "name": "obligation_id_keys_chain_id_idx",
763
+ "columns": [
764
+ {
765
+ "expression": "chain_id",
766
+ "isExpression": false,
767
+ "asc": true,
768
+ "nulls": "last"
769
+ }
770
+ ],
771
+ "isUnique": false,
772
+ "concurrently": false,
773
+ "method": "btree",
774
+ "with": {}
775
+ }
776
+ },
777
+ "foreignKeys": {
778
+ "obligation_id_keys_obligation_key_obligations_obligation_key_fk": {
779
+ "name": "obligation_id_keys_obligation_key_obligations_obligation_key_fk",
780
+ "tableFrom": "obligation_id_keys",
781
+ "tableTo": "obligations",
782
+ "schemaTo": "router_v1.12",
783
+ "columnsFrom": ["obligation_key"],
784
+ "columnsTo": ["obligation_key"],
785
+ "onDelete": "cascade",
786
+ "onUpdate": "no action"
787
+ }
788
+ },
789
+ "compositePrimaryKeys": {},
790
+ "uniqueConstraints": {},
791
+ "policies": {},
792
+ "checkConstraints": {},
793
+ "isRLSEnabled": false
794
+ },
795
+ "router_v1.12.obligations": {
796
+ "name": "obligations",
797
+ "schema": "router_v1.12",
798
+ "columns": {
799
+ "obligation_key": {
800
+ "name": "obligation_key",
801
+ "type": "varchar(66)",
802
+ "primaryKey": true,
803
+ "notNull": true
804
+ },
805
+ "loan_token": {
806
+ "name": "loan_token",
807
+ "type": "varchar(42)",
808
+ "primaryKey": false,
809
+ "notNull": true
810
+ },
811
+ "maturity": {
812
+ "name": "maturity",
813
+ "type": "integer",
814
+ "primaryKey": false,
815
+ "notNull": true
816
+ }
817
+ },
818
+ "indexes": {},
819
+ "foreignKeys": {},
820
+ "compositePrimaryKeys": {},
821
+ "uniqueConstraints": {},
822
+ "policies": {},
823
+ "checkConstraints": {},
824
+ "isRLSEnabled": false
825
+ },
826
+ "router_v1.12.offers": {
827
+ "name": "offers",
828
+ "schema": "router_v1.12",
829
+ "columns": {
830
+ "hash": {
831
+ "name": "hash",
832
+ "type": "varchar(66)",
833
+ "primaryKey": false,
834
+ "notNull": true
835
+ },
836
+ "obligation_id": {
837
+ "name": "obligation_id",
838
+ "type": "varchar(66)",
839
+ "primaryKey": false,
840
+ "notNull": true
841
+ },
842
+ "assets": {
843
+ "name": "assets",
844
+ "type": "numeric(78, 0)",
845
+ "primaryKey": false,
846
+ "notNull": true
847
+ },
848
+ "obligation_units": {
849
+ "name": "obligation_units",
850
+ "type": "numeric(78, 0)",
851
+ "primaryKey": false,
852
+ "notNull": true,
853
+ "default": "'0'"
854
+ },
855
+ "obligation_shares": {
856
+ "name": "obligation_shares",
857
+ "type": "numeric(78, 0)",
858
+ "primaryKey": false,
859
+ "notNull": true,
860
+ "default": "'0'"
861
+ },
862
+ "tick": {
863
+ "name": "tick",
864
+ "type": "integer",
865
+ "primaryKey": false,
866
+ "notNull": true
867
+ },
868
+ "maturity": {
869
+ "name": "maturity",
870
+ "type": "integer",
871
+ "primaryKey": false,
872
+ "notNull": true
873
+ },
874
+ "expiry": {
875
+ "name": "expiry",
876
+ "type": "integer",
877
+ "primaryKey": false,
878
+ "notNull": true
879
+ },
880
+ "start": {
881
+ "name": "start",
882
+ "type": "integer",
883
+ "primaryKey": false,
884
+ "notNull": true
885
+ },
886
+ "group_chain_id": {
887
+ "name": "group_chain_id",
888
+ "type": "bigint",
889
+ "primaryKey": false,
890
+ "notNull": true
891
+ },
892
+ "group_maker": {
893
+ "name": "group_maker",
894
+ "type": "varchar(42)",
895
+ "primaryKey": false,
896
+ "notNull": true
897
+ },
898
+ "group_group": {
899
+ "name": "group_group",
900
+ "type": "varchar(66)",
901
+ "primaryKey": false,
902
+ "notNull": true
903
+ },
904
+ "session": {
905
+ "name": "session",
906
+ "type": "varchar(66)",
907
+ "primaryKey": false,
908
+ "notNull": true
909
+ },
910
+ "buy": {
911
+ "name": "buy",
912
+ "type": "boolean",
913
+ "primaryKey": false,
914
+ "notNull": true
915
+ },
916
+ "callback_address": {
917
+ "name": "callback_address",
918
+ "type": "varchar(42)",
919
+ "primaryKey": false,
920
+ "notNull": true
921
+ },
922
+ "callback_data": {
923
+ "name": "callback_data",
924
+ "type": "text",
925
+ "primaryKey": false,
926
+ "notNull": true
927
+ },
928
+ "receiver_if_maker_is_seller": {
929
+ "name": "receiver_if_maker_is_seller",
930
+ "type": "varchar(42)",
931
+ "primaryKey": false,
932
+ "notNull": false
933
+ },
934
+ "block_number": {
935
+ "name": "block_number",
936
+ "type": "bigint",
937
+ "primaryKey": false,
938
+ "notNull": true
939
+ },
940
+ "updated_at": {
941
+ "name": "updated_at",
942
+ "type": "timestamp",
943
+ "primaryKey": false,
944
+ "notNull": true,
945
+ "default": "now()"
946
+ }
947
+ },
948
+ "indexes": {
949
+ "offers_group_fk_idx": {
950
+ "name": "offers_group_fk_idx",
951
+ "columns": [
952
+ {
953
+ "expression": "group_chain_id",
954
+ "isExpression": false,
955
+ "asc": true,
956
+ "nulls": "last"
957
+ },
958
+ {
959
+ "expression": "group_maker",
960
+ "isExpression": false,
961
+ "asc": true,
962
+ "nulls": "last"
963
+ },
964
+ {
965
+ "expression": "group_group",
966
+ "isExpression": false,
967
+ "asc": true,
968
+ "nulls": "last"
969
+ }
970
+ ],
971
+ "isUnique": false,
972
+ "concurrently": false,
973
+ "method": "btree",
974
+ "with": {}
975
+ },
976
+ "offers_group_and_hash_idx": {
977
+ "name": "offers_group_and_hash_idx",
978
+ "columns": [
979
+ {
980
+ "expression": "group_chain_id",
981
+ "isExpression": false,
982
+ "asc": true,
983
+ "nulls": "last"
984
+ },
985
+ {
986
+ "expression": "group_maker",
987
+ "isExpression": false,
988
+ "asc": true,
989
+ "nulls": "last"
990
+ },
991
+ {
992
+ "expression": "group_group",
993
+ "isExpression": false,
994
+ "asc": true,
995
+ "nulls": "last"
996
+ },
997
+ {
998
+ "expression": "hash",
999
+ "isExpression": false,
1000
+ "asc": true,
1001
+ "nulls": "last"
1002
+ }
1003
+ ],
1004
+ "isUnique": false,
1005
+ "concurrently": false,
1006
+ "method": "btree",
1007
+ "with": {}
1008
+ },
1009
+ "offers_obligation_id_side_idx": {
1010
+ "name": "offers_obligation_id_side_idx",
1011
+ "columns": [
1012
+ {
1013
+ "expression": "obligation_id",
1014
+ "isExpression": false,
1015
+ "asc": true,
1016
+ "nulls": "last"
1017
+ },
1018
+ {
1019
+ "expression": "buy",
1020
+ "isExpression": false,
1021
+ "asc": true,
1022
+ "nulls": "last"
1023
+ }
1024
+ ],
1025
+ "isUnique": false,
1026
+ "concurrently": false,
1027
+ "method": "btree",
1028
+ "with": {}
1029
+ }
1030
+ },
1031
+ "foreignKeys": {
1032
+ "offers_obligation_id_obligation_id_keys_obligation_id_fk": {
1033
+ "name": "offers_obligation_id_obligation_id_keys_obligation_id_fk",
1034
+ "tableFrom": "offers",
1035
+ "tableTo": "obligation_id_keys",
1036
+ "schemaTo": "router_v1.12",
1037
+ "columnsFrom": ["obligation_id"],
1038
+ "columnsTo": ["obligation_id"],
1039
+ "onDelete": "cascade",
1040
+ "onUpdate": "no action"
1041
+ },
1042
+ "offers_groups_fk": {
1043
+ "name": "offers_groups_fk",
1044
+ "tableFrom": "offers",
1045
+ "tableTo": "groups",
1046
+ "schemaTo": "router_v1.12",
1047
+ "columnsFrom": ["group_chain_id", "group_maker", "group_group"],
1048
+ "columnsTo": ["chain_id", "maker", "group"],
1049
+ "onDelete": "cascade",
1050
+ "onUpdate": "no action"
1051
+ }
1052
+ },
1053
+ "compositePrimaryKeys": {
1054
+ "offers_pk": {
1055
+ "name": "offers_pk",
1056
+ "columns": ["hash", "obligation_id"]
1057
+ }
1058
+ },
1059
+ "uniqueConstraints": {},
1060
+ "policies": {},
1061
+ "checkConstraints": {},
1062
+ "isRLSEnabled": false
1063
+ },
1064
+ "router_v1.12.offers_callbacks": {
1065
+ "name": "offers_callbacks",
1066
+ "schema": "router_v1.12",
1067
+ "columns": {
1068
+ "offer_hash": {
1069
+ "name": "offer_hash",
1070
+ "type": "varchar(66)",
1071
+ "primaryKey": false,
1072
+ "notNull": true
1073
+ },
1074
+ "obligation_id": {
1075
+ "name": "obligation_id",
1076
+ "type": "varchar(66)",
1077
+ "primaryKey": false,
1078
+ "notNull": true
1079
+ },
1080
+ "callback_id": {
1081
+ "name": "callback_id",
1082
+ "type": "varchar(66)",
1083
+ "primaryKey": false,
1084
+ "notNull": false
1085
+ }
1086
+ },
1087
+ "indexes": {},
1088
+ "foreignKeys": {
1089
+ "offers_callbacks_offer_fk": {
1090
+ "name": "offers_callbacks_offer_fk",
1091
+ "tableFrom": "offers_callbacks",
1092
+ "tableTo": "offers",
1093
+ "schemaTo": "router_v1.12",
1094
+ "columnsFrom": ["offer_hash", "obligation_id"],
1095
+ "columnsTo": ["hash", "obligation_id"],
1096
+ "onDelete": "cascade",
1097
+ "onUpdate": "no action"
1098
+ }
1099
+ },
1100
+ "compositePrimaryKeys": {
1101
+ "offers_callbacks_pk": {
1102
+ "name": "offers_callbacks_pk",
1103
+ "columns": ["offer_hash", "obligation_id", "callback_id"]
1104
+ }
1105
+ },
1106
+ "uniqueConstraints": {},
1107
+ "policies": {},
1108
+ "checkConstraints": {},
1109
+ "isRLSEnabled": false
1110
+ },
1111
+ "router_v1.12.offsets": {
1112
+ "name": "offsets",
1113
+ "schema": "router_v1.12",
1114
+ "columns": {
1115
+ "chain_id": {
1116
+ "name": "chain_id",
1117
+ "type": "bigint",
1118
+ "primaryKey": false,
1119
+ "notNull": true
1120
+ },
1121
+ "user": {
1122
+ "name": "user",
1123
+ "type": "varchar(42)",
1124
+ "primaryKey": false,
1125
+ "notNull": true
1126
+ },
1127
+ "contract": {
1128
+ "name": "contract",
1129
+ "type": "varchar(66)",
1130
+ "primaryKey": false,
1131
+ "notNull": true
1132
+ },
1133
+ "group": {
1134
+ "name": "group",
1135
+ "type": "varchar(66)",
1136
+ "primaryKey": false,
1137
+ "notNull": true
1138
+ },
1139
+ "obligation_id": {
1140
+ "name": "obligation_id",
1141
+ "type": "varchar(66)",
1142
+ "primaryKey": false,
1143
+ "notNull": true
1144
+ },
1145
+ "value": {
1146
+ "name": "value",
1147
+ "type": "numeric(78, 0)",
1148
+ "primaryKey": false,
1149
+ "notNull": true
1150
+ }
1151
+ },
1152
+ "indexes": {},
1153
+ "foreignKeys": {
1154
+ "offsets_lots_positions_fk": {
1155
+ "name": "offsets_lots_positions_fk",
1156
+ "tableFrom": "offsets",
1157
+ "tableTo": "lots_positions",
1158
+ "schemaTo": "router_v1.12",
1159
+ "columnsFrom": ["chain_id", "contract", "user"],
1160
+ "columnsTo": ["chain_id", "contract", "user"],
1161
+ "onDelete": "cascade",
1162
+ "onUpdate": "no action"
1163
+ }
1164
+ },
1165
+ "compositePrimaryKeys": {
1166
+ "offsets_pk": {
1167
+ "name": "offsets_pk",
1168
+ "columns": ["chain_id", "user", "contract", "group", "obligation_id"]
1169
+ }
1170
+ },
1171
+ "uniqueConstraints": {},
1172
+ "policies": {},
1173
+ "checkConstraints": {},
1174
+ "isRLSEnabled": false
1175
+ },
1176
+ "router_v1.12.oracles": {
1177
+ "name": "oracles",
1178
+ "schema": "router_v1.12",
1179
+ "columns": {
1180
+ "chain_id": {
1181
+ "name": "chain_id",
1182
+ "type": "bigint",
1183
+ "primaryKey": false,
1184
+ "notNull": true
1185
+ },
1186
+ "address": {
1187
+ "name": "address",
1188
+ "type": "varchar(42)",
1189
+ "primaryKey": false,
1190
+ "notNull": true
1191
+ },
1192
+ "price": {
1193
+ "name": "price",
1194
+ "type": "numeric(78, 0)",
1195
+ "primaryKey": false,
1196
+ "notNull": false
1197
+ },
1198
+ "block_number": {
1199
+ "name": "block_number",
1200
+ "type": "bigint",
1201
+ "primaryKey": false,
1202
+ "notNull": true
1203
+ },
1204
+ "updated_at": {
1205
+ "name": "updated_at",
1206
+ "type": "timestamp",
1207
+ "primaryKey": false,
1208
+ "notNull": true,
1209
+ "default": "now()"
1210
+ }
1211
+ },
1212
+ "indexes": {},
1213
+ "foreignKeys": {},
1214
+ "compositePrimaryKeys": {
1215
+ "oracles_pk": {
1216
+ "name": "oracles_pk",
1217
+ "columns": ["chain_id", "address"]
1218
+ }
1219
+ },
1220
+ "uniqueConstraints": {},
1221
+ "policies": {},
1222
+ "checkConstraints": {},
1223
+ "isRLSEnabled": false
1224
+ },
1225
+ "router_v1.12.position_types": {
1226
+ "name": "position_types",
1227
+ "schema": "router_v1.12",
1228
+ "columns": {
1229
+ "id": {
1230
+ "name": "id",
1231
+ "type": "serial",
1232
+ "primaryKey": true,
1233
+ "notNull": true
1234
+ },
1235
+ "type": {
1236
+ "name": "type",
1237
+ "type": "position_type",
1238
+ "typeSchema": "router_v1.12",
1239
+ "primaryKey": false,
1240
+ "notNull": true
1241
+ }
1242
+ },
1243
+ "indexes": {},
1244
+ "foreignKeys": {},
1245
+ "compositePrimaryKeys": {},
1246
+ "uniqueConstraints": {},
1247
+ "policies": {},
1248
+ "checkConstraints": {},
1249
+ "isRLSEnabled": false
1250
+ },
1251
+ "router_v1.12.positions": {
1252
+ "name": "positions",
1253
+ "schema": "router_v1.12",
1254
+ "columns": {
1255
+ "chain_id": {
1256
+ "name": "chain_id",
1257
+ "type": "bigint",
1258
+ "primaryKey": false,
1259
+ "notNull": true
1260
+ },
1261
+ "contract": {
1262
+ "name": "contract",
1263
+ "type": "varchar(66)",
1264
+ "primaryKey": false,
1265
+ "notNull": true
1266
+ },
1267
+ "user": {
1268
+ "name": "user",
1269
+ "type": "varchar(42)",
1270
+ "primaryKey": false,
1271
+ "notNull": true
1272
+ },
1273
+ "position_type_id": {
1274
+ "name": "position_type_id",
1275
+ "type": "integer",
1276
+ "primaryKey": false,
1277
+ "notNull": true
1278
+ },
1279
+ "balance": {
1280
+ "name": "balance",
1281
+ "type": "numeric(78, 0)",
1282
+ "primaryKey": false,
1283
+ "notNull": false
1284
+ },
1285
+ "asset": {
1286
+ "name": "asset",
1287
+ "type": "varchar(42)",
1288
+ "primaryKey": false,
1289
+ "notNull": true
1290
+ },
1291
+ "block_number": {
1292
+ "name": "block_number",
1293
+ "type": "bigint",
1294
+ "primaryKey": false,
1295
+ "notNull": true
1296
+ },
1297
+ "updated_at": {
1298
+ "name": "updated_at",
1299
+ "type": "timestamp",
1300
+ "primaryKey": false,
1301
+ "notNull": true,
1302
+ "default": "now()"
1303
+ }
1304
+ },
1305
+ "indexes": {},
1306
+ "foreignKeys": {
1307
+ "positions_position_type_id_position_types_id_fk": {
1308
+ "name": "positions_position_type_id_position_types_id_fk",
1309
+ "tableFrom": "positions",
1310
+ "tableTo": "position_types",
1311
+ "schemaTo": "router_v1.12",
1312
+ "columnsFrom": ["position_type_id"],
1313
+ "columnsTo": ["id"],
1314
+ "onDelete": "no action",
1315
+ "onUpdate": "no action"
1316
+ }
1317
+ },
1318
+ "compositePrimaryKeys": {
1319
+ "positions_pk": {
1320
+ "name": "positions_pk",
1321
+ "columns": ["chain_id", "contract", "user", "position_type_id", "asset"]
1322
+ }
1323
+ },
1324
+ "uniqueConstraints": {},
1325
+ "policies": {},
1326
+ "checkConstraints": {},
1327
+ "isRLSEnabled": false
1328
+ },
1329
+ "router_v1.12.status": {
1330
+ "name": "status",
1331
+ "schema": "router_v1.12",
1332
+ "columns": {
1333
+ "id": {
1334
+ "name": "id",
1335
+ "type": "serial",
1336
+ "primaryKey": true,
1337
+ "notNull": true
1338
+ },
1339
+ "code": {
1340
+ "name": "code",
1341
+ "type": "status_code",
1342
+ "typeSchema": "router_v1.12",
1343
+ "primaryKey": false,
1344
+ "notNull": false
1345
+ }
1346
+ },
1347
+ "indexes": {},
1348
+ "foreignKeys": {},
1349
+ "compositePrimaryKeys": {},
1350
+ "uniqueConstraints": {
1351
+ "status_code_unique": {
1352
+ "name": "status_code_unique",
1353
+ "nullsNotDistinct": false,
1354
+ "columns": ["code"]
1355
+ }
1356
+ },
1357
+ "policies": {},
1358
+ "checkConstraints": {},
1359
+ "isRLSEnabled": false
1360
+ },
1361
+ "router_v1.12.transfers": {
1362
+ "name": "transfers",
1363
+ "schema": "router_v1.12",
1364
+ "columns": {
1365
+ "event_id": {
1366
+ "name": "event_id",
1367
+ "type": "varchar(128)",
1368
+ "primaryKey": true,
1369
+ "notNull": true
1370
+ },
1371
+ "chain_id": {
1372
+ "name": "chain_id",
1373
+ "type": "bigint",
1374
+ "primaryKey": false,
1375
+ "notNull": true
1376
+ },
1377
+ "contract": {
1378
+ "name": "contract",
1379
+ "type": "varchar(66)",
1380
+ "primaryKey": false,
1381
+ "notNull": true
1382
+ },
1383
+ "from": {
1384
+ "name": "from",
1385
+ "type": "varchar(42)",
1386
+ "primaryKey": false,
1387
+ "notNull": true
1388
+ },
1389
+ "to": {
1390
+ "name": "to",
1391
+ "type": "varchar(42)",
1392
+ "primaryKey": false,
1393
+ "notNull": true
1394
+ },
1395
+ "value": {
1396
+ "name": "value",
1397
+ "type": "numeric(78, 0)",
1398
+ "primaryKey": false,
1399
+ "notNull": true
1400
+ },
1401
+ "position_type_id": {
1402
+ "name": "position_type_id",
1403
+ "type": "integer",
1404
+ "primaryKey": false,
1405
+ "notNull": true
1406
+ },
1407
+ "asset": {
1408
+ "name": "asset",
1409
+ "type": "varchar(42)",
1410
+ "primaryKey": false,
1411
+ "notNull": true
1412
+ },
1413
+ "block_number": {
1414
+ "name": "block_number",
1415
+ "type": "bigint",
1416
+ "primaryKey": false,
1417
+ "notNull": true
1418
+ },
1419
+ "created_at": {
1420
+ "name": "created_at",
1421
+ "type": "timestamp",
1422
+ "primaryKey": false,
1423
+ "notNull": true,
1424
+ "default": "now()"
1425
+ }
1426
+ },
1427
+ "indexes": {
1428
+ "transfers_chain_contract_user_idx": {
1429
+ "name": "transfers_chain_contract_user_idx",
1430
+ "columns": [
1431
+ {
1432
+ "expression": "chain_id",
1433
+ "isExpression": false,
1434
+ "asc": true,
1435
+ "nulls": "last"
1436
+ },
1437
+ {
1438
+ "expression": "contract",
1439
+ "isExpression": false,
1440
+ "asc": true,
1441
+ "nulls": "last"
1442
+ },
1443
+ {
1444
+ "expression": "from",
1445
+ "isExpression": false,
1446
+ "asc": true,
1447
+ "nulls": "last"
1448
+ },
1449
+ {
1450
+ "expression": "to",
1451
+ "isExpression": false,
1452
+ "asc": true,
1453
+ "nulls": "last"
1454
+ },
1455
+ {
1456
+ "expression": "block_number",
1457
+ "isExpression": false,
1458
+ "asc": true,
1459
+ "nulls": "last"
1460
+ }
1461
+ ],
1462
+ "isUnique": false,
1463
+ "concurrently": false,
1464
+ "method": "btree",
1465
+ "with": {}
1466
+ },
1467
+ "transfers_chain_type_block_idx": {
1468
+ "name": "transfers_chain_type_block_idx",
1469
+ "columns": [
1470
+ {
1471
+ "expression": "chain_id",
1472
+ "isExpression": false,
1473
+ "asc": true,
1474
+ "nulls": "last"
1475
+ },
1476
+ {
1477
+ "expression": "position_type_id",
1478
+ "isExpression": false,
1479
+ "asc": true,
1480
+ "nulls": "last"
1481
+ },
1482
+ {
1483
+ "expression": "block_number",
1484
+ "isExpression": false,
1485
+ "asc": true,
1486
+ "nulls": "last"
1487
+ }
1488
+ ],
1489
+ "isUnique": false,
1490
+ "concurrently": false,
1491
+ "method": "btree",
1492
+ "with": {}
1493
+ }
1494
+ },
1495
+ "foreignKeys": {
1496
+ "transfers_position_type_id_position_types_id_fk": {
1497
+ "name": "transfers_position_type_id_position_types_id_fk",
1498
+ "tableFrom": "transfers",
1499
+ "tableTo": "position_types",
1500
+ "schemaTo": "router_v1.12",
1501
+ "columnsFrom": ["position_type_id"],
1502
+ "columnsTo": ["id"],
1503
+ "onDelete": "no action",
1504
+ "onUpdate": "no action"
1505
+ },
1506
+ "transfers_positions_from_fk": {
1507
+ "name": "transfers_positions_from_fk",
1508
+ "tableFrom": "transfers",
1509
+ "tableTo": "positions",
1510
+ "schemaTo": "router_v1.12",
1511
+ "columnsFrom": ["chain_id", "contract", "from", "position_type_id", "asset"],
1512
+ "columnsTo": ["chain_id", "contract", "user", "position_type_id", "asset"],
1513
+ "onDelete": "cascade",
1514
+ "onUpdate": "no action"
1515
+ },
1516
+ "transfers_positions_to_fk": {
1517
+ "name": "transfers_positions_to_fk",
1518
+ "tableFrom": "transfers",
1519
+ "tableTo": "positions",
1520
+ "schemaTo": "router_v1.12",
1521
+ "columnsFrom": ["chain_id", "contract", "to", "position_type_id", "asset"],
1522
+ "columnsTo": ["chain_id", "contract", "user", "position_type_id", "asset"],
1523
+ "onDelete": "cascade",
1524
+ "onUpdate": "no action"
1525
+ }
1526
+ },
1527
+ "compositePrimaryKeys": {},
1528
+ "uniqueConstraints": {},
1529
+ "policies": {},
1530
+ "checkConstraints": {},
1531
+ "isRLSEnabled": false
1532
+ },
1533
+ "router_v1.12.trees": {
1534
+ "name": "trees",
1535
+ "schema": "router_v1.12",
1536
+ "columns": {
1537
+ "root": {
1538
+ "name": "root",
1539
+ "type": "varchar(66)",
1540
+ "primaryKey": true,
1541
+ "notNull": true
1542
+ },
1543
+ "root_signature": {
1544
+ "name": "root_signature",
1545
+ "type": "varchar(132)",
1546
+ "primaryKey": false,
1547
+ "notNull": true
1548
+ },
1549
+ "created_at": {
1550
+ "name": "created_at",
1551
+ "type": "timestamp",
1552
+ "primaryKey": false,
1553
+ "notNull": true,
1554
+ "default": "now()"
1555
+ }
1556
+ },
1557
+ "indexes": {},
1558
+ "foreignKeys": {},
1559
+ "compositePrimaryKeys": {},
1560
+ "uniqueConstraints": {},
1561
+ "policies": {},
1562
+ "checkConstraints": {},
1563
+ "isRLSEnabled": false
1564
+ },
1565
+ "router_v1.12.validations": {
1566
+ "name": "validations",
1567
+ "schema": "router_v1.12",
1568
+ "columns": {
1569
+ "offer_hash": {
1570
+ "name": "offer_hash",
1571
+ "type": "varchar(66)",
1572
+ "primaryKey": false,
1573
+ "notNull": true
1574
+ },
1575
+ "obligation_id": {
1576
+ "name": "obligation_id",
1577
+ "type": "varchar(66)",
1578
+ "primaryKey": false,
1579
+ "notNull": true
1580
+ },
1581
+ "status_id": {
1582
+ "name": "status_id",
1583
+ "type": "integer",
1584
+ "primaryKey": false,
1585
+ "notNull": true
1586
+ },
1587
+ "updated_at": {
1588
+ "name": "updated_at",
1589
+ "type": "timestamp",
1590
+ "primaryKey": false,
1591
+ "notNull": true,
1592
+ "default": "now()"
1593
+ }
1594
+ },
1595
+ "indexes": {},
1596
+ "foreignKeys": {
1597
+ "validations_status_id_status_id_fk": {
1598
+ "name": "validations_status_id_status_id_fk",
1599
+ "tableFrom": "validations",
1600
+ "tableTo": "status",
1601
+ "schemaTo": "router_v1.12",
1602
+ "columnsFrom": ["status_id"],
1603
+ "columnsTo": ["id"],
1604
+ "onDelete": "no action",
1605
+ "onUpdate": "no action"
1606
+ },
1607
+ "validations_offer_fk": {
1608
+ "name": "validations_offer_fk",
1609
+ "tableFrom": "validations",
1610
+ "tableTo": "offers",
1611
+ "schemaTo": "router_v1.12",
1612
+ "columnsFrom": ["offer_hash", "obligation_id"],
1613
+ "columnsTo": ["hash", "obligation_id"],
1614
+ "onDelete": "cascade",
1615
+ "onUpdate": "no action"
1616
+ }
1617
+ },
1618
+ "compositePrimaryKeys": {
1619
+ "validations_pk": {
1620
+ "name": "validations_pk",
1621
+ "columns": ["offer_hash", "obligation_id"]
1622
+ }
1623
+ },
1624
+ "uniqueConstraints": {},
1625
+ "policies": {},
1626
+ "checkConstraints": {},
1627
+ "isRLSEnabled": false
1628
+ }
1629
+ },
1630
+ "enums": {
1631
+ "router_v1.12.position_type": {
1632
+ "name": "position_type",
1633
+ "schema": "router_v1.12",
1634
+ "values": ["erc20", "vault_v1", "debtOf", "collateralOf"]
1635
+ },
1636
+ "router_v1.12.status_code": {
1637
+ "name": "status_code",
1638
+ "schema": "router_v1.12",
1639
+ "values": ["VALID", "SIMULATION_ERROR"]
1640
+ }
1641
+ },
1642
+ "schemas": {},
1643
+ "sequences": {},
1644
+ "roles": {},
1645
+ "policies": {},
1646
+ "views": {},
1647
+ "_meta": {
1648
+ "columns": {},
1649
+ "schemas": {},
1650
+ "tables": {}
1651
+ }
1652
+ }