@lssm/lib.files 0.0.0-canary-20251217080011 → 1.41.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 (138) hide show
  1. package/dist/contracts/index.js +1 -858
  2. package/dist/docs/files.docblock.js +2 -22
  3. package/dist/docs/index.js +1 -1
  4. package/dist/entities/index.js +1 -265
  5. package/dist/events.js +1 -343
  6. package/dist/files.feature.js +1 -124
  7. package/dist/index.js +1 -8
  8. package/dist/storage/index.js +1 -268
  9. package/package.json +13 -14
  10. package/dist/contracts/dist/capabilities/openbanking.js +0 -88
  11. package/dist/contracts/dist/client/index.js +0 -5
  12. package/dist/contracts/dist/client/react/feature-render.js +0 -2
  13. package/dist/contracts/dist/client/react/form-render.js +0 -4
  14. package/dist/contracts/dist/client/react/index.js +0 -4
  15. package/dist/contracts/dist/contract-registry/index.js +0 -1
  16. package/dist/contracts/dist/contract-registry/schemas.js +0 -60
  17. package/dist/contracts/dist/docs/PUBLISHING.docblock.js +0 -16
  18. package/dist/contracts/dist/docs/accessibility_wcag_compliance_specs.docblock.js +0 -16
  19. package/dist/contracts/dist/docs/index.js +0 -29
  20. package/dist/contracts/dist/docs/presentations.js +0 -71
  21. package/dist/contracts/dist/docs/registry.js +0 -44
  22. package/dist/contracts/dist/docs/tech/PHASE_1_QUICKSTART.docblock.js +0 -16
  23. package/dist/contracts/dist/docs/tech/PHASE_2_AI_NATIVE_OPERATIONS.docblock.js +0 -16
  24. package/dist/contracts/dist/docs/tech/PHASE_3_AUTO_EVOLUTION.docblock.js +0 -16
  25. package/dist/contracts/dist/docs/tech/PHASE_4_PERSONALIZATION_ENGINE.docblock.js +0 -16
  26. package/dist/contracts/dist/docs/tech/PHASE_5_ZERO_TOUCH_OPERATIONS.docblock.js +0 -16
  27. package/dist/contracts/dist/docs/tech/auth/better-auth-nextjs.docblock.js +0 -80
  28. package/dist/contracts/dist/docs/tech/contracts/openapi-export.docblock.js +0 -57
  29. package/dist/contracts/dist/docs/tech/lifecycle-stage-system.docblock.js +0 -16
  30. package/dist/contracts/dist/docs/tech/llm/llm-integration.docblock.js +0 -357
  31. package/dist/contracts/dist/docs/tech/mcp-endpoints.docblock.js +0 -37
  32. package/dist/contracts/dist/docs/tech/presentation-runtime.docblock.js +0 -16
  33. package/dist/contracts/dist/docs/tech/schema/README.docblock.js +0 -20
  34. package/dist/contracts/dist/docs/tech/studio/learning-events.docblock.js +0 -48
  35. package/dist/contracts/dist/docs/tech/studio/learning-journeys.docblock.js +0 -79
  36. package/dist/contracts/dist/docs/tech/studio/platform-admin-panel.docblock.js +0 -84
  37. package/dist/contracts/dist/docs/tech/studio/project-access-teams.docblock.js +0 -45
  38. package/dist/contracts/dist/docs/tech/studio/project-routing.docblock.js +0 -67
  39. package/dist/contracts/dist/docs/tech/studio/sandbox-unlogged.docblock.js +0 -40
  40. package/dist/contracts/dist/docs/tech/studio/team-invitations.docblock.js +0 -69
  41. package/dist/contracts/dist/docs/tech/studio/workspace-ops.docblock.js +0 -47
  42. package/dist/contracts/dist/docs/tech/studio/workspaces.docblock.js +0 -62
  43. package/dist/contracts/dist/docs/tech/telemetry-ingest.docblock.js +0 -155
  44. package/dist/contracts/dist/docs/tech/templates/runtime.docblock.js +0 -20
  45. package/dist/contracts/dist/docs/tech/vscode-extension.docblock.js +0 -101
  46. package/dist/contracts/dist/docs/tech/workflows/overview.docblock.js +0 -20
  47. package/dist/contracts/dist/events.js +0 -10
  48. package/dist/contracts/dist/experiments/evaluator.js +0 -1
  49. package/dist/contracts/dist/index.js +0 -71
  50. package/dist/contracts/dist/install.js +0 -2
  51. package/dist/contracts/dist/integrations/contracts.js +0 -377
  52. package/dist/contracts/dist/integrations/index.js +0 -18
  53. package/dist/contracts/dist/integrations/openbanking/contracts/accounts.js +0 -228
  54. package/dist/contracts/dist/integrations/openbanking/contracts/balances.js +0 -159
  55. package/dist/contracts/dist/integrations/openbanking/contracts/index.js +0 -3
  56. package/dist/contracts/dist/integrations/openbanking/contracts/transactions.js +0 -210
  57. package/dist/contracts/dist/integrations/openbanking/models.js +0 -242
  58. package/dist/contracts/dist/integrations/openbanking/telemetry.js +0 -13
  59. package/dist/contracts/dist/integrations/providers/elevenlabs.js +0 -52
  60. package/dist/contracts/dist/integrations/providers/gcs-storage.js +0 -75
  61. package/dist/contracts/dist/integrations/providers/gmail.js +0 -87
  62. package/dist/contracts/dist/integrations/providers/google-calendar.js +0 -66
  63. package/dist/contracts/dist/integrations/providers/index.js +0 -11
  64. package/dist/contracts/dist/integrations/providers/mistral.js +0 -68
  65. package/dist/contracts/dist/integrations/providers/postmark.js +0 -68
  66. package/dist/contracts/dist/integrations/providers/powens.js +0 -116
  67. package/dist/contracts/dist/integrations/providers/qdrant.js +0 -73
  68. package/dist/contracts/dist/integrations/providers/registry.js +0 -10
  69. package/dist/contracts/dist/integrations/providers/stripe.js +0 -83
  70. package/dist/contracts/dist/integrations/providers/twilio-sms.js +0 -61
  71. package/dist/contracts/dist/jsonschema.js +0 -1
  72. package/dist/contracts/dist/knowledge/contracts.js +0 -306
  73. package/dist/contracts/dist/knowledge/index.js +0 -7
  74. package/dist/contracts/dist/knowledge/spaces/email-threads.js +0 -34
  75. package/dist/contracts/dist/knowledge/spaces/financial-docs.js +0 -34
  76. package/dist/contracts/dist/knowledge/spaces/financial-overview.js +0 -38
  77. package/dist/contracts/dist/knowledge/spaces/index.js +0 -6
  78. package/dist/contracts/dist/knowledge/spaces/product-canon.js +0 -34
  79. package/dist/contracts/dist/knowledge/spaces/support-faq.js +0 -37
  80. package/dist/contracts/dist/knowledge/spaces/uploaded-docs.js +0 -34
  81. package/dist/contracts/dist/llm/exporters.js +0 -19
  82. package/dist/contracts/dist/llm/index.js +0 -2
  83. package/dist/contracts/dist/llm/prompts.js +0 -1
  84. package/dist/contracts/dist/onboarding-base.js +0 -196
  85. package/dist/contracts/dist/openapi.js +0 -1
  86. package/dist/contracts/dist/ownership.js +0 -21
  87. package/dist/contracts/dist/presentations.js +0 -1
  88. package/dist/contracts/dist/presentations.v2.js +0 -11
  89. package/dist/contracts/dist/prompt.js +0 -1
  90. package/dist/contracts/dist/promptRegistry.js +0 -1
  91. package/dist/contracts/dist/regenerator/index.js +0 -1
  92. package/dist/contracts/dist/regenerator/service.js +0 -6
  93. package/dist/contracts/dist/registry.js +0 -2
  94. package/dist/contracts/dist/resources.js +0 -1
  95. package/dist/contracts/dist/schema/dist/EnumType.js +0 -2
  96. package/dist/contracts/dist/schema/dist/FieldType.js +0 -49
  97. package/dist/contracts/dist/schema/dist/ScalarTypeEnum.js +0 -236
  98. package/dist/contracts/dist/schema/dist/SchemaModel.js +0 -34
  99. package/dist/contracts/dist/schema/dist/entity/defineEntity.js +0 -1
  100. package/dist/contracts/dist/schema/dist/entity/index.js +0 -2
  101. package/dist/contracts/dist/schema/dist/entity/types.js +0 -1
  102. package/dist/contracts/dist/schema/dist/index.js +0 -6
  103. package/dist/contracts/dist/server/graphql-pothos.js +0 -6
  104. package/dist/contracts/dist/server/index.js +0 -8
  105. package/dist/contracts/dist/server/mcp/createMcpServer.js +0 -4
  106. package/dist/contracts/dist/server/mcp/registerPresentations.js +0 -2
  107. package/dist/contracts/dist/server/mcp/registerPrompts.js +0 -1
  108. package/dist/contracts/dist/server/mcp/registerResources.js +0 -2
  109. package/dist/contracts/dist/server/mcp/registerTools.js +0 -1
  110. package/dist/contracts/dist/server/provider-mcp.js +0 -1
  111. package/dist/contracts/dist/server/rest-elysia.js +0 -1
  112. package/dist/contracts/dist/server/rest-express.js +0 -1
  113. package/dist/contracts/dist/server/rest-generic.js +0 -1
  114. package/dist/contracts/dist/server/rest-next-app.js +0 -1
  115. package/dist/contracts/dist/server/rest-next-pages.js +0 -1
  116. package/dist/contracts/dist/spec.js +0 -34
  117. package/dist/contracts/dist/telemetry/index.js +0 -1
  118. package/dist/contracts/dist/telemetry/tracker.js +0 -1
  119. package/dist/contracts/dist/tests/index.js +0 -1
  120. package/dist/contracts/dist/tests/runner.js +0 -2
  121. package/dist/contracts/dist/workflow/index.js +0 -1
  122. package/dist/contracts/dist/workflow/runner.js +0 -1
  123. package/dist/contracts/index.d.ts +0 -1139
  124. package/dist/docs/files.docblock.d.ts +0 -1
  125. package/dist/docs/index.d.ts +0 -1
  126. package/dist/entities/index.d.ts +0 -168
  127. package/dist/events.d.ts +0 -467
  128. package/dist/files.feature.d.ts +0 -11
  129. package/dist/index.d.ts +0 -6
  130. package/dist/schema/dist/EnumType.js +0 -2
  131. package/dist/schema/dist/FieldType.js +0 -49
  132. package/dist/schema/dist/ScalarTypeEnum.js +0 -236
  133. package/dist/schema/dist/SchemaModel.js +0 -39
  134. package/dist/schema/dist/entity/defineEntity.js +0 -236
  135. package/dist/schema/dist/entity/index.js +0 -2
  136. package/dist/schema/dist/entity/types.js +0 -1
  137. package/dist/schema/dist/index.js +0 -6
  138. package/dist/storage/index.d.ts +0 -200
