create-m5kdev 0.33.0 → 0.35.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 (147) hide show
  1. package/dist/src/catalog.cjs +21 -1
  2. package/dist/src/catalog.cjs.map +1 -1
  3. package/dist/src/catalog.d.cts +3 -1
  4. package/dist/src/create.cjs +6 -2
  5. package/dist/src/create.cjs.map +1 -1
  6. package/dist/src/doctor.cjs.map +1 -1
  7. package/dist/src/fs.cjs +10 -5
  8. package/dist/src/fs.cjs.map +1 -1
  9. package/dist/src/prompts.cjs +32 -0
  10. package/dist/src/prompts.cjs.map +1 -1
  11. package/dist/src/prompts.d.cts +7 -1
  12. package/dist/src/template.cjs +23 -4
  13. package/dist/src/template.cjs.map +1 -1
  14. package/dist/src/template.d.cts +17 -3
  15. package/dist/src/types.d.cts +11 -4
  16. package/package.json +4 -1
  17. package/templates/minimal-app/.cursor/rules/frontend-data-guide.mdc +1 -0
  18. package/templates/minimal-app/.cursor/rules/module-dto-guide.mdc +1 -1
  19. package/templates/minimal-app/.cursor/rules/module-grants-guide.mdc +3 -3
  20. package/templates/minimal-app/.cursor/rules/module-module-guide.mdc +3 -2
  21. package/templates/minimal-app/.cursor/rules/module-service-guide.mdc +1 -1
  22. package/templates/minimal-app/.cursor/rules/server-event-emit.mdc +41 -0
  23. package/templates/minimal-app/.dockerignore.tpl +31 -0
  24. package/templates/minimal-app/.gitignore.tpl +1 -0
  25. package/templates/minimal-app/AGENTS.md.tpl +14 -10
  26. package/templates/minimal-app/CLAUDE.md.tpl +133 -131
  27. package/templates/minimal-app/README.md.tpl +51 -19
  28. package/templates/minimal-app/apps/e2e/package.json.tpl +23 -23
  29. package/templates/minimal-app/apps/e2e/playwright.config.ts.tpl +51 -39
  30. package/templates/minimal-app/apps/e2e/playwright.expo.config.ts.tpl +38 -38
  31. package/templates/minimal-app/apps/e2e/servers.ts.tpl +136 -112
  32. package/templates/minimal-app/apps/e2e/tests/conversation.spec.ts.tpl +22 -0
  33. package/templates/minimal-app/apps/e2e/tests/email.spec.ts.tpl +47 -47
  34. package/templates/minimal-app/apps/e2e/tests/expo-helpers.ts.tpl +73 -73
  35. package/templates/minimal-app/apps/e2e/tests/expo-standard.spec.ts.tpl +517 -517
  36. package/templates/minimal-app/apps/e2e/tests/expo-waitlist.spec.ts.tpl +94 -94
  37. package/templates/minimal-app/apps/e2e/tests/files.spec.ts.tpl +35 -0
  38. package/templates/minimal-app/apps/e2e/tests/helpers.ts.tpl +289 -289
  39. package/templates/minimal-app/apps/e2e/tests/standard.spec.ts.tpl +516 -516
  40. package/templates/minimal-app/apps/e2e/tests/waitlist.spec.ts.tpl +107 -107
  41. package/templates/minimal-app/apps/e2e/tests/workflow.spec.ts.tpl +26 -0
  42. package/templates/minimal-app/apps/e2e/tsconfig.json.tpl +10 -10
  43. package/templates/minimal-app/apps/email/package.json.tpl +34 -34
  44. package/templates/minimal-app/apps/email/src/emails/trialEndingEmail.tsx.tpl +40 -0
  45. package/templates/minimal-app/apps/email/src/index.ts.tpl +7 -0
  46. package/templates/minimal-app/apps/email/src/resources.ts.tpl +72 -65
  47. package/templates/minimal-app/apps/expo/app.json.tpl +36 -36
  48. package/templates/minimal-app/apps/expo/eslint.config.js.tpl +8 -8
  49. package/templates/minimal-app/apps/expo/metro.config.js.tpl +16 -16
  50. package/templates/minimal-app/apps/expo/src/app/_layout.tsx.tpl +31 -31
  51. package/templates/minimal-app/apps/expo/src/app/claim-account.tsx.tpl +151 -151
  52. package/templates/minimal-app/apps/expo/src/app/forgot-password.tsx.tpl +53 -53
  53. package/templates/minimal-app/apps/expo/src/app/index.tsx.tpl +8 -8
  54. package/templates/minimal-app/apps/expo/src/app/login.tsx.tpl +71 -71
  55. package/templates/minimal-app/apps/expo/src/app/logout.tsx.tpl +19 -19
  56. package/templates/minimal-app/apps/expo/src/app/organization/accept-invitation.tsx.tpl +85 -85
  57. package/templates/minimal-app/apps/expo/src/app/posts.tsx.tpl +40 -40
  58. package/templates/minimal-app/apps/expo/src/app/reset-password.tsx.tpl +75 -75
  59. package/templates/minimal-app/apps/expo/src/app/signup.tsx.tpl +193 -193
  60. package/templates/minimal-app/apps/expo/src/components/AuthScaffold.tsx.tpl +34 -34
  61. package/templates/minimal-app/apps/expo/src/components/FormTextField.tsx.tpl +37 -37
  62. package/templates/minimal-app/apps/expo/src/components/LoadingScreen.tsx.tpl +10 -10
  63. package/templates/minimal-app/apps/expo/src/components/StatusText.tsx.tpl +22 -22
  64. package/templates/minimal-app/apps/expo/src/config.ts.tpl +9 -9
  65. package/templates/minimal-app/apps/expo/src/global.css.tpl +11 -11
  66. package/templates/minimal-app/apps/expo/src/lib/trpc.ts.tpl +20 -20
  67. package/templates/minimal-app/apps/expo/tsconfig.json.tpl +11 -11
  68. package/templates/minimal-app/apps/expo/uniwind-env.d.ts.tpl +1 -1
  69. package/templates/minimal-app/apps/landing/.env.production.example.tpl +7 -0
  70. package/templates/minimal-app/apps/landing/Dockerfile.tpl +39 -0
  71. package/templates/minimal-app/apps/landing/fly.toml.tpl +20 -0
  72. package/templates/minimal-app/apps/landing/index.html.tpl +35 -0
  73. package/templates/minimal-app/apps/landing/package.json.tpl +34 -0
  74. package/templates/minimal-app/apps/landing/src/App.tsx.tpl +12 -0
  75. package/templates/minimal-app/apps/landing/src/LandingPage.tsx.tpl +37 -0
  76. package/templates/minimal-app/apps/landing/src/index.css.tpl +24 -0
  77. package/templates/minimal-app/apps/landing/src/main.tsx.tpl +16 -0
  78. package/templates/minimal-app/apps/landing/src/vite-env.d.ts.tpl +11 -0
  79. package/templates/minimal-app/apps/landing/tsconfig.json.tpl +12 -0
  80. package/templates/minimal-app/apps/landing/vite.config.ts.tpl +25 -0
  81. package/templates/minimal-app/apps/server/AGENTS.md.tpl +55 -46
  82. package/templates/minimal-app/apps/server/{drizzle/seed.e2e.ts.tpl → db.e2e.ts.tpl} +57 -40
  83. package/templates/minimal-app/apps/server/{drizzle/seed.ts.tpl → db.ts.tpl} +27 -20
  84. package/templates/minimal-app/apps/server/drizzle/0003_silly_the_liberteens.sql +27 -0
  85. package/templates/minimal-app/apps/server/drizzle/meta/0000_snapshot.json.tpl +56 -166
  86. package/templates/minimal-app/apps/server/drizzle/meta/0001_snapshot.json.tpl +1796 -1910
  87. package/templates/minimal-app/apps/server/drizzle/meta/0002_snapshot.json.tpl +1818 -1932
  88. package/templates/minimal-app/apps/server/drizzle/meta/0003_snapshot.json.tpl +2137 -0
  89. package/templates/minimal-app/apps/server/drizzle/meta/_journal.json.tpl +8 -1
  90. package/templates/minimal-app/apps/server/drizzle.config.ts.tpl +3 -33
  91. package/templates/minimal-app/apps/server/package.json.tpl +5 -3
  92. package/templates/minimal-app/apps/server/src/app.ts.tpl +36 -0
  93. package/templates/minimal-app/apps/server/src/modules/conversation/conversation.mastra.ts.tpl +26 -0
  94. package/templates/minimal-app/apps/server/src/modules/demo-workflow/demo-workflow.module.ts.tpl +51 -0
  95. package/templates/minimal-app/apps/server/src/modules/demo-workflow/demo-workflow.service.ts.tpl +51 -0
  96. package/templates/minimal-app/apps/server/src/modules/demo-workflow/demo-workflow.trpc.ts.tpl +16 -0
  97. package/templates/minimal-app/apps/server/src/modules/posts/posts.db.ts.tpl +28 -28
  98. package/templates/minimal-app/apps/server/src/modules/posts/posts.grants.ts.tpl +28 -28
  99. package/templates/minimal-app/apps/server/src/modules/posts/posts.module.ts.tpl +57 -54
  100. package/templates/minimal-app/apps/server/src/modules/posts/posts.repository.ts.tpl +67 -67
  101. package/templates/minimal-app/apps/server/src/modules/posts/posts.service.ts.tpl +116 -116
  102. package/templates/minimal-app/apps/server/src/modules/posts/posts.trpc.ts.tpl +37 -37
  103. package/templates/minimal-app/apps/server/src/modules/test-harness/test-harness.module.ts.tpl +279 -279
  104. package/templates/minimal-app/apps/server/src/schema.ts.tpl +31 -20
  105. package/templates/minimal-app/apps/server/src/types.ts.tpl +12 -12
  106. package/templates/minimal-app/apps/server/tsconfig.json.tpl +1 -1
  107. package/templates/minimal-app/apps/server/tsup.config.ts.tpl +23 -9
  108. package/templates/minimal-app/apps/shared/.env.example.tpl +5 -0
  109. package/templates/minimal-app/apps/shared/.env.production.example.tpl +23 -0
  110. package/templates/minimal-app/apps/shared/.env.tpl +5 -0
  111. package/templates/minimal-app/apps/shared/Dockerfile.tpl +48 -0
  112. package/templates/minimal-app/apps/shared/fly.toml.tpl +24 -0
  113. package/templates/minimal-app/apps/shared/package.json.tpl +26 -24
  114. package/templates/minimal-app/apps/shared/src/modules/app/app.constants.ts.tpl +28 -28
  115. package/templates/minimal-app/apps/shared/src/modules/conversation/conversation.constants.ts.tpl +1 -0
  116. package/templates/minimal-app/apps/shared/src/modules/demo-workflow/demo-workflow.constants.ts.tpl +1 -0
  117. package/templates/minimal-app/apps/shared/src/modules/notification/notification.schema.ts.tpl +3 -3
  118. package/templates/minimal-app/apps/shared/src/modules/posts/posts.constants.ts.tpl +5 -5
  119. package/templates/minimal-app/apps/shared/src/modules/posts/posts.schema.ts.tpl +25 -25
  120. package/templates/minimal-app/apps/webapp/package.json.tpl +53 -53
  121. package/templates/minimal-app/apps/webapp/public/push-sw.js.tpl +34 -34
  122. package/templates/minimal-app/apps/webapp/src/App.tsx.tpl +49 -44
  123. package/templates/minimal-app/apps/webapp/src/Layout.tsx.tpl +96 -65
  124. package/templates/minimal-app/apps/webapp/src/Router.tsx.tpl +114 -93
  125. package/templates/minimal-app/apps/webapp/src/StarterServerEventProvider.tsx.tpl +38 -0
  126. package/templates/minimal-app/apps/webapp/src/index.css.tpl +15 -15
  127. package/templates/minimal-app/apps/webapp/src/main.tsx.tpl +26 -26
  128. package/templates/minimal-app/apps/webapp/src/modules/conversation/ConversationRoute.tsx.tpl +36 -0
  129. package/templates/minimal-app/apps/webapp/src/modules/files/FilesRoute.tsx.tpl +88 -0
  130. package/templates/minimal-app/apps/webapp/src/modules/files/hooks/useFilesRoute.ts.tpl +50 -0
  131. package/templates/minimal-app/apps/webapp/src/modules/workflows/WorkflowsRoute.tsx.tpl +97 -0
  132. package/templates/minimal-app/apps/webapp/src/modules/workflows/hooks/useWorkflowsRoute.ts.tpl +64 -0
  133. package/templates/minimal-app/apps/webapp/src/utils/i18n.ts.tpl +13 -13
  134. package/templates/minimal-app/apps/webapp/src/utils/trpc.ts.tpl +10 -10
  135. package/templates/minimal-app/apps/webapp/src/vite-env.d.ts.tpl +1 -1
  136. package/templates/minimal-app/apps/webapp/translations/en/app.json.tpl +7 -7
  137. package/templates/minimal-app/apps/webapp/translations/en/{{APP_SLUG}}.json.tpl +193 -135
  138. package/templates/minimal-app/apps/webapp/tsconfig.json.tpl +17 -17
  139. package/templates/minimal-app/apps/webapp/vite.config.ts.tpl +31 -31
  140. package/templates/minimal-app/biome.json.tpl +17 -12
  141. package/templates/minimal-app/package.json.tpl +7 -2
  142. package/templates/minimal-app/pnpm-workspace.yaml.tpl +14 -7
  143. package/templates/minimal-app/template.manifest.json +93 -2
  144. package/templates/minimal-app/apps/server/drizzle/db.ts.tpl +0 -26
  145. package/templates/minimal-app/apps/server/drizzle/guard.ts.tpl +0 -36
  146. package/templates/minimal-app/apps/server/drizzle/reset.ts.tpl +0 -40
  147. package/templates/minimal-app/apps/server/drizzle/sync.ts.tpl +0 -16
