@aopslab/aops-server 0.1.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.
Files changed (185) hide show
  1. package/LICENSE +202 -0
  2. package/NOTICE +6 -0
  3. package/README.md +21 -0
  4. package/aops-server-runtime.json +11 -0
  5. package/build/client/_app/immutable/chunks/2_TffmqH.js +1 -0
  6. package/build/client/_app/immutable/chunks/3DOfIKW0.js +1 -0
  7. package/build/client/_app/immutable/chunks/B2EkC-sy.js +1 -0
  8. package/build/client/_app/immutable/chunks/CMkIcmi1.js +2 -0
  9. package/build/client/_app/immutable/chunks/rqnVXeyB.js +1 -0
  10. package/build/client/_app/immutable/chunks/sZYZbj9W.js +1 -0
  11. package/build/client/_app/immutable/chunks/wbPk3Yxo.js +81 -0
  12. package/build/client/_app/immutable/entry/app.C7STLTX8.js +2 -0
  13. package/build/client/_app/immutable/entry/start.BC94hOaC.js +1 -0
  14. package/build/client/_app/immutable/nodes/0.BYBfjxZ5.js +1 -0
  15. package/build/client/_app/immutable/nodes/1.BNXFXajG.js +1 -0
  16. package/build/client/_app/version.json +1 -0
  17. package/build/env.js +70 -0
  18. package/build/env.js.map +1 -0
  19. package/build/handler.js +16 -0
  20. package/build/handler.js.map +1 -0
  21. package/build/index.js +139 -0
  22. package/build/index.js.map +1 -0
  23. package/build/server/chunks/0-RfB6m2nq.js +7 -0
  24. package/build/server/chunks/0-RfB6m2nq.js.map +1 -0
  25. package/build/server/chunks/1-_gg8Q0UT.js +9 -0
  26. package/build/server/chunks/1-_gg8Q0UT.js.map +1 -0
  27. package/build/server/chunks/_server.ts-6276EQIF.js +44 -0
  28. package/build/server/chunks/_server.ts-6276EQIF.js.map +1 -0
  29. package/build/server/chunks/_server.ts-B59WFQzX.js +174 -0
  30. package/build/server/chunks/_server.ts-B59WFQzX.js.map +1 -0
  31. package/build/server/chunks/_server.ts-BauJsLZI.js +40 -0
  32. package/build/server/chunks/_server.ts-BauJsLZI.js.map +1 -0
  33. package/build/server/chunks/_server.ts-BnGzJw2-.js +81 -0
  34. package/build/server/chunks/_server.ts-BnGzJw2-.js.map +1 -0
  35. package/build/server/chunks/_server.ts-CP7qM24V.js +34 -0
  36. package/build/server/chunks/_server.ts-CP7qM24V.js.map +1 -0
  37. package/build/server/chunks/_server.ts-Cbq_u99d.js +9 -0
  38. package/build/server/chunks/_server.ts-Cbq_u99d.js.map +1 -0
  39. package/build/server/chunks/_server.ts-Ch8fPT-o.js +92 -0
  40. package/build/server/chunks/_server.ts-Ch8fPT-o.js.map +1 -0
  41. package/build/server/chunks/_server.ts-Cv-yaXZI.js +7 -0
  42. package/build/server/chunks/_server.ts-Cv-yaXZI.js.map +1 -0
  43. package/build/server/chunks/_server.ts-D6lBwOON.js +34 -0
  44. package/build/server/chunks/_server.ts-D6lBwOON.js.map +1 -0
  45. package/build/server/chunks/_server.ts-D84K3pp9.js +11 -0
  46. package/build/server/chunks/_server.ts-D84K3pp9.js.map +1 -0
  47. package/build/server/chunks/_server.ts-DNzU1ToA.js +277 -0
  48. package/build/server/chunks/_server.ts-DNzU1ToA.js.map +1 -0
  49. package/build/server/chunks/_server.ts-DQQnw77t.js +17 -0
  50. package/build/server/chunks/_server.ts-DQQnw77t.js.map +1 -0
  51. package/build/server/chunks/_server.ts-DSxr5l15.js +18 -0
  52. package/build/server/chunks/_server.ts-DSxr5l15.js.map +1 -0
  53. package/build/server/chunks/_server.ts-DZYokvuR.js +80 -0
  54. package/build/server/chunks/_server.ts-DZYokvuR.js.map +1 -0
  55. package/build/server/chunks/_server.ts-Dcqwpz2t.js +144 -0
  56. package/build/server/chunks/_server.ts-Dcqwpz2t.js.map +1 -0
  57. package/build/server/chunks/_server.ts-Di9VJnF4.js +81 -0
  58. package/build/server/chunks/_server.ts-Di9VJnF4.js.map +1 -0
  59. package/build/server/chunks/_server.ts-FBEHFT8b.js +33 -0
  60. package/build/server/chunks/_server.ts-FBEHFT8b.js.map +1 -0
  61. package/build/server/chunks/_server.ts-gZytCuiJ.js +10 -0
  62. package/build/server/chunks/_server.ts-gZytCuiJ.js.map +1 -0
  63. package/build/server/chunks/_server.ts-tNULLyEO.js +261 -0
  64. package/build/server/chunks/_server.ts-tNULLyEO.js.map +1 -0
  65. package/build/server/chunks/agent-gateway-runtime-DTZ4SxaC.js +2598 -0
  66. package/build/server/chunks/agent-gateway-runtime-DTZ4SxaC.js.map +1 -0
  67. package/build/server/chunks/aops-runtime-config-wpVmg7T-.js +179 -0
  68. package/build/server/chunks/aops-runtime-config-wpVmg7T-.js.map +1 -0
  69. package/build/server/chunks/discovery-D9JnSgfu.js +894 -0
  70. package/build/server/chunks/discovery-D9JnSgfu.js.map +1 -0
  71. package/build/server/chunks/error.svelte-DgUOqi-L.js +45 -0
  72. package/build/server/chunks/error.svelte-DgUOqi-L.js.map +1 -0
  73. package/build/server/chunks/handler-BN3-p5rP.js +1733 -0
  74. package/build/server/chunks/handler-BN3-p5rP.js.map +1 -0
  75. package/build/server/chunks/hooks.server-C4wxiH5m.js +52 -0
  76. package/build/server/chunks/hooks.server-C4wxiH5m.js.map +1 -0
  77. package/build/server/chunks/index.js-nbqdVuWC.js +10698 -0
  78. package/build/server/chunks/index.js-nbqdVuWC.js.map +1 -0
  79. package/build/server/chunks/manifest.js-_Re-Wj-y.js +167 -0
  80. package/build/server/chunks/manifest.js-_Re-Wj-y.js.map +1 -0
  81. package/build/server/chunks/plugin-error-normalize-Bq14Qbz3.js +297 -0
  82. package/build/server/chunks/plugin-error-normalize-Bq14Qbz3.js.map +1 -0
  83. package/build/server/chunks/project-alias-DqE2v58Q.js +29 -0
  84. package/build/server/chunks/project-alias-DqE2v58Q.js.map +1 -0
  85. package/build/server/chunks/registry-5amIZito.js +289 -0
  86. package/build/server/chunks/registry-5amIZito.js.map +1 -0
  87. package/build/server/chunks/request-base-url-BDdrsaga.js +24 -0
  88. package/build/server/chunks/request-base-url-BDdrsaga.js.map +1 -0
  89. package/build/server/chunks/request-context-tNeFQjgb.js +422 -0
  90. package/build/server/chunks/request-context-tNeFQjgb.js.map +1 -0
  91. package/build/server/chunks/xf-result-BRDjvftr.js +17 -0
  92. package/build/server/chunks/xf-result-BRDjvftr.js.map +1 -0
  93. package/build/shims.js +33 -0
  94. package/build/shims.js.map +1 -0
  95. package/cockpit/.vite/manifest.json +198 -0
  96. package/cockpit/assets/dm-sans-latin-400-normal-BwCSEQnW.woff +0 -0
  97. package/cockpit/assets/dm-sans-latin-400-normal-CW0RaeGs.woff2 +0 -0
  98. package/cockpit/assets/dm-sans-latin-500-normal-B9HHJjqV.woff2 +0 -0
  99. package/cockpit/assets/dm-sans-latin-500-normal-Dr3UlScf.woff +0 -0
  100. package/cockpit/assets/dm-sans-latin-700-normal-CUSSCpQX.woff +0 -0
  101. package/cockpit/assets/dm-sans-latin-700-normal-DvUfVpUG.woff2 +0 -0
  102. package/cockpit/assets/dm-sans-latin-ext-400-normal-BjWJ59Pq.woff +0 -0
  103. package/cockpit/assets/dm-sans-latin-ext-400-normal-BtiwyxMk.woff2 +0 -0
  104. package/cockpit/assets/dm-sans-latin-ext-500-normal-BJfUCQsA.woff2 +0 -0
  105. package/cockpit/assets/dm-sans-latin-ext-500-normal-DR84L5F-.woff +0 -0
  106. package/cockpit/assets/dm-sans-latin-ext-700-normal-BLI3TTWz.woff +0 -0
  107. package/cockpit/assets/dm-sans-latin-ext-700-normal-CJIcxD6K.woff2 +0 -0
  108. package/cockpit/assets/index-DDswO4B1.css +1 -0
  109. package/cockpit/assets/index-bovtnZ98.js +18 -0
  110. package/cockpit/assets/jetbrains-mono-cyrillic-400-normal-BEIGL1Tu.woff2 +0 -0
  111. package/cockpit/assets/jetbrains-mono-cyrillic-400-normal-ugxPyKxw.woff +0 -0
  112. package/cockpit/assets/jetbrains-mono-greek-400-normal-B9oWc5Lo.woff +0 -0
  113. package/cockpit/assets/jetbrains-mono-greek-400-normal-C190GLew.woff2 +0 -0
  114. package/cockpit/assets/jetbrains-mono-latin-400-normal-6-qcROiO.woff +0 -0
  115. package/cockpit/assets/jetbrains-mono-latin-400-normal-V6pRDFza.woff2 +0 -0
  116. package/cockpit/assets/jetbrains-mono-latin-ext-400-normal-Bc8Ftmh3.woff2 +0 -0
  117. package/cockpit/assets/jetbrains-mono-latin-ext-400-normal-fXTG6kC5.woff +0 -0
  118. package/cockpit/assets/jetbrains-mono-vietnamese-400-normal-CqNFfHCs.woff +0 -0
  119. package/cockpit/assets/outfit-latin-400-normal-BGsTXAXT.woff2 +0 -0
  120. package/cockpit/assets/outfit-latin-400-normal-DMwTpYkH.woff +0 -0
  121. package/cockpit/assets/outfit-latin-600-normal-B7SfZ07L.woff2 +0 -0
  122. package/cockpit/assets/outfit-latin-600-normal-BEfTtDA7.woff +0 -0
  123. package/cockpit/assets/outfit-latin-ext-400-normal-5tcqmc2S.woff2 +0 -0
  124. package/cockpit/assets/outfit-latin-ext-400-normal-DHm7mdGe.woff +0 -0
  125. package/cockpit/assets/outfit-latin-ext-600-normal-B85nYjL1.woff2 +0 -0
  126. package/cockpit/assets/outfit-latin-ext-600-normal-CWJcPgd7.woff +0 -0
  127. package/cockpit/assets/unbounded-cyrillic-600-normal-B-s5c2Kn.woff +0 -0
  128. package/cockpit/assets/unbounded-cyrillic-600-normal-DW6uzIMB.woff2 +0 -0
  129. package/cockpit/assets/unbounded-latin-600-normal-BPdB_PEv.woff +0 -0
  130. package/cockpit/assets/unbounded-latin-600-normal-oRSANpZr.woff2 +0 -0
  131. package/cockpit/assets/unbounded-latin-ext-600-normal-0iZLtTDV.woff2 +0 -0
  132. package/cockpit/assets/unbounded-latin-ext-600-normal-ClMPf-bu.woff +0 -0
  133. package/cockpit/assets/unbounded-vietnamese-600-normal-BzfrgZ_C.woff +0 -0
  134. package/cockpit/assets/unbounded-vietnamese-600-normal-Cx2bTSHN.woff2 +0 -0
  135. package/cockpit/community.module-inventory.json +2389 -0
  136. package/cockpit/index.html +14 -0
  137. package/community-postgres.json +13 -0
  138. package/migrations/agentspace/0000_thin_carlie_cooper.sql +764 -0
  139. package/migrations/agentspace/meta/0000_snapshot.json +6885 -0
  140. package/migrations/agentspace/meta/_journal.json +13 -0
  141. package/migrations/chatv3/0000_dry_ego.sql +218 -0
  142. package/migrations/chatv3/0001_nosy_obadiah_stane.sql +35 -0
  143. package/migrations/chatv3/0002_narrow_darkhawk.sql +4 -0
  144. package/migrations/chatv3/0003_damp_zarek.sql +2 -0
  145. package/migrations/chatv3/0004_nervous_martin_li.sql +60 -0
  146. package/migrations/chatv3/0005_chatv3_server_encrypted_mode.sql +1 -0
  147. package/migrations/chatv3/meta/0000_snapshot.json +1887 -0
  148. package/migrations/chatv3/meta/0001_snapshot.json +2175 -0
  149. package/migrations/chatv3/meta/0002_snapshot.json +2229 -0
  150. package/migrations/chatv3/meta/0003_snapshot.json +2241 -0
  151. package/migrations/chatv3/meta/0004_snapshot.json +2746 -0
  152. package/migrations/chatv3/meta/_journal.json +48 -0
  153. package/migrations/docman/0000_curvy_valeria_richards.sql +257 -0
  154. package/migrations/docman/0001_massive_risque.sql +2 -0
  155. package/migrations/docman/0002_simple_logan.sql +50 -0
  156. package/migrations/docman/0003_quick_index.sql +45 -0
  157. package/migrations/docman/0004_known_summary.sql +9 -0
  158. package/migrations/docman/0005_vector_signal.sql +9 -0
  159. package/migrations/docman/0006_document_version_current_invariant.sql +15 -0
  160. package/migrations/docman/meta/_journal.json +55 -0
  161. package/migrations/projectman/0000_smooth_klaw.sql +257 -0
  162. package/migrations/projectman/0001_worthless_zodiak.sql +9 -0
  163. package/migrations/projectman/0002_board_rename.sql +108 -0
  164. package/migrations/projectman/0003_review_request.sql +62 -0
  165. package/migrations/projectman/0004_review_request_idempotency.sql +3 -0
  166. package/migrations/projectman/0005_allow_multi_sprint_per_task.sql +1 -0
  167. package/migrations/projectman/meta/_journal.json +48 -0
  168. package/migrations/sys/0000_loose_praxagora.sql +31 -0
  169. package/migrations/sys/0001_awesome_ronan.sql +2 -0
  170. package/migrations/sys/0002_steady_maximus.sql +2 -0
  171. package/migrations/sys/0003_escalating_rate_limiter.sql +2 -0
  172. package/migrations/sys/0004_rate_limiter_timestamptz.sql +22 -0
  173. package/migrations/sys/0005_sys_counters.sql +21 -0
  174. package/migrations/sys/meta/_journal.json +48 -0
  175. package/npm-shrinkwrap.json +4375 -0
  176. package/package.json +62 -0
  177. package/runtime/agentspace-host-adapter.mjs +64 -0
  178. package/runtime/agentspace-tooling.mjs +389 -0
  179. package/runtime/docman-host-adapter.mjs +177 -0
  180. package/runtime/docman-policy.mjs +450 -0
  181. package/runtime/docman-tooling.mjs +20 -0
  182. package/runtime/projectman-host-adapter.mjs +597 -0
  183. package/runtime/scope-context.mjs +99 -0
  184. package/scripts/community-host.mjs +626 -0
  185. package/scripts/community-migration-policy-v1.json +296 -0