@@ -1,858 +1 @@
1
- import { ScalarTypeEnum } from "../schema/dist/ScalarTypeEnum.js";
2
- import { defineSchemaModel } from "../schema/dist/SchemaModel.js";
3
- import "../schema/dist/index.js";
4
- import { defineCommand, defineQuery } from "./dist/spec.js";
5
- import "./dist/index.js";
6
-
7
- //#region src/contracts/index.ts
8
- const OWNERS = ["platform.files"];
9
- const FileModel = defineSchemaModel({
10
- name: "File",
11
- description: "Represents an uploaded file",
12
- fields: {
13
- id: {
14
- type: ScalarTypeEnum.String_unsecure(),
15
- isOptional: false
16
- },
17
- name: {
18
- type: ScalarTypeEnum.String_unsecure(),
19
- isOptional: false
20
- },
21
- mimeType: {
22
- type: ScalarTypeEnum.String_unsecure(),
23
- isOptional: false
24
- },
25
- size: {
26
- type: ScalarTypeEnum.Int_unsecure(),
27
- isOptional: false
28
- },
29
- storageProvider: {
30
- type: ScalarTypeEnum.String_unsecure(),
31
- isOptional: false
32
- },
33
- storagePath: {
34
- type: ScalarTypeEnum.String_unsecure(),
35
- isOptional: false
36
- },
37
- checksum: {
38
- type: ScalarTypeEnum.String_unsecure(),
39
- isOptional: true
40
- },
41
- status: {
42
- type: ScalarTypeEnum.String_unsecure(),
43
- isOptional: false
44
- },
45
- isPublic: {
46
- type: ScalarTypeEnum.Boolean(),
47
- isOptional: false
48
- },
49
- ownerId: {
50
- type: ScalarTypeEnum.String_unsecure(),
51
- isOptional: false
52
- },
53
- orgId: {
54
- type: ScalarTypeEnum.String_unsecure(),
55
- isOptional: true
56
- },
57
- metadata: {
58
- type: ScalarTypeEnum.JSON(),
59
- isOptional: true
60
- },
61
- width: {
62
- type: ScalarTypeEnum.Int_unsecure(),
63
- isOptional: true
64
- },
65
- height: {
66
- type: ScalarTypeEnum.Int_unsecure(),
67
- isOptional: true
68
- },
69
- createdAt: {
70
- type: ScalarTypeEnum.DateTime(),
71
- isOptional: false
72
- },
73
- updatedAt: {
74
- type: ScalarTypeEnum.DateTime(),
75
- isOptional: false
76
- }
77
- }
78
- });
79
- const FileVersionModel = defineSchemaModel({
80
- name: "FileVersion",
81
- description: "Represents a file version",
82
- fields: {
83
- id: {
84
- type: ScalarTypeEnum.String_unsecure(),
85
- isOptional: false
86
- },
87
- fileId: {
88
- type: ScalarTypeEnum.String_unsecure(),
89
- isOptional: false
90
- },
91
- version: {
92
- type: ScalarTypeEnum.Int_unsecure(),
93
- isOptional: false
94
- },
95
- size: {
96
- type: ScalarTypeEnum.Int_unsecure(),
97
- isOptional: false
98
- },
99
- storagePath: {
100
- type: ScalarTypeEnum.String_unsecure(),
101
- isOptional: false
102
- },
103
- checksum: {
104
- type: ScalarTypeEnum.String_unsecure(),
105
- isOptional: true
106
- },
107
- comment: {
108
- type: ScalarTypeEnum.String_unsecure(),
109
- isOptional: true
110
- },
111
- createdBy: {
112
- type: ScalarTypeEnum.String_unsecure(),
113
- isOptional: false
114
- },
115
- createdAt: {
116
- type: ScalarTypeEnum.DateTime(),
117
- isOptional: false
118
- }
119
- }
120
- });
121
- const AttachmentModel = defineSchemaModel({
122
- name: "Attachment",
123
- description: "Represents an attachment",
124
- fields: {
125
- id: {
126
- type: ScalarTypeEnum.String_unsecure(),
127
- isOptional: false
128
- },
129
- fileId: {
130
- type: ScalarTypeEnum.String_unsecure(),
131
- isOptional: false
132
- },
133
- entityType: {
134
- type: ScalarTypeEnum.String_unsecure(),
135
- isOptional: false
136
- },
137
- entityId: {
138
- type: ScalarTypeEnum.String_unsecure(),
139
- isOptional: false
140
- },
141
- attachmentType: {
142
- type: ScalarTypeEnum.String_unsecure(),
143
- isOptional: true
144
- },
145
- name: {
146
- type: ScalarTypeEnum.String_unsecure(),
147
- isOptional: true
148
- },
149
- description: {
150
- type: ScalarTypeEnum.String_unsecure(),
151
- isOptional: true
152
- },
153
- order: {
154
- type: ScalarTypeEnum.Int_unsecure(),
155
- isOptional: false
156
- },
157
- metadata: {
158
- type: ScalarTypeEnum.JSON(),
159
- isOptional: true
160
- },
161
- createdBy: {
162
- type: ScalarTypeEnum.String_unsecure(),
163
- isOptional: false
164
- },
165
- createdAt: {
166
- type: ScalarTypeEnum.DateTime(),
167
- isOptional: false
168
- },
169
- file: {
170
- type: FileModel,
171
- isOptional: true
172
- }
173
- }
174
- });
175
- const PresignedUrlModel = defineSchemaModel({
176
- name: "PresignedUrl",
177
- description: "A presigned URL for file operations",
178
- fields: {
179
- url: {
180
- type: ScalarTypeEnum.String_unsecure(),
181
- isOptional: false
182
- },
183
- fields: {
184
- type: ScalarTypeEnum.JSON(),
185
- isOptional: true
186
- },
187
- expiresAt: {
188
- type: ScalarTypeEnum.DateTime(),
189
- isOptional: false
190
- },
191
- fileId: {
192
- type: ScalarTypeEnum.String_unsecure(),
193
- isOptional: true
194
- },
195
- sessionId: {
196
- type: ScalarTypeEnum.String_unsecure(),
197
- isOptional: true
198
- }
199
- }
200
- });
201
- const UploadFileInput = defineSchemaModel({
202
- name: "UploadFileInput",
203
- description: "Input for uploading a file",
204
- fields: {
205
- name: {
206
- type: ScalarTypeEnum.String_unsecure(),
207
- isOptional: false
208
- },
209
- mimeType: {
210
- type: ScalarTypeEnum.String_unsecure(),
211
- isOptional: false
212
- },
213
- size: {
214
- type: ScalarTypeEnum.Int_unsecure(),
215
- isOptional: false
216
- },
217
- content: {
218
- type: ScalarTypeEnum.String_unsecure(),
219
- isOptional: false
220
- },
221
- orgId: {
222
- type: ScalarTypeEnum.String_unsecure(),
223
- isOptional: true
224
- },
225
- isPublic: {
226
- type: ScalarTypeEnum.Boolean(),
227
- isOptional: true
228
- },
229
- metadata: {
230
- type: ScalarTypeEnum.JSON(),
231
- isOptional: true
232
- },
233
- tags: {
234
- type: ScalarTypeEnum.JSON(),
235
- isOptional: true
236
- }
237
- }
238
- });
239
- const UpdateFileInput = defineSchemaModel({
240
- name: "UpdateFileInput",
241
- description: "Input for updating a file",
242
- fields: {
243
- fileId: {
244
- type: ScalarTypeEnum.String_unsecure(),
245
- isOptional: false
246
- },
247
- name: {
248
- type: ScalarTypeEnum.String_unsecure(),
249
- isOptional: true
250
- },
251
- isPublic: {
252
- type: ScalarTypeEnum.Boolean(),
253
- isOptional: true
254
- },
255
- metadata: {
256
- type: ScalarTypeEnum.JSON(),
257
- isOptional: true
258
- },
259
- tags: {
260
- type: ScalarTypeEnum.JSON(),
261
- isOptional: true
262
- }
263
- }
264
- });
265
- const DeleteFileInput = defineSchemaModel({
266
- name: "DeleteFileInput",
267
- description: "Input for deleting a file",
268
- fields: { fileId: {
269
- type: ScalarTypeEnum.String_unsecure(),
270
- isOptional: false
271
- } }
272
- });
273
- const GetFileInput = defineSchemaModel({
274
- name: "GetFileInput",
275
- description: "Input for getting a file",
276
- fields: { fileId: {
277
- type: ScalarTypeEnum.String_unsecure(),
278
- isOptional: false
279
- } }
280
- });
281
- const ListFilesInput = defineSchemaModel({
282
- name: "ListFilesInput",
283
- description: "Input for listing files",
284
- fields: {
285
- orgId: {
286
- type: ScalarTypeEnum.String_unsecure(),
287
- isOptional: true
288
- },
289
- ownerId: {
290
- type: ScalarTypeEnum.String_unsecure(),
291
- isOptional: true
292
- },
293
- mimeType: {
294
- type: ScalarTypeEnum.String_unsecure(),
295
- isOptional: true
296
- },
297
- status: {
298
- type: ScalarTypeEnum.String_unsecure(),
299
- isOptional: true
300
- },
301
- tags: {
302
- type: ScalarTypeEnum.JSON(),
303
- isOptional: true
304
- },
305
- limit: {
306
- type: ScalarTypeEnum.Int_unsecure(),
307
- isOptional: true
308
- },
309
- offset: {
310
- type: ScalarTypeEnum.Int_unsecure(),
311
- isOptional: true
312
- }
313
- }
314
- });
315
- const ListFilesOutput = defineSchemaModel({
316
- name: "ListFilesOutput",
317
- description: "Output for listing files",
318
- fields: {
319
- files: {
320
- type: FileModel,
321
- isArray: true,
322
- isOptional: false
323
- },
324
- total: {
325
- type: ScalarTypeEnum.Int_unsecure(),
326
- isOptional: false
327
- }
328
- }
329
- });
330
- const GetDownloadUrlInput = defineSchemaModel({
331
- name: "GetDownloadUrlInput",
332
- description: "Input for getting a download URL",
333
- fields: {
334
- fileId: {
335
- type: ScalarTypeEnum.String_unsecure(),
336
- isOptional: false
337
- },
338
- expiresInSeconds: {
339
- type: ScalarTypeEnum.Int_unsecure(),
340
- isOptional: true
341
- }
342
- }
343
- });
344
- const CreateVersionInput = defineSchemaModel({
345
- name: "CreateVersionInput",
346
- description: "Input for creating a file version",
347
- fields: {
348
- fileId: {
349
- type: ScalarTypeEnum.String_unsecure(),
350
- isOptional: false
351
- },
352
- content: {
353
- type: ScalarTypeEnum.String_unsecure(),
354
- isOptional: false
355
- },
356
- comment: {
357
- type: ScalarTypeEnum.String_unsecure(),
358
- isOptional: true
359
- }
360
- }
361
- });
362
- const GetVersionsInput = defineSchemaModel({
363
- name: "GetVersionsInput",
364
- description: "Input for getting file versions",
365
- fields: {
366
- fileId: {
367
- type: ScalarTypeEnum.String_unsecure(),
368
- isOptional: false
369
- },
370
- limit: {
371
- type: ScalarTypeEnum.Int_unsecure(),
372
- isOptional: true
373
- },
374
- offset: {
375
- type: ScalarTypeEnum.Int_unsecure(),
376
- isOptional: true
377
- }
378
- }
379
- });
380
- const GetVersionsOutput = defineSchemaModel({
381
- name: "GetVersionsOutput",
382
- description: "Output for getting file versions",
383
- fields: {
384
- versions: {
385
- type: FileVersionModel,
386
- isArray: true,
387
- isOptional: false
388
- },
389
- total: {
390
- type: ScalarTypeEnum.Int_unsecure(),
391
- isOptional: false
392
- }
393
- }
394
- });
395
- const AttachFileInput = defineSchemaModel({
396
- name: "AttachFileInput",
397
- description: "Input for attaching a file to an entity",
398
- fields: {
399
- fileId: {
400
- type: ScalarTypeEnum.String_unsecure(),
401
- isOptional: false
402
- },
403
- entityType: {
404
- type: ScalarTypeEnum.String_unsecure(),
405
- isOptional: false
406
- },
407
- entityId: {
408
- type: ScalarTypeEnum.String_unsecure(),
409
- isOptional: false
410
- },
411
- attachmentType: {
412
- type: ScalarTypeEnum.String_unsecure(),
413
- isOptional: true
414
- },
415
- name: {
416
- type: ScalarTypeEnum.String_unsecure(),
417
- isOptional: true
418
- },
419
- description: {
420
- type: ScalarTypeEnum.String_unsecure(),
421
- isOptional: true
422
- },
423
- order: {
424
- type: ScalarTypeEnum.Int_unsecure(),
425
- isOptional: true
426
- },
427
- metadata: {
428
- type: ScalarTypeEnum.JSON(),
429
- isOptional: true
430
- }
431
- }
432
- });
433
- const DetachFileInput = defineSchemaModel({
434
- name: "DetachFileInput",
435
- description: "Input for detaching a file",
436
- fields: { attachmentId: {
437
- type: ScalarTypeEnum.String_unsecure(),
438
- isOptional: false
439
- } }
440
- });
441
- const ListAttachmentsInput = defineSchemaModel({
442
- name: "ListAttachmentsInput",
443
- description: "Input for listing attachments",
444
- fields: {
445
- entityType: {
446
- type: ScalarTypeEnum.String_unsecure(),
447
- isOptional: false
448
- },
449
- entityId: {
450
- type: ScalarTypeEnum.String_unsecure(),
451
- isOptional: false
452
- },
453
- attachmentType: {
454
- type: ScalarTypeEnum.String_unsecure(),
455
- isOptional: true
456
- }
457
- }
458
- });
459
- const ListAttachmentsOutput = defineSchemaModel({
460
- name: "ListAttachmentsOutput",
461
- description: "Output for listing attachments",
462
- fields: {
463
- attachments: {
464
- type: AttachmentModel,
465
- isArray: true,
466
- isOptional: false
467
- },
468
- total: {
469
- type: ScalarTypeEnum.Int_unsecure(),
470
- isOptional: false
471
- }
472
- }
473
- });
474
- const CreatePresignedUrlInput = defineSchemaModel({
475
- name: "CreatePresignedUrlInput",
476
- description: "Input for creating a presigned upload URL",
477
- fields: {
478
- fileName: {
479
- type: ScalarTypeEnum.String_unsecure(),
480
- isOptional: false
481
- },
482
- mimeType: {
483
- type: ScalarTypeEnum.String_unsecure(),
484
- isOptional: false
485
- },
486
- size: {
487
- type: ScalarTypeEnum.Int_unsecure(),
488
- isOptional: false
489
- },
490
- orgId: {
491
- type: ScalarTypeEnum.String_unsecure(),
492
- isOptional: true
493
- },
494
- expiresInSeconds: {
495
- type: ScalarTypeEnum.Int_unsecure(),
496
- isOptional: true
497
- }
498
- }
499
- });
500
- const SuccessOutput = defineSchemaModel({
501
- name: "SuccessOutput",
502
- description: "Generic success output",
503
- fields: { success: {
504
- type: ScalarTypeEnum.Boolean(),
505
- isOptional: false
506
- } }
507
- });
508
- /**
509
- * Upload a file.
510
- */
511
- const UploadFileContract = defineCommand({
512
- meta: {
513
- name: "file.upload",
514
- version: 1,
515
- stability: "stable",
516
- owners: [...OWNERS],
517
- tags: ["files", "upload"],
518
- description: "Upload a new file.",
519
- goal: "Store a file and create a file record.",
520
- context: "Called when uploading files directly."
521
- },
522
- io: {
523
- input: UploadFileInput,
524
- output: FileModel,
525
- errors: {
526
- FILE_TOO_LARGE: {
527
- description: "File exceeds size limit",
528
- http: 413,
529
- gqlCode: "FILE_TOO_LARGE",
530
- when: "File size exceeds configured limit"
531
- },
532
- INVALID_MIME_TYPE: {
533
- description: "MIME type not allowed",
534
- http: 415,
535
- gqlCode: "INVALID_MIME_TYPE",
536
- when: "File type is not in allowed list"
537
- }
538
- }
539
- },
540
- policy: { auth: "user" }
541
- });
542
- /**
543
- * Update a file.
544
- */
545
- const UpdateFileContract = defineCommand({
546
- meta: {
547
- name: "file.update",
548
- version: 1,
549
- stability: "stable",
550
- owners: [...OWNERS],
551
- tags: ["files", "update"],
552
- description: "Update file metadata.",
553
- goal: "Modify file properties without replacing content.",
554
- context: "Called when renaming or updating file metadata."
555
- },
556
- io: {
557
- input: UpdateFileInput,
558
- output: FileModel,
559
- errors: { FILE_NOT_FOUND: {
560
- description: "File does not exist",
561
- http: 404,
562
- gqlCode: "FILE_NOT_FOUND",
563
- when: "File ID is invalid"
564
- } }
565
- },
566
- policy: { auth: "user" }
567
- });
568
- /**
569
- * Delete a file.
570
- */
571
- const DeleteFileContract = defineCommand({
572
- meta: {
573
- name: "file.delete",
574
- version: 1,
575
- stability: "stable",
576
- owners: [...OWNERS],
577
- tags: ["files", "delete"],
578
- description: "Delete a file.",
579
- goal: "Remove a file and all its versions and attachments.",
580
- context: "Called when removing a file permanently."
581
- },
582
- io: {
583
- input: DeleteFileInput,
584
- output: SuccessOutput,
585
- errors: { FILE_NOT_FOUND: {
586
- description: "File does not exist",
587
- http: 404,
588
- gqlCode: "FILE_NOT_FOUND",
589
- when: "File ID is invalid"
590
- } }
591
- },
592
- policy: { auth: "user" }
593
- });
594
- /**
595
- * Get a file by ID.
596
- */
597
- const GetFileContract = defineQuery({
598
- meta: {
599
- name: "file.get",
600
- version: 1,
601
- stability: "stable",
602
- owners: [...OWNERS],
603
- tags: ["files", "get"],
604
- description: "Get a file by ID.",
605
- goal: "Retrieve file metadata.",
606
- context: "Called to inspect file details."
607
- },
608
- io: {
609
- input: GetFileInput,
610
- output: FileModel,
611
- errors: { FILE_NOT_FOUND: {
612
- description: "File does not exist",
613
- http: 404,
614
- gqlCode: "FILE_NOT_FOUND",
615
- when: "File ID is invalid"
616
- } }
617
- },
618
- policy: { auth: "user" }
619
- });
620
- /**
621
- * List files.
622
- */
623
- const ListFilesContract = defineQuery({
624
- meta: {
625
- name: "file.list",
626
- version: 1,
627
- stability: "stable",
628
- owners: [...OWNERS],
629
- tags: ["files", "list"],
630
- description: "List files with filtering.",
631
- goal: "Browse uploaded files.",
632
- context: "Called to browse file library."
633
- },
634
- io: {
635
- input: ListFilesInput,
636
- output: ListFilesOutput
637
- },
638
- policy: { auth: "user" }
639
- });
640
- /**
641
- * Get download URL.
642
- */
643
- const GetDownloadUrlContract = defineQuery({
644
- meta: {
645
- name: "file.downloadUrl",
646
- version: 1,
647
- stability: "stable",
648
- owners: [...OWNERS],
649
- tags: ["files", "download"],
650
- description: "Get a presigned download URL.",
651
- goal: "Generate a temporary URL for downloading.",
652
- context: "Called when user wants to download a file."
653
- },
654
- io: {
655
- input: GetDownloadUrlInput,
656
- output: PresignedUrlModel,
657
- errors: { FILE_NOT_FOUND: {
658
- description: "File does not exist",
659
- http: 404,
660
- gqlCode: "FILE_NOT_FOUND",
661
- when: "File ID is invalid"
662
- } }
663
- },
664
- policy: { auth: "user" }
665
- });
666
- /**
667
- * Create a file version.
668
- */
669
- const CreateVersionContract = defineCommand({
670
- meta: {
671
- name: "file.version.create",
672
- version: 1,
673
- stability: "stable",
674
- owners: [...OWNERS],
675
- tags: [
676
- "files",
677
- "version",
678
- "create"
679
- ],
680
- description: "Create a new version of a file.",
681
- goal: "Upload a new version while preserving history.",
682
- context: "Called when updating a document."
683
- },
684
- io: {
685
- input: CreateVersionInput,
686
- output: FileVersionModel,
687
- errors: { FILE_NOT_FOUND: {
688
- description: "File does not exist",
689
- http: 404,
690
- gqlCode: "FILE_NOT_FOUND",
691
- when: "File ID is invalid"
692
- } }
693
- },
694
- policy: { auth: "user" }
695
- });
696
- /**
697
- * Get file versions.
698
- */
699
- const GetVersionsContract = defineQuery({
700
- meta: {
701
- name: "file.version.list",
702
- version: 1,
703
- stability: "stable",
704
- owners: [...OWNERS],
705
- tags: [
706
- "files",
707
- "version",
708
- "list"
709
- ],
710
- description: "Get file version history.",
711
- goal: "View all versions of a file.",
712
- context: "Called to browse file history."
713
- },
714
- io: {
715
- input: GetVersionsInput,
716
- output: GetVersionsOutput,
717
- errors: { FILE_NOT_FOUND: {
718
- description: "File does not exist",
719
- http: 404,
720
- gqlCode: "FILE_NOT_FOUND",
721
- when: "File ID is invalid"
722
- } }
723
- },
724
- policy: { auth: "user" }
725
- });
726
- /**
727
- * Attach a file to an entity.
728
- */
729
- const AttachFileContract = defineCommand({
730
- meta: {
731
- name: "attachment.attach",
732
- version: 1,
733
- stability: "stable",
734
- owners: [...OWNERS],
735
- tags: [
736
- "files",
737
- "attachment",
738
- "attach"
739
- ],
740
- description: "Attach a file to an entity.",
741
- goal: "Link a file to a business entity.",
742
- context: "Called when associating files with entities."
743
- },
744
- io: {
745
- input: AttachFileInput,
746
- output: AttachmentModel,
747
- errors: {
748
- FILE_NOT_FOUND: {
749
- description: "File does not exist",
750
- http: 404,
751
- gqlCode: "FILE_NOT_FOUND",
752
- when: "File ID is invalid"
753
- },
754
- ATTACHMENT_EXISTS: {
755
- description: "Attachment already exists",
756
- http: 409,
757
- gqlCode: "ATTACHMENT_EXISTS",
758
- when: "File is already attached to this entity"
759
- }
760
- }
761
- },
762
- policy: { auth: "user" }
763
- });
764
- /**
765
- * Detach a file from an entity.
766
- */
767
- const DetachFileContract = defineCommand({
768
- meta: {
769
- name: "attachment.detach",
770
- version: 1,
771
- stability: "stable",
772
- owners: [...OWNERS],
773
- tags: [
774
- "files",
775
- "attachment",
776
- "detach"
777
- ],
778
- description: "Detach a file from an entity.",
779
- goal: "Remove a file association.",
780
- context: "Called when removing file from entity."
781
- },
782
- io: {
783
- input: DetachFileInput,
784
- output: SuccessOutput,
785
- errors: { ATTACHMENT_NOT_FOUND: {
786
- description: "Attachment does not exist",
787
- http: 404,
788
- gqlCode: "ATTACHMENT_NOT_FOUND",
789
- when: "Attachment ID is invalid"
790
- } }
791
- },
792
- policy: { auth: "user" }
793
- });
794
- /**
795
- * List attachments for an entity.
796
- */
797
- const ListAttachmentsContract = defineQuery({
798
- meta: {
799
- name: "attachment.list",
800
- version: 1,
801
- stability: "stable",
802
- owners: [...OWNERS],
803
- tags: [
804
- "files",
805
- "attachment",
806
- "list"
807
- ],
808
- description: "List attachments for an entity.",
809
- goal: "Get all files attached to an entity.",
810
- context: "Called to display attached files."
811
- },
812
- io: {
813
- input: ListAttachmentsInput,
814
- output: ListAttachmentsOutput
815
- },
816
- policy: { auth: "user" }
817
- });
818
- /**
819
- * Create a presigned upload URL.
820
- */
821
- const CreatePresignedUrlContract = defineCommand({
822
- meta: {
823
- name: "file.presignedUrl.create",
824
- version: 1,
825
- stability: "stable",
826
- owners: [...OWNERS],
827
- tags: [
828
- "files",
829
- "presigned",
830
- "upload"
831
- ],
832
- description: "Create a presigned URL for direct upload.",
833
- goal: "Enable direct-to-storage uploads.",
834
- context: "Called for large file uploads."
835
- },
836
- io: {
837
- input: CreatePresignedUrlInput,
838
- output: PresignedUrlModel,
839
- errors: {
840
- FILE_TOO_LARGE: {
841
- description: "File exceeds size limit",
842
- http: 413,
843
- gqlCode: "FILE_TOO_LARGE",
844
- when: "Requested file size exceeds limit"
845
- },
846
- INVALID_MIME_TYPE: {
847
- description: "MIME type not allowed",
848
- http: 415,
849
- gqlCode: "INVALID_MIME_TYPE",
850
- when: "File type is not in allowed list"
851
- }
852
- }
853
- },
854
- policy: { auth: "user" }
855
- });
856
-
857
- //#endregion
858
- export { AttachFileContract, AttachmentModel, CreatePresignedUrlContract, CreateVersionContract, DeleteFileContract, DetachFileContract, FileModel, FileVersionModel, GetDownloadUrlContract, GetFileContract, GetVersionsContract, ListAttachmentsContract, ListFilesContract, PresignedUrlModel, UpdateFileContract, UploadFileContract };
1
+ import{ScalarTypeEnum as e,defineSchemaModel as t}from"@lssm/lib.schema";import{defineCommand as n,defineQuery as r}from"@lssm/lib.contracts";const i=[`platform.files`],a=t({name:`File`,description:`Represents an uploaded file`,fields:{id:{type:e.String_unsecure(),isOptional:!1},name:{type:e.String_unsecure(),isOptional:!1},mimeType:{type:e.String_unsecure(),isOptional:!1},size:{type:e.Int_unsecure(),isOptional:!1},storageProvider:{type:e.String_unsecure(),isOptional:!1},storagePath:{type:e.String_unsecure(),isOptional:!1},checksum:{type:e.String_unsecure(),isOptional:!0},status:{type:e.String_unsecure(),isOptional:!1},isPublic:{type:e.Boolean(),isOptional:!1},ownerId:{type:e.String_unsecure(),isOptional:!1},orgId:{type:e.String_unsecure(),isOptional:!0},metadata:{type:e.JSON(),isOptional:!0},width:{type:e.Int_unsecure(),isOptional:!0},height:{type:e.Int_unsecure(),isOptional:!0},createdAt:{type:e.DateTime(),isOptional:!1},updatedAt:{type:e.DateTime(),isOptional:!1}}}),o=t({name:`FileVersion`,description:`Represents a file version`,fields:{id:{type:e.String_unsecure(),isOptional:!1},fileId:{type:e.String_unsecure(),isOptional:!1},version:{type:e.Int_unsecure(),isOptional:!1},size:{type:e.Int_unsecure(),isOptional:!1},storagePath:{type:e.String_unsecure(),isOptional:!1},checksum:{type:e.String_unsecure(),isOptional:!0},comment:{type:e.String_unsecure(),isOptional:!0},createdBy:{type:e.String_unsecure(),isOptional:!1},createdAt:{type:e.DateTime(),isOptional:!1}}}),s=t({name:`Attachment`,description:`Represents an attachment`,fields:{id:{type:e.String_unsecure(),isOptional:!1},fileId:{type:e.String_unsecure(),isOptional:!1},entityType:{type:e.String_unsecure(),isOptional:!1},entityId:{type:e.String_unsecure(),isOptional:!1},attachmentType:{type:e.String_unsecure(),isOptional:!0},name:{type:e.String_unsecure(),isOptional:!0},description:{type:e.String_unsecure(),isOptional:!0},order:{type:e.Int_unsecure(),isOptional:!1},metadata:{type:e.JSON(),isOptional:!0},createdBy:{type:e.String_unsecure(),isOptional:!1},createdAt:{type:e.DateTime(),isOptional:!1},file:{type:a,isOptional:!0}}}),c=t({name:`PresignedUrl`,description:`A presigned URL for file operations`,fields:{url:{type:e.String_unsecure(),isOptional:!1},fields:{type:e.JSON(),isOptional:!0},expiresAt:{type:e.DateTime(),isOptional:!1},fileId:{type:e.String_unsecure(),isOptional:!0},sessionId:{type:e.String_unsecure(),isOptional:!0}}}),l=t({name:`UploadFileInput`,description:`Input for uploading a file`,fields:{name:{type:e.String_unsecure(),isOptional:!1},mimeType:{type:e.String_unsecure(),isOptional:!1},size:{type:e.Int_unsecure(),isOptional:!1},content:{type:e.String_unsecure(),isOptional:!1},orgId:{type:e.String_unsecure(),isOptional:!0},isPublic:{type:e.Boolean(),isOptional:!0},metadata:{type:e.JSON(),isOptional:!0},tags:{type:e.JSON(),isOptional:!0}}}),u=t({name:`UpdateFileInput`,description:`Input for updating a file`,fields:{fileId:{type:e.String_unsecure(),isOptional:!1},name:{type:e.String_unsecure(),isOptional:!0},isPublic:{type:e.Boolean(),isOptional:!0},metadata:{type:e.JSON(),isOptional:!0},tags:{type:e.JSON(),isOptional:!0}}}),d=t({name:`DeleteFileInput`,description:`Input for deleting a file`,fields:{fileId:{type:e.String_unsecure(),isOptional:!1}}}),f=t({name:`GetFileInput`,description:`Input for getting a file`,fields:{fileId:{type:e.String_unsecure(),isOptional:!1}}}),p=t({name:`ListFilesInput`,description:`Input for listing files`,fields:{orgId:{type:e.String_unsecure(),isOptional:!0},ownerId:{type:e.String_unsecure(),isOptional:!0},mimeType:{type:e.String_unsecure(),isOptional:!0},status:{type:e.String_unsecure(),isOptional:!0},tags:{type:e.JSON(),isOptional:!0},limit:{type:e.Int_unsecure(),isOptional:!0},offset:{type:e.Int_unsecure(),isOptional:!0}}}),m=t({name:`ListFilesOutput`,description:`Output for listing files`,fields:{files:{type:a,isArray:!0,isOptional:!1},total:{type:e.Int_unsecure(),isOptional:!1}}}),h=t({name:`GetDownloadUrlInput`,description:`Input for getting a download URL`,fields:{fileId:{type:e.String_unsecure(),isOptional:!1},expiresInSeconds:{type:e.Int_unsecure(),isOptional:!0}}}),g=t({name:`CreateVersionInput`,description:`Input for creating a file version`,fields:{fileId:{type:e.String_unsecure(),isOptional:!1},content:{type:e.String_unsecure(),isOptional:!1},comment:{type:e.String_unsecure(),isOptional:!0}}}),_=t({name:`GetVersionsInput`,description:`Input for getting file versions`,fields:{fileId:{type:e.String_unsecure(),isOptional:!1},limit:{type:e.Int_unsecure(),isOptional:!0},offset:{type:e.Int_unsecure(),isOptional:!0}}}),v=t({name:`GetVersionsOutput`,description:`Output for getting file versions`,fields:{versions:{type:o,isArray:!0,isOptional:!1},total:{type:e.Int_unsecure(),isOptional:!1}}}),y=t({name:`AttachFileInput`,description:`Input for attaching a file to an entity`,fields:{fileId:{type:e.String_unsecure(),isOptional:!1},entityType:{type:e.String_unsecure(),isOptional:!1},entityId:{type:e.String_unsecure(),isOptional:!1},attachmentType:{type:e.String_unsecure(),isOptional:!0},name:{type:e.String_unsecure(),isOptional:!0},description:{type:e.String_unsecure(),isOptional:!0},order:{type:e.Int_unsecure(),isOptional:!0},metadata:{type:e.JSON(),isOptional:!0}}}),b=t({name:`DetachFileInput`,description:`Input for detaching a file`,fields:{attachmentId:{type:e.String_unsecure(),isOptional:!1}}}),x=t({name:`ListAttachmentsInput`,description:`Input for listing attachments`,fields:{entityType:{type:e.String_unsecure(),isOptional:!1},entityId:{type:e.String_unsecure(),isOptional:!1},attachmentType:{type:e.String_unsecure(),isOptional:!0}}}),S=t({name:`ListAttachmentsOutput`,description:`Output for listing attachments`,fields:{attachments:{type:s,isArray:!0,isOptional:!1},total:{type:e.Int_unsecure(),isOptional:!1}}}),C=t({name:`CreatePresignedUrlInput`,description:`Input for creating a presigned upload URL`,fields:{fileName:{type:e.String_unsecure(),isOptional:!1},mimeType:{type:e.String_unsecure(),isOptional:!1},size:{type:e.Int_unsecure(),isOptional:!1},orgId:{type:e.String_unsecure(),isOptional:!0},expiresInSeconds:{type:e.Int_unsecure(),isOptional:!0}}}),w=t({name:`SuccessOutput`,description:`Generic success output`,fields:{success:{type:e.Boolean(),isOptional:!1}}}),T=n({meta:{name:`file.upload`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`upload`],description:`Upload a new file.`,goal:`Store a file and create a file record.`,context:`Called when uploading files directly.`},io:{input:l,output:a,errors:{FILE_TOO_LARGE:{description:`File exceeds size limit`,http:413,gqlCode:`FILE_TOO_LARGE`,when:`File size exceeds configured limit`},INVALID_MIME_TYPE:{description:`MIME type not allowed`,http:415,gqlCode:`INVALID_MIME_TYPE`,when:`File type is not in allowed list`}}},policy:{auth:`user`}}),E=n({meta:{name:`file.update`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`update`],description:`Update file metadata.`,goal:`Modify file properties without replacing content.`,context:`Called when renaming or updating file metadata.`},io:{input:u,output:a,errors:{FILE_NOT_FOUND:{description:`File does not exist`,http:404,gqlCode:`FILE_NOT_FOUND`,when:`File ID is invalid`}}},policy:{auth:`user`}}),D=n({meta:{name:`file.delete`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`delete`],description:`Delete a file.`,goal:`Remove a file and all its versions and attachments.`,context:`Called when removing a file permanently.`},io:{input:d,output:w,errors:{FILE_NOT_FOUND:{description:`File does not exist`,http:404,gqlCode:`FILE_NOT_FOUND`,when:`File ID is invalid`}}},policy:{auth:`user`}}),O=r({meta:{name:`file.get`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`get`],description:`Get a file by ID.`,goal:`Retrieve file metadata.`,context:`Called to inspect file details.`},io:{input:f,output:a,errors:{FILE_NOT_FOUND:{description:`File does not exist`,http:404,gqlCode:`FILE_NOT_FOUND`,when:`File ID is invalid`}}},policy:{auth:`user`}}),k=r({meta:{name:`file.list`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`list`],description:`List files with filtering.`,goal:`Browse uploaded files.`,context:`Called to browse file library.`},io:{input:p,output:m},policy:{auth:`user`}}),A=r({meta:{name:`file.downloadUrl`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`download`],description:`Get a presigned download URL.`,goal:`Generate a temporary URL for downloading.`,context:`Called when user wants to download a file.`},io:{input:h,output:c,errors:{FILE_NOT_FOUND:{description:`File does not exist`,http:404,gqlCode:`FILE_NOT_FOUND`,when:`File ID is invalid`}}},policy:{auth:`user`}}),j=n({meta:{name:`file.version.create`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`version`,`create`],description:`Create a new version of a file.`,goal:`Upload a new version while preserving history.`,context:`Called when updating a document.`},io:{input:g,output:o,errors:{FILE_NOT_FOUND:{description:`File does not exist`,http:404,gqlCode:`FILE_NOT_FOUND`,when:`File ID is invalid`}}},policy:{auth:`user`}}),M=r({meta:{name:`file.version.list`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`version`,`list`],description:`Get file version history.`,goal:`View all versions of a file.`,context:`Called to browse file history.`},io:{input:_,output:v,errors:{FILE_NOT_FOUND:{description:`File does not exist`,http:404,gqlCode:`FILE_NOT_FOUND`,when:`File ID is invalid`}}},policy:{auth:`user`}}),N=n({meta:{name:`attachment.attach`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`attachment`,`attach`],description:`Attach a file to an entity.`,goal:`Link a file to a business entity.`,context:`Called when associating files with entities.`},io:{input:y,output:s,errors:{FILE_NOT_FOUND:{description:`File does not exist`,http:404,gqlCode:`FILE_NOT_FOUND`,when:`File ID is invalid`},ATTACHMENT_EXISTS:{description:`Attachment already exists`,http:409,gqlCode:`ATTACHMENT_EXISTS`,when:`File is already attached to this entity`}}},policy:{auth:`user`}}),P=n({meta:{name:`attachment.detach`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`attachment`,`detach`],description:`Detach a file from an entity.`,goal:`Remove a file association.`,context:`Called when removing file from entity.`},io:{input:b,output:w,errors:{ATTACHMENT_NOT_FOUND:{description:`Attachment does not exist`,http:404,gqlCode:`ATTACHMENT_NOT_FOUND`,when:`Attachment ID is invalid`}}},policy:{auth:`user`}}),F=r({meta:{name:`attachment.list`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`attachment`,`list`],description:`List attachments for an entity.`,goal:`Get all files attached to an entity.`,context:`Called to display attached files.`},io:{input:x,output:S},policy:{auth:`user`}}),I=n({meta:{name:`file.presignedUrl.create`,version:1,stability:`stable`,owners:[...i],tags:[`files`,`presigned`,`upload`],description:`Create a presigned URL for direct upload.`,goal:`Enable direct-to-storage uploads.`,context:`Called for large file uploads.`},io:{input:C,output:c,errors:{FILE_TOO_LARGE:{description:`File exceeds size limit`,http:413,gqlCode:`FILE_TOO_LARGE`,when:`Requested file size exceeds limit`},INVALID_MIME_TYPE:{description:`MIME type not allowed`,http:415,gqlCode:`INVALID_MIME_TYPE`,when:`File type is not in allowed list`}}},policy:{auth:`user`}});export{N as AttachFileContract,s as AttachmentModel,I as CreatePresignedUrlContract,j as CreateVersionContract,D as DeleteFileContract,P as DetachFileContract,a as FileModel,o as FileVersionModel,A as GetDownloadUrlContract,O as GetFileContract,M as GetVersionsContract,F as ListAttachmentsContract,k as ListFilesContract,c as PresignedUrlModel,E as UpdateFileContract,T as UploadFileContract};