@open-mercato/core 0.6.1-develop.3291.1.6fad645fd0 → 0.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (122) hide show
  1. package/.turbo/turbo-build.log +1 -1
  2. package/AGENTS.md +14 -0
  3. package/dist/modules/auth/backend/roles/[id]/edit/page.js +2 -1
  4. package/dist/modules/auth/backend/roles/[id]/edit/page.js.map +2 -2
  5. package/dist/modules/auth/backend/users/[id]/edit/page.js +2 -5
  6. package/dist/modules/auth/backend/users/[id]/edit/page.js.map +2 -2
  7. package/dist/modules/catalog/ai-agents.js +47 -5
  8. package/dist/modules/catalog/ai-agents.js.map +2 -2
  9. package/dist/modules/catalog/backend/catalog/categories/[id]/edit/page.js +2 -5
  10. package/dist/modules/catalog/backend/catalog/categories/[id]/edit/page.js.map +2 -2
  11. package/dist/modules/catalog/backend/catalog/products/MerchandisingAssistantSheet.js +4 -3
  12. package/dist/modules/catalog/backend/catalog/products/MerchandisingAssistantSheet.js.map +2 -2
  13. package/dist/modules/catalog/backend/catalog/products/[id]/page.js +2 -9
  14. package/dist/modules/catalog/backend/catalog/products/[id]/page.js.map +2 -2
  15. package/dist/modules/catalog/backend/catalog/products/[productId]/variants/[variantId]/page.js +2 -9
  16. package/dist/modules/catalog/backend/catalog/products/[productId]/variants/[variantId]/page.js.map +2 -2
  17. package/dist/modules/customers/ai-agents.js +174 -1
  18. package/dist/modules/customers/ai-agents.js.map +2 -2
  19. package/dist/modules/customers/ai-tools/deal-analyzer-pack.js +196 -0
  20. package/dist/modules/customers/ai-tools/deal-analyzer-pack.js.map +7 -0
  21. package/dist/modules/customers/ai-tools.js +3 -1
  22. package/dist/modules/customers/ai-tools.js.map +2 -2
  23. package/dist/modules/customers/backend/customers/companies/page.js +11 -1
  24. package/dist/modules/customers/backend/customers/companies/page.js.map +2 -2
  25. package/dist/modules/customers/backend/customers/deals/page.js +11 -1
  26. package/dist/modules/customers/backend/customers/deals/page.js.map +2 -2
  27. package/dist/modules/customers/backend/customers/people/page.js +11 -1
  28. package/dist/modules/customers/backend/customers/people/page.js.map +2 -2
  29. package/dist/modules/customers/commands/companies.js +37 -15
  30. package/dist/modules/customers/commands/companies.js.map +2 -2
  31. package/dist/modules/customers/components/detail/AiActionChips.js +2 -2
  32. package/dist/modules/customers/components/detail/AiActionChips.js.map +2 -2
  33. package/dist/modules/customers/components/detail/ChangelogTab.js +3 -9
  34. package/dist/modules/customers/components/detail/ChangelogTab.js.map +2 -2
  35. package/dist/modules/customers/components/detail/changelogValues.js +35 -0
  36. package/dist/modules/customers/components/detail/changelogValues.js.map +7 -0
  37. package/dist/modules/customers/components/detail/customFieldUtils.js +1 -1
  38. package/dist/modules/customers/components/detail/customFieldUtils.js.map +1 -1
  39. package/dist/modules/customers/components/formConfig.js +3 -2
  40. package/dist/modules/customers/components/formConfig.js.map +2 -2
  41. package/dist/modules/customers/widgets/injection/ai-assistant-trigger/widget.client.js +4 -9
  42. package/dist/modules/customers/widgets/injection/ai-assistant-trigger/widget.client.js.map +2 -2
  43. package/dist/modules/customers/widgets/injection/ai-deal-analyzer-trigger/widget.client.js +302 -0
  44. package/dist/modules/customers/widgets/injection/ai-deal-analyzer-trigger/widget.client.js.map +7 -0
  45. package/dist/modules/customers/widgets/injection/ai-deal-analyzer-trigger/widget.js +17 -0
  46. package/dist/modules/customers/widgets/injection/ai-deal-analyzer-trigger/widget.js.map +7 -0
  47. package/dist/modules/customers/widgets/injection/ai-deal-detail-trigger/widget.client.js +2 -2
  48. package/dist/modules/customers/widgets/injection/ai-deal-detail-trigger/widget.client.js.map +2 -2
  49. package/dist/modules/customers/widgets/injection-table.js +2 -2
  50. package/dist/modules/customers/widgets/injection-table.js.map +2 -2
  51. package/dist/modules/directory/backend/directory/organizations/[id]/edit/page.js +2 -5
  52. package/dist/modules/directory/backend/directory/organizations/[id]/edit/page.js.map +2 -2
  53. package/dist/modules/directory/backend/directory/tenants/[id]/edit/page.js +2 -5
  54. package/dist/modules/directory/backend/directory/tenants/[id]/edit/page.js.map +2 -2
  55. package/dist/modules/resources/backend/resources/resources/[id]/page.js +2 -5
  56. package/dist/modules/resources/backend/resources/resources/[id]/page.js.map +2 -2
  57. package/dist/modules/sales/backend/sales/channels/[channelId]/edit/page.js +2 -25
  58. package/dist/modules/sales/backend/sales/channels/[channelId]/edit/page.js.map +2 -2
  59. package/dist/modules/sales/components/channels/ChannelOfferForm.js +2 -43
  60. package/dist/modules/sales/components/channels/ChannelOfferForm.js.map +2 -2
  61. package/dist/modules/sales/components/documents/LineItemDialog.js +162 -42
  62. package/dist/modules/sales/components/documents/LineItemDialog.js.map +2 -2
  63. package/dist/modules/sales/components/documents/customFieldHelpers.js +4 -31
  64. package/dist/modules/sales/components/documents/customFieldHelpers.js.map +2 -2
  65. package/package.json +16 -8
  66. package/src/modules/auth/backend/roles/[id]/edit/page.tsx +2 -1
  67. package/src/modules/auth/backend/users/[id]/edit/page.tsx +2 -5
  68. package/src/modules/business_rules/migrations/.snapshot-open-mercato.json +746 -394
  69. package/src/modules/catalog/ai-agents.ts +62 -4
  70. package/src/modules/catalog/backend/catalog/categories/[id]/edit/page.tsx +2 -5
  71. package/src/modules/catalog/backend/catalog/products/MerchandisingAssistantSheet.tsx +4 -3
  72. package/src/modules/catalog/backend/catalog/products/[id]/page.tsx +2 -12
  73. package/src/modules/catalog/backend/catalog/products/[productId]/variants/[variantId]/page.tsx +2 -10
  74. package/src/modules/catalog/migrations/.snapshot-open-mercato.json +2519 -1307
  75. package/src/modules/customer_accounts/migrations/.snapshot-open-mercato.json +828 -834
  76. package/src/modules/customers/AGENTS.md +6 -1
  77. package/src/modules/customers/ai-agents.ts +213 -6
  78. package/src/modules/customers/ai-tools/deal-analyzer-pack.ts +286 -0
  79. package/src/modules/customers/ai-tools.ts +2 -0
  80. package/src/modules/customers/backend/customers/companies/page.tsx +10 -0
  81. package/src/modules/customers/backend/customers/deals/page.tsx +10 -0
  82. package/src/modules/customers/backend/customers/people/page.tsx +10 -0
  83. package/src/modules/customers/commands/companies.ts +38 -14
  84. package/src/modules/customers/components/detail/AiActionChips.tsx +2 -2
  85. package/src/modules/customers/components/detail/ChangelogTab.tsx +3 -10
  86. package/src/modules/customers/components/detail/changelogValues.ts +42 -0
  87. package/src/modules/customers/components/detail/customFieldUtils.ts +1 -1
  88. package/src/modules/customers/components/formConfig.tsx +3 -2
  89. package/src/modules/customers/i18n/de.json +7 -0
  90. package/src/modules/customers/i18n/en.json +7 -0
  91. package/src/modules/customers/i18n/es.json +7 -0
  92. package/src/modules/customers/i18n/pl.json +7 -0
  93. package/src/modules/customers/migrations/.snapshot-open-mercato.json +2313 -2336
  94. package/src/modules/customers/widgets/injection/ai-assistant-trigger/widget.client.tsx +4 -6
  95. package/src/modules/customers/widgets/injection/ai-deal-analyzer-trigger/widget.client.tsx +358 -0
  96. package/src/modules/customers/widgets/injection/ai-deal-analyzer-trigger/widget.ts +34 -0
  97. package/src/modules/customers/widgets/injection/ai-deal-detail-trigger/widget.client.tsx +2 -2
  98. package/src/modules/customers/widgets/injection-table.ts +12 -9
  99. package/src/modules/data_sync/migrations/.snapshot-open-mercato.json +554 -210
  100. package/src/modules/dictionaries/migrations/.snapshot-open-mercato.json +146 -146
  101. package/src/modules/directory/backend/directory/organizations/[id]/edit/page.tsx +2 -5
  102. package/src/modules/directory/backend/directory/tenants/[id]/edit/page.tsx +2 -5
  103. package/src/modules/directory/migrations/.snapshot-open-mercato.json +273 -140
  104. package/src/modules/feature_toggles/migrations/.snapshot-open-mercato.json +242 -137
  105. package/src/modules/integrations/migrations/.snapshot-open-mercato.json +498 -195
  106. package/src/modules/payment_gateways/migrations/.snapshot-open-mercato.json +158 -157
  107. package/src/modules/perspectives/migrations/.snapshot-open-mercato.json +274 -129
  108. package/src/modules/planner/migrations/.snapshot-open-mercato.json +327 -157
  109. package/src/modules/progress/AGENTS.md +72 -0
  110. package/src/modules/resources/backend/resources/resources/[id]/page.tsx +2 -5
  111. package/src/modules/resources/migrations/.snapshot-open-mercato.json +920 -470
  112. package/src/modules/sales/backend/sales/channels/[channelId]/edit/page.tsx +2 -27
  113. package/src/modules/sales/components/channels/ChannelOfferForm.tsx +2 -49
  114. package/src/modules/sales/components/documents/LineItemDialog.tsx +214 -78
  115. package/src/modules/sales/components/documents/customFieldHelpers.ts +4 -43
  116. package/src/modules/sales/i18n/de.json +3 -0
  117. package/src/modules/sales/i18n/en.json +3 -0
  118. package/src/modules/sales/i18n/es.json +3 -0
  119. package/src/modules/sales/i18n/pl.json +3 -0
  120. package/src/modules/sales/migrations/.snapshot-open-mercato.json +4740 -4778
  121. package/src/modules/shipping_carriers/migrations/.snapshot-open-mercato.json +340 -81
  122. package/src/modules/staff/migrations/.snapshot-open-mercato.json +1439 -729
