@happyvertical/smrt-properties 0.30.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,1612 @@
1
+ {
2
+ "version": "1.0.0",
3
+ "timestamp": 1782177128343,
4
+ "packageName": "@happyvertical/smrt-properties",
5
+ "packageVersion": "0.30.0",
6
+ "objects": {
7
+ "@happyvertical/smrt-properties:PropertyCollection": {
8
+ "name": "propertycollection",
9
+ "className": "PropertyCollection",
10
+ "qualifiedName": "@happyvertical/smrt-properties:PropertyCollection",
11
+ "collection": "properties",
12
+ "filePath": "/home/runner/_work/smrt/smrt/packages/properties/src/collections/Properties.ts",
13
+ "packageName": "@happyvertical/smrt-properties",
14
+ "fields": {},
15
+ "methods": {
16
+ "findByDomain": {
17
+ "name": "findByDomain",
18
+ "async": true,
19
+ "parameters": [
20
+ {
21
+ "name": "domain",
22
+ "type": "string",
23
+ "optional": false
24
+ }
25
+ ],
26
+ "returnType": "Promise<Property | null>",
27
+ "isStatic": false,
28
+ "isPublic": true
29
+ },
30
+ "findByRepository": {
31
+ "name": "findByRepository",
32
+ "async": true,
33
+ "parameters": [
34
+ {
35
+ "name": "repositoryId",
36
+ "type": "string",
37
+ "optional": false
38
+ }
39
+ ],
40
+ "returnType": "Promise<Property[]>",
41
+ "isStatic": false,
42
+ "isPublic": true
43
+ },
44
+ "findByOwner": {
45
+ "name": "findByOwner",
46
+ "async": true,
47
+ "parameters": [
48
+ {
49
+ "name": "ownerId",
50
+ "type": "string",
51
+ "optional": false
52
+ }
53
+ ],
54
+ "returnType": "Promise<Property[]>",
55
+ "isStatic": false,
56
+ "isPublic": true
57
+ },
58
+ "findActive": {
59
+ "name": "findActive",
60
+ "async": true,
61
+ "parameters": [],
62
+ "returnType": "Promise<Property[]>",
63
+ "isStatic": false,
64
+ "isPublic": true
65
+ },
66
+ "findByStatus": {
67
+ "name": "findByStatus",
68
+ "async": true,
69
+ "parameters": [
70
+ {
71
+ "name": "status",
72
+ "type": "PropertyStatus",
73
+ "optional": false
74
+ }
75
+ ],
76
+ "returnType": "Promise<Property[]>",
77
+ "isStatic": false,
78
+ "isPublic": true
79
+ },
80
+ "getOrCreateByDomain": {
81
+ "name": "getOrCreateByDomain",
82
+ "async": true,
83
+ "parameters": [
84
+ {
85
+ "name": "domain",
86
+ "type": "string",
87
+ "optional": false
88
+ },
89
+ {
90
+ "name": "defaults",
91
+ "type": "object",
92
+ "optional": true
93
+ }
94
+ ],
95
+ "returnType": "Promise<Property>",
96
+ "isStatic": false,
97
+ "isPublic": true
98
+ },
99
+ "countByStatus": {
100
+ "name": "countByStatus",
101
+ "async": true,
102
+ "parameters": [],
103
+ "returnType": "Promise<Record<PropertyStatus, number>>",
104
+ "isStatic": false,
105
+ "isPublic": true
106
+ },
107
+ "findByTenant": {
108
+ "name": "findByTenant",
109
+ "async": true,
110
+ "parameters": [
111
+ {
112
+ "name": "tenantId",
113
+ "type": "string",
114
+ "optional": false
115
+ }
116
+ ],
117
+ "returnType": "Promise<Property[]>",
118
+ "isStatic": false,
119
+ "isPublic": true
120
+ },
121
+ "findGlobal": {
122
+ "name": "findGlobal",
123
+ "async": true,
124
+ "parameters": [],
125
+ "returnType": "Promise<Property[]>",
126
+ "isStatic": false,
127
+ "isPublic": true
128
+ },
129
+ "findWithGlobals": {
130
+ "name": "findWithGlobals",
131
+ "async": true,
132
+ "parameters": [
133
+ {
134
+ "name": "tenantId",
135
+ "type": "string",
136
+ "optional": false
137
+ }
138
+ ],
139
+ "returnType": "Promise<Property[]>",
140
+ "isStatic": false,
141
+ "isPublic": true
142
+ }
143
+ },
144
+ "decoratorConfig": {},
145
+ "extends": "SmrtCollection",
146
+ "extendsTypeArg": "Property",
147
+ "exportName": "PropertyCollection",
148
+ "collectionExportName": "PropertyCollectionCollection",
149
+ "schema": {
150
+ "tableName": "property_collections",
151
+ "ddl": "CREATE TABLE IF NOT EXISTS \"property_collections\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp\n);",
152
+ "columns": {
153
+ "id": {
154
+ "type": "UUID",
155
+ "primaryKey": true,
156
+ "referenceKind": "id",
157
+ "notNull": true
158
+ },
159
+ "slug": {
160
+ "type": "TEXT",
161
+ "notNull": true
162
+ },
163
+ "context": {
164
+ "type": "TEXT",
165
+ "notNull": true,
166
+ "default": ""
167
+ },
168
+ "created_at": {
169
+ "type": "TIMESTAMP",
170
+ "notNull": true,
171
+ "default": "current_timestamp"
172
+ },
173
+ "updated_at": {
174
+ "type": "TIMESTAMP",
175
+ "notNull": true,
176
+ "default": "current_timestamp"
177
+ }
178
+ },
179
+ "indexes": [
180
+ {
181
+ "name": "property_collections_id_idx",
182
+ "columns": [
183
+ "id"
184
+ ]
185
+ },
186
+ {
187
+ "name": "property_collections_slug_context_idx",
188
+ "columns": [
189
+ "slug",
190
+ "context"
191
+ ],
192
+ "unique": true
193
+ }
194
+ ],
195
+ "version": "755c73e0"
196
+ }
197
+ },
198
+ "@happyvertical/smrt-properties:ZoneCollection": {
199
+ "name": "zonecollection",
200
+ "className": "ZoneCollection",
201
+ "qualifiedName": "@happyvertical/smrt-properties:ZoneCollection",
202
+ "collection": "zones",
203
+ "filePath": "/home/runner/_work/smrt/smrt/packages/properties/src/collections/Zones.ts",
204
+ "packageName": "@happyvertical/smrt-properties",
205
+ "fields": {},
206
+ "methods": {
207
+ "findByProperty": {
208
+ "name": "findByProperty",
209
+ "async": true,
210
+ "parameters": [
211
+ {
212
+ "name": "propertyId",
213
+ "type": "string",
214
+ "optional": false
215
+ }
216
+ ],
217
+ "returnType": "Promise<Zone[]>",
218
+ "isStatic": false,
219
+ "isPublic": true
220
+ },
221
+ "findTopLevel": {
222
+ "name": "findTopLevel",
223
+ "async": true,
224
+ "parameters": [
225
+ {
226
+ "name": "propertyId",
227
+ "type": "string",
228
+ "optional": false
229
+ }
230
+ ],
231
+ "returnType": "Promise<Zone[]>",
232
+ "isStatic": false,
233
+ "isPublic": true
234
+ },
235
+ "findChildren": {
236
+ "name": "findChildren",
237
+ "async": true,
238
+ "parameters": [
239
+ {
240
+ "name": "parentId",
241
+ "type": "string",
242
+ "optional": false
243
+ }
244
+ ],
245
+ "returnType": "Promise<Zone[]>",
246
+ "isStatic": false,
247
+ "isPublic": true
248
+ },
249
+ "findByPath": {
250
+ "name": "findByPath",
251
+ "async": true,
252
+ "parameters": [
253
+ {
254
+ "name": "propertyId",
255
+ "type": "string",
256
+ "optional": false
257
+ },
258
+ {
259
+ "name": "path",
260
+ "type": "string",
261
+ "optional": false
262
+ }
263
+ ],
264
+ "returnType": "Promise<Zone[]>",
265
+ "isStatic": false,
266
+ "isPublic": true
267
+ },
268
+ "findByType": {
269
+ "name": "findByType",
270
+ "async": true,
271
+ "parameters": [
272
+ {
273
+ "name": "propertyId",
274
+ "type": "string",
275
+ "optional": false
276
+ },
277
+ {
278
+ "name": "type",
279
+ "type": "string",
280
+ "optional": false
281
+ }
282
+ ],
283
+ "returnType": "Promise<Zone[]>",
284
+ "isStatic": false,
285
+ "isPublic": true
286
+ },
287
+ "getTree": {
288
+ "name": "getTree",
289
+ "async": true,
290
+ "parameters": [
291
+ {
292
+ "name": "propertyId",
293
+ "type": "string",
294
+ "optional": false
295
+ }
296
+ ],
297
+ "returnType": "Promise<ZoneTree<Zone>>",
298
+ "isStatic": false,
299
+ "isPublic": true
300
+ },
301
+ "getAncestors": {
302
+ "name": "getAncestors",
303
+ "async": true,
304
+ "parameters": [
305
+ {
306
+ "name": "zoneId",
307
+ "type": "string",
308
+ "optional": false
309
+ }
310
+ ],
311
+ "returnType": "Promise<Zone[]>",
312
+ "isStatic": false,
313
+ "isPublic": true
314
+ },
315
+ "getDescendants": {
316
+ "name": "getDescendants",
317
+ "async": true,
318
+ "parameters": [
319
+ {
320
+ "name": "zoneId",
321
+ "type": "string",
322
+ "optional": false
323
+ }
324
+ ],
325
+ "returnType": "Promise<Zone[]>",
326
+ "isStatic": false,
327
+ "isPublic": true
328
+ },
329
+ "getMaxDepth": {
330
+ "name": "getMaxDepth",
331
+ "async": true,
332
+ "parameters": [
333
+ {
334
+ "name": "propertyId",
335
+ "type": "string",
336
+ "optional": false
337
+ }
338
+ ],
339
+ "returnType": "Promise<number>",
340
+ "isStatic": false,
341
+ "isPublic": true
342
+ },
343
+ "findByDimensions": {
344
+ "name": "findByDimensions",
345
+ "async": true,
346
+ "parameters": [
347
+ {
348
+ "name": "propertyId",
349
+ "type": "string",
350
+ "optional": false
351
+ },
352
+ {
353
+ "name": "width",
354
+ "type": "number",
355
+ "optional": false
356
+ },
357
+ {
358
+ "name": "height",
359
+ "type": "number",
360
+ "optional": false
361
+ }
362
+ ],
363
+ "returnType": "Promise<Zone[]>",
364
+ "isStatic": false,
365
+ "isPublic": true
366
+ },
367
+ "findByAllowedFormat": {
368
+ "name": "findByAllowedFormat",
369
+ "async": true,
370
+ "parameters": [
371
+ {
372
+ "name": "propertyId",
373
+ "type": "string",
374
+ "optional": false
375
+ },
376
+ {
377
+ "name": "format",
378
+ "type": "string",
379
+ "optional": false
380
+ }
381
+ ],
382
+ "returnType": "Promise<Zone[]>",
383
+ "isStatic": false,
384
+ "isPublic": true
385
+ },
386
+ "moveZone": {
387
+ "name": "moveZone",
388
+ "async": true,
389
+ "parameters": [
390
+ {
391
+ "name": "zoneId",
392
+ "type": "string",
393
+ "optional": false
394
+ },
395
+ {
396
+ "name": "newParentId",
397
+ "type": "string | null",
398
+ "optional": false
399
+ }
400
+ ],
401
+ "returnType": "Promise<Zone | null>",
402
+ "isStatic": false,
403
+ "isPublic": true
404
+ },
405
+ "deleteZone": {
406
+ "name": "deleteZone",
407
+ "async": true,
408
+ "parameters": [
409
+ {
410
+ "name": "zoneId",
411
+ "type": "string",
412
+ "optional": false
413
+ },
414
+ {
415
+ "name": "cascade",
416
+ "type": "boolean",
417
+ "optional": true
418
+ }
419
+ ],
420
+ "returnType": "Promise<number>",
421
+ "isStatic": false,
422
+ "isPublic": true
423
+ },
424
+ "findByTenant": {
425
+ "name": "findByTenant",
426
+ "async": true,
427
+ "parameters": [
428
+ {
429
+ "name": "tenantId",
430
+ "type": "string",
431
+ "optional": false
432
+ }
433
+ ],
434
+ "returnType": "Promise<Zone[]>",
435
+ "isStatic": false,
436
+ "isPublic": true
437
+ },
438
+ "findGlobal": {
439
+ "name": "findGlobal",
440
+ "async": true,
441
+ "parameters": [],
442
+ "returnType": "Promise<Zone[]>",
443
+ "isStatic": false,
444
+ "isPublic": true
445
+ },
446
+ "findWithGlobals": {
447
+ "name": "findWithGlobals",
448
+ "async": true,
449
+ "parameters": [
450
+ {
451
+ "name": "tenantId",
452
+ "type": "string",
453
+ "optional": false
454
+ }
455
+ ],
456
+ "returnType": "Promise<Zone[]>",
457
+ "isStatic": false,
458
+ "isPublic": true
459
+ }
460
+ },
461
+ "decoratorConfig": {},
462
+ "extends": "SmrtCollection",
463
+ "extendsTypeArg": "Zone",
464
+ "exportName": "ZoneCollection",
465
+ "collectionExportName": "ZoneCollectionCollection",
466
+ "schema": {
467
+ "tableName": "zone_collections",
468
+ "ddl": "CREATE TABLE IF NOT EXISTS \"zone_collections\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp\n);",
469
+ "columns": {
470
+ "id": {
471
+ "type": "UUID",
472
+ "primaryKey": true,
473
+ "referenceKind": "id",
474
+ "notNull": true
475
+ },
476
+ "slug": {
477
+ "type": "TEXT",
478
+ "notNull": true
479
+ },
480
+ "context": {
481
+ "type": "TEXT",
482
+ "notNull": true,
483
+ "default": ""
484
+ },
485
+ "created_at": {
486
+ "type": "TIMESTAMP",
487
+ "notNull": true,
488
+ "default": "current_timestamp"
489
+ },
490
+ "updated_at": {
491
+ "type": "TIMESTAMP",
492
+ "notNull": true,
493
+ "default": "current_timestamp"
494
+ }
495
+ },
496
+ "indexes": [
497
+ {
498
+ "name": "zone_collections_id_idx",
499
+ "columns": [
500
+ "id"
501
+ ]
502
+ },
503
+ {
504
+ "name": "zone_collections_slug_context_idx",
505
+ "columns": [
506
+ "slug",
507
+ "context"
508
+ ],
509
+ "unique": true
510
+ }
511
+ ],
512
+ "version": "5bed4522"
513
+ }
514
+ },
515
+ "@happyvertical/smrt-properties:Property": {
516
+ "name": "property",
517
+ "className": "Property",
518
+ "qualifiedName": "@happyvertical/smrt-properties:Property",
519
+ "collection": "properties",
520
+ "filePath": "/home/runner/_work/smrt/smrt/packages/properties/src/models/Property.ts",
521
+ "packageName": "@happyvertical/smrt-properties",
522
+ "fields": {
523
+ "created_at": {
524
+ "type": "datetime",
525
+ "required": false
526
+ },
527
+ "updated_at": {
528
+ "type": "datetime",
529
+ "required": false
530
+ },
531
+ "tenantId": {
532
+ "type": "text",
533
+ "required": false,
534
+ "_meta": {
535
+ "sqlType": "UUID",
536
+ "nullable": true,
537
+ "__tenancy": {
538
+ "isTenantIdField": true,
539
+ "autoFilter": true,
540
+ "required": false,
541
+ "autoPopulate": true,
542
+ "nullable": true,
543
+ "mode": "optional",
544
+ "field": "tenantId",
545
+ "allowSuperAdminBypass": false
546
+ }
547
+ }
548
+ },
549
+ "name": {
550
+ "type": "text",
551
+ "required": false,
552
+ "default": ""
553
+ },
554
+ "domain": {
555
+ "type": "text",
556
+ "required": false,
557
+ "default": ""
558
+ },
559
+ "url": {
560
+ "type": "text",
561
+ "required": false,
562
+ "default": ""
563
+ },
564
+ "description": {
565
+ "type": "text",
566
+ "required": false,
567
+ "default": ""
568
+ },
569
+ "repositoryId": {
570
+ "type": "crossPackageRef",
571
+ "required": false,
572
+ "related": "@happyvertical/smrt-projects:Repository"
573
+ },
574
+ "ownerId": {
575
+ "type": "crossPackageRef",
576
+ "required": false,
577
+ "related": "@happyvertical/smrt-profiles:Profile"
578
+ },
579
+ "status": {
580
+ "type": "text",
581
+ "required": false,
582
+ "default": "active"
583
+ },
584
+ "metadata": {
585
+ "type": "json",
586
+ "required": false,
587
+ "default": {}
588
+ }
589
+ },
590
+ "methods": {
591
+ "getAiUsageSnapshot": {
592
+ "name": "getAiUsageSnapshot",
593
+ "async": false,
594
+ "parameters": [],
595
+ "returnType": "AiUsageSnapshot | undefined",
596
+ "isStatic": false,
597
+ "isPublic": true
598
+ },
599
+ "resetAiUsage": {
600
+ "name": "resetAiUsage",
601
+ "async": false,
602
+ "parameters": [],
603
+ "returnType": "void",
604
+ "isStatic": false,
605
+ "isPublic": true
606
+ },
607
+ "listAiUsage": {
608
+ "name": "listAiUsage",
609
+ "async": true,
610
+ "parameters": [
611
+ {
612
+ "name": "options",
613
+ "type": "AiUsageListOptions",
614
+ "optional": true
615
+ }
616
+ ],
617
+ "returnType": "Promise<SmrtAiUsageRecord[]>",
618
+ "isStatic": false,
619
+ "isPublic": true
620
+ },
621
+ "summarizeAiUsage": {
622
+ "name": "summarizeAiUsage",
623
+ "async": true,
624
+ "parameters": [
625
+ {
626
+ "name": "options",
627
+ "type": "AiUsageSummaryOptions",
628
+ "optional": true
629
+ }
630
+ ],
631
+ "returnType": "Promise<Record<string, AiUsageStats>>",
632
+ "isStatic": false,
633
+ "isPublic": true
634
+ },
635
+ "destroy": {
636
+ "name": "destroy",
637
+ "async": false,
638
+ "parameters": [],
639
+ "returnType": "void",
640
+ "isStatic": false,
641
+ "isPublic": true
642
+ },
643
+ "markAsPersisted": {
644
+ "name": "markAsPersisted",
645
+ "async": false,
646
+ "parameters": [],
647
+ "returnType": "void",
648
+ "isStatic": false,
649
+ "isPublic": true
650
+ },
651
+ "initialize": {
652
+ "name": "initialize",
653
+ "async": true,
654
+ "parameters": [],
655
+ "returnType": "Promise",
656
+ "isStatic": false,
657
+ "isPublic": true
658
+ },
659
+ "loadDataFromDb": {
660
+ "name": "loadDataFromDb",
661
+ "async": true,
662
+ "parameters": [
663
+ {
664
+ "name": "data",
665
+ "type": "any",
666
+ "optional": false
667
+ }
668
+ ],
669
+ "returnType": "any",
670
+ "isStatic": false,
671
+ "isPublic": true
672
+ },
673
+ "getFields": {
674
+ "name": "getFields",
675
+ "async": true,
676
+ "parameters": [],
677
+ "returnType": "any",
678
+ "isStatic": false,
679
+ "isPublic": true
680
+ },
681
+ "toJSON": {
682
+ "name": "toJSON",
683
+ "async": false,
684
+ "parameters": [],
685
+ "returnType": "any",
686
+ "isStatic": false,
687
+ "isPublic": true
688
+ },
689
+ "toPlainObject": {
690
+ "name": "toPlainObject",
691
+ "async": false,
692
+ "parameters": [],
693
+ "returnType": "Record<string>",
694
+ "isStatic": false,
695
+ "isPublic": true
696
+ },
697
+ "toPublicJSON": {
698
+ "name": "toPublicJSON",
699
+ "async": false,
700
+ "parameters": [],
701
+ "returnType": "Record<string>",
702
+ "isStatic": false,
703
+ "isPublic": true
704
+ },
705
+ "getId": {
706
+ "name": "getId",
707
+ "async": true,
708
+ "parameters": [],
709
+ "returnType": "any",
710
+ "isStatic": false,
711
+ "isPublic": true
712
+ },
713
+ "getSlug": {
714
+ "name": "getSlug",
715
+ "async": true,
716
+ "parameters": [],
717
+ "returnType": "any",
718
+ "isStatic": false,
719
+ "isPublic": true
720
+ },
721
+ "getSavedId": {
722
+ "name": "getSavedId",
723
+ "async": true,
724
+ "parameters": [],
725
+ "returnType": "any",
726
+ "isStatic": false,
727
+ "isPublic": true
728
+ },
729
+ "isSaved": {
730
+ "name": "isSaved",
731
+ "async": true,
732
+ "parameters": [],
733
+ "returnType": "any",
734
+ "isStatic": false,
735
+ "isPublic": true
736
+ },
737
+ "save": {
738
+ "name": "save",
739
+ "async": true,
740
+ "parameters": [],
741
+ "returnType": "any",
742
+ "isStatic": false,
743
+ "isPublic": true
744
+ },
745
+ "classifyConstraintError": {
746
+ "name": "classifyConstraintError",
747
+ "async": false,
748
+ "parameters": [
749
+ {
750
+ "name": "message",
751
+ "type": "string",
752
+ "optional": false
753
+ }
754
+ ],
755
+ "returnType": "'unique' | 'not_null' | null",
756
+ "isStatic": true,
757
+ "isPublic": true
758
+ },
759
+ "loadFromId": {
760
+ "name": "loadFromId",
761
+ "async": true,
762
+ "parameters": [],
763
+ "returnType": "any",
764
+ "isStatic": false,
765
+ "isPublic": true
766
+ },
767
+ "loadFromSlug": {
768
+ "name": "loadFromSlug",
769
+ "async": true,
770
+ "parameters": [],
771
+ "returnType": "any",
772
+ "isStatic": false,
773
+ "isPublic": true
774
+ },
775
+ "is": {
776
+ "name": "is",
777
+ "async": true,
778
+ "parameters": [
779
+ {
780
+ "name": "criteria",
781
+ "type": "string",
782
+ "optional": false
783
+ },
784
+ {
785
+ "name": "options",
786
+ "type": "any",
787
+ "optional": true
788
+ }
789
+ ],
790
+ "returnType": "any",
791
+ "isStatic": false,
792
+ "isPublic": true
793
+ },
794
+ "do": {
795
+ "name": "do",
796
+ "async": true,
797
+ "parameters": [
798
+ {
799
+ "name": "instructions",
800
+ "type": "string",
801
+ "optional": false
802
+ },
803
+ {
804
+ "name": "options",
805
+ "type": "any",
806
+ "optional": true
807
+ }
808
+ ],
809
+ "returnType": "any",
810
+ "isStatic": false,
811
+ "isPublic": true
812
+ },
813
+ "describe": {
814
+ "name": "describe",
815
+ "async": true,
816
+ "parameters": [
817
+ {
818
+ "name": "options",
819
+ "type": "any",
820
+ "optional": true
821
+ }
822
+ ],
823
+ "returnType": "any",
824
+ "isStatic": false,
825
+ "isPublic": true
826
+ },
827
+ "delete": {
828
+ "name": "delete",
829
+ "async": true,
830
+ "parameters": [],
831
+ "returnType": "Promise<void>",
832
+ "isStatic": false,
833
+ "isPublic": true
834
+ },
835
+ "isRelatedLoaded": {
836
+ "name": "isRelatedLoaded",
837
+ "async": false,
838
+ "parameters": [
839
+ {
840
+ "name": "fieldName",
841
+ "type": "string",
842
+ "optional": false
843
+ }
844
+ ],
845
+ "returnType": "boolean",
846
+ "isStatic": false,
847
+ "isPublic": true
848
+ },
849
+ "loadRelated": {
850
+ "name": "loadRelated",
851
+ "async": true,
852
+ "parameters": [
853
+ {
854
+ "name": "fieldName",
855
+ "type": "string",
856
+ "optional": false
857
+ },
858
+ {
859
+ "name": "opts",
860
+ "type": "LoadRelatedOptions",
861
+ "optional": true
862
+ }
863
+ ],
864
+ "returnType": "Promise<any>",
865
+ "isStatic": false,
866
+ "isPublic": true
867
+ },
868
+ "loadRelatedMany": {
869
+ "name": "loadRelatedMany",
870
+ "async": true,
871
+ "parameters": [
872
+ {
873
+ "name": "fieldName",
874
+ "type": "string",
875
+ "optional": false
876
+ },
877
+ {
878
+ "name": "opts",
879
+ "type": "LoadRelatedOptions",
880
+ "optional": true
881
+ }
882
+ ],
883
+ "returnType": "Promise<any[]>",
884
+ "isStatic": false,
885
+ "isPublic": true
886
+ },
887
+ "getRelated": {
888
+ "name": "getRelated",
889
+ "async": true,
890
+ "parameters": [
891
+ {
892
+ "name": "fieldName",
893
+ "type": "string",
894
+ "optional": false
895
+ },
896
+ {
897
+ "name": "opts",
898
+ "type": "LoadRelatedOptions",
899
+ "optional": true
900
+ }
901
+ ],
902
+ "returnType": "Promise<any>",
903
+ "isStatic": false,
904
+ "isPublic": true
905
+ },
906
+ "getAvailableTools": {
907
+ "name": "getAvailableTools",
908
+ "async": false,
909
+ "parameters": [],
910
+ "returnType": "AITool[]",
911
+ "isStatic": false,
912
+ "isPublic": true
913
+ },
914
+ "executeToolCall": {
915
+ "name": "executeToolCall",
916
+ "async": true,
917
+ "parameters": [
918
+ {
919
+ "name": "toolCall",
920
+ "type": "ToolCall",
921
+ "optional": false
922
+ }
923
+ ],
924
+ "returnType": "Promise<ToolCallResult>",
925
+ "isStatic": false,
926
+ "isPublic": true
927
+ },
928
+ "remember": {
929
+ "name": "remember",
930
+ "async": true,
931
+ "parameters": [
932
+ {
933
+ "name": "options",
934
+ "type": "object",
935
+ "optional": false
936
+ }
937
+ ],
938
+ "returnType": "Promise<void>",
939
+ "isStatic": false,
940
+ "isPublic": true
941
+ },
942
+ "recall": {
943
+ "name": "recall",
944
+ "async": true,
945
+ "parameters": [
946
+ {
947
+ "name": "options",
948
+ "type": "object",
949
+ "optional": false
950
+ }
951
+ ],
952
+ "returnType": "Promise<any | null>",
953
+ "isStatic": false,
954
+ "isPublic": true
955
+ },
956
+ "recallAll": {
957
+ "name": "recallAll",
958
+ "async": true,
959
+ "parameters": [
960
+ {
961
+ "name": "options",
962
+ "type": "object",
963
+ "optional": true
964
+ }
965
+ ],
966
+ "returnType": "Promise<Map<string, any>>",
967
+ "isStatic": false,
968
+ "isPublic": true
969
+ },
970
+ "forget": {
971
+ "name": "forget",
972
+ "async": true,
973
+ "parameters": [
974
+ {
975
+ "name": "options",
976
+ "type": "object",
977
+ "optional": false
978
+ }
979
+ ],
980
+ "returnType": "Promise<void>",
981
+ "isStatic": false,
982
+ "isPublic": true
983
+ },
984
+ "forgetScope": {
985
+ "name": "forgetScope",
986
+ "async": true,
987
+ "parameters": [
988
+ {
989
+ "name": "options",
990
+ "type": "object",
991
+ "optional": false
992
+ }
993
+ ],
994
+ "returnType": "Promise<number>",
995
+ "isStatic": false,
996
+ "isPublic": true
997
+ },
998
+ "generateEmbeddings": {
999
+ "name": "generateEmbeddings",
1000
+ "async": true,
1001
+ "parameters": [
1002
+ {
1003
+ "name": "options",
1004
+ "type": "GenerateEmbeddingsOptions",
1005
+ "optional": true
1006
+ }
1007
+ ],
1008
+ "returnType": "Promise<void>",
1009
+ "isStatic": false,
1010
+ "isPublic": true
1011
+ },
1012
+ "getEmbedding": {
1013
+ "name": "getEmbedding",
1014
+ "async": true,
1015
+ "parameters": [
1016
+ {
1017
+ "name": "fieldName",
1018
+ "type": "string",
1019
+ "optional": false
1020
+ },
1021
+ {
1022
+ "name": "model",
1023
+ "type": "string",
1024
+ "optional": true
1025
+ }
1026
+ ],
1027
+ "returnType": "Promise<number[] | null>",
1028
+ "isStatic": false,
1029
+ "isPublic": true
1030
+ },
1031
+ "hasStaleEmbeddings": {
1032
+ "name": "hasStaleEmbeddings",
1033
+ "async": true,
1034
+ "parameters": [],
1035
+ "returnType": "Promise<boolean>",
1036
+ "isStatic": false,
1037
+ "isPublic": true
1038
+ },
1039
+ "clearEmbeddings": {
1040
+ "name": "clearEmbeddings",
1041
+ "async": true,
1042
+ "parameters": [],
1043
+ "returnType": "Promise<void>",
1044
+ "isStatic": false,
1045
+ "isPublic": true
1046
+ },
1047
+ "getZones": {
1048
+ "name": "getZones",
1049
+ "async": true,
1050
+ "parameters": [],
1051
+ "returnType": "Promise",
1052
+ "isStatic": false,
1053
+ "isPublic": true
1054
+ },
1055
+ "getZoneTree": {
1056
+ "name": "getZoneTree",
1057
+ "async": true,
1058
+ "parameters": [],
1059
+ "returnType": "Promise",
1060
+ "isStatic": false,
1061
+ "isPublic": true
1062
+ },
1063
+ "createZone": {
1064
+ "name": "createZone",
1065
+ "async": true,
1066
+ "parameters": [
1067
+ {
1068
+ "name": "options",
1069
+ "type": "Omit<'propertyId'>",
1070
+ "optional": false
1071
+ }
1072
+ ],
1073
+ "returnType": "Promise",
1074
+ "isStatic": false,
1075
+ "isPublic": true
1076
+ },
1077
+ "isActive": {
1078
+ "name": "isActive",
1079
+ "async": false,
1080
+ "parameters": [],
1081
+ "returnType": "boolean",
1082
+ "isStatic": false,
1083
+ "isPublic": true
1084
+ },
1085
+ "summarize": {
1086
+ "name": "summarize",
1087
+ "async": true,
1088
+ "parameters": [],
1089
+ "returnType": "Promise<string>",
1090
+ "isStatic": false,
1091
+ "isPublic": true
1092
+ }
1093
+ },
1094
+ "decoratorConfig": {
1095
+ "tableStrategy": "sti",
1096
+ "api": {
1097
+ "include": [
1098
+ "list",
1099
+ "get",
1100
+ "create",
1101
+ "update",
1102
+ "delete"
1103
+ ]
1104
+ },
1105
+ "mcp": {
1106
+ "include": [
1107
+ "list",
1108
+ "get",
1109
+ "create"
1110
+ ]
1111
+ },
1112
+ "cli": true,
1113
+ "tenantScoped": {
1114
+ "mode": "optional"
1115
+ }
1116
+ },
1117
+ "extends": "SmrtObject",
1118
+ "exportName": "Property",
1119
+ "collectionExportName": "PropertyCollection",
1120
+ "schema": {
1121
+ "tableName": "properties",
1122
+ "ddl": "CREATE TABLE IF NOT EXISTS \"properties\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"_meta_type\" TEXT NOT NULL,\n \"_meta_data\" JSON,\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"tenant_id\" UUID,\n \"name\" TEXT DEFAULT '',\n \"domain\" TEXT DEFAULT '',\n \"url\" TEXT DEFAULT '',\n \"description\" TEXT DEFAULT '',\n \"repository_id\" UUID,\n \"owner_id\" UUID,\n \"status\" TEXT DEFAULT 'active',\n \"metadata\" JSON DEFAULT '{}'\n);",
1123
+ "columns": {
1124
+ "id": {
1125
+ "type": "UUID",
1126
+ "primaryKey": true,
1127
+ "referenceKind": "id",
1128
+ "notNull": true
1129
+ },
1130
+ "slug": {
1131
+ "type": "TEXT",
1132
+ "notNull": true
1133
+ },
1134
+ "context": {
1135
+ "type": "TEXT",
1136
+ "notNull": true,
1137
+ "default": ""
1138
+ },
1139
+ "_meta_type": {
1140
+ "type": "TEXT",
1141
+ "notNull": true
1142
+ },
1143
+ "_meta_data": {
1144
+ "type": "JSON",
1145
+ "notNull": false
1146
+ },
1147
+ "created_at": {
1148
+ "type": "TIMESTAMP",
1149
+ "notNull": true,
1150
+ "default": "current_timestamp"
1151
+ },
1152
+ "updated_at": {
1153
+ "type": "TIMESTAMP",
1154
+ "notNull": true,
1155
+ "default": "current_timestamp"
1156
+ },
1157
+ "tenant_id": {
1158
+ "type": "UUID",
1159
+ "referenceKind": "tenantId",
1160
+ "notNull": false
1161
+ },
1162
+ "name": {
1163
+ "type": "TEXT",
1164
+ "notNull": false,
1165
+ "default": ""
1166
+ },
1167
+ "domain": {
1168
+ "type": "TEXT",
1169
+ "notNull": false,
1170
+ "default": ""
1171
+ },
1172
+ "url": {
1173
+ "type": "TEXT",
1174
+ "notNull": false,
1175
+ "default": ""
1176
+ },
1177
+ "description": {
1178
+ "type": "TEXT",
1179
+ "notNull": false,
1180
+ "default": ""
1181
+ },
1182
+ "repository_id": {
1183
+ "type": "UUID",
1184
+ "referenceKind": "crossPackageRef",
1185
+ "notNull": false
1186
+ },
1187
+ "owner_id": {
1188
+ "type": "UUID",
1189
+ "referenceKind": "crossPackageRef",
1190
+ "notNull": false
1191
+ },
1192
+ "status": {
1193
+ "type": "TEXT",
1194
+ "notNull": false,
1195
+ "default": "active"
1196
+ },
1197
+ "metadata": {
1198
+ "type": "JSON",
1199
+ "notNull": false,
1200
+ "default": {}
1201
+ }
1202
+ },
1203
+ "indexes": [
1204
+ {
1205
+ "name": "properties_id_idx",
1206
+ "columns": [
1207
+ "id"
1208
+ ]
1209
+ },
1210
+ {
1211
+ "name": "properties_slug_context_meta_type_idx",
1212
+ "columns": [
1213
+ "slug",
1214
+ "context",
1215
+ "_meta_type"
1216
+ ],
1217
+ "unique": true
1218
+ },
1219
+ {
1220
+ "name": "properties_meta_type_idx",
1221
+ "columns": [
1222
+ "_meta_type"
1223
+ ]
1224
+ }
1225
+ ],
1226
+ "version": "6431d246"
1227
+ }
1228
+ },
1229
+ "@happyvertical/smrt-properties:Zone": {
1230
+ "name": "zone",
1231
+ "className": "Zone",
1232
+ "qualifiedName": "@happyvertical/smrt-properties:Zone",
1233
+ "collection": "zones",
1234
+ "filePath": "/home/runner/_work/smrt/smrt/packages/properties/src/models/Zone.ts",
1235
+ "packageName": "@happyvertical/smrt-properties",
1236
+ "fields": {
1237
+ "parentId": {
1238
+ "type": "foreignKey",
1239
+ "required": false,
1240
+ "related": "Zone",
1241
+ "_meta": {
1242
+ "nullable": true
1243
+ }
1244
+ },
1245
+ "tenantId": {
1246
+ "type": "text",
1247
+ "required": false,
1248
+ "_meta": {
1249
+ "sqlType": "UUID",
1250
+ "nullable": true,
1251
+ "__tenancy": {
1252
+ "isTenantIdField": true,
1253
+ "autoFilter": true,
1254
+ "required": false,
1255
+ "autoPopulate": true,
1256
+ "nullable": true,
1257
+ "mode": "optional",
1258
+ "field": "tenantId",
1259
+ "allowSuperAdminBypass": false
1260
+ }
1261
+ }
1262
+ },
1263
+ "propertyId": {
1264
+ "type": "foreignKey",
1265
+ "required": false,
1266
+ "related": "Property"
1267
+ },
1268
+ "name": {
1269
+ "type": "text",
1270
+ "required": false,
1271
+ "default": ""
1272
+ },
1273
+ "type": {
1274
+ "type": "text",
1275
+ "required": false,
1276
+ "default": ""
1277
+ },
1278
+ "path": {
1279
+ "type": "text",
1280
+ "required": false,
1281
+ "default": ""
1282
+ },
1283
+ "selector": {
1284
+ "type": "text",
1285
+ "required": false,
1286
+ "default": ""
1287
+ },
1288
+ "position": {
1289
+ "type": "text",
1290
+ "required": false,
1291
+ "default": ""
1292
+ },
1293
+ "width": {
1294
+ "type": "integer",
1295
+ "required": false
1296
+ },
1297
+ "height": {
1298
+ "type": "integer",
1299
+ "required": false
1300
+ },
1301
+ "allowedFormats": {
1302
+ "type": "json",
1303
+ "required": false,
1304
+ "default": []
1305
+ },
1306
+ "defaultContentId": {
1307
+ "type": "text",
1308
+ "required": false
1309
+ },
1310
+ "metadata": {
1311
+ "type": "json",
1312
+ "required": false,
1313
+ "default": {}
1314
+ }
1315
+ },
1316
+ "methods": {
1317
+ "getParent": {
1318
+ "name": "getParent",
1319
+ "async": true,
1320
+ "parameters": [],
1321
+ "returnType": "Promise<null>",
1322
+ "isStatic": false,
1323
+ "isPublic": true
1324
+ },
1325
+ "getChildren": {
1326
+ "name": "getChildren",
1327
+ "async": true,
1328
+ "parameters": [],
1329
+ "returnType": "Promise",
1330
+ "isStatic": false,
1331
+ "isPublic": true
1332
+ },
1333
+ "getAncestors": {
1334
+ "name": "getAncestors",
1335
+ "async": true,
1336
+ "parameters": [],
1337
+ "returnType": "Promise",
1338
+ "isStatic": false,
1339
+ "isPublic": true
1340
+ },
1341
+ "getDescendants": {
1342
+ "name": "getDescendants",
1343
+ "async": true,
1344
+ "parameters": [],
1345
+ "returnType": "Promise",
1346
+ "isStatic": false,
1347
+ "isPublic": true
1348
+ },
1349
+ "getHierarchy": {
1350
+ "name": "getHierarchy",
1351
+ "async": true,
1352
+ "parameters": [],
1353
+ "returnType": "Promise<HierarchyView>",
1354
+ "isStatic": false,
1355
+ "isPublic": true
1356
+ },
1357
+ "moveTo": {
1358
+ "name": "moveTo",
1359
+ "async": true,
1360
+ "parameters": [
1361
+ {
1362
+ "name": "newParent",
1363
+ "type": "string | null",
1364
+ "optional": false
1365
+ }
1366
+ ],
1367
+ "returnType": "Promise<void>",
1368
+ "isStatic": false,
1369
+ "isPublic": true
1370
+ },
1371
+ "isTopLevel": {
1372
+ "name": "isTopLevel",
1373
+ "async": false,
1374
+ "parameters": [],
1375
+ "returnType": "boolean",
1376
+ "isStatic": false,
1377
+ "isPublic": true
1378
+ },
1379
+ "hasDimensions": {
1380
+ "name": "hasDimensions",
1381
+ "async": false,
1382
+ "parameters": [],
1383
+ "returnType": "boolean",
1384
+ "isStatic": false,
1385
+ "isPublic": true
1386
+ },
1387
+ "getDimensionString": {
1388
+ "name": "getDimensionString",
1389
+ "async": false,
1390
+ "parameters": [],
1391
+ "returnType": "string | null",
1392
+ "isStatic": false,
1393
+ "isPublic": true
1394
+ },
1395
+ "getProperty": {
1396
+ "name": "getProperty",
1397
+ "async": true,
1398
+ "parameters": [],
1399
+ "returnType": "Promise<null>",
1400
+ "isStatic": false,
1401
+ "isPublic": true
1402
+ },
1403
+ "getFullPath": {
1404
+ "name": "getFullPath",
1405
+ "async": true,
1406
+ "parameters": [],
1407
+ "returnType": "Promise<string>",
1408
+ "isStatic": false,
1409
+ "isPublic": true
1410
+ },
1411
+ "getDepth": {
1412
+ "name": "getDepth",
1413
+ "async": true,
1414
+ "parameters": [],
1415
+ "returnType": "Promise<number>",
1416
+ "isStatic": false,
1417
+ "isPublic": true
1418
+ },
1419
+ "createChild": {
1420
+ "name": "createChild",
1421
+ "async": true,
1422
+ "parameters": [
1423
+ {
1424
+ "name": "options",
1425
+ "type": "Omit<ZoneOptions, 'propertyId' | 'parentId'>",
1426
+ "optional": false
1427
+ }
1428
+ ],
1429
+ "returnType": "Promise<Zone>",
1430
+ "isStatic": false,
1431
+ "isPublic": true
1432
+ },
1433
+ "toTreeNode": {
1434
+ "name": "toTreeNode",
1435
+ "async": true,
1436
+ "parameters": [],
1437
+ "returnType": "Promise<ZoneTreeNode<Zone>>",
1438
+ "isStatic": false,
1439
+ "isPublic": true
1440
+ },
1441
+ "isFormatAllowed": {
1442
+ "name": "isFormatAllowed",
1443
+ "async": false,
1444
+ "parameters": [
1445
+ {
1446
+ "name": "format",
1447
+ "type": "string",
1448
+ "optional": false
1449
+ }
1450
+ ],
1451
+ "returnType": "boolean",
1452
+ "isStatic": false,
1453
+ "isPublic": true
1454
+ }
1455
+ },
1456
+ "decoratorConfig": {
1457
+ "api": {
1458
+ "include": [
1459
+ "list",
1460
+ "get",
1461
+ "create",
1462
+ "update",
1463
+ "delete"
1464
+ ]
1465
+ },
1466
+ "mcp": {
1467
+ "include": [
1468
+ "list",
1469
+ "get",
1470
+ "create"
1471
+ ]
1472
+ },
1473
+ "cli": true,
1474
+ "tenantScoped": {
1475
+ "mode": "optional"
1476
+ }
1477
+ },
1478
+ "extends": "SmrtHierarchical",
1479
+ "exportName": "Zone",
1480
+ "collectionExportName": "ZoneCollection",
1481
+ "schema": {
1482
+ "tableName": "zones",
1483
+ "ddl": "CREATE TABLE IF NOT EXISTS \"zones\" (\n \"id\" UUID PRIMARY KEY NOT NULL,\n \"slug\" TEXT NOT NULL,\n \"context\" TEXT NOT NULL DEFAULT '',\n \"created_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"updated_at\" TIMESTAMP NOT NULL DEFAULT current_timestamp,\n \"parent_id\" UUID,\n \"tenant_id\" UUID,\n \"property_id\" UUID,\n \"name\" TEXT DEFAULT '',\n \"type\" TEXT DEFAULT '',\n \"path\" TEXT DEFAULT '',\n \"selector\" TEXT DEFAULT '',\n \"position\" TEXT DEFAULT '',\n \"width\" INTEGER,\n \"height\" INTEGER,\n \"allowed_formats\" JSON DEFAULT '[]',\n \"default_content_id\" TEXT,\n \"metadata\" JSON DEFAULT '{}'\n);",
1484
+ "columns": {
1485
+ "id": {
1486
+ "type": "UUID",
1487
+ "primaryKey": true,
1488
+ "referenceKind": "id",
1489
+ "notNull": true
1490
+ },
1491
+ "slug": {
1492
+ "type": "TEXT",
1493
+ "notNull": true
1494
+ },
1495
+ "context": {
1496
+ "type": "TEXT",
1497
+ "notNull": true,
1498
+ "default": ""
1499
+ },
1500
+ "created_at": {
1501
+ "type": "TIMESTAMP",
1502
+ "notNull": true,
1503
+ "default": "current_timestamp"
1504
+ },
1505
+ "updated_at": {
1506
+ "type": "TIMESTAMP",
1507
+ "notNull": true,
1508
+ "default": "current_timestamp"
1509
+ },
1510
+ "parent_id": {
1511
+ "type": "UUID",
1512
+ "referenceKind": "foreignKey",
1513
+ "notNull": false,
1514
+ "unique": false
1515
+ },
1516
+ "tenant_id": {
1517
+ "type": "UUID",
1518
+ "referenceKind": "tenantId",
1519
+ "notNull": false,
1520
+ "unique": false
1521
+ },
1522
+ "property_id": {
1523
+ "type": "UUID",
1524
+ "referenceKind": "foreignKey",
1525
+ "notNull": false,
1526
+ "unique": false
1527
+ },
1528
+ "name": {
1529
+ "type": "TEXT",
1530
+ "notNull": false,
1531
+ "unique": false,
1532
+ "default": ""
1533
+ },
1534
+ "type": {
1535
+ "type": "TEXT",
1536
+ "notNull": false,
1537
+ "unique": false,
1538
+ "default": ""
1539
+ },
1540
+ "path": {
1541
+ "type": "TEXT",
1542
+ "notNull": false,
1543
+ "unique": false,
1544
+ "default": ""
1545
+ },
1546
+ "selector": {
1547
+ "type": "TEXT",
1548
+ "notNull": false,
1549
+ "unique": false,
1550
+ "default": ""
1551
+ },
1552
+ "position": {
1553
+ "type": "TEXT",
1554
+ "notNull": false,
1555
+ "unique": false,
1556
+ "default": ""
1557
+ },
1558
+ "width": {
1559
+ "type": "INTEGER",
1560
+ "notNull": false,
1561
+ "unique": false
1562
+ },
1563
+ "height": {
1564
+ "type": "INTEGER",
1565
+ "notNull": false,
1566
+ "unique": false
1567
+ },
1568
+ "allowed_formats": {
1569
+ "type": "JSON",
1570
+ "notNull": false,
1571
+ "unique": false,
1572
+ "default": []
1573
+ },
1574
+ "default_content_id": {
1575
+ "type": "TEXT",
1576
+ "notNull": false,
1577
+ "unique": false
1578
+ },
1579
+ "metadata": {
1580
+ "type": "JSON",
1581
+ "notNull": false,
1582
+ "unique": false,
1583
+ "default": {}
1584
+ }
1585
+ },
1586
+ "indexes": [
1587
+ {
1588
+ "name": "zones_id_idx",
1589
+ "columns": [
1590
+ "id"
1591
+ ]
1592
+ },
1593
+ {
1594
+ "name": "zones_slug_context_idx",
1595
+ "columns": [
1596
+ "slug",
1597
+ "context"
1598
+ ],
1599
+ "unique": true
1600
+ }
1601
+ ],
1602
+ "version": "53529202"
1603
+ }
1604
+ }
1605
+ },
1606
+ "moduleType": "smrt",
1607
+ "smrtDependencies": [
1608
+ "@happyvertical/smrt-core",
1609
+ "@happyvertical/smrt-prompts",
1610
+ "@happyvertical/smrt-tenancy"
1611
+ ]
1612
+ }