@@ -0,0 +1,2137 @@
1
+ {
2
+ "version": "6",
3
+ "dialect": "sqlite",
4
+ "id": "d3ade3d2-d0fe-4822-8b3b-4d14d1cdbee1",
5
+ "prevId": "a4efbe3a-95de-45c2-a7a4-2e80de0472d5",
6
+ "tables": {
7
+ "account_claim_magic_links": {
8
+ "name": "account_claim_magic_links",
9
+ "columns": {
10
+ "id": {
11
+ "name": "id",
12
+ "type": "text",
13
+ "primaryKey": true,
14
+ "notNull": true,
15
+ "autoincrement": false
16
+ },
17
+ "claim_id": {
18
+ "name": "claim_id",
19
+ "type": "text",
20
+ "primaryKey": false,
21
+ "notNull": true,
22
+ "autoincrement": false
23
+ },
24
+ "user_id": {
25
+ "name": "user_id",
26
+ "type": "text",
27
+ "primaryKey": false,
28
+ "notNull": true,
29
+ "autoincrement": false
30
+ },
31
+ "email": {
32
+ "name": "email",
33
+ "type": "text",
34
+ "primaryKey": false,
35
+ "notNull": true,
36
+ "autoincrement": false
37
+ },
38
+ "token": {
39
+ "name": "token",
40
+ "type": "text",
41
+ "primaryKey": false,
42
+ "notNull": true,
43
+ "autoincrement": false
44
+ },
45
+ "url": {
46
+ "name": "url",
47
+ "type": "text",
48
+ "primaryKey": false,
49
+ "notNull": true,
50
+ "autoincrement": false
51
+ },
52
+ "expires_at": {
53
+ "name": "expires_at",
54
+ "type": "integer",
55
+ "primaryKey": false,
56
+ "notNull": false,
57
+ "autoincrement": false
58
+ },
59
+ "created_at": {
60
+ "name": "created_at",
61
+ "type": "integer",
62
+ "primaryKey": false,
63
+ "notNull": true,
64
+ "autoincrement": false
65
+ }
66
+ },
67
+ "indexes": {},
68
+ "foreignKeys": {
69
+ "account_claim_magic_links_claim_id_waitlist_id_fk": {
70
+ "name": "account_claim_magic_links_claim_id_waitlist_id_fk",
71
+ "tableFrom": "account_claim_magic_links",
72
+ "tableTo": "waitlist",
73
+ "columnsFrom": [
74
+ "claim_id"
75
+ ],
76
+ "columnsTo": [
77
+ "id"
78
+ ],
79
+ "onDelete": "cascade",
80
+ "onUpdate": "no action"
81
+ },
82
+ "account_claim_magic_links_user_id_users_id_fk": {
83
+ "name": "account_claim_magic_links_user_id_users_id_fk",
84
+ "tableFrom": "account_claim_magic_links",
85
+ "tableTo": "users",
86
+ "columnsFrom": [
87
+ "user_id"
88
+ ],
89
+ "columnsTo": [
90
+ "id"
91
+ ],
92
+ "onDelete": "cascade",
93
+ "onUpdate": "no action"
94
+ }
95
+ },
96
+ "compositePrimaryKeys": {},
97
+ "uniqueConstraints": {},
98
+ "checkConstraints": {}
99
+ },
100
+ "accounts": {
101
+ "name": "accounts",
102
+ "columns": {
103
+ "id": {
104
+ "name": "id",
105
+ "type": "text",
106
+ "primaryKey": true,
107
+ "notNull": true,
108
+ "autoincrement": false
109
+ },
110
+ "account_id": {
111
+ "name": "account_id",
112
+ "type": "text",
113
+ "primaryKey": false,
114
+ "notNull": true,
115
+ "autoincrement": false
116
+ },
117
+ "provider_id": {
118
+ "name": "provider_id",
119
+ "type": "text",
120
+ "primaryKey": false,
121
+ "notNull": true,
122
+ "autoincrement": false
123
+ },
124
+ "user_id": {
125
+ "name": "user_id",
126
+ "type": "text",
127
+ "primaryKey": false,
128
+ "notNull": true,
129
+ "autoincrement": false
130
+ },
131
+ "access_token": {
132
+ "name": "access_token",
133
+ "type": "text",
134
+ "primaryKey": false,
135
+ "notNull": false,
136
+ "autoincrement": false
137
+ },
138
+ "refresh_token": {
139
+ "name": "refresh_token",
140
+ "type": "text",
141
+ "primaryKey": false,
142
+ "notNull": false,
143
+ "autoincrement": false
144
+ },
145
+ "id_token": {
146
+ "name": "id_token",
147
+ "type": "text",
148
+ "primaryKey": false,
149
+ "notNull": false,
150
+ "autoincrement": false
151
+ },
152
+ "access_token_expires_at": {
153
+ "name": "access_token_expires_at",
154
+ "type": "integer",
155
+ "primaryKey": false,
156
+ "notNull": false,
157
+ "autoincrement": false
158
+ },
159
+ "refresh_token_expires_at": {
160
+ "name": "refresh_token_expires_at",
161
+ "type": "integer",
162
+ "primaryKey": false,
163
+ "notNull": false,
164
+ "autoincrement": false
165
+ },
166
+ "scope": {
167
+ "name": "scope",
168
+ "type": "text",
169
+ "primaryKey": false,
170
+ "notNull": false,
171
+ "autoincrement": false
172
+ },
173
+ "password": {
174
+ "name": "password",
175
+ "type": "text",
176
+ "primaryKey": false,
177
+ "notNull": false,
178
+ "autoincrement": false
179
+ },
180
+ "created_at": {
181
+ "name": "created_at",
182
+ "type": "integer",
183
+ "primaryKey": false,
184
+ "notNull": true,
185
+ "autoincrement": false
186
+ },
187
+ "updated_at": {
188
+ "name": "updated_at",
189
+ "type": "integer",
190
+ "primaryKey": false,
191
+ "notNull": true,
192
+ "autoincrement": false
193
+ }
194
+ },
195
+ "indexes": {},
196
+ "foreignKeys": {
197
+ "accounts_user_id_users_id_fk": {
198
+ "name": "accounts_user_id_users_id_fk",
199
+ "tableFrom": "accounts",
200
+ "tableTo": "users",
201
+ "columnsFrom": [
202
+ "user_id"
203
+ ],
204
+ "columnsTo": [
205
+ "id"
206
+ ],
207
+ "onDelete": "cascade",
208
+ "onUpdate": "no action"
209
+ }
210
+ },
211
+ "compositePrimaryKeys": {},
212
+ "uniqueConstraints": {},
213
+ "checkConstraints": {}
214
+ },
215
+ "apikeys": {
216
+ "name": "apikeys",
217
+ "columns": {
218
+ "id": {
219
+ "name": "id",
220
+ "type": "text",
221
+ "primaryKey": true,
222
+ "notNull": true,
223
+ "autoincrement": false
224
+ },
225
+ "name": {
226
+ "name": "name",
227
+ "type": "text",
228
+ "primaryKey": false,
229
+ "notNull": false,
230
+ "autoincrement": false
231
+ },
232
+ "start": {
233
+ "name": "start",
234
+ "type": "text",
235
+ "primaryKey": false,
236
+ "notNull": false,
237
+ "autoincrement": false
238
+ },
239
+ "prefix": {
240
+ "name": "prefix",
241
+ "type": "text",
242
+ "primaryKey": false,
243
+ "notNull": false,
244
+ "autoincrement": false
245
+ },
246
+ "key": {
247
+ "name": "key",
248
+ "type": "text",
249
+ "primaryKey": false,
250
+ "notNull": true,
251
+ "autoincrement": false
252
+ },
253
+ "user_id": {
254
+ "name": "user_id",
255
+ "type": "text",
256
+ "primaryKey": false,
257
+ "notNull": true,
258
+ "autoincrement": false
259
+ },
260
+ "refill_interval": {
261
+ "name": "refill_interval",
262
+ "type": "integer",
263
+ "primaryKey": false,
264
+ "notNull": false,
265
+ "autoincrement": false
266
+ },
267
+ "refill_amount": {
268
+ "name": "refill_amount",
269
+ "type": "integer",
270
+ "primaryKey": false,
271
+ "notNull": false,
272
+ "autoincrement": false
273
+ },
274
+ "last_refill_at": {
275
+ "name": "last_refill_at",
276
+ "type": "integer",
277
+ "primaryKey": false,
278
+ "notNull": false,
279
+ "autoincrement": false
280
+ },
281
+ "enabled": {
282
+ "name": "enabled",
283
+ "type": "integer",
284
+ "primaryKey": false,
285
+ "notNull": true,
286
+ "autoincrement": false
287
+ },
288
+ "rate_limit_enabled": {
289
+ "name": "rate_limit_enabled",
290
+ "type": "integer",
291
+ "primaryKey": false,
292
+ "notNull": true,
293
+ "autoincrement": false
294
+ },
295
+ "rate_limit_time_window": {
296
+ "name": "rate_limit_time_window",
297
+ "type": "integer",
298
+ "primaryKey": false,
299
+ "notNull": false,
300
+ "autoincrement": false
301
+ },
302
+ "rate_limit_max": {
303
+ "name": "rate_limit_max",
304
+ "type": "integer",
305
+ "primaryKey": false,
306
+ "notNull": false,
307
+ "autoincrement": false
308
+ },
309
+ "request_count": {
310
+ "name": "request_count",
311
+ "type": "integer",
312
+ "primaryKey": false,
313
+ "notNull": true,
314
+ "autoincrement": false
315
+ },
316
+ "remaining": {
317
+ "name": "remaining",
318
+ "type": "integer",
319
+ "primaryKey": false,
320
+ "notNull": false,
321
+ "autoincrement": false
322
+ },
323
+ "last_request": {
324
+ "name": "last_request",
325
+ "type": "integer",
326
+ "primaryKey": false,
327
+ "notNull": false,
328
+ "autoincrement": false
329
+ },
330
+ "expires_at": {
331
+ "name": "expires_at",
332
+ "type": "integer",
333
+ "primaryKey": false,
334
+ "notNull": false,
335
+ "autoincrement": false
336
+ },
337
+ "created_at": {
338
+ "name": "created_at",
339
+ "type": "integer",
340
+ "primaryKey": false,
341
+ "notNull": true,
342
+ "autoincrement": false
343
+ },
344
+ "updated_at": {
345
+ "name": "updated_at",
346
+ "type": "integer",
347
+ "primaryKey": false,
348
+ "notNull": true,
349
+ "autoincrement": false
350
+ },
351
+ "permissions": {
352
+ "name": "permissions",
353
+ "type": "text",
354
+ "primaryKey": false,
355
+ "notNull": false,
356
+ "autoincrement": false
357
+ },
358
+ "metadata": {
359
+ "name": "metadata",
360
+ "type": "text",
361
+ "primaryKey": false,
362
+ "notNull": false,
363
+ "autoincrement": false
364
+ }
365
+ },
366
+ "indexes": {},
367
+ "foreignKeys": {
368
+ "apikeys_user_id_users_id_fk": {
369
+ "name": "apikeys_user_id_users_id_fk",
370
+ "tableFrom": "apikeys",
371
+ "tableTo": "users",
372
+ "columnsFrom": [
373
+ "user_id"
374
+ ],
375
+ "columnsTo": [
376
+ "id"
377
+ ],
378
+ "onDelete": "no action",
379
+ "onUpdate": "no action"
380
+ }
381
+ },
382
+ "compositePrimaryKeys": {},
383
+ "uniqueConstraints": {},
384
+ "checkConstraints": {}
385
+ },
386
+ "files": {
387
+ "name": "files",
388
+ "columns": {
389
+ "id": {
390
+ "name": "id",
391
+ "type": "text",
392
+ "primaryKey": true,
393
+ "notNull": true,
394
+ "autoincrement": false
395
+ },
396
+ "created_at": {
397
+ "name": "created_at",
398
+ "type": "integer",
399
+ "primaryKey": false,
400
+ "notNull": true,
401
+ "autoincrement": false
402
+ },
403
+ "updated_at": {
404
+ "name": "updated_at",
405
+ "type": "integer",
406
+ "primaryKey": false,
407
+ "notNull": false,
408
+ "autoincrement": false
409
+ },
410
+ "deleted_at": {
411
+ "name": "deleted_at",
412
+ "type": "integer",
413
+ "primaryKey": false,
414
+ "notNull": false,
415
+ "autoincrement": false
416
+ },
417
+ "user_id": {
418
+ "name": "user_id",
419
+ "type": "text",
420
+ "primaryKey": false,
421
+ "notNull": false,
422
+ "autoincrement": false
423
+ },
424
+ "member_id": {
425
+ "name": "member_id",
426
+ "type": "text",
427
+ "primaryKey": false,
428
+ "notNull": false,
429
+ "autoincrement": false
430
+ },
431
+ "organization_id": {
432
+ "name": "organization_id",
433
+ "type": "text",
434
+ "primaryKey": false,
435
+ "notNull": false,
436
+ "autoincrement": false
437
+ },
438
+ "team_id": {
439
+ "name": "team_id",
440
+ "type": "text",
441
+ "primaryKey": false,
442
+ "notNull": false,
443
+ "autoincrement": false
444
+ },
445
+ "bucket": {
446
+ "name": "bucket",
447
+ "type": "text",
448
+ "primaryKey": false,
449
+ "notNull": true,
450
+ "autoincrement": false
451
+ },
452
+ "key": {
453
+ "name": "key",
454
+ "type": "text",
455
+ "primaryKey": false,
456
+ "notNull": true,
457
+ "autoincrement": false
458
+ },
459
+ "original_name": {
460
+ "name": "original_name",
461
+ "type": "text",
462
+ "primaryKey": false,
463
+ "notNull": true,
464
+ "autoincrement": false
465
+ },
466
+ "original_extension": {
467
+ "name": "original_extension",
468
+ "type": "text",
469
+ "primaryKey": false,
470
+ "notNull": false,
471
+ "autoincrement": false
472
+ },
473
+ "content_type": {
474
+ "name": "content_type",
475
+ "type": "text",
476
+ "primaryKey": false,
477
+ "notNull": true,
478
+ "autoincrement": false
479
+ },
480
+ "size_bytes": {
481
+ "name": "size_bytes",
482
+ "type": "integer",
483
+ "primaryKey": false,
484
+ "notNull": false,
485
+ "autoincrement": false
486
+ },
487
+ "etag": {
488
+ "name": "etag",
489
+ "type": "text",
490
+ "primaryKey": false,
491
+ "notNull": false,
492
+ "autoincrement": false
493
+ },
494
+ "checksum_sha256": {
495
+ "name": "checksum_sha256",
496
+ "type": "text",
497
+ "primaryKey": false,
498
+ "notNull": false,
499
+ "autoincrement": false
500
+ },
501
+ "metadata": {
502
+ "name": "metadata",
503
+ "type": "text",
504
+ "primaryKey": false,
505
+ "notNull": false,
506
+ "autoincrement": false
507
+ },
508
+ "status": {
509
+ "name": "status",
510
+ "type": "text",
511
+ "primaryKey": false,
512
+ "notNull": true,
513
+ "autoincrement": false
514
+ },
515
+ "uploaded_at": {
516
+ "name": "uploaded_at",
517
+ "type": "integer",
518
+ "primaryKey": false,
519
+ "notNull": false,
520
+ "autoincrement": false
521
+ }
522
+ },
523
+ "indexes": {
524
+ "files_bucket_key_unique": {
525
+ "name": "files_bucket_key_unique",
526
+ "columns": [
527
+ "bucket",
528
+ "key"
529
+ ],
530
+ "isUnique": true
531
+ }
532
+ },
533
+ "foreignKeys": {
534
+ "files_user_id_users_id_fk": {
535
+ "name": "files_user_id_users_id_fk",
536
+ "tableFrom": "files",
537
+ "tableTo": "users",
538
+ "columnsFrom": [
539
+ "user_id"
540
+ ],
541
+ "columnsTo": [
542
+ "id"
543
+ ],
544
+ "onDelete": "set null",
545
+ "onUpdate": "no action"
546
+ },
547
+ "files_member_id_members_id_fk": {
548
+ "name": "files_member_id_members_id_fk",
549
+ "tableFrom": "files",
550
+ "tableTo": "members",
551
+ "columnsFrom": [
552
+ "member_id"
553
+ ],
554
+ "columnsTo": [
555
+ "id"
556
+ ],
557
+ "onDelete": "set null",
558
+ "onUpdate": "no action"
559
+ },
560
+ "files_organization_id_organizations_id_fk": {
561
+ "name": "files_organization_id_organizations_id_fk",
562
+ "tableFrom": "files",
563
+ "tableTo": "organizations",
564
+ "columnsFrom": [
565
+ "organization_id"
566
+ ],
567
+ "columnsTo": [
568
+ "id"
569
+ ],
570
+ "onDelete": "set null",
571
+ "onUpdate": "no action"
572
+ },
573
+ "files_team_id_teams_id_fk": {
574
+ "name": "files_team_id_teams_id_fk",
575
+ "tableFrom": "files",
576
+ "tableTo": "teams",
577
+ "columnsFrom": [
578
+ "team_id"
579
+ ],
580
+ "columnsTo": [
581
+ "id"
582
+ ],
583
+ "onDelete": "set null",
584
+ "onUpdate": "no action"
585
+ }
586
+ },
587
+ "compositePrimaryKeys": {},
588
+ "uniqueConstraints": {},
589
+ "checkConstraints": {}
590
+ },
591
+ "invitations": {
592
+ "name": "invitations",
593
+ "columns": {
594
+ "id": {
595
+ "name": "id",
596
+ "type": "text",
597
+ "primaryKey": true,
598
+ "notNull": true,
599
+ "autoincrement": false
600
+ },
601
+ "organization_id": {
602
+ "name": "organization_id",
603
+ "type": "text",
604
+ "primaryKey": false,
605
+ "notNull": true,
606
+ "autoincrement": false
607
+ },
608
+ "team_id": {
609
+ "name": "team_id",
610
+ "type": "text",
611
+ "primaryKey": false,
612
+ "notNull": false,
613
+ "autoincrement": false
614
+ },
615
+ "email": {
616
+ "name": "email",
617
+ "type": "text",
618
+ "primaryKey": false,
619
+ "notNull": true,
620
+ "autoincrement": false
621
+ },
622
+ "role": {
623
+ "name": "role",
624
+ "type": "text",
625
+ "primaryKey": false,
626
+ "notNull": false,
627
+ "autoincrement": false
628
+ },
629
+ "status": {
630
+ "name": "status",
631
+ "type": "text",
632
+ "primaryKey": false,
633
+ "notNull": true,
634
+ "autoincrement": false
635
+ },
636
+ "created_at": {
637
+ "name": "created_at",
638
+ "type": "integer",
639
+ "primaryKey": false,
640
+ "notNull": true,
641
+ "autoincrement": false
642
+ },
643
+ "expires_at": {
644
+ "name": "expires_at",
645
+ "type": "integer",
646
+ "primaryKey": false,
647
+ "notNull": true,
648
+ "autoincrement": false
649
+ },
650
+ "inviter_id": {
651
+ "name": "inviter_id",
652
+ "type": "text",
653
+ "primaryKey": false,
654
+ "notNull": true,
655
+ "autoincrement": false
656
+ }
657
+ },
658
+ "indexes": {},
659
+ "foreignKeys": {
660
+ "invitations_organization_id_organizations_id_fk": {
661
+ "name": "invitations_organization_id_organizations_id_fk",
662
+ "tableFrom": "invitations",
663
+ "tableTo": "organizations",
664
+ "columnsFrom": [
665
+ "organization_id"
666
+ ],
667
+ "columnsTo": [
668
+ "id"
669
+ ],
670
+ "onDelete": "no action",
671
+ "onUpdate": "no action"
672
+ },
673
+ "invitations_team_id_teams_id_fk": {
674
+ "name": "invitations_team_id_teams_id_fk",
675
+ "tableFrom": "invitations",
676
+ "tableTo": "teams",
677
+ "columnsFrom": [
678
+ "team_id"
679
+ ],
680
+ "columnsTo": [
681
+ "id"
682
+ ],
683
+ "onDelete": "no action",
684
+ "onUpdate": "no action"
685
+ },
686
+ "invitations_inviter_id_users_id_fk": {
687
+ "name": "invitations_inviter_id_users_id_fk",
688
+ "tableFrom": "invitations",
689
+ "tableTo": "users",
690
+ "columnsFrom": [
691
+ "inviter_id"
692
+ ],
693
+ "columnsTo": [
694
+ "id"
695
+ ],
696
+ "onDelete": "no action",
697
+ "onUpdate": "no action"
698
+ }
699
+ },
700
+ "compositePrimaryKeys": {},
701
+ "uniqueConstraints": {},
702
+ "checkConstraints": {}
703
+ },
704
+ "members": {
705
+ "name": "members",
706
+ "columns": {
707
+ "id": {
708
+ "name": "id",
709
+ "type": "text",
710
+ "primaryKey": true,
711
+ "notNull": true,
712
+ "autoincrement": false
713
+ },
714
+ "organization_id": {
715
+ "name": "organization_id",
716
+ "type": "text",
717
+ "primaryKey": false,
718
+ "notNull": true,
719
+ "autoincrement": false
720
+ },
721
+ "user_id": {
722
+ "name": "user_id",
723
+ "type": "text",
724
+ "primaryKey": false,
725
+ "notNull": true,
726
+ "autoincrement": false
727
+ },
728
+ "name": {
729
+ "name": "name",
730
+ "type": "text",
731
+ "primaryKey": false,
732
+ "notNull": true,
733
+ "autoincrement": false,
734
+ "default": "''"
735
+ },
736
+ "image": {
737
+ "name": "image",
738
+ "type": "text",
739
+ "primaryKey": false,
740
+ "notNull": false,
741
+ "autoincrement": false
742
+ },
743
+ "role": {
744
+ "name": "role",
745
+ "type": "text",
746
+ "primaryKey": false,
747
+ "notNull": true,
748
+ "autoincrement": false
749
+ },
750
+ "created_at": {
751
+ "name": "created_at",
752
+ "type": "integer",
753
+ "primaryKey": false,
754
+ "notNull": true,
755
+ "autoincrement": false
756
+ },
757
+ "deleted_at": {
758
+ "name": "deleted_at",
759
+ "type": "integer",
760
+ "primaryKey": false,
761
+ "notNull": false,
762
+ "autoincrement": false
763
+ },
764
+ "preferences": {
765
+ "name": "preferences",
766
+ "type": "text",
767
+ "primaryKey": false,
768
+ "notNull": false,
769
+ "autoincrement": false,
770
+ "default": "'{}'"
771
+ },
772
+ "metadata": {
773
+ "name": "metadata",
774
+ "type": "text",
775
+ "primaryKey": false,
776
+ "notNull": false,
777
+ "autoincrement": false,
778
+ "default": "'{}'"
779
+ },
780
+ "onboarding": {
781
+ "name": "onboarding",
782
+ "type": "integer",
783
+ "primaryKey": false,
784
+ "notNull": false,
785
+ "autoincrement": false
786
+ },
787
+ "flags": {
788
+ "name": "flags",
789
+ "type": "text",
790
+ "primaryKey": false,
791
+ "notNull": false,
792
+ "autoincrement": false,
793
+ "default": "'[]'"
794
+ }
795
+ },
796
+ "indexes": {},
797
+ "foreignKeys": {
798
+ "members_organization_id_organizations_id_fk": {
799
+ "name": "members_organization_id_organizations_id_fk",
800
+ "tableFrom": "members",
801
+ "tableTo": "organizations",
802
+ "columnsFrom": [
803
+ "organization_id"
804
+ ],
805
+ "columnsTo": [
806
+ "id"
807
+ ],
808
+ "onDelete": "no action",
809
+ "onUpdate": "no action"
810
+ },
811
+ "members_user_id_users_id_fk": {
812
+ "name": "members_user_id_users_id_fk",
813
+ "tableFrom": "members",
814
+ "tableTo": "users",
815
+ "columnsFrom": [
816
+ "user_id"
817
+ ],
818
+ "columnsTo": [
819
+ "id"
820
+ ],
821
+ "onDelete": "no action",
822
+ "onUpdate": "no action"
823
+ }
824
+ },
825
+ "compositePrimaryKeys": {},
826
+ "uniqueConstraints": {},
827
+ "checkConstraints": {}
828
+ },
829
+ "notification_devices": {
830
+ "name": "notification_devices",
831
+ "columns": {
832
+ "id": {
833
+ "name": "id",
834
+ "type": "text",
835
+ "primaryKey": true,
836
+ "notNull": true,
837
+ "autoincrement": false
838
+ },
839
+ "user_id": {
840
+ "name": "user_id",
841
+ "type": "text",
842
+ "primaryKey": false,
843
+ "notNull": true,
844
+ "autoincrement": false
845
+ },
846
+ "platform": {
847
+ "name": "platform",
848
+ "type": "text",
849
+ "primaryKey": false,
850
+ "notNull": true,
851
+ "autoincrement": false
852
+ },
853
+ "endpoint": {
854
+ "name": "endpoint",
855
+ "type": "text",
856
+ "primaryKey": false,
857
+ "notNull": false,
858
+ "autoincrement": false
859
+ },
860
+ "subscription": {
861
+ "name": "subscription",
862
+ "type": "text",
863
+ "primaryKey": false,
864
+ "notNull": false,
865
+ "autoincrement": false
866
+ },
867
+ "token": {
868
+ "name": "token",
869
+ "type": "text",
870
+ "primaryKey": false,
871
+ "notNull": false,
872
+ "autoincrement": false
873
+ },
874
+ "label": {
875
+ "name": "label",
876
+ "type": "text",
877
+ "primaryKey": false,
878
+ "notNull": false,
879
+ "autoincrement": false
880
+ },
881
+ "enabled": {
882
+ "name": "enabled",
883
+ "type": "integer",
884
+ "primaryKey": false,
885
+ "notNull": true,
886
+ "autoincrement": false,
887
+ "default": true
888
+ },
889
+ "created_at": {
890
+ "name": "created_at",
891
+ "type": "integer",
892
+ "primaryKey": false,
893
+ "notNull": true,
894
+ "autoincrement": false
895
+ },
896
+ "updated_at": {
897
+ "name": "updated_at",
898
+ "type": "integer",
899
+ "primaryKey": false,
900
+ "notNull": true,
901
+ "autoincrement": false
902
+ }
903
+ },
904
+ "indexes": {
905
+ "notification_devices_endpoint_unique": {
906
+ "name": "notification_devices_endpoint_unique",
907
+ "columns": [
908
+ "endpoint"
909
+ ],
910
+ "isUnique": true
911
+ },
912
+ "notification_devices_token_unique": {
913
+ "name": "notification_devices_token_unique",
914
+ "columns": [
915
+ "token"
916
+ ],
917
+ "isUnique": true
918
+ }
919
+ },
920
+ "foreignKeys": {
921
+ "notification_devices_user_id_users_id_fk": {
922
+ "name": "notification_devices_user_id_users_id_fk",
923
+ "tableFrom": "notification_devices",
924
+ "tableTo": "users",
925
+ "columnsFrom": [
926
+ "user_id"
927
+ ],
928
+ "columnsTo": [
929
+ "id"
930
+ ],
931
+ "onDelete": "cascade",
932
+ "onUpdate": "no action"
933
+ }
934
+ },
935
+ "compositePrimaryKeys": {},
936
+ "uniqueConstraints": {},
937
+ "checkConstraints": {}
938
+ },
939
+ "notification_send_logs": {
940
+ "name": "notification_send_logs",
941
+ "columns": {
942
+ "id": {
943
+ "name": "id",
944
+ "type": "text",
945
+ "primaryKey": true,
946
+ "notNull": true,
947
+ "autoincrement": false
948
+ },
949
+ "batch_id": {
950
+ "name": "batch_id",
951
+ "type": "text",
952
+ "primaryKey": false,
953
+ "notNull": true,
954
+ "autoincrement": false
955
+ },
956
+ "user_id": {
957
+ "name": "user_id",
958
+ "type": "text",
959
+ "primaryKey": false,
960
+ "notNull": true,
961
+ "autoincrement": false
962
+ },
963
+ "device_id": {
964
+ "name": "device_id",
965
+ "type": "text",
966
+ "primaryKey": false,
967
+ "notNull": true,
968
+ "autoincrement": false
969
+ },
970
+ "provider": {
971
+ "name": "provider",
972
+ "type": "text",
973
+ "primaryKey": false,
974
+ "notNull": true,
975
+ "autoincrement": false
976
+ },
977
+ "title": {
978
+ "name": "title",
979
+ "type": "text",
980
+ "primaryKey": false,
981
+ "notNull": true,
982
+ "autoincrement": false
983
+ },
984
+ "body": {
985
+ "name": "body",
986
+ "type": "text",
987
+ "primaryKey": false,
988
+ "notNull": true,
989
+ "autoincrement": false
990
+ },
991
+ "data": {
992
+ "name": "data",
993
+ "type": "text",
994
+ "primaryKey": false,
995
+ "notNull": false,
996
+ "autoincrement": false
997
+ },
998
+ "status": {
999
+ "name": "status",
1000
+ "type": "text",
1001
+ "primaryKey": false,
1002
+ "notNull": true,
1003
+ "autoincrement": false
1004
+ },
1005
+ "error": {
1006
+ "name": "error",
1007
+ "type": "text",
1008
+ "primaryKey": false,
1009
+ "notNull": false,
1010
+ "autoincrement": false
1011
+ },
1012
+ "job_id": {
1013
+ "name": "job_id",
1014
+ "type": "text",
1015
+ "primaryKey": false,
1016
+ "notNull": false,
1017
+ "autoincrement": false
1018
+ },
1019
+ "created_at": {
1020
+ "name": "created_at",
1021
+ "type": "integer",
1022
+ "primaryKey": false,
1023
+ "notNull": true,
1024
+ "autoincrement": false
1025
+ },
1026
+ "updated_at": {
1027
+ "name": "updated_at",
1028
+ "type": "integer",
1029
+ "primaryKey": false,
1030
+ "notNull": true,
1031
+ "autoincrement": false
1032
+ }
1033
+ },
1034
+ "indexes": {},
1035
+ "foreignKeys": {
1036
+ "notification_send_logs_user_id_users_id_fk": {
1037
+ "name": "notification_send_logs_user_id_users_id_fk",
1038
+ "tableFrom": "notification_send_logs",
1039
+ "tableTo": "users",
1040
+ "columnsFrom": [
1041
+ "user_id"
1042
+ ],
1043
+ "columnsTo": [
1044
+ "id"
1045
+ ],
1046
+ "onDelete": "cascade",
1047
+ "onUpdate": "no action"
1048
+ },
1049
+ "notification_send_logs_device_id_notification_devices_id_fk": {
1050
+ "name": "notification_send_logs_device_id_notification_devices_id_fk",
1051
+ "tableFrom": "notification_send_logs",
1052
+ "tableTo": "notification_devices",
1053
+ "columnsFrom": [
1054
+ "device_id"
1055
+ ],
1056
+ "columnsTo": [
1057
+ "id"
1058
+ ],
1059
+ "onDelete": "cascade",
1060
+ "onUpdate": "no action"
1061
+ }
1062
+ },
1063
+ "compositePrimaryKeys": {},
1064
+ "uniqueConstraints": {},
1065
+ "checkConstraints": {}
1066
+ },
1067
+ "organizations": {
1068
+ "name": "organizations",
1069
+ "columns": {
1070
+ "id": {
1071
+ "name": "id",
1072
+ "type": "text",
1073
+ "primaryKey": true,
1074
+ "notNull": true,
1075
+ "autoincrement": false
1076
+ },
1077
+ "name": {
1078
+ "name": "name",
1079
+ "type": "text",
1080
+ "primaryKey": false,
1081
+ "notNull": true,
1082
+ "autoincrement": false
1083
+ },
1084
+ "slug": {
1085
+ "name": "slug",
1086
+ "type": "text",
1087
+ "primaryKey": false,
1088
+ "notNull": false,
1089
+ "autoincrement": false
1090
+ },
1091
+ "logo": {
1092
+ "name": "logo",
1093
+ "type": "text",
1094
+ "primaryKey": false,
1095
+ "notNull": false,
1096
+ "autoincrement": false
1097
+ },
1098
+ "type": {
1099
+ "name": "type",
1100
+ "type": "text",
1101
+ "primaryKey": false,
1102
+ "notNull": false,
1103
+ "autoincrement": false
1104
+ },
1105
+ "parent_id": {
1106
+ "name": "parent_id",
1107
+ "type": "text",
1108
+ "primaryKey": false,
1109
+ "notNull": false,
1110
+ "autoincrement": false
1111
+ },
1112
+ "created_at": {
1113
+ "name": "created_at",
1114
+ "type": "integer",
1115
+ "primaryKey": false,
1116
+ "notNull": true,
1117
+ "autoincrement": false
1118
+ },
1119
+ "onboarding": {
1120
+ "name": "onboarding",
1121
+ "type": "integer",
1122
+ "primaryKey": false,
1123
+ "notNull": false,
1124
+ "autoincrement": false
1125
+ },
1126
+ "preferences": {
1127
+ "name": "preferences",
1128
+ "type": "text",
1129
+ "primaryKey": false,
1130
+ "notNull": false,
1131
+ "autoincrement": false,
1132
+ "default": "'{}'"
1133
+ },
1134
+ "metadata": {
1135
+ "name": "metadata",
1136
+ "type": "text",
1137
+ "primaryKey": false,
1138
+ "notNull": false,
1139
+ "autoincrement": false,
1140
+ "default": "'{}'"
1141
+ },
1142
+ "flags": {
1143
+ "name": "flags",
1144
+ "type": "text",
1145
+ "primaryKey": false,
1146
+ "notNull": false,
1147
+ "autoincrement": false,
1148
+ "default": "'[]'"
1149
+ },
1150
+ "locale": {
1151
+ "name": "locale",
1152
+ "type": "text",
1153
+ "primaryKey": false,
1154
+ "notNull": false,
1155
+ "autoincrement": false
1156
+ }
1157
+ },
1158
+ "indexes": {
1159
+ "organizations_slug_unique": {
1160
+ "name": "organizations_slug_unique",
1161
+ "columns": [
1162
+ "slug"
1163
+ ],
1164
+ "isUnique": true
1165
+ }
1166
+ },
1167
+ "foreignKeys": {
1168
+ "organizations_parent_id_organizations_id_fk": {
1169
+ "name": "organizations_parent_id_organizations_id_fk",
1170
+ "tableFrom": "organizations",
1171
+ "tableTo": "organizations",
1172
+ "columnsFrom": [
1173
+ "parent_id"
1174
+ ],
1175
+ "columnsTo": [
1176
+ "id"
1177
+ ],
1178
+ "onDelete": "set null",
1179
+ "onUpdate": "no action"
1180
+ }
1181
+ },
1182
+ "compositePrimaryKeys": {},
1183
+ "uniqueConstraints": {},
1184
+ "checkConstraints": {}
1185
+ },
1186
+ "posts": {
1187
+ "name": "posts",
1188
+ "columns": {
1189
+ "id": {
1190
+ "name": "id",
1191
+ "type": "text",
1192
+ "primaryKey": true,
1193
+ "notNull": true,
1194
+ "autoincrement": false
1195
+ },
1196
+ "author_user_id": {
1197
+ "name": "author_user_id",
1198
+ "type": "text",
1199
+ "primaryKey": false,
1200
+ "notNull": false,
1201
+ "autoincrement": false
1202
+ },
1203
+ "member_id": {
1204
+ "name": "member_id",
1205
+ "type": "text",
1206
+ "primaryKey": false,
1207
+ "notNull": false,
1208
+ "autoincrement": false
1209
+ },
1210
+ "organization_id": {
1211
+ "name": "organization_id",
1212
+ "type": "text",
1213
+ "primaryKey": false,
1214
+ "notNull": false,
1215
+ "autoincrement": false
1216
+ },
1217
+ "team_id": {
1218
+ "name": "team_id",
1219
+ "type": "text",
1220
+ "primaryKey": false,
1221
+ "notNull": false,
1222
+ "autoincrement": false
1223
+ },
1224
+ "title": {
1225
+ "name": "title",
1226
+ "type": "text",
1227
+ "primaryKey": false,
1228
+ "notNull": true,
1229
+ "autoincrement": false
1230
+ },
1231
+ "slug": {
1232
+ "name": "slug",
1233
+ "type": "text",
1234
+ "primaryKey": false,
1235
+ "notNull": true,
1236
+ "autoincrement": false
1237
+ },
1238
+ "excerpt": {
1239
+ "name": "excerpt",
1240
+ "type": "text",
1241
+ "primaryKey": false,
1242
+ "notNull": false,
1243
+ "autoincrement": false
1244
+ },
1245
+ "content": {
1246
+ "name": "content",
1247
+ "type": "text",
1248
+ "primaryKey": false,
1249
+ "notNull": true,
1250
+ "autoincrement": false
1251
+ },
1252
+ "status": {
1253
+ "name": "status",
1254
+ "type": "text",
1255
+ "primaryKey": false,
1256
+ "notNull": true,
1257
+ "autoincrement": false,
1258
+ "default": "'draft'"
1259
+ },
1260
+ "published_at": {
1261
+ "name": "published_at",
1262
+ "type": "integer",
1263
+ "primaryKey": false,
1264
+ "notNull": false,
1265
+ "autoincrement": false
1266
+ },
1267
+ "created_at": {
1268
+ "name": "created_at",
1269
+ "type": "integer",
1270
+ "primaryKey": false,
1271
+ "notNull": true,
1272
+ "autoincrement": false
1273
+ },
1274
+ "updated_at": {
1275
+ "name": "updated_at",
1276
+ "type": "integer",
1277
+ "primaryKey": false,
1278
+ "notNull": false,
1279
+ "autoincrement": false
1280
+ },
1281
+ "deleted_at": {
1282
+ "name": "deleted_at",
1283
+ "type": "integer",
1284
+ "primaryKey": false,
1285
+ "notNull": false,
1286
+ "autoincrement": false
1287
+ }
1288
+ },
1289
+ "indexes": {
1290
+ "posts_slug_unique": {
1291
+ "name": "posts_slug_unique",
1292
+ "columns": [
1293
+ "slug"
1294
+ ],
1295
+ "isUnique": true
1296
+ }
1297
+ },
1298
+ "foreignKeys": {
1299
+ "posts_author_user_id_users_id_fk": {
1300
+ "name": "posts_author_user_id_users_id_fk",
1301
+ "tableFrom": "posts",
1302
+ "tableTo": "users",
1303
+ "columnsFrom": [
1304
+ "author_user_id"
1305
+ ],
1306
+ "columnsTo": [
1307
+ "id"
1308
+ ],
1309
+ "onDelete": "set null",
1310
+ "onUpdate": "no action"
1311
+ },
1312
+ "posts_member_id_members_id_fk": {
1313
+ "name": "posts_member_id_members_id_fk",
1314
+ "tableFrom": "posts",
1315
+ "tableTo": "members",
1316
+ "columnsFrom": [
1317
+ "member_id"
1318
+ ],
1319
+ "columnsTo": [
1320
+ "id"
1321
+ ],
1322
+ "onDelete": "set null",
1323
+ "onUpdate": "no action"
1324
+ },
1325
+ "posts_organization_id_organizations_id_fk": {
1326
+ "name": "posts_organization_id_organizations_id_fk",
1327
+ "tableFrom": "posts",
1328
+ "tableTo": "organizations",
1329
+ "columnsFrom": [
1330
+ "organization_id"
1331
+ ],
1332
+ "columnsTo": [
1333
+ "id"
1334
+ ],
1335
+ "onDelete": "set null",
1336
+ "onUpdate": "no action"
1337
+ },
1338
+ "posts_team_id_teams_id_fk": {
1339
+ "name": "posts_team_id_teams_id_fk",
1340
+ "tableFrom": "posts",
1341
+ "tableTo": "teams",
1342
+ "columnsFrom": [
1343
+ "team_id"
1344
+ ],
1345
+ "columnsTo": [
1346
+ "id"
1347
+ ],
1348
+ "onDelete": "set null",
1349
+ "onUpdate": "no action"
1350
+ }
1351
+ },
1352
+ "compositePrimaryKeys": {},
1353
+ "uniqueConstraints": {},
1354
+ "checkConstraints": {}
1355
+ },
1356
+ "sessions": {
1357
+ "name": "sessions",
1358
+ "columns": {
1359
+ "id": {
1360
+ "name": "id",
1361
+ "type": "text",
1362
+ "primaryKey": true,
1363
+ "notNull": true,
1364
+ "autoincrement": false
1365
+ },
1366
+ "expires_at": {
1367
+ "name": "expires_at",
1368
+ "type": "integer",
1369
+ "primaryKey": false,
1370
+ "notNull": true,
1371
+ "autoincrement": false
1372
+ },
1373
+ "token": {
1374
+ "name": "token",
1375
+ "type": "text",
1376
+ "primaryKey": false,
1377
+ "notNull": true,
1378
+ "autoincrement": false
1379
+ },
1380
+ "created_at": {
1381
+ "name": "created_at",
1382
+ "type": "integer",
1383
+ "primaryKey": false,
1384
+ "notNull": true,
1385
+ "autoincrement": false
1386
+ },
1387
+ "updated_at": {
1388
+ "name": "updated_at",
1389
+ "type": "integer",
1390
+ "primaryKey": false,
1391
+ "notNull": true,
1392
+ "autoincrement": false
1393
+ },
1394
+ "ip_address": {
1395
+ "name": "ip_address",
1396
+ "type": "text",
1397
+ "primaryKey": false,
1398
+ "notNull": false,
1399
+ "autoincrement": false
1400
+ },
1401
+ "user_agent": {
1402
+ "name": "user_agent",
1403
+ "type": "text",
1404
+ "primaryKey": false,
1405
+ "notNull": false,
1406
+ "autoincrement": false
1407
+ },
1408
+ "user_id": {
1409
+ "name": "user_id",
1410
+ "type": "text",
1411
+ "primaryKey": false,
1412
+ "notNull": true,
1413
+ "autoincrement": false
1414
+ },
1415
+ "impersonated_by": {
1416
+ "name": "impersonated_by",
1417
+ "type": "text",
1418
+ "primaryKey": false,
1419
+ "notNull": false,
1420
+ "autoincrement": false
1421
+ },
1422
+ "active_organization_id": {
1423
+ "name": "active_organization_id",
1424
+ "type": "text",
1425
+ "primaryKey": false,
1426
+ "notNull": false,
1427
+ "autoincrement": false
1428
+ },
1429
+ "active_organization_member_id": {
1430
+ "name": "active_organization_member_id",
1431
+ "type": "text",
1432
+ "primaryKey": false,
1433
+ "notNull": false,
1434
+ "autoincrement": false
1435
+ },
1436
+ "active_organization_role": {
1437
+ "name": "active_organization_role",
1438
+ "type": "text",
1439
+ "primaryKey": false,
1440
+ "notNull": false,
1441
+ "autoincrement": false
1442
+ },
1443
+ "active_organization_type": {
1444
+ "name": "active_organization_type",
1445
+ "type": "text",
1446
+ "primaryKey": false,
1447
+ "notNull": false,
1448
+ "autoincrement": false
1449
+ },
1450
+ "active_team_id": {
1451
+ "name": "active_team_id",
1452
+ "type": "text",
1453
+ "primaryKey": false,
1454
+ "notNull": false,
1455
+ "autoincrement": false
1456
+ },
1457
+ "active_team_role": {
1458
+ "name": "active_team_role",
1459
+ "type": "text",
1460
+ "primaryKey": false,
1461
+ "notNull": false,
1462
+ "autoincrement": false
1463
+ }
1464
+ },
1465
+ "indexes": {
1466
+ "sessions_token_unique": {
1467
+ "name": "sessions_token_unique",
1468
+ "columns": [
1469
+ "token"
1470
+ ],
1471
+ "isUnique": true
1472
+ }
1473
+ },
1474
+ "foreignKeys": {
1475
+ "sessions_user_id_users_id_fk": {
1476
+ "name": "sessions_user_id_users_id_fk",
1477
+ "tableFrom": "sessions",
1478
+ "tableTo": "users",
1479
+ "columnsFrom": [
1480
+ "user_id"
1481
+ ],
1482
+ "columnsTo": [
1483
+ "id"
1484
+ ],
1485
+ "onDelete": "cascade",
1486
+ "onUpdate": "no action"
1487
+ }
1488
+ },
1489
+ "compositePrimaryKeys": {},
1490
+ "uniqueConstraints": {},
1491
+ "checkConstraints": {}
1492
+ },
1493
+ "teammembers": {
1494
+ "name": "teammembers",
1495
+ "columns": {
1496
+ "id": {
1497
+ "name": "id",
1498
+ "type": "text",
1499
+ "primaryKey": true,
1500
+ "notNull": true,
1501
+ "autoincrement": false
1502
+ },
1503
+ "team_id": {
1504
+ "name": "team_id",
1505
+ "type": "text",
1506
+ "primaryKey": false,
1507
+ "notNull": true,
1508
+ "autoincrement": false
1509
+ },
1510
+ "user_id": {
1511
+ "name": "user_id",
1512
+ "type": "text",
1513
+ "primaryKey": false,
1514
+ "notNull": true,
1515
+ "autoincrement": false
1516
+ },
1517
+ "role": {
1518
+ "name": "role",
1519
+ "type": "text",
1520
+ "primaryKey": false,
1521
+ "notNull": true,
1522
+ "autoincrement": false
1523
+ },
1524
+ "created_at": {
1525
+ "name": "created_at",
1526
+ "type": "integer",
1527
+ "primaryKey": false,
1528
+ "notNull": true,
1529
+ "autoincrement": false
1530
+ }
1531
+ },
1532
+ "indexes": {},
1533
+ "foreignKeys": {
1534
+ "teammembers_team_id_teams_id_fk": {
1535
+ "name": "teammembers_team_id_teams_id_fk",
1536
+ "tableFrom": "teammembers",
1537
+ "tableTo": "teams",
1538
+ "columnsFrom": [
1539
+ "team_id"
1540
+ ],
1541
+ "columnsTo": [
1542
+ "id"
1543
+ ],
1544
+ "onDelete": "no action",
1545
+ "onUpdate": "no action"
1546
+ },
1547
+ "teammembers_user_id_users_id_fk": {
1548
+ "name": "teammembers_user_id_users_id_fk",
1549
+ "tableFrom": "teammembers",
1550
+ "tableTo": "users",
1551
+ "columnsFrom": [
1552
+ "user_id"
1553
+ ],
1554
+ "columnsTo": [
1555
+ "id"
1556
+ ],
1557
+ "onDelete": "no action",
1558
+ "onUpdate": "no action"
1559
+ }
1560
+ },
1561
+ "compositePrimaryKeys": {},
1562
+ "uniqueConstraints": {},
1563
+ "checkConstraints": {}
1564
+ },
1565
+ "teams": {
1566
+ "name": "teams",
1567
+ "columns": {
1568
+ "id": {
1569
+ "name": "id",
1570
+ "type": "text",
1571
+ "primaryKey": true,
1572
+ "notNull": true,
1573
+ "autoincrement": false
1574
+ },
1575
+ "name": {
1576
+ "name": "name",
1577
+ "type": "text",
1578
+ "primaryKey": false,
1579
+ "notNull": true,
1580
+ "autoincrement": false
1581
+ },
1582
+ "organization_id": {
1583
+ "name": "organization_id",
1584
+ "type": "text",
1585
+ "primaryKey": false,
1586
+ "notNull": true,
1587
+ "autoincrement": false
1588
+ },
1589
+ "created_at": {
1590
+ "name": "created_at",
1591
+ "type": "integer",
1592
+ "primaryKey": false,
1593
+ "notNull": true,
1594
+ "autoincrement": false
1595
+ },
1596
+ "updated_at": {
1597
+ "name": "updated_at",
1598
+ "type": "integer",
1599
+ "primaryKey": false,
1600
+ "notNull": false,
1601
+ "autoincrement": false
1602
+ }
1603
+ },
1604
+ "indexes": {},
1605
+ "foreignKeys": {
1606
+ "teams_organization_id_organizations_id_fk": {
1607
+ "name": "teams_organization_id_organizations_id_fk",
1608
+ "tableFrom": "teams",
1609
+ "tableTo": "organizations",
1610
+ "columnsFrom": [
1611
+ "organization_id"
1612
+ ],
1613
+ "columnsTo": [
1614
+ "id"
1615
+ ],
1616
+ "onDelete": "no action",
1617
+ "onUpdate": "no action"
1618
+ }
1619
+ },
1620
+ "compositePrimaryKeys": {},
1621
+ "uniqueConstraints": {},
1622
+ "checkConstraints": {}
1623
+ },
1624
+ "users": {
1625
+ "name": "users",
1626
+ "columns": {
1627
+ "id": {
1628
+ "name": "id",
1629
+ "type": "text",
1630
+ "primaryKey": true,
1631
+ "notNull": true,
1632
+ "autoincrement": false
1633
+ },
1634
+ "name": {
1635
+ "name": "name",
1636
+ "type": "text",
1637
+ "primaryKey": false,
1638
+ "notNull": true,
1639
+ "autoincrement": false
1640
+ },
1641
+ "email": {
1642
+ "name": "email",
1643
+ "type": "text",
1644
+ "primaryKey": false,
1645
+ "notNull": true,
1646
+ "autoincrement": false
1647
+ },
1648
+ "email_verified": {
1649
+ "name": "email_verified",
1650
+ "type": "integer",
1651
+ "primaryKey": false,
1652
+ "notNull": true,
1653
+ "autoincrement": false
1654
+ },
1655
+ "image": {
1656
+ "name": "image",
1657
+ "type": "text",
1658
+ "primaryKey": false,
1659
+ "notNull": false,
1660
+ "autoincrement": false
1661
+ },
1662
+ "created_at": {
1663
+ "name": "created_at",
1664
+ "type": "integer",
1665
+ "primaryKey": false,
1666
+ "notNull": true,
1667
+ "autoincrement": false
1668
+ },
1669
+ "updated_at": {
1670
+ "name": "updated_at",
1671
+ "type": "integer",
1672
+ "primaryKey": false,
1673
+ "notNull": true,
1674
+ "autoincrement": false
1675
+ },
1676
+ "role": {
1677
+ "name": "role",
1678
+ "type": "text",
1679
+ "primaryKey": false,
1680
+ "notNull": false,
1681
+ "autoincrement": false
1682
+ },
1683
+ "banned": {
1684
+ "name": "banned",
1685
+ "type": "integer",
1686
+ "primaryKey": false,
1687
+ "notNull": false,
1688
+ "autoincrement": false
1689
+ },
1690
+ "ban_reason": {
1691
+ "name": "ban_reason",
1692
+ "type": "text",
1693
+ "primaryKey": false,
1694
+ "notNull": false,
1695
+ "autoincrement": false
1696
+ },
1697
+ "ban_expires": {
1698
+ "name": "ban_expires",
1699
+ "type": "integer",
1700
+ "primaryKey": false,
1701
+ "notNull": false,
1702
+ "autoincrement": false
1703
+ },
1704
+ "stripe_customer_id": {
1705
+ "name": "stripe_customer_id",
1706
+ "type": "text",
1707
+ "primaryKey": false,
1708
+ "notNull": false,
1709
+ "autoincrement": false
1710
+ },
1711
+ "payment_customer_id": {
1712
+ "name": "payment_customer_id",
1713
+ "type": "text",
1714
+ "primaryKey": false,
1715
+ "notNull": false,
1716
+ "autoincrement": false
1717
+ },
1718
+ "payment_plan_tier": {
1719
+ "name": "payment_plan_tier",
1720
+ "type": "text",
1721
+ "primaryKey": false,
1722
+ "notNull": false,
1723
+ "autoincrement": false
1724
+ },
1725
+ "payment_plan_expires_at": {
1726
+ "name": "payment_plan_expires_at",
1727
+ "type": "integer",
1728
+ "primaryKey": false,
1729
+ "notNull": false,
1730
+ "autoincrement": false
1731
+ },
1732
+ "preferences": {
1733
+ "name": "preferences",
1734
+ "type": "text",
1735
+ "primaryKey": false,
1736
+ "notNull": false,
1737
+ "autoincrement": false,
1738
+ "default": "'{}'"
1739
+ },
1740
+ "metadata": {
1741
+ "name": "metadata",
1742
+ "type": "text",
1743
+ "primaryKey": false,
1744
+ "notNull": false,
1745
+ "autoincrement": false,
1746
+ "default": "'{}'"
1747
+ },
1748
+ "onboarding": {
1749
+ "name": "onboarding",
1750
+ "type": "integer",
1751
+ "primaryKey": false,
1752
+ "notNull": false,
1753
+ "autoincrement": false
1754
+ },
1755
+ "flags": {
1756
+ "name": "flags",
1757
+ "type": "text",
1758
+ "primaryKey": false,
1759
+ "notNull": false,
1760
+ "autoincrement": false,
1761
+ "default": "'[]'"
1762
+ },
1763
+ "locale": {
1764
+ "name": "locale",
1765
+ "type": "text",
1766
+ "primaryKey": false,
1767
+ "notNull": false,
1768
+ "autoincrement": false
1769
+ }
1770
+ },
1771
+ "indexes": {
1772
+ "users_email_unique": {
1773
+ "name": "users_email_unique",
1774
+ "columns": [
1775
+ "email"
1776
+ ],
1777
+ "isUnique": true
1778
+ },
1779
+ "users_stripe_customer_id_unique": {
1780
+ "name": "users_stripe_customer_id_unique",
1781
+ "columns": [
1782
+ "stripe_customer_id"
1783
+ ],
1784
+ "isUnique": true
1785
+ },
1786
+ "users_payment_customer_id_unique": {
1787
+ "name": "users_payment_customer_id_unique",
1788
+ "columns": [
1789
+ "payment_customer_id"
1790
+ ],
1791
+ "isUnique": true
1792
+ }
1793
+ },
1794
+ "foreignKeys": {},
1795
+ "compositePrimaryKeys": {},
1796
+ "uniqueConstraints": {},
1797
+ "checkConstraints": {}
1798
+ },
1799
+ "verifications": {
1800
+ "name": "verifications",
1801
+ "columns": {
1802
+ "id": {
1803
+ "name": "id",
1804
+ "type": "text",
1805
+ "primaryKey": true,
1806
+ "notNull": true,
1807
+ "autoincrement": false
1808
+ },
1809
+ "identifier": {
1810
+ "name": "identifier",
1811
+ "type": "text",
1812
+ "primaryKey": false,
1813
+ "notNull": true,
1814
+ "autoincrement": false
1815
+ },
1816
+ "value": {
1817
+ "name": "value",
1818
+ "type": "text",
1819
+ "primaryKey": false,
1820
+ "notNull": true,
1821
+ "autoincrement": false
1822
+ },
1823
+ "expires_at": {
1824
+ "name": "expires_at",
1825
+ "type": "integer",
1826
+ "primaryKey": false,
1827
+ "notNull": true,
1828
+ "autoincrement": false
1829
+ },
1830
+ "created_at": {
1831
+ "name": "created_at",
1832
+ "type": "integer",
1833
+ "primaryKey": false,
1834
+ "notNull": false,
1835
+ "autoincrement": false
1836
+ },
1837
+ "updated_at": {
1838
+ "name": "updated_at",
1839
+ "type": "integer",
1840
+ "primaryKey": false,
1841
+ "notNull": false,
1842
+ "autoincrement": false
1843
+ }
1844
+ },
1845
+ "indexes": {},
1846
+ "foreignKeys": {},
1847
+ "compositePrimaryKeys": {},
1848
+ "uniqueConstraints": {},
1849
+ "checkConstraints": {}
1850
+ },
1851
+ "waitlist": {
1852
+ "name": "waitlist",
1853
+ "columns": {
1854
+ "id": {
1855
+ "name": "id",
1856
+ "type": "text",
1857
+ "primaryKey": true,
1858
+ "notNull": true,
1859
+ "autoincrement": false
1860
+ },
1861
+ "name": {
1862
+ "name": "name",
1863
+ "type": "text",
1864
+ "primaryKey": false,
1865
+ "notNull": false,
1866
+ "autoincrement": false
1867
+ },
1868
+ "email": {
1869
+ "name": "email",
1870
+ "type": "text",
1871
+ "primaryKey": false,
1872
+ "notNull": false,
1873
+ "autoincrement": false
1874
+ },
1875
+ "created_at": {
1876
+ "name": "created_at",
1877
+ "type": "integer",
1878
+ "primaryKey": false,
1879
+ "notNull": true,
1880
+ "autoincrement": false
1881
+ },
1882
+ "updated_at": {
1883
+ "name": "updated_at",
1884
+ "type": "integer",
1885
+ "primaryKey": false,
1886
+ "notNull": false,
1887
+ "autoincrement": false
1888
+ },
1889
+ "status": {
1890
+ "name": "status",
1891
+ "type": "text",
1892
+ "primaryKey": false,
1893
+ "notNull": true,
1894
+ "autoincrement": false,
1895
+ "default": "'WAITLIST'"
1896
+ },
1897
+ "type": {
1898
+ "name": "type",
1899
+ "type": "text",
1900
+ "primaryKey": false,
1901
+ "notNull": true,
1902
+ "autoincrement": false,
1903
+ "default": "'WAITLIST'"
1904
+ },
1905
+ "code": {
1906
+ "name": "code",
1907
+ "type": "text",
1908
+ "primaryKey": false,
1909
+ "notNull": false,
1910
+ "autoincrement": false
1911
+ },
1912
+ "expires_at": {
1913
+ "name": "expires_at",
1914
+ "type": "integer",
1915
+ "primaryKey": false,
1916
+ "notNull": false,
1917
+ "autoincrement": false
1918
+ },
1919
+ "user_id": {
1920
+ "name": "user_id",
1921
+ "type": "text",
1922
+ "primaryKey": false,
1923
+ "notNull": false,
1924
+ "autoincrement": false
1925
+ },
1926
+ "claim_user_id": {
1927
+ "name": "claim_user_id",
1928
+ "type": "text",
1929
+ "primaryKey": false,
1930
+ "notNull": false,
1931
+ "autoincrement": false
1932
+ },
1933
+ "claimed_at": {
1934
+ "name": "claimed_at",
1935
+ "type": "integer",
1936
+ "primaryKey": false,
1937
+ "notNull": false,
1938
+ "autoincrement": false
1939
+ },
1940
+ "claimed_email": {
1941
+ "name": "claimed_email",
1942
+ "type": "text",
1943
+ "primaryKey": false,
1944
+ "notNull": false,
1945
+ "autoincrement": false
1946
+ }
1947
+ },
1948
+ "indexes": {},
1949
+ "foreignKeys": {
1950
+ "waitlist_user_id_users_id_fk": {
1951
+ "name": "waitlist_user_id_users_id_fk",
1952
+ "tableFrom": "waitlist",
1953
+ "tableTo": "users",
1954
+ "columnsFrom": [
1955
+ "user_id"
1956
+ ],
1957
+ "columnsTo": [
1958
+ "id"
1959
+ ],
1960
+ "onDelete": "no action",
1961
+ "onUpdate": "no action"
1962
+ },
1963
+ "waitlist_claim_user_id_users_id_fk": {
1964
+ "name": "waitlist_claim_user_id_users_id_fk",
1965
+ "tableFrom": "waitlist",
1966
+ "tableTo": "users",
1967
+ "columnsFrom": [
1968
+ "claim_user_id"
1969
+ ],
1970
+ "columnsTo": [
1971
+ "id"
1972
+ ],
1973
+ "onDelete": "no action",
1974
+ "onUpdate": "no action"
1975
+ }
1976
+ },
1977
+ "compositePrimaryKeys": {},
1978
+ "uniqueConstraints": {},
1979
+ "checkConstraints": {}
1980
+ },
1981
+ "workflows": {
1982
+ "name": "workflows",
1983
+ "columns": {
1984
+ "id": {
1985
+ "name": "id",
1986
+ "type": "text",
1987
+ "primaryKey": true,
1988
+ "notNull": true,
1989
+ "autoincrement": false
1990
+ },
1991
+ "user_id": {
1992
+ "name": "user_id",
1993
+ "type": "text",
1994
+ "primaryKey": false,
1995
+ "notNull": false,
1996
+ "autoincrement": false
1997
+ },
1998
+ "job_id": {
1999
+ "name": "job_id",
2000
+ "type": "text",
2001
+ "primaryKey": false,
2002
+ "notNull": true,
2003
+ "autoincrement": false
2004
+ },
2005
+ "job_name": {
2006
+ "name": "job_name",
2007
+ "type": "text",
2008
+ "primaryKey": false,
2009
+ "notNull": true,
2010
+ "autoincrement": false
2011
+ },
2012
+ "queue_name": {
2013
+ "name": "queue_name",
2014
+ "type": "text",
2015
+ "primaryKey": false,
2016
+ "notNull": true,
2017
+ "autoincrement": false
2018
+ },
2019
+ "timeout": {
2020
+ "name": "timeout",
2021
+ "type": "integer",
2022
+ "primaryKey": false,
2023
+ "notNull": false,
2024
+ "autoincrement": false
2025
+ },
2026
+ "tags": {
2027
+ "name": "tags",
2028
+ "type": "text",
2029
+ "primaryKey": false,
2030
+ "notNull": false,
2031
+ "autoincrement": false
2032
+ },
2033
+ "input": {
2034
+ "name": "input",
2035
+ "type": "text",
2036
+ "primaryKey": false,
2037
+ "notNull": false,
2038
+ "autoincrement": false
2039
+ },
2040
+ "output": {
2041
+ "name": "output",
2042
+ "type": "text",
2043
+ "primaryKey": false,
2044
+ "notNull": false,
2045
+ "autoincrement": false
2046
+ },
2047
+ "status": {
2048
+ "name": "status",
2049
+ "type": "text",
2050
+ "primaryKey": false,
2051
+ "notNull": true,
2052
+ "autoincrement": false
2053
+ },
2054
+ "error": {
2055
+ "name": "error",
2056
+ "type": "text",
2057
+ "primaryKey": false,
2058
+ "notNull": false,
2059
+ "autoincrement": false
2060
+ },
2061
+ "retries": {
2062
+ "name": "retries",
2063
+ "type": "integer",
2064
+ "primaryKey": false,
2065
+ "notNull": true,
2066
+ "autoincrement": false,
2067
+ "default": 0
2068
+ },
2069
+ "finished_at": {
2070
+ "name": "finished_at",
2071
+ "type": "integer",
2072
+ "primaryKey": false,
2073
+ "notNull": false,
2074
+ "autoincrement": false
2075
+ },
2076
+ "processed_at": {
2077
+ "name": "processed_at",
2078
+ "type": "integer",
2079
+ "primaryKey": false,
2080
+ "notNull": false,
2081
+ "autoincrement": false
2082
+ },
2083
+ "created_at": {
2084
+ "name": "created_at",
2085
+ "type": "integer",
2086
+ "primaryKey": false,
2087
+ "notNull": true,
2088
+ "autoincrement": false
2089
+ },
2090
+ "updated_at": {
2091
+ "name": "updated_at",
2092
+ "type": "integer",
2093
+ "primaryKey": false,
2094
+ "notNull": true,
2095
+ "autoincrement": false
2096
+ }
2097
+ },
2098
+ "indexes": {
2099
+ "workflows_job_id_unique": {
2100
+ "name": "workflows_job_id_unique",
2101
+ "columns": [
2102
+ "job_id"
2103
+ ],
2104
+ "isUnique": true
2105
+ }
2106
+ },
2107
+ "foreignKeys": {
2108
+ "workflows_user_id_users_id_fk": {
2109
+ "name": "workflows_user_id_users_id_fk",
2110
+ "tableFrom": "workflows",
2111
+ "tableTo": "users",
2112
+ "columnsFrom": [
2113
+ "user_id"
2114
+ ],
2115
+ "columnsTo": [
2116
+ "id"
2117
+ ],
2118
+ "onDelete": "cascade",
2119
+ "onUpdate": "no action"
2120
+ }
2121
+ },
2122
+ "compositePrimaryKeys": {},
2123
+ "uniqueConstraints": {},
2124
+ "checkConstraints": {}
2125
+ }
2126
+ },
2127
+ "views": {},
2128
+ "enums": {},
2129
+ "_meta": {
2130
+ "schemas": {},
2131
+ "tables": {},
2132
+ "columns": {}
2133
+ },
2134
+ "internal": {
2135
+ "indexes": {}
2136
+ }
2137
+ }