@@ -0,0 +1,2241 @@
1
+ {
2
+ "id": "f065931a-51d7-4236-8c4b-a5cc06afc629",
3
+ "prevId": "a28fa97f-713d-4f39-ad35-01f6a19b2d72",
4
+ "version": "7",
5
+ "dialect": "postgresql",
6
+ "tables": {
7
+ "public.chatv3-spaces": {
8
+ "name": "chatv3-spaces",
9
+ "schema": "",
10
+ "columns": {
11
+ "id": {
12
+ "name": "id",
13
+ "type": "uuid",
14
+ "primaryKey": true,
15
+ "notNull": true,
16
+ "default": "gen_random_uuid()"
17
+ },
18
+ "tenantId": {
19
+ "name": "tenantId",
20
+ "type": "text",
21
+ "primaryKey": false,
22
+ "notNull": true,
23
+ "default": "'default'"
24
+ },
25
+ "slug": {
26
+ "name": "slug",
27
+ "type": "text",
28
+ "primaryKey": false,
29
+ "notNull": true
30
+ },
31
+ "title": {
32
+ "name": "title",
33
+ "type": "text",
34
+ "primaryKey": false,
35
+ "notNull": true
36
+ },
37
+ "description": {
38
+ "name": "description",
39
+ "type": "text",
40
+ "primaryKey": false,
41
+ "notNull": false
42
+ },
43
+ "externalRefs": {
44
+ "name": "externalRefs",
45
+ "type": "jsonb",
46
+ "primaryKey": false,
47
+ "notNull": true,
48
+ "default": "'[]'::jsonb"
49
+ },
50
+ "status": {
51
+ "name": "status",
52
+ "type": "text",
53
+ "primaryKey": false,
54
+ "notNull": true,
55
+ "default": "'active'"
56
+ },
57
+ "createdBy": {
58
+ "name": "createdBy",
59
+ "type": "text",
60
+ "primaryKey": false,
61
+ "notNull": false
62
+ },
63
+ "updatedBy": {
64
+ "name": "updatedBy",
65
+ "type": "text",
66
+ "primaryKey": false,
67
+ "notNull": false
68
+ },
69
+ "createdAt": {
70
+ "name": "createdAt",
71
+ "type": "timestamp with time zone",
72
+ "primaryKey": false,
73
+ "notNull": true,
74
+ "default": "now()"
75
+ },
76
+ "updatedAt": {
77
+ "name": "updatedAt",
78
+ "type": "timestamp with time zone",
79
+ "primaryKey": false,
80
+ "notNull": true,
81
+ "default": "now()"
82
+ }
83
+ },
84
+ "indexes": {
85
+ "chatv3_space_tenant_slug_unique": {
86
+ "name": "chatv3_space_tenant_slug_unique",
87
+ "columns": [
88
+ {
89
+ "expression": "tenantId",
90
+ "isExpression": false,
91
+ "asc": true,
92
+ "nulls": "last"
93
+ },
94
+ {
95
+ "expression": "slug",
96
+ "isExpression": false,
97
+ "asc": true,
98
+ "nulls": "last"
99
+ }
100
+ ],
101
+ "isUnique": true,
102
+ "concurrently": false,
103
+ "method": "btree",
104
+ "with": {}
105
+ },
106
+ "chatv3_space_idx_tenant_status": {
107
+ "name": "chatv3_space_idx_tenant_status",
108
+ "columns": [
109
+ {
110
+ "expression": "tenantId",
111
+ "isExpression": false,
112
+ "asc": true,
113
+ "nulls": "last"
114
+ },
115
+ {
116
+ "expression": "status",
117
+ "isExpression": false,
118
+ "asc": true,
119
+ "nulls": "last"
120
+ }
121
+ ],
122
+ "isUnique": false,
123
+ "concurrently": false,
124
+ "method": "btree",
125
+ "with": {}
126
+ }
127
+ },
128
+ "foreignKeys": {},
129
+ "compositePrimaryKeys": {},
130
+ "uniqueConstraints": {},
131
+ "policies": {},
132
+ "checkConstraints": {},
133
+ "isRLSEnabled": false
134
+ },
135
+ "public.chatv3-channels": {
136
+ "name": "chatv3-channels",
137
+ "schema": "",
138
+ "columns": {
139
+ "id": {
140
+ "name": "id",
141
+ "type": "uuid",
142
+ "primaryKey": true,
143
+ "notNull": true,
144
+ "default": "gen_random_uuid()"
145
+ },
146
+ "tenantId": {
147
+ "name": "tenantId",
148
+ "type": "text",
149
+ "primaryKey": false,
150
+ "notNull": true,
151
+ "default": "'default'"
152
+ },
153
+ "spaceId": {
154
+ "name": "spaceId",
155
+ "type": "uuid",
156
+ "primaryKey": false,
157
+ "notNull": true
158
+ },
159
+ "slug": {
160
+ "name": "slug",
161
+ "type": "text",
162
+ "primaryKey": false,
163
+ "notNull": true
164
+ },
165
+ "title": {
166
+ "name": "title",
167
+ "type": "text",
168
+ "primaryKey": false,
169
+ "notNull": true
170
+ },
171
+ "purpose": {
172
+ "name": "purpose",
173
+ "type": "text",
174
+ "primaryKey": false,
175
+ "notNull": false
176
+ },
177
+ "guidanceMarkdown": {
178
+ "name": "guidanceMarkdown",
179
+ "type": "text",
180
+ "primaryKey": false,
181
+ "notNull": false
182
+ },
183
+ "status": {
184
+ "name": "status",
185
+ "type": "text",
186
+ "primaryKey": false,
187
+ "notNull": true,
188
+ "default": "'active'"
189
+ },
190
+ "generalRoomId": {
191
+ "name": "generalRoomId",
192
+ "type": "uuid",
193
+ "primaryKey": false,
194
+ "notNull": false
195
+ },
196
+ "createdBy": {
197
+ "name": "createdBy",
198
+ "type": "text",
199
+ "primaryKey": false,
200
+ "notNull": false
201
+ },
202
+ "updatedBy": {
203
+ "name": "updatedBy",
204
+ "type": "text",
205
+ "primaryKey": false,
206
+ "notNull": false
207
+ },
208
+ "ownerUserId": {
209
+ "name": "ownerUserId",
210
+ "type": "text",
211
+ "primaryKey": false,
212
+ "notNull": false
213
+ },
214
+ "createdAt": {
215
+ "name": "createdAt",
216
+ "type": "timestamp with time zone",
217
+ "primaryKey": false,
218
+ "notNull": true,
219
+ "default": "now()"
220
+ },
221
+ "updatedAt": {
222
+ "name": "updatedAt",
223
+ "type": "timestamp with time zone",
224
+ "primaryKey": false,
225
+ "notNull": true,
226
+ "default": "now()"
227
+ },
228
+ "archivedAt": {
229
+ "name": "archivedAt",
230
+ "type": "timestamp with time zone",
231
+ "primaryKey": false,
232
+ "notNull": false
233
+ }
234
+ },
235
+ "indexes": {
236
+ "chatv3_channel_tenant_space_slug_unique": {
237
+ "name": "chatv3_channel_tenant_space_slug_unique",
238
+ "columns": [
239
+ {
240
+ "expression": "tenantId",
241
+ "isExpression": false,
242
+ "asc": true,
243
+ "nulls": "last"
244
+ },
245
+ {
246
+ "expression": "spaceId",
247
+ "isExpression": false,
248
+ "asc": true,
249
+ "nulls": "last"
250
+ },
251
+ {
252
+ "expression": "slug",
253
+ "isExpression": false,
254
+ "asc": true,
255
+ "nulls": "last"
256
+ }
257
+ ],
258
+ "isUnique": true,
259
+ "concurrently": false,
260
+ "method": "btree",
261
+ "with": {}
262
+ },
263
+ "chatv3_channel_idx_tenant_space_status": {
264
+ "name": "chatv3_channel_idx_tenant_space_status",
265
+ "columns": [
266
+ {
267
+ "expression": "tenantId",
268
+ "isExpression": false,
269
+ "asc": true,
270
+ "nulls": "last"
271
+ },
272
+ {
273
+ "expression": "spaceId",
274
+ "isExpression": false,
275
+ "asc": true,
276
+ "nulls": "last"
277
+ },
278
+ {
279
+ "expression": "status",
280
+ "isExpression": false,
281
+ "asc": true,
282
+ "nulls": "last"
283
+ }
284
+ ],
285
+ "isUnique": false,
286
+ "concurrently": false,
287
+ "method": "btree",
288
+ "with": {}
289
+ },
290
+ "chatv3_channel_idx_tenant_owner": {
291
+ "name": "chatv3_channel_idx_tenant_owner",
292
+ "columns": [
293
+ {
294
+ "expression": "tenantId",
295
+ "isExpression": false,
296
+ "asc": true,
297
+ "nulls": "last"
298
+ },
299
+ {
300
+ "expression": "ownerUserId",
301
+ "isExpression": false,
302
+ "asc": true,
303
+ "nulls": "last"
304
+ }
305
+ ],
306
+ "isUnique": false,
307
+ "concurrently": false,
308
+ "method": "btree",
309
+ "with": {}
310
+ }
311
+ },
312
+ "foreignKeys": {
313
+ "chatv3-channels_spaceId_chatv3-spaces_id_fk": {
314
+ "name": "chatv3-channels_spaceId_chatv3-spaces_id_fk",
315
+ "tableFrom": "chatv3-channels",
316
+ "tableTo": "chatv3-spaces",
317
+ "columnsFrom": [
318
+ "spaceId"
319
+ ],
320
+ "columnsTo": [
321
+ "id"
322
+ ],
323
+ "onDelete": "cascade",
324
+ "onUpdate": "no action"
325
+ }
326
+ },
327
+ "compositePrimaryKeys": {},
328
+ "uniqueConstraints": {},
329
+ "policies": {},
330
+ "checkConstraints": {},
331
+ "isRLSEnabled": false
332
+ },
333
+ "public.chatv3-rooms": {
334
+ "name": "chatv3-rooms",
335
+ "schema": "",
336
+ "columns": {
337
+ "id": {
338
+ "name": "id",
339
+ "type": "uuid",
340
+ "primaryKey": true,
341
+ "notNull": true,
342
+ "default": "gen_random_uuid()"
343
+ },
344
+ "tenantId": {
345
+ "name": "tenantId",
346
+ "type": "text",
347
+ "primaryKey": false,
348
+ "notNull": true,
349
+ "default": "'default'"
350
+ },
351
+ "channelId": {
352
+ "name": "channelId",
353
+ "type": "uuid",
354
+ "primaryKey": false,
355
+ "notNull": true
356
+ },
357
+ "slug": {
358
+ "name": "slug",
359
+ "type": "text",
360
+ "primaryKey": false,
361
+ "notNull": true
362
+ },
363
+ "title": {
364
+ "name": "title",
365
+ "type": "text",
366
+ "primaryKey": false,
367
+ "notNull": true
368
+ },
369
+ "kind": {
370
+ "name": "kind",
371
+ "type": "text",
372
+ "primaryKey": false,
373
+ "notNull": true,
374
+ "default": "'session'"
375
+ },
376
+ "purpose": {
377
+ "name": "purpose",
378
+ "type": "text",
379
+ "primaryKey": false,
380
+ "notNull": false
381
+ },
382
+ "guidanceMarkdown": {
383
+ "name": "guidanceMarkdown",
384
+ "type": "text",
385
+ "primaryKey": false,
386
+ "notNull": false
387
+ },
388
+ "status": {
389
+ "name": "status",
390
+ "type": "text",
391
+ "primaryKey": false,
392
+ "notNull": true,
393
+ "default": "'active'"
394
+ },
395
+ "lastSeq": {
396
+ "name": "lastSeq",
397
+ "type": "integer",
398
+ "primaryKey": false,
399
+ "notNull": true,
400
+ "default": 0
401
+ },
402
+ "lastMessageAt": {
403
+ "name": "lastMessageAt",
404
+ "type": "timestamp with time zone",
405
+ "primaryKey": false,
406
+ "notNull": false
407
+ },
408
+ "currentEpoch": {
409
+ "name": "currentEpoch",
410
+ "type": "integer",
411
+ "primaryKey": false,
412
+ "notNull": true,
413
+ "default": 0
414
+ },
415
+ "createdBy": {
416
+ "name": "createdBy",
417
+ "type": "text",
418
+ "primaryKey": false,
419
+ "notNull": false
420
+ },
421
+ "updatedBy": {
422
+ "name": "updatedBy",
423
+ "type": "text",
424
+ "primaryKey": false,
425
+ "notNull": false
426
+ },
427
+ "createdAt": {
428
+ "name": "createdAt",
429
+ "type": "timestamp with time zone",
430
+ "primaryKey": false,
431
+ "notNull": true,
432
+ "default": "now()"
433
+ },
434
+ "updatedAt": {
435
+ "name": "updatedAt",
436
+ "type": "timestamp with time zone",
437
+ "primaryKey": false,
438
+ "notNull": true,
439
+ "default": "now()"
440
+ },
441
+ "archivedAt": {
442
+ "name": "archivedAt",
443
+ "type": "timestamp with time zone",
444
+ "primaryKey": false,
445
+ "notNull": false
446
+ }
447
+ },
448
+ "indexes": {
449
+ "chatv3_room_tenant_channel_slug_unique": {
450
+ "name": "chatv3_room_tenant_channel_slug_unique",
451
+ "columns": [
452
+ {
453
+ "expression": "tenantId",
454
+ "isExpression": false,
455
+ "asc": true,
456
+ "nulls": "last"
457
+ },
458
+ {
459
+ "expression": "channelId",
460
+ "isExpression": false,
461
+ "asc": true,
462
+ "nulls": "last"
463
+ },
464
+ {
465
+ "expression": "slug",
466
+ "isExpression": false,
467
+ "asc": true,
468
+ "nulls": "last"
469
+ }
470
+ ],
471
+ "isUnique": true,
472
+ "concurrently": false,
473
+ "method": "btree",
474
+ "with": {}
475
+ },
476
+ "chatv3_room_idx_tenant_channel_status": {
477
+ "name": "chatv3_room_idx_tenant_channel_status",
478
+ "columns": [
479
+ {
480
+ "expression": "tenantId",
481
+ "isExpression": false,
482
+ "asc": true,
483
+ "nulls": "last"
484
+ },
485
+ {
486
+ "expression": "channelId",
487
+ "isExpression": false,
488
+ "asc": true,
489
+ "nulls": "last"
490
+ },
491
+ {
492
+ "expression": "status",
493
+ "isExpression": false,
494
+ "asc": true,
495
+ "nulls": "last"
496
+ }
497
+ ],
498
+ "isUnique": false,
499
+ "concurrently": false,
500
+ "method": "btree",
501
+ "with": {}
502
+ },
503
+ "chatv3_room_idx_tenant_last_message": {
504
+ "name": "chatv3_room_idx_tenant_last_message",
505
+ "columns": [
506
+ {
507
+ "expression": "tenantId",
508
+ "isExpression": false,
509
+ "asc": true,
510
+ "nulls": "last"
511
+ },
512
+ {
513
+ "expression": "lastMessageAt",
514
+ "isExpression": false,
515
+ "asc": true,
516
+ "nulls": "last"
517
+ }
518
+ ],
519
+ "isUnique": false,
520
+ "concurrently": false,
521
+ "method": "btree",
522
+ "with": {}
523
+ }
524
+ },
525
+ "foreignKeys": {
526
+ "chatv3-rooms_channelId_chatv3-channels_id_fk": {
527
+ "name": "chatv3-rooms_channelId_chatv3-channels_id_fk",
528
+ "tableFrom": "chatv3-rooms",
529
+ "tableTo": "chatv3-channels",
530
+ "columnsFrom": [
531
+ "channelId"
532
+ ],
533
+ "columnsTo": [
534
+ "id"
535
+ ],
536
+ "onDelete": "cascade",
537
+ "onUpdate": "no action"
538
+ }
539
+ },
540
+ "compositePrimaryKeys": {},
541
+ "uniqueConstraints": {},
542
+ "policies": {},
543
+ "checkConstraints": {},
544
+ "isRLSEnabled": false
545
+ },
546
+ "public.chatv3-members": {
547
+ "name": "chatv3-members",
548
+ "schema": "",
549
+ "columns": {
550
+ "id": {
551
+ "name": "id",
552
+ "type": "uuid",
553
+ "primaryKey": true,
554
+ "notNull": true,
555
+ "default": "gen_random_uuid()"
556
+ },
557
+ "tenantId": {
558
+ "name": "tenantId",
559
+ "type": "text",
560
+ "primaryKey": false,
561
+ "notNull": true,
562
+ "default": "'default'"
563
+ },
564
+ "channelId": {
565
+ "name": "channelId",
566
+ "type": "uuid",
567
+ "primaryKey": false,
568
+ "notNull": true
569
+ },
570
+ "handle": {
571
+ "name": "handle",
572
+ "type": "text",
573
+ "primaryKey": false,
574
+ "notNull": true
575
+ },
576
+ "displayName": {
577
+ "name": "displayName",
578
+ "type": "text",
579
+ "primaryKey": false,
580
+ "notNull": false
581
+ },
582
+ "actorKind": {
583
+ "name": "actorKind",
584
+ "type": "text",
585
+ "primaryKey": false,
586
+ "notNull": true,
587
+ "default": "'agent'"
588
+ },
589
+ "roleKey": {
590
+ "name": "roleKey",
591
+ "type": "text",
592
+ "primaryKey": false,
593
+ "notNull": true,
594
+ "default": "'member'"
595
+ },
596
+ "status": {
597
+ "name": "status",
598
+ "type": "text",
599
+ "primaryKey": false,
600
+ "notNull": true,
601
+ "default": "'active'"
602
+ },
603
+ "tokenHash": {
604
+ "name": "tokenHash",
605
+ "type": "text",
606
+ "primaryKey": false,
607
+ "notNull": true
608
+ },
609
+ "joinedViaKeyId": {
610
+ "name": "joinedViaKeyId",
611
+ "type": "uuid",
612
+ "primaryKey": false,
613
+ "notNull": false
614
+ },
615
+ "userId": {
616
+ "name": "userId",
617
+ "type": "text",
618
+ "primaryKey": false,
619
+ "notNull": false
620
+ },
621
+ "lastSeenAt": {
622
+ "name": "lastSeenAt",
623
+ "type": "timestamp with time zone",
624
+ "primaryKey": false,
625
+ "notNull": false
626
+ },
627
+ "joinedAt": {
628
+ "name": "joinedAt",
629
+ "type": "timestamp with time zone",
630
+ "primaryKey": false,
631
+ "notNull": true,
632
+ "default": "now()"
633
+ },
634
+ "removedAt": {
635
+ "name": "removedAt",
636
+ "type": "timestamp with time zone",
637
+ "primaryKey": false,
638
+ "notNull": false
639
+ },
640
+ "updatedAt": {
641
+ "name": "updatedAt",
642
+ "type": "timestamp with time zone",
643
+ "primaryKey": false,
644
+ "notNull": true,
645
+ "default": "now()"
646
+ }
647
+ },
648
+ "indexes": {
649
+ "chatv3_member_tenant_channel_handle_unique": {
650
+ "name": "chatv3_member_tenant_channel_handle_unique",
651
+ "columns": [
652
+ {
653
+ "expression": "tenantId",
654
+ "isExpression": false,
655
+ "asc": true,
656
+ "nulls": "last"
657
+ },
658
+ {
659
+ "expression": "channelId",
660
+ "isExpression": false,
661
+ "asc": true,
662
+ "nulls": "last"
663
+ },
664
+ {
665
+ "expression": "handle",
666
+ "isExpression": false,
667
+ "asc": true,
668
+ "nulls": "last"
669
+ }
670
+ ],
671
+ "isUnique": true,
672
+ "concurrently": false,
673
+ "method": "btree",
674
+ "with": {}
675
+ },
676
+ "chatv3_member_idx_tenant_channel_status": {
677
+ "name": "chatv3_member_idx_tenant_channel_status",
678
+ "columns": [
679
+ {
680
+ "expression": "tenantId",
681
+ "isExpression": false,
682
+ "asc": true,
683
+ "nulls": "last"
684
+ },
685
+ {
686
+ "expression": "channelId",
687
+ "isExpression": false,
688
+ "asc": true,
689
+ "nulls": "last"
690
+ },
691
+ {
692
+ "expression": "status",
693
+ "isExpression": false,
694
+ "asc": true,
695
+ "nulls": "last"
696
+ }
697
+ ],
698
+ "isUnique": false,
699
+ "concurrently": false,
700
+ "method": "btree",
701
+ "with": {}
702
+ },
703
+ "chatv3_member_idx_tenant_user": {
704
+ "name": "chatv3_member_idx_tenant_user",
705
+ "columns": [
706
+ {
707
+ "expression": "tenantId",
708
+ "isExpression": false,
709
+ "asc": true,
710
+ "nulls": "last"
711
+ },
712
+ {
713
+ "expression": "userId",
714
+ "isExpression": false,
715
+ "asc": true,
716
+ "nulls": "last"
717
+ }
718
+ ],
719
+ "isUnique": false,
720
+ "concurrently": false,
721
+ "method": "btree",
722
+ "with": {}
723
+ }
724
+ },
725
+ "foreignKeys": {
726
+ "chatv3-members_channelId_chatv3-channels_id_fk": {
727
+ "name": "chatv3-members_channelId_chatv3-channels_id_fk",
728
+ "tableFrom": "chatv3-members",
729
+ "tableTo": "chatv3-channels",
730
+ "columnsFrom": [
731
+ "channelId"
732
+ ],
733
+ "columnsTo": [
734
+ "id"
735
+ ],
736
+ "onDelete": "cascade",
737
+ "onUpdate": "no action"
738
+ }
739
+ },
740
+ "compositePrimaryKeys": {},
741
+ "uniqueConstraints": {},
742
+ "policies": {},
743
+ "checkConstraints": {},
744
+ "isRLSEnabled": false
745
+ },
746
+ "public.chatv3-room-cursors": {
747
+ "name": "chatv3-room-cursors",
748
+ "schema": "",
749
+ "columns": {
750
+ "id": {
751
+ "name": "id",
752
+ "type": "uuid",
753
+ "primaryKey": true,
754
+ "notNull": true,
755
+ "default": "gen_random_uuid()"
756
+ },
757
+ "tenantId": {
758
+ "name": "tenantId",
759
+ "type": "text",
760
+ "primaryKey": false,
761
+ "notNull": true,
762
+ "default": "'default'"
763
+ },
764
+ "roomId": {
765
+ "name": "roomId",
766
+ "type": "uuid",
767
+ "primaryKey": false,
768
+ "notNull": true
769
+ },
770
+ "memberId": {
771
+ "name": "memberId",
772
+ "type": "uuid",
773
+ "primaryKey": false,
774
+ "notNull": true
775
+ },
776
+ "lastReadSeq": {
777
+ "name": "lastReadSeq",
778
+ "type": "integer",
779
+ "primaryKey": false,
780
+ "notNull": true,
781
+ "default": 0
782
+ },
783
+ "deliveredSeq": {
784
+ "name": "deliveredSeq",
785
+ "type": "integer",
786
+ "primaryKey": false,
787
+ "notNull": true,
788
+ "default": 0
789
+ },
790
+ "ackSeq": {
791
+ "name": "ackSeq",
792
+ "type": "integer",
793
+ "primaryKey": false,
794
+ "notNull": true,
795
+ "default": 0
796
+ },
797
+ "lastReadAt": {
798
+ "name": "lastReadAt",
799
+ "type": "timestamp with time zone",
800
+ "primaryKey": false,
801
+ "notNull": false
802
+ },
803
+ "updatedAt": {
804
+ "name": "updatedAt",
805
+ "type": "timestamp with time zone",
806
+ "primaryKey": false,
807
+ "notNull": true,
808
+ "default": "now()"
809
+ }
810
+ },
811
+ "indexes": {
812
+ "chatv3_room_cursor_room_member_unique": {
813
+ "name": "chatv3_room_cursor_room_member_unique",
814
+ "columns": [
815
+ {
816
+ "expression": "roomId",
817
+ "isExpression": false,
818
+ "asc": true,
819
+ "nulls": "last"
820
+ },
821
+ {
822
+ "expression": "memberId",
823
+ "isExpression": false,
824
+ "asc": true,
825
+ "nulls": "last"
826
+ }
827
+ ],
828
+ "isUnique": true,
829
+ "concurrently": false,
830
+ "method": "btree",
831
+ "with": {}
832
+ },
833
+ "chatv3_room_cursor_idx_member": {
834
+ "name": "chatv3_room_cursor_idx_member",
835
+ "columns": [
836
+ {
837
+ "expression": "tenantId",
838
+ "isExpression": false,
839
+ "asc": true,
840
+ "nulls": "last"
841
+ },
842
+ {
843
+ "expression": "memberId",
844
+ "isExpression": false,
845
+ "asc": true,
846
+ "nulls": "last"
847
+ }
848
+ ],
849
+ "isUnique": false,
850
+ "concurrently": false,
851
+ "method": "btree",
852
+ "with": {}
853
+ }
854
+ },
855
+ "foreignKeys": {
856
+ "chatv3-room-cursors_roomId_chatv3-rooms_id_fk": {
857
+ "name": "chatv3-room-cursors_roomId_chatv3-rooms_id_fk",
858
+ "tableFrom": "chatv3-room-cursors",
859
+ "tableTo": "chatv3-rooms",
860
+ "columnsFrom": [
861
+ "roomId"
862
+ ],
863
+ "columnsTo": [
864
+ "id"
865
+ ],
866
+ "onDelete": "cascade",
867
+ "onUpdate": "no action"
868
+ },
869
+ "chatv3-room-cursors_memberId_chatv3-members_id_fk": {
870
+ "name": "chatv3-room-cursors_memberId_chatv3-members_id_fk",
871
+ "tableFrom": "chatv3-room-cursors",
872
+ "tableTo": "chatv3-members",
873
+ "columnsFrom": [
874
+ "memberId"
875
+ ],
876
+ "columnsTo": [
877
+ "id"
878
+ ],
879
+ "onDelete": "cascade",
880
+ "onUpdate": "no action"
881
+ }
882
+ },
883
+ "compositePrimaryKeys": {},
884
+ "uniqueConstraints": {},
885
+ "policies": {},
886
+ "checkConstraints": {},
887
+ "isRLSEnabled": false
888
+ },
889
+ "public.chatv3-access-keys": {
890
+ "name": "chatv3-access-keys",
891
+ "schema": "",
892
+ "columns": {
893
+ "id": {
894
+ "name": "id",
895
+ "type": "uuid",
896
+ "primaryKey": true,
897
+ "notNull": true,
898
+ "default": "gen_random_uuid()"
899
+ },
900
+ "tenantId": {
901
+ "name": "tenantId",
902
+ "type": "text",
903
+ "primaryKey": false,
904
+ "notNull": true,
905
+ "default": "'default'"
906
+ },
907
+ "channelId": {
908
+ "name": "channelId",
909
+ "type": "uuid",
910
+ "primaryKey": false,
911
+ "notNull": true
912
+ },
913
+ "keyId": {
914
+ "name": "keyId",
915
+ "type": "text",
916
+ "primaryKey": false,
917
+ "notNull": true
918
+ },
919
+ "verifierHash": {
920
+ "name": "verifierHash",
921
+ "type": "text",
922
+ "primaryKey": false,
923
+ "notNull": true
924
+ },
925
+ "label": {
926
+ "name": "label",
927
+ "type": "text",
928
+ "primaryKey": false,
929
+ "notNull": false
930
+ },
931
+ "roleKey": {
932
+ "name": "roleKey",
933
+ "type": "text",
934
+ "primaryKey": false,
935
+ "notNull": true,
936
+ "default": "'member'"
937
+ },
938
+ "status": {
939
+ "name": "status",
940
+ "type": "text",
941
+ "primaryKey": false,
942
+ "notNull": true,
943
+ "default": "'active'"
944
+ },
945
+ "epoch": {
946
+ "name": "epoch",
947
+ "type": "integer",
948
+ "primaryKey": false,
949
+ "notNull": true,
950
+ "default": 1
951
+ },
952
+ "createdBy": {
953
+ "name": "createdBy",
954
+ "type": "text",
955
+ "primaryKey": false,
956
+ "notNull": false
957
+ },
958
+ "createdAt": {
959
+ "name": "createdAt",
960
+ "type": "timestamp with time zone",
961
+ "primaryKey": false,
962
+ "notNull": true,
963
+ "default": "now()"
964
+ },
965
+ "revokedAt": {
966
+ "name": "revokedAt",
967
+ "type": "timestamp with time zone",
968
+ "primaryKey": false,
969
+ "notNull": false
970
+ },
971
+ "lastUsedAt": {
972
+ "name": "lastUsedAt",
973
+ "type": "timestamp with time zone",
974
+ "primaryKey": false,
975
+ "notNull": false
976
+ }
977
+ },
978
+ "indexes": {
979
+ "chatv3_access_key_tenant_key_id_unique": {
980
+ "name": "chatv3_access_key_tenant_key_id_unique",
981
+ "columns": [
982
+ {
983
+ "expression": "tenantId",
984
+ "isExpression": false,
985
+ "asc": true,
986
+ "nulls": "last"
987
+ },
988
+ {
989
+ "expression": "keyId",
990
+ "isExpression": false,
991
+ "asc": true,
992
+ "nulls": "last"
993
+ }
994
+ ],
995
+ "isUnique": true,
996
+ "concurrently": false,
997
+ "method": "btree",
998
+ "with": {}
999
+ },
1000
+ "chatv3_access_key_idx_channel_status": {
1001
+ "name": "chatv3_access_key_idx_channel_status",
1002
+ "columns": [
1003
+ {
1004
+ "expression": "tenantId",
1005
+ "isExpression": false,
1006
+ "asc": true,
1007
+ "nulls": "last"
1008
+ },
1009
+ {
1010
+ "expression": "channelId",
1011
+ "isExpression": false,
1012
+ "asc": true,
1013
+ "nulls": "last"
1014
+ },
1015
+ {
1016
+ "expression": "status",
1017
+ "isExpression": false,
1018
+ "asc": true,
1019
+ "nulls": "last"
1020
+ }
1021
+ ],
1022
+ "isUnique": false,
1023
+ "concurrently": false,
1024
+ "method": "btree",
1025
+ "with": {}
1026
+ }
1027
+ },
1028
+ "foreignKeys": {
1029
+ "chatv3-access-keys_channelId_chatv3-channels_id_fk": {
1030
+ "name": "chatv3-access-keys_channelId_chatv3-channels_id_fk",
1031
+ "tableFrom": "chatv3-access-keys",
1032
+ "tableTo": "chatv3-channels",
1033
+ "columnsFrom": [
1034
+ "channelId"
1035
+ ],
1036
+ "columnsTo": [
1037
+ "id"
1038
+ ],
1039
+ "onDelete": "cascade",
1040
+ "onUpdate": "no action"
1041
+ }
1042
+ },
1043
+ "compositePrimaryKeys": {},
1044
+ "uniqueConstraints": {},
1045
+ "policies": {},
1046
+ "checkConstraints": {},
1047
+ "isRLSEnabled": false
1048
+ },
1049
+ "public.chatv3-room-epochs": {
1050
+ "name": "chatv3-room-epochs",
1051
+ "schema": "",
1052
+ "columns": {
1053
+ "id": {
1054
+ "name": "id",
1055
+ "type": "uuid",
1056
+ "primaryKey": true,
1057
+ "notNull": true,
1058
+ "default": "gen_random_uuid()"
1059
+ },
1060
+ "tenantId": {
1061
+ "name": "tenantId",
1062
+ "type": "text",
1063
+ "primaryKey": false,
1064
+ "notNull": true,
1065
+ "default": "'default'"
1066
+ },
1067
+ "roomId": {
1068
+ "name": "roomId",
1069
+ "type": "uuid",
1070
+ "primaryKey": false,
1071
+ "notNull": true
1072
+ },
1073
+ "epoch": {
1074
+ "name": "epoch",
1075
+ "type": "integer",
1076
+ "primaryKey": false,
1077
+ "notNull": true
1078
+ },
1079
+ "cipherSuite": {
1080
+ "name": "cipherSuite",
1081
+ "type": "text",
1082
+ "primaryKey": false,
1083
+ "notNull": true
1084
+ },
1085
+ "wrappedKeyBlob": {
1086
+ "name": "wrappedKeyBlob",
1087
+ "type": "text",
1088
+ "primaryKey": false,
1089
+ "notNull": true
1090
+ },
1091
+ "kdfMeta": {
1092
+ "name": "kdfMeta",
1093
+ "type": "jsonb",
1094
+ "primaryKey": false,
1095
+ "notNull": true,
1096
+ "default": "'{}'::jsonb"
1097
+ },
1098
+ "status": {
1099
+ "name": "status",
1100
+ "type": "text",
1101
+ "primaryKey": false,
1102
+ "notNull": true,
1103
+ "default": "'active'"
1104
+ },
1105
+ "createdBy": {
1106
+ "name": "createdBy",
1107
+ "type": "text",
1108
+ "primaryKey": false,
1109
+ "notNull": false
1110
+ },
1111
+ "createdAt": {
1112
+ "name": "createdAt",
1113
+ "type": "timestamp with time zone",
1114
+ "primaryKey": false,
1115
+ "notNull": true,
1116
+ "default": "now()"
1117
+ },
1118
+ "retiredAt": {
1119
+ "name": "retiredAt",
1120
+ "type": "timestamp with time zone",
1121
+ "primaryKey": false,
1122
+ "notNull": false
1123
+ }
1124
+ },
1125
+ "indexes": {
1126
+ "chatv3_room_epoch_room_epoch_unique": {
1127
+ "name": "chatv3_room_epoch_room_epoch_unique",
1128
+ "columns": [
1129
+ {
1130
+ "expression": "roomId",
1131
+ "isExpression": false,
1132
+ "asc": true,
1133
+ "nulls": "last"
1134
+ },
1135
+ {
1136
+ "expression": "epoch",
1137
+ "isExpression": false,
1138
+ "asc": true,
1139
+ "nulls": "last"
1140
+ }
1141
+ ],
1142
+ "isUnique": true,
1143
+ "concurrently": false,
1144
+ "method": "btree",
1145
+ "with": {}
1146
+ },
1147
+ "chatv3_room_epoch_idx_room_status": {
1148
+ "name": "chatv3_room_epoch_idx_room_status",
1149
+ "columns": [
1150
+ {
1151
+ "expression": "tenantId",
1152
+ "isExpression": false,
1153
+ "asc": true,
1154
+ "nulls": "last"
1155
+ },
1156
+ {
1157
+ "expression": "roomId",
1158
+ "isExpression": false,
1159
+ "asc": true,
1160
+ "nulls": "last"
1161
+ },
1162
+ {
1163
+ "expression": "status",
1164
+ "isExpression": false,
1165
+ "asc": true,
1166
+ "nulls": "last"
1167
+ }
1168
+ ],
1169
+ "isUnique": false,
1170
+ "concurrently": false,
1171
+ "method": "btree",
1172
+ "with": {}
1173
+ }
1174
+ },
1175
+ "foreignKeys": {
1176
+ "chatv3-room-epochs_roomId_chatv3-rooms_id_fk": {
1177
+ "name": "chatv3-room-epochs_roomId_chatv3-rooms_id_fk",
1178
+ "tableFrom": "chatv3-room-epochs",
1179
+ "tableTo": "chatv3-rooms",
1180
+ "columnsFrom": [
1181
+ "roomId"
1182
+ ],
1183
+ "columnsTo": [
1184
+ "id"
1185
+ ],
1186
+ "onDelete": "cascade",
1187
+ "onUpdate": "no action"
1188
+ }
1189
+ },
1190
+ "compositePrimaryKeys": {},
1191
+ "uniqueConstraints": {},
1192
+ "policies": {},
1193
+ "checkConstraints": {},
1194
+ "isRLSEnabled": false
1195
+ },
1196
+ "public.chatv3-member-devices": {
1197
+ "name": "chatv3-member-devices",
1198
+ "schema": "",
1199
+ "columns": {
1200
+ "id": {
1201
+ "name": "id",
1202
+ "type": "uuid",
1203
+ "primaryKey": true,
1204
+ "notNull": true,
1205
+ "default": "gen_random_uuid()"
1206
+ },
1207
+ "tenantId": {
1208
+ "name": "tenantId",
1209
+ "type": "text",
1210
+ "primaryKey": false,
1211
+ "notNull": true,
1212
+ "default": "'default'"
1213
+ },
1214
+ "memberId": {
1215
+ "name": "memberId",
1216
+ "type": "uuid",
1217
+ "primaryKey": false,
1218
+ "notNull": true
1219
+ },
1220
+ "deviceLabel": {
1221
+ "name": "deviceLabel",
1222
+ "type": "text",
1223
+ "primaryKey": false,
1224
+ "notNull": false
1225
+ },
1226
+ "identityPublicKey": {
1227
+ "name": "identityPublicKey",
1228
+ "type": "text",
1229
+ "primaryKey": false,
1230
+ "notNull": true
1231
+ },
1232
+ "signingPublicKey": {
1233
+ "name": "signingPublicKey",
1234
+ "type": "text",
1235
+ "primaryKey": false,
1236
+ "notNull": false
1237
+ },
1238
+ "status": {
1239
+ "name": "status",
1240
+ "type": "text",
1241
+ "primaryKey": false,
1242
+ "notNull": true,
1243
+ "default": "'active'"
1244
+ },
1245
+ "createdAt": {
1246
+ "name": "createdAt",
1247
+ "type": "timestamp with time zone",
1248
+ "primaryKey": false,
1249
+ "notNull": true,
1250
+ "default": "now()"
1251
+ },
1252
+ "lastSeenAt": {
1253
+ "name": "lastSeenAt",
1254
+ "type": "timestamp with time zone",
1255
+ "primaryKey": false,
1256
+ "notNull": false
1257
+ },
1258
+ "revokedAt": {
1259
+ "name": "revokedAt",
1260
+ "type": "timestamp with time zone",
1261
+ "primaryKey": false,
1262
+ "notNull": false
1263
+ }
1264
+ },
1265
+ "indexes": {
1266
+ "chatv3_member_device_idx_member_status": {
1267
+ "name": "chatv3_member_device_idx_member_status",
1268
+ "columns": [
1269
+ {
1270
+ "expression": "tenantId",
1271
+ "isExpression": false,
1272
+ "asc": true,
1273
+ "nulls": "last"
1274
+ },
1275
+ {
1276
+ "expression": "memberId",
1277
+ "isExpression": false,
1278
+ "asc": true,
1279
+ "nulls": "last"
1280
+ },
1281
+ {
1282
+ "expression": "status",
1283
+ "isExpression": false,
1284
+ "asc": true,
1285
+ "nulls": "last"
1286
+ }
1287
+ ],
1288
+ "isUnique": false,
1289
+ "concurrently": false,
1290
+ "method": "btree",
1291
+ "with": {}
1292
+ }
1293
+ },
1294
+ "foreignKeys": {
1295
+ "chatv3-member-devices_memberId_chatv3-members_id_fk": {
1296
+ "name": "chatv3-member-devices_memberId_chatv3-members_id_fk",
1297
+ "tableFrom": "chatv3-member-devices",
1298
+ "tableTo": "chatv3-members",
1299
+ "columnsFrom": [
1300
+ "memberId"
1301
+ ],
1302
+ "columnsTo": [
1303
+ "id"
1304
+ ],
1305
+ "onDelete": "cascade",
1306
+ "onUpdate": "no action"
1307
+ }
1308
+ },
1309
+ "compositePrimaryKeys": {},
1310
+ "uniqueConstraints": {},
1311
+ "policies": {},
1312
+ "checkConstraints": {},
1313
+ "isRLSEnabled": false
1314
+ },
1315
+ "public.chatv3-device-key-packages": {
1316
+ "name": "chatv3-device-key-packages",
1317
+ "schema": "",
1318
+ "columns": {
1319
+ "id": {
1320
+ "name": "id",
1321
+ "type": "uuid",
1322
+ "primaryKey": true,
1323
+ "notNull": true,
1324
+ "default": "gen_random_uuid()"
1325
+ },
1326
+ "tenantId": {
1327
+ "name": "tenantId",
1328
+ "type": "text",
1329
+ "primaryKey": false,
1330
+ "notNull": true,
1331
+ "default": "'default'"
1332
+ },
1333
+ "deviceId": {
1334
+ "name": "deviceId",
1335
+ "type": "uuid",
1336
+ "primaryKey": false,
1337
+ "notNull": true
1338
+ },
1339
+ "kind": {
1340
+ "name": "kind",
1341
+ "type": "text",
1342
+ "primaryKey": false,
1343
+ "notNull": true,
1344
+ "default": "'v0'"
1345
+ },
1346
+ "packageBlob": {
1347
+ "name": "packageBlob",
1348
+ "type": "text",
1349
+ "primaryKey": false,
1350
+ "notNull": true
1351
+ },
1352
+ "status": {
1353
+ "name": "status",
1354
+ "type": "text",
1355
+ "primaryKey": false,
1356
+ "notNull": true,
1357
+ "default": "'available'"
1358
+ },
1359
+ "createdAt": {
1360
+ "name": "createdAt",
1361
+ "type": "timestamp with time zone",
1362
+ "primaryKey": false,
1363
+ "notNull": true,
1364
+ "default": "now()"
1365
+ },
1366
+ "consumedAt": {
1367
+ "name": "consumedAt",
1368
+ "type": "timestamp with time zone",
1369
+ "primaryKey": false,
1370
+ "notNull": false
1371
+ }
1372
+ },
1373
+ "indexes": {
1374
+ "chatv3_device_key_package_idx_device_status": {
1375
+ "name": "chatv3_device_key_package_idx_device_status",
1376
+ "columns": [
1377
+ {
1378
+ "expression": "deviceId",
1379
+ "isExpression": false,
1380
+ "asc": true,
1381
+ "nulls": "last"
1382
+ },
1383
+ {
1384
+ "expression": "status",
1385
+ "isExpression": false,
1386
+ "asc": true,
1387
+ "nulls": "last"
1388
+ }
1389
+ ],
1390
+ "isUnique": false,
1391
+ "concurrently": false,
1392
+ "method": "btree",
1393
+ "with": {}
1394
+ }
1395
+ },
1396
+ "foreignKeys": {
1397
+ "chatv3-device-key-packages_deviceId_chatv3-member-devices_id_fk": {
1398
+ "name": "chatv3-device-key-packages_deviceId_chatv3-member-devices_id_fk",
1399
+ "tableFrom": "chatv3-device-key-packages",
1400
+ "tableTo": "chatv3-member-devices",
1401
+ "columnsFrom": [
1402
+ "deviceId"
1403
+ ],
1404
+ "columnsTo": [
1405
+ "id"
1406
+ ],
1407
+ "onDelete": "cascade",
1408
+ "onUpdate": "no action"
1409
+ }
1410
+ },
1411
+ "compositePrimaryKeys": {},
1412
+ "uniqueConstraints": {},
1413
+ "policies": {},
1414
+ "checkConstraints": {},
1415
+ "isRLSEnabled": false
1416
+ },
1417
+ "public.chatv3-welcome-envelopes": {
1418
+ "name": "chatv3-welcome-envelopes",
1419
+ "schema": "",
1420
+ "columns": {
1421
+ "id": {
1422
+ "name": "id",
1423
+ "type": "uuid",
1424
+ "primaryKey": true,
1425
+ "notNull": true,
1426
+ "default": "gen_random_uuid()"
1427
+ },
1428
+ "tenantId": {
1429
+ "name": "tenantId",
1430
+ "type": "text",
1431
+ "primaryKey": false,
1432
+ "notNull": true,
1433
+ "default": "'default'"
1434
+ },
1435
+ "roomId": {
1436
+ "name": "roomId",
1437
+ "type": "uuid",
1438
+ "primaryKey": false,
1439
+ "notNull": true
1440
+ },
1441
+ "epoch": {
1442
+ "name": "epoch",
1443
+ "type": "integer",
1444
+ "primaryKey": false,
1445
+ "notNull": true
1446
+ },
1447
+ "targetDeviceId": {
1448
+ "name": "targetDeviceId",
1449
+ "type": "uuid",
1450
+ "primaryKey": false,
1451
+ "notNull": true
1452
+ },
1453
+ "envelopeBlob": {
1454
+ "name": "envelopeBlob",
1455
+ "type": "text",
1456
+ "primaryKey": false,
1457
+ "notNull": true
1458
+ },
1459
+ "status": {
1460
+ "name": "status",
1461
+ "type": "text",
1462
+ "primaryKey": false,
1463
+ "notNull": true,
1464
+ "default": "'pending'"
1465
+ },
1466
+ "createdBy": {
1467
+ "name": "createdBy",
1468
+ "type": "text",
1469
+ "primaryKey": false,
1470
+ "notNull": false
1471
+ },
1472
+ "createdAt": {
1473
+ "name": "createdAt",
1474
+ "type": "timestamp with time zone",
1475
+ "primaryKey": false,
1476
+ "notNull": true,
1477
+ "default": "now()"
1478
+ },
1479
+ "claimedAt": {
1480
+ "name": "claimedAt",
1481
+ "type": "timestamp with time zone",
1482
+ "primaryKey": false,
1483
+ "notNull": false
1484
+ }
1485
+ },
1486
+ "indexes": {
1487
+ "chatv3_welcome_envelope_idx_target_status": {
1488
+ "name": "chatv3_welcome_envelope_idx_target_status",
1489
+ "columns": [
1490
+ {
1491
+ "expression": "targetDeviceId",
1492
+ "isExpression": false,
1493
+ "asc": true,
1494
+ "nulls": "last"
1495
+ },
1496
+ {
1497
+ "expression": "status",
1498
+ "isExpression": false,
1499
+ "asc": true,
1500
+ "nulls": "last"
1501
+ }
1502
+ ],
1503
+ "isUnique": false,
1504
+ "concurrently": false,
1505
+ "method": "btree",
1506
+ "with": {}
1507
+ },
1508
+ "chatv3_welcome_envelope_idx_room_epoch": {
1509
+ "name": "chatv3_welcome_envelope_idx_room_epoch",
1510
+ "columns": [
1511
+ {
1512
+ "expression": "roomId",
1513
+ "isExpression": false,
1514
+ "asc": true,
1515
+ "nulls": "last"
1516
+ },
1517
+ {
1518
+ "expression": "epoch",
1519
+ "isExpression": false,
1520
+ "asc": true,
1521
+ "nulls": "last"
1522
+ }
1523
+ ],
1524
+ "isUnique": false,
1525
+ "concurrently": false,
1526
+ "method": "btree",
1527
+ "with": {}
1528
+ }
1529
+ },
1530
+ "foreignKeys": {
1531
+ "chatv3-welcome-envelopes_roomId_chatv3-rooms_id_fk": {
1532
+ "name": "chatv3-welcome-envelopes_roomId_chatv3-rooms_id_fk",
1533
+ "tableFrom": "chatv3-welcome-envelopes",
1534
+ "tableTo": "chatv3-rooms",
1535
+ "columnsFrom": [
1536
+ "roomId"
1537
+ ],
1538
+ "columnsTo": [
1539
+ "id"
1540
+ ],
1541
+ "onDelete": "cascade",
1542
+ "onUpdate": "no action"
1543
+ },
1544
+ "chatv3-welcome-envelopes_targetDeviceId_chatv3-member-devices_id_fk": {
1545
+ "name": "chatv3-welcome-envelopes_targetDeviceId_chatv3-member-devices_id_fk",
1546
+ "tableFrom": "chatv3-welcome-envelopes",
1547
+ "tableTo": "chatv3-member-devices",
1548
+ "columnsFrom": [
1549
+ "targetDeviceId"
1550
+ ],
1551
+ "columnsTo": [
1552
+ "id"
1553
+ ],
1554
+ "onDelete": "cascade",
1555
+ "onUpdate": "no action"
1556
+ }
1557
+ },
1558
+ "compositePrimaryKeys": {},
1559
+ "uniqueConstraints": {},
1560
+ "policies": {},
1561
+ "checkConstraints": {},
1562
+ "isRLSEnabled": false
1563
+ },
1564
+ "public.chatv3-messages": {
1565
+ "name": "chatv3-messages",
1566
+ "schema": "",
1567
+ "columns": {
1568
+ "id": {
1569
+ "name": "id",
1570
+ "type": "uuid",
1571
+ "primaryKey": true,
1572
+ "notNull": true,
1573
+ "default": "gen_random_uuid()"
1574
+ },
1575
+ "tenantId": {
1576
+ "name": "tenantId",
1577
+ "type": "text",
1578
+ "primaryKey": false,
1579
+ "notNull": true,
1580
+ "default": "'default'"
1581
+ },
1582
+ "roomId": {
1583
+ "name": "roomId",
1584
+ "type": "uuid",
1585
+ "primaryKey": false,
1586
+ "notNull": true
1587
+ },
1588
+ "seq": {
1589
+ "name": "seq",
1590
+ "type": "integer",
1591
+ "primaryKey": false,
1592
+ "notNull": true
1593
+ },
1594
+ "senderMemberId": {
1595
+ "name": "senderMemberId",
1596
+ "type": "uuid",
1597
+ "primaryKey": false,
1598
+ "notNull": true
1599
+ },
1600
+ "senderDeviceId": {
1601
+ "name": "senderDeviceId",
1602
+ "type": "uuid",
1603
+ "primaryKey": false,
1604
+ "notNull": false
1605
+ },
1606
+ "kind": {
1607
+ "name": "kind",
1608
+ "type": "text",
1609
+ "primaryKey": false,
1610
+ "notNull": true,
1611
+ "default": "'message'"
1612
+ },
1613
+ "protocolVersion": {
1614
+ "name": "protocolVersion",
1615
+ "type": "integer",
1616
+ "primaryKey": false,
1617
+ "notNull": true,
1618
+ "default": 1
1619
+ },
1620
+ "cipherSuite": {
1621
+ "name": "cipherSuite",
1622
+ "type": "text",
1623
+ "primaryKey": false,
1624
+ "notNull": true
1625
+ },
1626
+ "epoch": {
1627
+ "name": "epoch",
1628
+ "type": "integer",
1629
+ "primaryKey": false,
1630
+ "notNull": true
1631
+ },
1632
+ "ciphertext": {
1633
+ "name": "ciphertext",
1634
+ "type": "text",
1635
+ "primaryKey": false,
1636
+ "notNull": true
1637
+ },
1638
+ "nonce": {
1639
+ "name": "nonce",
1640
+ "type": "text",
1641
+ "primaryKey": false,
1642
+ "notNull": true
1643
+ },
1644
+ "aad": {
1645
+ "name": "aad",
1646
+ "type": "text",
1647
+ "primaryKey": false,
1648
+ "notNull": false
1649
+ },
1650
+ "authTag": {
1651
+ "name": "authTag",
1652
+ "type": "text",
1653
+ "primaryKey": false,
1654
+ "notNull": false
1655
+ },
1656
+ "mentions": {
1657
+ "name": "mentions",
1658
+ "type": "jsonb",
1659
+ "primaryKey": false,
1660
+ "notNull": true,
1661
+ "default": "'[]'::jsonb"
1662
+ },
1663
+ "replyToSeq": {
1664
+ "name": "replyToSeq",
1665
+ "type": "integer",
1666
+ "primaryKey": false,
1667
+ "notNull": false
1668
+ },
1669
+ "idempotencyKey": {
1670
+ "name": "idempotencyKey",
1671
+ "type": "text",
1672
+ "primaryKey": false,
1673
+ "notNull": false
1674
+ },
1675
+ "createdAt": {
1676
+ "name": "createdAt",
1677
+ "type": "timestamp with time zone",
1678
+ "primaryKey": false,
1679
+ "notNull": true,
1680
+ "default": "now()"
1681
+ }
1682
+ },
1683
+ "indexes": {
1684
+ "chatv3_message_room_seq_unique": {
1685
+ "name": "chatv3_message_room_seq_unique",
1686
+ "columns": [
1687
+ {
1688
+ "expression": "roomId",
1689
+ "isExpression": false,
1690
+ "asc": true,
1691
+ "nulls": "last"
1692
+ },
1693
+ {
1694
+ "expression": "seq",
1695
+ "isExpression": false,
1696
+ "asc": true,
1697
+ "nulls": "last"
1698
+ }
1699
+ ],
1700
+ "isUnique": true,
1701
+ "concurrently": false,
1702
+ "method": "btree",
1703
+ "with": {}
1704
+ },
1705
+ "chatv3_message_room_idempotency_unique": {
1706
+ "name": "chatv3_message_room_idempotency_unique",
1707
+ "columns": [
1708
+ {
1709
+ "expression": "roomId",
1710
+ "isExpression": false,
1711
+ "asc": true,
1712
+ "nulls": "last"
1713
+ },
1714
+ {
1715
+ "expression": "idempotencyKey",
1716
+ "isExpression": false,
1717
+ "asc": true,
1718
+ "nulls": "last"
1719
+ }
1720
+ ],
1721
+ "isUnique": true,
1722
+ "concurrently": false,
1723
+ "method": "btree",
1724
+ "with": {}
1725
+ },
1726
+ "chatv3_message_idx_room_created": {
1727
+ "name": "chatv3_message_idx_room_created",
1728
+ "columns": [
1729
+ {
1730
+ "expression": "roomId",
1731
+ "isExpression": false,
1732
+ "asc": true,
1733
+ "nulls": "last"
1734
+ },
1735
+ {
1736
+ "expression": "createdAt",
1737
+ "isExpression": false,
1738
+ "asc": true,
1739
+ "nulls": "last"
1740
+ }
1741
+ ],
1742
+ "isUnique": false,
1743
+ "concurrently": false,
1744
+ "method": "btree",
1745
+ "with": {}
1746
+ },
1747
+ "chatv3_message_idx_tenant_room_kind": {
1748
+ "name": "chatv3_message_idx_tenant_room_kind",
1749
+ "columns": [
1750
+ {
1751
+ "expression": "tenantId",
1752
+ "isExpression": false,
1753
+ "asc": true,
1754
+ "nulls": "last"
1755
+ },
1756
+ {
1757
+ "expression": "roomId",
1758
+ "isExpression": false,
1759
+ "asc": true,
1760
+ "nulls": "last"
1761
+ },
1762
+ {
1763
+ "expression": "kind",
1764
+ "isExpression": false,
1765
+ "asc": true,
1766
+ "nulls": "last"
1767
+ }
1768
+ ],
1769
+ "isUnique": false,
1770
+ "concurrently": false,
1771
+ "method": "btree",
1772
+ "with": {}
1773
+ }
1774
+ },
1775
+ "foreignKeys": {
1776
+ "chatv3-messages_roomId_chatv3-rooms_id_fk": {
1777
+ "name": "chatv3-messages_roomId_chatv3-rooms_id_fk",
1778
+ "tableFrom": "chatv3-messages",
1779
+ "tableTo": "chatv3-rooms",
1780
+ "columnsFrom": [
1781
+ "roomId"
1782
+ ],
1783
+ "columnsTo": [
1784
+ "id"
1785
+ ],
1786
+ "onDelete": "cascade",
1787
+ "onUpdate": "no action"
1788
+ }
1789
+ },
1790
+ "compositePrimaryKeys": {},
1791
+ "uniqueConstraints": {},
1792
+ "policies": {},
1793
+ "checkConstraints": {},
1794
+ "isRLSEnabled": false
1795
+ },
1796
+ "public.chatv3-bindings": {
1797
+ "name": "chatv3-bindings",
1798
+ "schema": "",
1799
+ "columns": {
1800
+ "id": {
1801
+ "name": "id",
1802
+ "type": "uuid",
1803
+ "primaryKey": true,
1804
+ "notNull": true,
1805
+ "default": "gen_random_uuid()"
1806
+ },
1807
+ "tenantId": {
1808
+ "name": "tenantId",
1809
+ "type": "text",
1810
+ "primaryKey": false,
1811
+ "notNull": true,
1812
+ "default": "'default'"
1813
+ },
1814
+ "channelId": {
1815
+ "name": "channelId",
1816
+ "type": "uuid",
1817
+ "primaryKey": false,
1818
+ "notNull": true
1819
+ },
1820
+ "roomId": {
1821
+ "name": "roomId",
1822
+ "type": "uuid",
1823
+ "primaryKey": false,
1824
+ "notNull": false
1825
+ },
1826
+ "bindingType": {
1827
+ "name": "bindingType",
1828
+ "type": "text",
1829
+ "primaryKey": false,
1830
+ "notNull": true
1831
+ },
1832
+ "refId": {
1833
+ "name": "refId",
1834
+ "type": "text",
1835
+ "primaryKey": false,
1836
+ "notNull": false
1837
+ },
1838
+ "uri": {
1839
+ "name": "uri",
1840
+ "type": "text",
1841
+ "primaryKey": false,
1842
+ "notNull": false
1843
+ },
1844
+ "title": {
1845
+ "name": "title",
1846
+ "type": "text",
1847
+ "primaryKey": false,
1848
+ "notNull": false
1849
+ },
1850
+ "note": {
1851
+ "name": "note",
1852
+ "type": "text",
1853
+ "primaryKey": false,
1854
+ "notNull": false
1855
+ },
1856
+ "createdBy": {
1857
+ "name": "createdBy",
1858
+ "type": "text",
1859
+ "primaryKey": false,
1860
+ "notNull": false
1861
+ },
1862
+ "createdAt": {
1863
+ "name": "createdAt",
1864
+ "type": "timestamp with time zone",
1865
+ "primaryKey": false,
1866
+ "notNull": true,
1867
+ "default": "now()"
1868
+ }
1869
+ },
1870
+ "indexes": {
1871
+ "chatv3_binding_idx_channel_type": {
1872
+ "name": "chatv3_binding_idx_channel_type",
1873
+ "columns": [
1874
+ {
1875
+ "expression": "tenantId",
1876
+ "isExpression": false,
1877
+ "asc": true,
1878
+ "nulls": "last"
1879
+ },
1880
+ {
1881
+ "expression": "channelId",
1882
+ "isExpression": false,
1883
+ "asc": true,
1884
+ "nulls": "last"
1885
+ },
1886
+ {
1887
+ "expression": "bindingType",
1888
+ "isExpression": false,
1889
+ "asc": true,
1890
+ "nulls": "last"
1891
+ }
1892
+ ],
1893
+ "isUnique": false,
1894
+ "concurrently": false,
1895
+ "method": "btree",
1896
+ "with": {}
1897
+ },
1898
+ "chatv3_binding_idx_room": {
1899
+ "name": "chatv3_binding_idx_room",
1900
+ "columns": [
1901
+ {
1902
+ "expression": "roomId",
1903
+ "isExpression": false,
1904
+ "asc": true,
1905
+ "nulls": "last"
1906
+ }
1907
+ ],
1908
+ "isUnique": false,
1909
+ "concurrently": false,
1910
+ "method": "btree",
1911
+ "with": {}
1912
+ }
1913
+ },
1914
+ "foreignKeys": {
1915
+ "chatv3-bindings_channelId_chatv3-channels_id_fk": {
1916
+ "name": "chatv3-bindings_channelId_chatv3-channels_id_fk",
1917
+ "tableFrom": "chatv3-bindings",
1918
+ "tableTo": "chatv3-channels",
1919
+ "columnsFrom": [
1920
+ "channelId"
1921
+ ],
1922
+ "columnsTo": [
1923
+ "id"
1924
+ ],
1925
+ "onDelete": "cascade",
1926
+ "onUpdate": "no action"
1927
+ },
1928
+ "chatv3-bindings_roomId_chatv3-rooms_id_fk": {
1929
+ "name": "chatv3-bindings_roomId_chatv3-rooms_id_fk",
1930
+ "tableFrom": "chatv3-bindings",
1931
+ "tableTo": "chatv3-rooms",
1932
+ "columnsFrom": [
1933
+ "roomId"
1934
+ ],
1935
+ "columnsTo": [
1936
+ "id"
1937
+ ],
1938
+ "onDelete": "cascade",
1939
+ "onUpdate": "no action"
1940
+ }
1941
+ },
1942
+ "compositePrimaryKeys": {},
1943
+ "uniqueConstraints": {},
1944
+ "policies": {},
1945
+ "checkConstraints": {},
1946
+ "isRLSEnabled": false
1947
+ },
1948
+ "public.chatv3-presence": {
1949
+ "name": "chatv3-presence",
1950
+ "schema": "",
1951
+ "columns": {
1952
+ "id": {
1953
+ "name": "id",
1954
+ "type": "uuid",
1955
+ "primaryKey": true,
1956
+ "notNull": true,
1957
+ "default": "gen_random_uuid()"
1958
+ },
1959
+ "tenantId": {
1960
+ "name": "tenantId",
1961
+ "type": "text",
1962
+ "primaryKey": false,
1963
+ "notNull": true,
1964
+ "default": "'default'"
1965
+ },
1966
+ "roomId": {
1967
+ "name": "roomId",
1968
+ "type": "uuid",
1969
+ "primaryKey": false,
1970
+ "notNull": true
1971
+ },
1972
+ "memberId": {
1973
+ "name": "memberId",
1974
+ "type": "uuid",
1975
+ "primaryKey": false,
1976
+ "notNull": true
1977
+ },
1978
+ "state": {
1979
+ "name": "state",
1980
+ "type": "text",
1981
+ "primaryKey": false,
1982
+ "notNull": true,
1983
+ "default": "'active'"
1984
+ },
1985
+ "note": {
1986
+ "name": "note",
1987
+ "type": "text",
1988
+ "primaryKey": false,
1989
+ "notNull": false
1990
+ },
1991
+ "expiresAt": {
1992
+ "name": "expiresAt",
1993
+ "type": "timestamp with time zone",
1994
+ "primaryKey": false,
1995
+ "notNull": true
1996
+ },
1997
+ "updatedAt": {
1998
+ "name": "updatedAt",
1999
+ "type": "timestamp with time zone",
2000
+ "primaryKey": false,
2001
+ "notNull": true,
2002
+ "default": "now()"
2003
+ }
2004
+ },
2005
+ "indexes": {
2006
+ "chatv3_presence_room_member_unique": {
2007
+ "name": "chatv3_presence_room_member_unique",
2008
+ "columns": [
2009
+ {
2010
+ "expression": "roomId",
2011
+ "isExpression": false,
2012
+ "asc": true,
2013
+ "nulls": "last"
2014
+ },
2015
+ {
2016
+ "expression": "memberId",
2017
+ "isExpression": false,
2018
+ "asc": true,
2019
+ "nulls": "last"
2020
+ }
2021
+ ],
2022
+ "isUnique": true,
2023
+ "concurrently": false,
2024
+ "method": "btree",
2025
+ "with": {}
2026
+ },
2027
+ "chatv3_presence_idx_room_expires": {
2028
+ "name": "chatv3_presence_idx_room_expires",
2029
+ "columns": [
2030
+ {
2031
+ "expression": "roomId",
2032
+ "isExpression": false,
2033
+ "asc": true,
2034
+ "nulls": "last"
2035
+ },
2036
+ {
2037
+ "expression": "expiresAt",
2038
+ "isExpression": false,
2039
+ "asc": true,
2040
+ "nulls": "last"
2041
+ }
2042
+ ],
2043
+ "isUnique": false,
2044
+ "concurrently": false,
2045
+ "method": "btree",
2046
+ "with": {}
2047
+ }
2048
+ },
2049
+ "foreignKeys": {
2050
+ "chatv3-presence_roomId_chatv3-rooms_id_fk": {
2051
+ "name": "chatv3-presence_roomId_chatv3-rooms_id_fk",
2052
+ "tableFrom": "chatv3-presence",
2053
+ "tableTo": "chatv3-rooms",
2054
+ "columnsFrom": [
2055
+ "roomId"
2056
+ ],
2057
+ "columnsTo": [
2058
+ "id"
2059
+ ],
2060
+ "onDelete": "cascade",
2061
+ "onUpdate": "no action"
2062
+ },
2063
+ "chatv3-presence_memberId_chatv3-members_id_fk": {
2064
+ "name": "chatv3-presence_memberId_chatv3-members_id_fk",
2065
+ "tableFrom": "chatv3-presence",
2066
+ "tableTo": "chatv3-members",
2067
+ "columnsFrom": [
2068
+ "memberId"
2069
+ ],
2070
+ "columnsTo": [
2071
+ "id"
2072
+ ],
2073
+ "onDelete": "cascade",
2074
+ "onUpdate": "no action"
2075
+ }
2076
+ },
2077
+ "compositePrimaryKeys": {},
2078
+ "uniqueConstraints": {},
2079
+ "policies": {},
2080
+ "checkConstraints": {},
2081
+ "isRLSEnabled": false
2082
+ },
2083
+ "public.chatv3-webhooks": {
2084
+ "name": "chatv3-webhooks",
2085
+ "schema": "",
2086
+ "columns": {
2087
+ "id": {
2088
+ "name": "id",
2089
+ "type": "uuid",
2090
+ "primaryKey": true,
2091
+ "notNull": true,
2092
+ "default": "gen_random_uuid()"
2093
+ },
2094
+ "tenantId": {
2095
+ "name": "tenantId",
2096
+ "type": "text",
2097
+ "primaryKey": false,
2098
+ "notNull": true,
2099
+ "default": "'default'"
2100
+ },
2101
+ "channelId": {
2102
+ "name": "channelId",
2103
+ "type": "uuid",
2104
+ "primaryKey": false,
2105
+ "notNull": true
2106
+ },
2107
+ "url": {
2108
+ "name": "url",
2109
+ "type": "text",
2110
+ "primaryKey": false,
2111
+ "notNull": true
2112
+ },
2113
+ "signingSecret": {
2114
+ "name": "signingSecret",
2115
+ "type": "text",
2116
+ "primaryKey": false,
2117
+ "notNull": true
2118
+ },
2119
+ "events": {
2120
+ "name": "events",
2121
+ "type": "jsonb",
2122
+ "primaryKey": false,
2123
+ "notNull": true,
2124
+ "default": "'[]'::jsonb"
2125
+ },
2126
+ "label": {
2127
+ "name": "label",
2128
+ "type": "text",
2129
+ "primaryKey": false,
2130
+ "notNull": false
2131
+ },
2132
+ "status": {
2133
+ "name": "status",
2134
+ "type": "text",
2135
+ "primaryKey": false,
2136
+ "notNull": true,
2137
+ "default": "'active'"
2138
+ },
2139
+ "failCount": {
2140
+ "name": "failCount",
2141
+ "type": "integer",
2142
+ "primaryKey": false,
2143
+ "notNull": true,
2144
+ "default": 0
2145
+ },
2146
+ "lastDeliveryAt": {
2147
+ "name": "lastDeliveryAt",
2148
+ "type": "timestamp with time zone",
2149
+ "primaryKey": false,
2150
+ "notNull": false
2151
+ },
2152
+ "lastFailureAt": {
2153
+ "name": "lastFailureAt",
2154
+ "type": "timestamp with time zone",
2155
+ "primaryKey": false,
2156
+ "notNull": false
2157
+ },
2158
+ "createdBy": {
2159
+ "name": "createdBy",
2160
+ "type": "text",
2161
+ "primaryKey": false,
2162
+ "notNull": false
2163
+ },
2164
+ "createdAt": {
2165
+ "name": "createdAt",
2166
+ "type": "timestamp with time zone",
2167
+ "primaryKey": false,
2168
+ "notNull": true,
2169
+ "default": "now()"
2170
+ },
2171
+ "updatedAt": {
2172
+ "name": "updatedAt",
2173
+ "type": "timestamp with time zone",
2174
+ "primaryKey": false,
2175
+ "notNull": true,
2176
+ "default": "now()"
2177
+ }
2178
+ },
2179
+ "indexes": {
2180
+ "chatv3_webhook_idx_channel_status": {
2181
+ "name": "chatv3_webhook_idx_channel_status",
2182
+ "columns": [
2183
+ {
2184
+ "expression": "tenantId",
2185
+ "isExpression": false,
2186
+ "asc": true,
2187
+ "nulls": "last"
2188
+ },
2189
+ {
2190
+ "expression": "channelId",
2191
+ "isExpression": false,
2192
+ "asc": true,
2193
+ "nulls": "last"
2194
+ },
2195
+ {
2196
+ "expression": "status",
2197
+ "isExpression": false,
2198
+ "asc": true,
2199
+ "nulls": "last"
2200
+ }
2201
+ ],
2202
+ "isUnique": false,
2203
+ "concurrently": false,
2204
+ "method": "btree",
2205
+ "with": {}
2206
+ }
2207
+ },
2208
+ "foreignKeys": {
2209
+ "chatv3-webhooks_channelId_chatv3-channels_id_fk": {
2210
+ "name": "chatv3-webhooks_channelId_chatv3-channels_id_fk",
2211
+ "tableFrom": "chatv3-webhooks",
2212
+ "tableTo": "chatv3-channels",
2213
+ "columnsFrom": [
2214
+ "channelId"
2215
+ ],
2216
+ "columnsTo": [
2217
+ "id"
2218
+ ],
2219
+ "onDelete": "cascade",
2220
+ "onUpdate": "no action"
2221
+ }
2222
+ },
2223
+ "compositePrimaryKeys": {},
2224
+ "uniqueConstraints": {},
2225
+ "policies": {},
2226
+ "checkConstraints": {},
2227
+ "isRLSEnabled": false
2228
+ }
2229
+ },
2230
+ "enums": {},
2231
+ "schemas": {},
2232
+ "sequences": {},
2233
+ "roles": {},
2234
+ "policies": {},
2235
+ "views": {},
2236
+ "_meta": {
2237
+ "columns": {},
2238
+ "schemas": {},
2239
+ "tables": {}
2240
+ }
2241
+ }