@@ -1,19 +1,75 @@
1
1
  {
2
+ "name": "public",
2
3
  "namespaces": [
3
4
  "public"
4
5
  ],
5
- "name": "public",
6
6
  "tables": [
7
7
  {
8
+ "name": "integration_credentials",
9
+ "schema": "public",
8
10
  "columns": {
11
+ "created_at": {
12
+ "name": "created_at",
13
+ "type": "timestamptz(6)",
14
+ "unsigned": false,
15
+ "autoincrement": false,
16
+ "primary": false,
17
+ "nullable": false,
18
+ "unique": false,
19
+ "length": 6,
20
+ "precision": null,
21
+ "scale": null,
22
+ "default": null,
23
+ "comment": null,
24
+ "enumItems": [],
25
+ "mappedType": "datetime"
26
+ },
27
+ "credentials": {
28
+ "name": "credentials",
29
+ "type": "jsonb",
30
+ "unsigned": false,
31
+ "autoincrement": false,
32
+ "primary": false,
33
+ "nullable": false,
34
+ "unique": false,
35
+ "length": null,
36
+ "precision": null,
37
+ "scale": null,
38
+ "default": null,
39
+ "comment": null,
40
+ "enumItems": [],
41
+ "mappedType": "json"
42
+ },
43
+ "deleted_at": {
44
+ "name": "deleted_at",
45
+ "type": "timestamptz(6)",
46
+ "unsigned": false,
47
+ "autoincrement": false,
48
+ "primary": false,
49
+ "nullable": true,
50
+ "unique": false,
51
+ "length": 6,
52
+ "precision": null,
53
+ "scale": null,
54
+ "default": null,
55
+ "comment": null,
56
+ "enumItems": [],
57
+ "mappedType": "datetime"
58
+ },
9
59
  "id": {
10
60
  "name": "id",
11
61
  "type": "uuid",
12
62
  "unsigned": false,
13
63
  "autoincrement": false,
14
- "primary": false,
64
+ "primary": true,
15
65
  "nullable": false,
66
+ "unique": false,
67
+ "length": null,
68
+ "precision": null,
69
+ "scale": null,
16
70
  "default": "gen_random_uuid()",
71
+ "comment": null,
72
+ "enumItems": [],
17
73
  "mappedType": "uuid"
18
74
  },
19
75
  "integration_id": {
@@ -23,17 +79,15 @@
23
79
  "autoincrement": false,
24
80
  "primary": false,
25
81
  "nullable": false,
82
+ "unique": false,
83
+ "length": null,
84
+ "precision": null,
85
+ "scale": null,
86
+ "default": null,
87
+ "comment": null,
88
+ "enumItems": [],
26
89
  "mappedType": "text"
27
90
  },
28
- "credentials": {
29
- "name": "credentials",
30
- "type": "jsonb",
31
- "unsigned": false,
32
- "autoincrement": false,
33
- "primary": false,
34
- "nullable": false,
35
- "mappedType": "json"
36
- },
37
91
  "organization_id": {
38
92
  "name": "organization_id",
39
93
  "type": "uuid",
@@ -41,6 +95,13 @@
41
95
  "autoincrement": false,
42
96
  "primary": false,
43
97
  "nullable": false,
98
+ "unique": false,
99
+ "length": null,
100
+ "precision": null,
101
+ "scale": null,
102
+ "default": null,
103
+ "comment": null,
104
+ "enumItems": [],
44
105
  "mappedType": "uuid"
45
106
  },
46
107
  "tenant_id": {
@@ -50,44 +111,34 @@
50
111
  "autoincrement": false,
51
112
  "primary": false,
52
113
  "nullable": false,
114
+ "unique": false,
115
+ "length": null,
116
+ "precision": null,
117
+ "scale": null,
118
+ "default": null,
119
+ "comment": null,
120
+ "enumItems": [],
53
121
  "mappedType": "uuid"
54
122
  },
55
- "created_at": {
56
- "name": "created_at",
57
- "type": "timestamptz",
58
- "unsigned": false,
59
- "autoincrement": false,
60
- "primary": false,
61
- "nullable": false,
62
- "length": 6,
63
- "mappedType": "datetime"
64
- },
65
123
  "updated_at": {
66
124
  "name": "updated_at",
67
- "type": "timestamptz",
125
+ "type": "timestamptz(6)",
68
126
  "unsigned": false,
69
127
  "autoincrement": false,
70
128
  "primary": false,
71
129
  "nullable": false,
130
+ "unique": false,
72
131
  "length": 6,
73
- "mappedType": "datetime"
74
- },
75
- "deleted_at": {
76
- "name": "deleted_at",
77
- "type": "timestamptz",
78
- "unsigned": false,
79
- "autoincrement": false,
80
- "primary": false,
81
- "nullable": true,
82
- "length": 6,
132
+ "precision": null,
133
+ "scale": null,
134
+ "default": null,
135
+ "comment": null,
136
+ "enumItems": [],
83
137
  "mappedType": "datetime"
84
138
  }
85
139
  },
86
- "name": "integration_credentials",
87
- "schema": "public",
88
140
  "indexes": [
89
141
  {
90
- "keyName": "integration_credentials_integration_id_organizatio_291ea_index",
91
142
  "columnNames": [
92
143
  "integration_id",
93
144
  "organization_id",
@@ -95,72 +146,93 @@
95
146
  ],
96
147
  "composite": true,
97
148
  "constraint": false,
149
+ "keyName": "integration_credentials_integration_id_organizatio_58963_index",
98
150
  "primary": false,
99
151
  "unique": false
100
152
  },
101
153
  {
102
- "keyName": "integration_credentials_pkey",
103
154
  "columnNames": [
104
155
  "id"
105
156
  ],
106
157
  "composite": false,
107
158
  "constraint": true,
159
+ "keyName": "integration_credentials_pkey",
108
160
  "primary": true,
109
161
  "unique": true
110
162
  }
111
163
  ],
112
164
  "checks": [],
113
165
  "foreignKeys": {},
114
- "nativeEnums": {}
166
+ "comment": null
115
167
  },
116
168
  {
169
+ "name": "integration_logs",
170
+ "schema": "public",
117
171
  "columns": {
118
- "id": {
119
- "name": "id",
120
- "type": "uuid",
172
+ "code": {
173
+ "name": "code",
174
+ "type": "text",
121
175
  "unsigned": false,
122
176
  "autoincrement": false,
123
177
  "primary": false,
124
- "nullable": false,
125
- "default": "gen_random_uuid()",
126
- "mappedType": "uuid"
178
+ "nullable": true,
179
+ "unique": false,
180
+ "length": null,
181
+ "precision": null,
182
+ "scale": null,
183
+ "default": null,
184
+ "comment": null,
185
+ "enumItems": [],
186
+ "mappedType": "text"
127
187
  },
128
- "integration_id": {
129
- "name": "integration_id",
130
- "type": "text",
188
+ "created_at": {
189
+ "name": "created_at",
190
+ "type": "timestamptz(6)",
131
191
  "unsigned": false,
132
192
  "autoincrement": false,
133
193
  "primary": false,
134
194
  "nullable": false,
135
- "mappedType": "text"
195
+ "unique": false,
196
+ "length": 6,
197
+ "precision": null,
198
+ "scale": null,
199
+ "default": null,
200
+ "comment": null,
201
+ "enumItems": [],
202
+ "mappedType": "datetime"
136
203
  },
137
- "run_id": {
138
- "name": "run_id",
204
+ "id": {
205
+ "name": "id",
139
206
  "type": "uuid",
140
207
  "unsigned": false,
141
208
  "autoincrement": false,
142
- "primary": false,
143
- "nullable": true,
209
+ "primary": true,
210
+ "nullable": false,
211
+ "unique": false,
212
+ "length": null,
213
+ "precision": null,
214
+ "scale": null,
215
+ "default": "gen_random_uuid()",
216
+ "comment": null,
217
+ "enumItems": [],
144
218
  "mappedType": "uuid"
145
219
  },
146
- "scope_entity_type": {
147
- "name": "scope_entity_type",
220
+ "integration_id": {
221
+ "name": "integration_id",
148
222
  "type": "text",
149
223
  "unsigned": false,
150
224
  "autoincrement": false,
151
225
  "primary": false,
152
- "nullable": true,
226
+ "nullable": false,
227
+ "unique": false,
228
+ "length": null,
229
+ "precision": null,
230
+ "scale": null,
231
+ "default": null,
232
+ "comment": null,
233
+ "enumItems": [],
153
234
  "mappedType": "text"
154
235
  },
155
- "scope_entity_id": {
156
- "name": "scope_entity_id",
157
- "type": "uuid",
158
- "unsigned": false,
159
- "autoincrement": false,
160
- "primary": false,
161
- "nullable": true,
162
- "mappedType": "uuid"
163
- },
164
236
  "level": {
165
237
  "name": "level",
166
238
  "type": "text",
@@ -168,6 +240,13 @@
168
240
  "autoincrement": false,
169
241
  "primary": false,
170
242
  "nullable": false,
243
+ "unique": false,
244
+ "length": null,
245
+ "precision": null,
246
+ "scale": null,
247
+ "default": null,
248
+ "comment": null,
249
+ "enumItems": [],
171
250
  "mappedType": "text"
172
251
  },
173
252
  "message": {
@@ -177,16 +256,30 @@
177
256
  "autoincrement": false,
178
257
  "primary": false,
179
258
  "nullable": false,
259
+ "unique": false,
260
+ "length": null,
261
+ "precision": null,
262
+ "scale": null,
263
+ "default": null,
264
+ "comment": null,
265
+ "enumItems": [],
180
266
  "mappedType": "text"
181
267
  },
182
- "code": {
183
- "name": "code",
184
- "type": "text",
268
+ "organization_id": {
269
+ "name": "organization_id",
270
+ "type": "uuid",
185
271
  "unsigned": false,
186
272
  "autoincrement": false,
187
273
  "primary": false,
188
- "nullable": true,
189
- "mappedType": "text"
274
+ "nullable": false,
275
+ "unique": false,
276
+ "length": null,
277
+ "precision": null,
278
+ "scale": null,
279
+ "default": null,
280
+ "comment": null,
281
+ "enumItems": [],
282
+ "mappedType": "uuid"
190
283
  },
191
284
  "payload": {
192
285
  "name": "payload",
@@ -195,148 +288,252 @@
195
288
  "autoincrement": false,
196
289
  "primary": false,
197
290
  "nullable": true,
291
+ "unique": false,
292
+ "length": null,
293
+ "precision": null,
294
+ "scale": null,
295
+ "default": null,
296
+ "comment": null,
297
+ "enumItems": [],
198
298
  "mappedType": "json"
199
299
  },
200
- "organization_id": {
201
- "name": "organization_id",
300
+ "run_id": {
301
+ "name": "run_id",
202
302
  "type": "uuid",
203
303
  "unsigned": false,
204
304
  "autoincrement": false,
205
305
  "primary": false,
206
- "nullable": false,
306
+ "nullable": true,
307
+ "unique": false,
308
+ "length": null,
309
+ "precision": null,
310
+ "scale": null,
311
+ "default": null,
312
+ "comment": null,
313
+ "enumItems": [],
207
314
  "mappedType": "uuid"
208
315
  },
209
- "tenant_id": {
210
- "name": "tenant_id",
316
+ "scope_entity_id": {
317
+ "name": "scope_entity_id",
211
318
  "type": "uuid",
212
319
  "unsigned": false,
213
320
  "autoincrement": false,
214
321
  "primary": false,
215
- "nullable": false,
322
+ "nullable": true,
323
+ "unique": false,
324
+ "length": null,
325
+ "precision": null,
326
+ "scale": null,
327
+ "default": null,
328
+ "comment": null,
329
+ "enumItems": [],
216
330
  "mappedType": "uuid"
217
331
  },
218
- "created_at": {
219
- "name": "created_at",
220
- "type": "timestamptz",
332
+ "scope_entity_type": {
333
+ "name": "scope_entity_type",
334
+ "type": "text",
335
+ "unsigned": false,
336
+ "autoincrement": false,
337
+ "primary": false,
338
+ "nullable": true,
339
+ "unique": false,
340
+ "length": null,
341
+ "precision": null,
342
+ "scale": null,
343
+ "default": null,
344
+ "comment": null,
345
+ "enumItems": [],
346
+ "mappedType": "text"
347
+ },
348
+ "tenant_id": {
349
+ "name": "tenant_id",
350
+ "type": "uuid",
221
351
  "unsigned": false,
222
352
  "autoincrement": false,
223
353
  "primary": false,
224
354
  "nullable": false,
225
- "length": 6,
226
- "mappedType": "datetime"
355
+ "unique": false,
356
+ "length": null,
357
+ "precision": null,
358
+ "scale": null,
359
+ "default": null,
360
+ "comment": null,
361
+ "enumItems": [],
362
+ "mappedType": "uuid"
227
363
  }
228
364
  },
229
- "name": "integration_logs",
230
- "schema": "public",
231
365
  "indexes": [
232
366
  {
233
- "keyName": "integration_logs_level_organization_id_tenant_id_c_107e7_index",
234
367
  "columnNames": [
235
- "level",
368
+ "integration_id",
236
369
  "organization_id",
237
370
  "tenant_id",
238
371
  "created_at"
239
372
  ],
240
373
  "composite": true,
241
374
  "constraint": false,
375
+ "keyName": "integration_logs_integration_id_organization_id_te_41dbc_index",
242
376
  "primary": false,
243
377
  "unique": false
244
378
  },
245
379
  {
246
- "keyName": "integration_logs_integration_id_organization_id_te_38189_index",
247
380
  "columnNames": [
248
- "integration_id",
381
+ "level",
249
382
  "organization_id",
250
383
  "tenant_id",
251
384
  "created_at"
252
385
  ],
253
386
  "composite": true,
254
387
  "constraint": false,
388
+ "keyName": "integration_logs_level_organization_id_tenant_id_c_af75d_index",
255
389
  "primary": false,
256
390
  "unique": false
257
391
  },
258
392
  {
259
- "keyName": "integration_logs_pkey",
260
393
  "columnNames": [
261
394
  "id"
262
395
  ],
263
396
  "composite": false,
264
397
  "constraint": true,
398
+ "keyName": "integration_logs_pkey",
265
399
  "primary": true,
266
400
  "unique": true
267
401
  }
268
402
  ],
269
403
  "checks": [],
270
404
  "foreignKeys": {},
271
- "nativeEnums": {}
405
+ "comment": null
272
406
  },
273
407
  {
408
+ "name": "integration_states",
409
+ "schema": "public",
274
410
  "columns": {
275
- "id": {
276
- "name": "id",
277
- "type": "uuid",
411
+ "api_version": {
412
+ "name": "api_version",
413
+ "type": "text",
278
414
  "unsigned": false,
279
415
  "autoincrement": false,
280
416
  "primary": false,
281
- "nullable": false,
282
- "default": "gen_random_uuid()",
283
- "mappedType": "uuid"
417
+ "nullable": true,
418
+ "unique": false,
419
+ "length": null,
420
+ "precision": null,
421
+ "scale": null,
422
+ "default": null,
423
+ "comment": null,
424
+ "enumItems": [],
425
+ "mappedType": "text"
284
426
  },
285
- "integration_id": {
286
- "name": "integration_id",
287
- "type": "text",
427
+ "created_at": {
428
+ "name": "created_at",
429
+ "type": "timestamptz(6)",
288
430
  "unsigned": false,
289
431
  "autoincrement": false,
290
432
  "primary": false,
291
433
  "nullable": false,
292
- "mappedType": "text"
434
+ "unique": false,
435
+ "length": 6,
436
+ "precision": null,
437
+ "scale": null,
438
+ "default": null,
439
+ "comment": null,
440
+ "enumItems": [],
441
+ "mappedType": "datetime"
293
442
  },
294
- "is_enabled": {
295
- "name": "is_enabled",
296
- "type": "boolean",
443
+ "deleted_at": {
444
+ "name": "deleted_at",
445
+ "type": "timestamptz(6)",
297
446
  "unsigned": false,
298
447
  "autoincrement": false,
299
448
  "primary": false,
300
- "nullable": false,
301
- "default": "true",
302
- "mappedType": "boolean"
449
+ "nullable": true,
450
+ "unique": false,
451
+ "length": 6,
452
+ "precision": null,
453
+ "scale": null,
454
+ "default": null,
455
+ "comment": null,
456
+ "enumItems": [],
457
+ "mappedType": "datetime"
303
458
  },
304
- "api_version": {
305
- "name": "api_version",
306
- "type": "text",
459
+ "enabled_at": {
460
+ "name": "enabled_at",
461
+ "type": "timestamptz(6)",
307
462
  "unsigned": false,
308
463
  "autoincrement": false,
309
464
  "primary": false,
310
465
  "nullable": true,
311
- "mappedType": "text"
466
+ "unique": false,
467
+ "length": 6,
468
+ "precision": null,
469
+ "scale": null,
470
+ "default": null,
471
+ "comment": null,
472
+ "enumItems": [],
473
+ "mappedType": "datetime"
312
474
  },
313
- "reauth_required": {
314
- "name": "reauth_required",
315
- "type": "boolean",
475
+ "id": {
476
+ "name": "id",
477
+ "type": "uuid",
316
478
  "unsigned": false,
317
479
  "autoincrement": false,
318
- "primary": false,
480
+ "primary": true,
319
481
  "nullable": false,
320
- "default": "false",
321
- "mappedType": "boolean"
482
+ "unique": false,
483
+ "length": null,
484
+ "precision": null,
485
+ "scale": null,
486
+ "default": "gen_random_uuid()",
487
+ "comment": null,
488
+ "enumItems": [],
489
+ "mappedType": "uuid"
322
490
  },
323
- "last_health_status": {
324
- "name": "last_health_status",
491
+ "integration_id": {
492
+ "name": "integration_id",
325
493
  "type": "text",
326
494
  "unsigned": false,
327
495
  "autoincrement": false,
328
496
  "primary": false,
329
- "nullable": true,
497
+ "nullable": false,
498
+ "unique": false,
499
+ "length": null,
500
+ "precision": null,
501
+ "scale": null,
502
+ "default": null,
503
+ "comment": null,
504
+ "enumItems": [],
330
505
  "mappedType": "text"
331
506
  },
507
+ "is_enabled": {
508
+ "name": "is_enabled",
509
+ "type": "boolean",
510
+ "unsigned": false,
511
+ "autoincrement": false,
512
+ "primary": false,
513
+ "nullable": false,
514
+ "unique": false,
515
+ "length": null,
516
+ "precision": null,
517
+ "scale": null,
518
+ "default": "true",
519
+ "comment": null,
520
+ "enumItems": [],
521
+ "mappedType": "boolean"
522
+ },
332
523
  "last_health_checked_at": {
333
524
  "name": "last_health_checked_at",
334
- "type": "timestamptz",
525
+ "type": "timestamptz(6)",
335
526
  "unsigned": false,
336
527
  "autoincrement": false,
337
528
  "primary": false,
338
529
  "nullable": true,
530
+ "unique": false,
339
531
  "length": 6,
532
+ "precision": null,
533
+ "scale": null,
534
+ "default": null,
535
+ "comment": null,
536
+ "enumItems": [],
340
537
  "mappedType": "datetime"
341
538
  },
342
539
  "last_health_latency_ms": {
@@ -346,17 +543,30 @@
346
543
  "autoincrement": false,
347
544
  "primary": false,
348
545
  "nullable": true,
546
+ "unique": false,
547
+ "length": null,
548
+ "precision": null,
549
+ "scale": null,
550
+ "default": null,
551
+ "comment": null,
552
+ "enumItems": [],
349
553
  "mappedType": "integer"
350
554
  },
351
- "enabled_at": {
352
- "name": "enabled_at",
353
- "type": "timestamptz",
555
+ "last_health_status": {
556
+ "name": "last_health_status",
557
+ "type": "text",
354
558
  "unsigned": false,
355
559
  "autoincrement": false,
356
560
  "primary": false,
357
561
  "nullable": true,
358
- "length": 6,
359
- "mappedType": "datetime"
562
+ "unique": false,
563
+ "length": null,
564
+ "precision": null,
565
+ "scale": null,
566
+ "default": null,
567
+ "comment": null,
568
+ "enumItems": [],
569
+ "mappedType": "text"
360
570
  },
361
571
  "organization_id": {
362
572
  "name": "organization_id",
@@ -365,53 +575,66 @@
365
575
  "autoincrement": false,
366
576
  "primary": false,
367
577
  "nullable": false,
578
+ "unique": false,
579
+ "length": null,
580
+ "precision": null,
581
+ "scale": null,
582
+ "default": null,
583
+ "comment": null,
584
+ "enumItems": [],
368
585
  "mappedType": "uuid"
369
586
  },
370
- "tenant_id": {
371
- "name": "tenant_id",
372
- "type": "uuid",
587
+ "reauth_required": {
588
+ "name": "reauth_required",
589
+ "type": "boolean",
373
590
  "unsigned": false,
374
591
  "autoincrement": false,
375
592
  "primary": false,
376
593
  "nullable": false,
377
- "mappedType": "uuid"
594
+ "unique": false,
595
+ "length": null,
596
+ "precision": null,
597
+ "scale": null,
598
+ "default": "false",
599
+ "comment": null,
600
+ "enumItems": [],
601
+ "mappedType": "boolean"
378
602
  },
379
- "created_at": {
380
- "name": "created_at",
381
- "type": "timestamptz",
603
+ "tenant_id": {
604
+ "name": "tenant_id",
605
+ "type": "uuid",
382
606
  "unsigned": false,
383
607
  "autoincrement": false,
384
608
  "primary": false,
385
609
  "nullable": false,
386
- "length": 6,
387
- "mappedType": "datetime"
610
+ "unique": false,
611
+ "length": null,
612
+ "precision": null,
613
+ "scale": null,
614
+ "default": null,
615
+ "comment": null,
616
+ "enumItems": [],
617
+ "mappedType": "uuid"
388
618
  },
389
619
  "updated_at": {
390
620
  "name": "updated_at",
391
- "type": "timestamptz",
621
+ "type": "timestamptz(6)",
392
622
  "unsigned": false,
393
623
  "autoincrement": false,
394
624
  "primary": false,
395
625
  "nullable": false,
626
+ "unique": false,
396
627
  "length": 6,
397
- "mappedType": "datetime"
398
- },
399
- "deleted_at": {
400
- "name": "deleted_at",
401
- "type": "timestamptz",
402
- "unsigned": false,
403
- "autoincrement": false,
404
- "primary": false,
405
- "nullable": true,
406
- "length": 6,
628
+ "precision": null,
629
+ "scale": null,
630
+ "default": null,
631
+ "comment": null,
632
+ "enumItems": [],
407
633
  "mappedType": "datetime"
408
634
  }
409
635
  },
410
- "name": "integration_states",
411
- "schema": "public",
412
636
  "indexes": [
413
637
  {
414
- "keyName": "integration_states_integration_id_organization_id__32acc_index",
415
638
  "columnNames": [
416
639
  "integration_id",
417
640
  "organization_id",
@@ -419,90 +642,155 @@
419
642
  ],
420
643
  "composite": true,
421
644
  "constraint": false,
645
+ "keyName": "integration_states_integration_id_organization_id__8b1c1_index",
422
646
  "primary": false,
423
647
  "unique": false
424
648
  },
425
649
  {
426
- "keyName": "integration_states_pkey",
427
650
  "columnNames": [
428
651
  "id"
429
652
  ],
430
653
  "composite": false,
431
654
  "constraint": true,
655
+ "keyName": "integration_states_pkey",
432
656
  "primary": true,
433
657
  "unique": true
434
658
  }
435
659
  ],
436
660
  "checks": [],
437
661
  "foreignKeys": {},
438
- "nativeEnums": {}
662
+ "comment": null
439
663
  },
440
664
  {
665
+ "name": "sync_external_id_mappings",
666
+ "schema": "public",
441
667
  "columns": {
442
- "id": {
443
- "name": "id",
444
- "type": "uuid",
668
+ "created_at": {
669
+ "name": "created_at",
670
+ "type": "timestamptz(6)",
445
671
  "unsigned": false,
446
672
  "autoincrement": false,
447
673
  "primary": false,
448
674
  "nullable": false,
449
- "default": "gen_random_uuid()",
450
- "mappedType": "uuid"
675
+ "unique": false,
676
+ "length": 6,
677
+ "precision": null,
678
+ "scale": null,
679
+ "default": null,
680
+ "comment": null,
681
+ "enumItems": [],
682
+ "mappedType": "datetime"
451
683
  },
452
- "integration_id": {
453
- "name": "integration_id",
454
- "type": "text",
684
+ "deleted_at": {
685
+ "name": "deleted_at",
686
+ "type": "timestamptz(6)",
455
687
  "unsigned": false,
456
688
  "autoincrement": false,
457
689
  "primary": false,
458
- "nullable": false,
459
- "mappedType": "text"
690
+ "nullable": true,
691
+ "unique": false,
692
+ "length": 6,
693
+ "precision": null,
694
+ "scale": null,
695
+ "default": null,
696
+ "comment": null,
697
+ "enumItems": [],
698
+ "mappedType": "datetime"
460
699
  },
461
- "internal_entity_type": {
462
- "name": "internal_entity_type",
700
+ "external_id": {
701
+ "name": "external_id",
463
702
  "type": "text",
464
703
  "unsigned": false,
465
704
  "autoincrement": false,
466
705
  "primary": false,
467
706
  "nullable": false,
707
+ "unique": false,
708
+ "length": null,
709
+ "precision": null,
710
+ "scale": null,
711
+ "default": null,
712
+ "comment": null,
713
+ "enumItems": [],
468
714
  "mappedType": "text"
469
715
  },
470
- "internal_entity_id": {
471
- "name": "internal_entity_id",
716
+ "id": {
717
+ "name": "id",
472
718
  "type": "uuid",
473
719
  "unsigned": false,
474
720
  "autoincrement": false,
475
- "primary": false,
721
+ "primary": true,
476
722
  "nullable": false,
723
+ "unique": false,
724
+ "length": null,
725
+ "precision": null,
726
+ "scale": null,
727
+ "default": "gen_random_uuid()",
728
+ "comment": null,
729
+ "enumItems": [],
477
730
  "mappedType": "uuid"
478
731
  },
479
- "external_id": {
480
- "name": "external_id",
732
+ "integration_id": {
733
+ "name": "integration_id",
481
734
  "type": "text",
482
735
  "unsigned": false,
483
736
  "autoincrement": false,
484
737
  "primary": false,
485
738
  "nullable": false,
739
+ "unique": false,
740
+ "length": null,
741
+ "precision": null,
742
+ "scale": null,
743
+ "default": null,
744
+ "comment": null,
745
+ "enumItems": [],
486
746
  "mappedType": "text"
487
747
  },
488
- "sync_status": {
489
- "name": "sync_status",
748
+ "internal_entity_id": {
749
+ "name": "internal_entity_id",
750
+ "type": "uuid",
751
+ "unsigned": false,
752
+ "autoincrement": false,
753
+ "primary": false,
754
+ "nullable": false,
755
+ "unique": false,
756
+ "length": null,
757
+ "precision": null,
758
+ "scale": null,
759
+ "default": null,
760
+ "comment": null,
761
+ "enumItems": [],
762
+ "mappedType": "uuid"
763
+ },
764
+ "internal_entity_type": {
765
+ "name": "internal_entity_type",
490
766
  "type": "text",
491
767
  "unsigned": false,
492
768
  "autoincrement": false,
493
769
  "primary": false,
494
770
  "nullable": false,
495
- "default": "'not_synced'",
771
+ "unique": false,
772
+ "length": null,
773
+ "precision": null,
774
+ "scale": null,
775
+ "default": null,
776
+ "comment": null,
777
+ "enumItems": [],
496
778
  "mappedType": "text"
497
779
  },
498
780
  "last_synced_at": {
499
781
  "name": "last_synced_at",
500
- "type": "timestamptz",
782
+ "type": "timestamptz(6)",
501
783
  "unsigned": false,
502
784
  "autoincrement": false,
503
785
  "primary": false,
504
786
  "nullable": true,
787
+ "unique": false,
505
788
  "length": 6,
789
+ "precision": null,
790
+ "scale": null,
791
+ "default": null,
792
+ "comment": null,
793
+ "enumItems": [],
506
794
  "mappedType": "datetime"
507
795
  },
508
796
  "organization_id": {
@@ -512,53 +800,66 @@
512
800
  "autoincrement": false,
513
801
  "primary": false,
514
802
  "nullable": false,
803
+ "unique": false,
804
+ "length": null,
805
+ "precision": null,
806
+ "scale": null,
807
+ "default": null,
808
+ "comment": null,
809
+ "enumItems": [],
515
810
  "mappedType": "uuid"
516
811
  },
517
- "tenant_id": {
518
- "name": "tenant_id",
519
- "type": "uuid",
812
+ "sync_status": {
813
+ "name": "sync_status",
814
+ "type": "text",
520
815
  "unsigned": false,
521
816
  "autoincrement": false,
522
817
  "primary": false,
523
818
  "nullable": false,
524
- "mappedType": "uuid"
819
+ "unique": false,
820
+ "length": null,
821
+ "precision": null,
822
+ "scale": null,
823
+ "default": "'not_synced'",
824
+ "comment": null,
825
+ "enumItems": [],
826
+ "mappedType": "text"
525
827
  },
526
- "created_at": {
527
- "name": "created_at",
528
- "type": "timestamptz",
828
+ "tenant_id": {
829
+ "name": "tenant_id",
830
+ "type": "uuid",
529
831
  "unsigned": false,
530
832
  "autoincrement": false,
531
833
  "primary": false,
532
834
  "nullable": false,
533
- "length": 6,
534
- "mappedType": "datetime"
835
+ "unique": false,
836
+ "length": null,
837
+ "precision": null,
838
+ "scale": null,
839
+ "default": null,
840
+ "comment": null,
841
+ "enumItems": [],
842
+ "mappedType": "uuid"
535
843
  },
536
844
  "updated_at": {
537
845
  "name": "updated_at",
538
- "type": "timestamptz",
846
+ "type": "timestamptz(6)",
539
847
  "unsigned": false,
540
848
  "autoincrement": false,
541
849
  "primary": false,
542
850
  "nullable": false,
851
+ "unique": false,
543
852
  "length": 6,
544
- "mappedType": "datetime"
545
- },
546
- "deleted_at": {
547
- "name": "deleted_at",
548
- "type": "timestamptz",
549
- "unsigned": false,
550
- "autoincrement": false,
551
- "primary": false,
552
- "nullable": true,
553
- "length": 6,
853
+ "precision": null,
854
+ "scale": null,
855
+ "default": null,
856
+ "comment": null,
857
+ "enumItems": [],
554
858
  "mappedType": "datetime"
555
859
  }
556
860
  },
557
- "name": "sync_external_id_mappings",
558
- "schema": "public",
559
861
  "indexes": [
560
862
  {
561
- "keyName": "sync_external_id_mappings_integration_id_external__c088c_index",
562
863
  "columnNames": [
563
864
  "integration_id",
564
865
  "external_id",
@@ -566,11 +867,11 @@
566
867
  ],
567
868
  "composite": true,
568
869
  "constraint": false,
870
+ "keyName": "sync_external_id_mappings_integration_id_external__063e8_index",
569
871
  "primary": false,
570
872
  "unique": false
571
873
  },
572
874
  {
573
- "keyName": "sync_external_id_mappings_internal_entity_type_int_f9194_index",
574
875
  "columnNames": [
575
876
  "internal_entity_type",
576
877
  "internal_entity_id",
@@ -578,24 +879,26 @@
578
879
  ],
579
880
  "composite": true,
580
881
  "constraint": false,
882
+ "keyName": "sync_external_id_mappings_internal_entity_type_int_7f84a_index",
581
883
  "primary": false,
582
884
  "unique": false
583
885
  },
584
886
  {
585
- "keyName": "sync_external_id_mappings_pkey",
586
887
  "columnNames": [
587
888
  "id"
588
889
  ],
589
890
  "composite": false,
590
891
  "constraint": true,
892
+ "keyName": "sync_external_id_mappings_pkey",
591
893
  "primary": true,
592
894
  "unique": true
593
895
  }
594
896
  ],
595
897
  "checks": [],
596
898
  "foreignKeys": {},
597
- "nativeEnums": {}
899
+ "comment": null
598
900
  }
599
901
  ],
902
+ "views": [],
600
903
  "nativeEnums": {}
601
- }
904
+ }