@rossum/api-client 0.1.19 → 0.1.21

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 (92) hide show
  1. package/index.js +2 -0
  2. package/index.js.map +1 -1
  3. package/package.json +1 -1
  4. package/src/deleteRecommendations/endpoints/list.js.map +1 -1
  5. package/src/deleteRecommendations/endpoints/list.schema.js +3 -1
  6. package/src/deleteRecommendations/endpoints/list.schema.js.map +1 -1
  7. package/src/documents/endpoints/downloads.js.map +1 -1
  8. package/src/documents/endpoints/downloads.schema.js +17 -5
  9. package/src/documents/endpoints/downloads.schema.js.map +1 -1
  10. package/src/hooks/models/hookUtils.schema.js +5 -1
  11. package/src/hooks/models/hookUtils.schema.js.map +1 -1
  12. package/src/hooks/models/log.schema.js +6 -0
  13. package/src/hooks/models/log.schema.js.map +1 -1
  14. package/src/inboxes/endpoints/index.js +2 -0
  15. package/src/inboxes/endpoints/index.js.map +1 -1
  16. package/src/inboxes/endpoints/list.js +17 -0
  17. package/src/inboxes/endpoints/list.js.map +1 -0
  18. package/src/inboxes/endpoints/list.schema.js +8 -0
  19. package/src/inboxes/endpoints/list.schema.js.map +1 -0
  20. package/src/internal/endpoints/generateRejectionEmail.js +15 -0
  21. package/src/internal/endpoints/generateRejectionEmail.js.map +1 -0
  22. package/src/internal/endpoints/generateRejectionEmail.schema.js +23 -0
  23. package/src/internal/endpoints/generateRejectionEmail.schema.js.map +1 -0
  24. package/src/internal/endpoints/index.js +2 -0
  25. package/src/internal/endpoints/index.js.map +1 -1
  26. package/src/models/annotationStatus.schema.js +1 -0
  27. package/src/models/annotationStatus.schema.js.map +1 -1
  28. package/src/queues/endpoints/upload.js +2 -1
  29. package/src/queues/endpoints/upload.js.map +1 -1
  30. package/src/tasks/endpoints/get.js +2 -1
  31. package/src/tasks/endpoints/get.js.map +1 -1
  32. package/src/tasks/models/asyncTask.schema.js +5 -1
  33. package/src/tasks/models/asyncTask.schema.js.map +1 -1
  34. package/src/uploads/endpoints/get.js +13 -0
  35. package/src/uploads/endpoints/get.js.map +1 -0
  36. package/src/uploads/endpoints/index.js +10 -0
  37. package/src/uploads/endpoints/index.js.map +1 -0
  38. package/src/uploads/endpoints/post.js +20 -0
  39. package/src/uploads/endpoints/post.js.map +1 -0
  40. package/src/uploads/endpoints/post.schema.js +12 -0
  41. package/src/uploads/endpoints/post.schema.js.map +1 -0
  42. package/src/uploads/models/index.js +18 -0
  43. package/src/uploads/models/index.js.map +1 -0
  44. package/src/uploads/models/upload.js +3 -0
  45. package/src/uploads/models/upload.js.map +1 -0
  46. package/src/uploads/models/upload.schema.js +18 -0
  47. package/src/uploads/models/upload.schema.js.map +1 -0
  48. package/src/utils/requestConfig.js +2 -1
  49. package/src/utils/requestConfig.js.map +1 -1
  50. package/types/index.d.ts +8 -2
  51. package/types/src/annotations/endpoints/list.schema.d.ts +3 -3
  52. package/types/src/annotations/endpoints/patch.schema.d.ts +3 -3
  53. package/types/src/annotations/models/annotation.schema.d.ts +3 -3
  54. package/types/src/annotations/models/annotationListResponse.d.ts +5 -5
  55. package/types/src/annotations/models/editPages.schema.d.ts +11 -11
  56. package/types/src/deleteRecommendations/endpoints/list.d.ts +3 -1
  57. package/types/src/deleteRecommendations/endpoints/list.schema.d.ts +7 -1
  58. package/types/src/documents/endpoints/downloads.d.ts +6 -0
  59. package/types/src/documents/endpoints/downloads.schema.d.ts +18 -2
  60. package/types/src/hookTemplates/models/hookTemplate.schema.d.ts +6 -6
  61. package/types/src/hooks/endpoints/logs.schema.d.ts +70 -0
  62. package/types/src/hooks/endpoints/patch.schema.d.ts +6 -6
  63. package/types/src/hooks/models/hook.schema.d.ts +9 -9
  64. package/types/src/hooks/models/hookUtils.d.ts +3 -2
  65. package/types/src/hooks/models/hookUtils.schema.d.ts +3 -2
  66. package/types/src/hooks/models/log.d.ts +7 -2
  67. package/types/src/hooks/models/log.schema.d.ts +42 -0
  68. package/types/src/inboxes/endpoints/index.d.ts +1 -0
  69. package/types/src/inboxes/endpoints/list.d.ts +7 -0
  70. package/types/src/inboxes/endpoints/list.schema.d.ts +8 -0
  71. package/types/src/internal/endpoints/generateRejectionEmail.d.ts +21 -0
  72. package/types/src/internal/endpoints/generateRejectionEmail.schema.d.ts +56 -0
  73. package/types/src/internal/endpoints/index.d.ts +1 -0
  74. package/types/src/models/annotationStatus.d.ts +1 -1
  75. package/types/src/models/annotationStatus.schema.d.ts +1 -1
  76. package/types/src/queues/endpoints/index.d.ts +1 -1
  77. package/types/src/queues/endpoints/patch.schema.d.ts +3 -3
  78. package/types/src/queues/endpoints/upload.d.ts +1 -1
  79. package/types/src/queues/models/queue.schema.d.ts +3 -3
  80. package/types/src/queues/models/queueCounts.schema.d.ts +1 -1
  81. package/types/src/tasks/endpoints/get.d.ts +1 -1
  82. package/types/src/tasks/endpoints/index.d.ts +1 -1
  83. package/types/src/tasks/models/asyncTask.d.ts +2 -1
  84. package/types/src/tasks/models/asyncTask.schema.d.ts +9 -4
  85. package/types/src/uploads/endpoints/get.d.ts +3 -0
  86. package/types/src/uploads/endpoints/index.d.ts +4 -0
  87. package/types/src/uploads/endpoints/post.d.ts +9 -0
  88. package/types/src/uploads/endpoints/post.schema.d.ts +15 -0
  89. package/types/src/uploads/models/index.d.ts +1 -0
  90. package/types/src/uploads/models/upload.d.ts +13 -0
  91. package/types/src/uploads/models/upload.schema.d.ts +35 -0
  92. package/types/src/utils/requestConfig.d.ts +1 -0
@@ -6,7 +6,7 @@ export declare const hookBaseSchema: z.ZodObject<{
6
6
  queues: z.ZodArray<z.ZodString, "many">;
7
7
  runAfter: z.ZodArray<z.ZodString, "many">;
8
8
  active: z.ZodBoolean;
9
- events: z.ZodArray<z.ZodUnion<[z.ZodLiteral<"annotation_content.confirm">, z.ZodLiteral<"annotation_content.export">, z.ZodLiteral<"annotation_content.initialize">, z.ZodLiteral<"annotation_content.started">, z.ZodLiteral<"annotation_content.updated">, z.ZodLiteral<"annotation_content.user_update">, z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status.changed">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"email.received">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation.manual">, z.ZodLiteral<"invocation.scheduled">, z.ZodLiteral<"invocation">]>, "many">;
9
+ events: z.ZodArray<z.ZodUnion<[z.ZodLiteral<"annotation_content.confirm">, z.ZodLiteral<"annotation_content.export">, z.ZodLiteral<"annotation_content.initialize">, z.ZodLiteral<"annotation_content.started">, z.ZodLiteral<"annotation_content.updated">, z.ZodLiteral<"annotation_content.user_update">, z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status.changed">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"upload.created">, z.ZodLiteral<"upload">, z.ZodLiteral<"email.received">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation.manual">, z.ZodLiteral<"invocation.scheduled">, z.ZodLiteral<"invocation">]>, "many">;
10
10
  sideload: z.ZodArray<z.ZodString, "many">;
11
11
  metadata: z.ZodOptional<z.ZodUnknown>;
12
12
  tokenOwner: z.ZodNullable<z.ZodString>;
@@ -29,7 +29,7 @@ export declare const hookBaseSchema: z.ZodObject<{
29
29
  description: string | null;
30
30
  runAfter: string[];
31
31
  active: boolean;
32
- events: ("email" | "annotation_content" | "annotation_status" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
32
+ events: ("email" | "annotation_content" | "annotation_status" | "upload" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "upload.created" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
33
33
  tokenOwner: string | null;
34
34
  extensionSource: "custom" | "rossum_store";
35
35
  guide: string | null;
@@ -50,7 +50,7 @@ export declare const hookBaseSchema: z.ZodObject<{
50
50
  description: string | null;
51
51
  runAfter: string[];
52
52
  active: boolean;
53
- events: ("email" | "annotation_content" | "annotation_status" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
53
+ events: ("email" | "annotation_content" | "annotation_status" | "upload" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "upload.created" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
54
54
  tokenOwner: string | null;
55
55
  extensionSource: "custom" | "rossum_store";
56
56
  guide: string | null;
@@ -71,7 +71,7 @@ export declare const hookSchema: z.ZodUnion<[z.ZodIntersection<z.ZodObject<{
71
71
  queues: z.ZodArray<z.ZodString, "many">;
72
72
  runAfter: z.ZodArray<z.ZodString, "many">;
73
73
  active: z.ZodBoolean;
74
- events: z.ZodArray<z.ZodUnion<[z.ZodLiteral<"annotation_content.confirm">, z.ZodLiteral<"annotation_content.export">, z.ZodLiteral<"annotation_content.initialize">, z.ZodLiteral<"annotation_content.started">, z.ZodLiteral<"annotation_content.updated">, z.ZodLiteral<"annotation_content.user_update">, z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status.changed">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"email.received">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation.manual">, z.ZodLiteral<"invocation.scheduled">, z.ZodLiteral<"invocation">]>, "many">;
74
+ events: z.ZodArray<z.ZodUnion<[z.ZodLiteral<"annotation_content.confirm">, z.ZodLiteral<"annotation_content.export">, z.ZodLiteral<"annotation_content.initialize">, z.ZodLiteral<"annotation_content.started">, z.ZodLiteral<"annotation_content.updated">, z.ZodLiteral<"annotation_content.user_update">, z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status.changed">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"upload.created">, z.ZodLiteral<"upload">, z.ZodLiteral<"email.received">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation.manual">, z.ZodLiteral<"invocation.scheduled">, z.ZodLiteral<"invocation">]>, "many">;
75
75
  sideload: z.ZodArray<z.ZodString, "many">;
76
76
  metadata: z.ZodOptional<z.ZodUnknown>;
77
77
  tokenOwner: z.ZodNullable<z.ZodString>;
@@ -94,7 +94,7 @@ export declare const hookSchema: z.ZodUnion<[z.ZodIntersection<z.ZodObject<{
94
94
  description: string | null;
95
95
  runAfter: string[];
96
96
  active: boolean;
97
- events: ("email" | "annotation_content" | "annotation_status" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
97
+ events: ("email" | "annotation_content" | "annotation_status" | "upload" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "upload.created" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
98
98
  tokenOwner: string | null;
99
99
  extensionSource: "custom" | "rossum_store";
100
100
  guide: string | null;
@@ -115,7 +115,7 @@ export declare const hookSchema: z.ZodUnion<[z.ZodIntersection<z.ZodObject<{
115
115
  description: string | null;
116
116
  runAfter: string[];
117
117
  active: boolean;
118
- events: ("email" | "annotation_content" | "annotation_status" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
118
+ events: ("email" | "annotation_content" | "annotation_status" | "upload" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "upload.created" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
119
119
  tokenOwner: string | null;
120
120
  extensionSource: "custom" | "rossum_store";
121
121
  guide: string | null;
@@ -235,7 +235,7 @@ export declare const hookSchema: z.ZodUnion<[z.ZodIntersection<z.ZodObject<{
235
235
  queues: z.ZodArray<z.ZodString, "many">;
236
236
  runAfter: z.ZodArray<z.ZodString, "many">;
237
237
  active: z.ZodBoolean;
238
- events: z.ZodArray<z.ZodUnion<[z.ZodLiteral<"annotation_content.confirm">, z.ZodLiteral<"annotation_content.export">, z.ZodLiteral<"annotation_content.initialize">, z.ZodLiteral<"annotation_content.started">, z.ZodLiteral<"annotation_content.updated">, z.ZodLiteral<"annotation_content.user_update">, z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status.changed">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"email.received">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation.manual">, z.ZodLiteral<"invocation.scheduled">, z.ZodLiteral<"invocation">]>, "many">;
238
+ events: z.ZodArray<z.ZodUnion<[z.ZodLiteral<"annotation_content.confirm">, z.ZodLiteral<"annotation_content.export">, z.ZodLiteral<"annotation_content.initialize">, z.ZodLiteral<"annotation_content.started">, z.ZodLiteral<"annotation_content.updated">, z.ZodLiteral<"annotation_content.user_update">, z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status.changed">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"upload.created">, z.ZodLiteral<"upload">, z.ZodLiteral<"email.received">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation.manual">, z.ZodLiteral<"invocation.scheduled">, z.ZodLiteral<"invocation">]>, "many">;
239
239
  sideload: z.ZodArray<z.ZodString, "many">;
240
240
  metadata: z.ZodOptional<z.ZodUnknown>;
241
241
  tokenOwner: z.ZodNullable<z.ZodString>;
@@ -258,7 +258,7 @@ export declare const hookSchema: z.ZodUnion<[z.ZodIntersection<z.ZodObject<{
258
258
  description: string | null;
259
259
  runAfter: string[];
260
260
  active: boolean;
261
- events: ("email" | "annotation_content" | "annotation_status" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
261
+ events: ("email" | "annotation_content" | "annotation_status" | "upload" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "upload.created" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
262
262
  tokenOwner: string | null;
263
263
  extensionSource: "custom" | "rossum_store";
264
264
  guide: string | null;
@@ -279,7 +279,7 @@ export declare const hookSchema: z.ZodUnion<[z.ZodIntersection<z.ZodObject<{
279
279
  description: string | null;
280
280
  runAfter: string[];
281
281
  active: boolean;
282
- events: ("email" | "annotation_content" | "annotation_status" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
282
+ events: ("email" | "annotation_content" | "annotation_status" | "upload" | "invocation" | "annotation_content.confirm" | "annotation_content.export" | "annotation_content.initialize" | "annotation_content.started" | "annotation_content.updated" | "annotation_content.user_update" | "annotation_status.changed" | "upload.created" | "email.received" | "invocation.manual" | "invocation.scheduled")[];
283
283
  tokenOwner: string | null;
284
284
  extensionSource: "custom" | "rossum_store";
285
285
  guide: string | null;
@@ -1,9 +1,10 @@
1
- export type ExtensionEventGroup = 'annotation_content' | 'annotation_status' | 'email' | 'invocation';
1
+ export type ExtensionEventGroup = 'annotation_content' | 'annotation_status' | 'upload' | 'email' | 'invocation';
2
2
  export type AnnotationContentAction = 'confirm' | 'export' | 'initialize' | 'started' | 'updated' | 'user_update';
3
+ export type UploadAction = 'created';
3
4
  export type AnnotationStatusAction = 'changed';
4
5
  export type EmailAction = 'received';
5
6
  export type InvocationAction = 'manual' | 'scheduled';
6
- export type ExtensionEvent = 'annotation_content.confirm' | 'annotation_content.export' | 'annotation_content.initialize' | 'annotation_content.started' | 'annotation_content.updated' | 'annotation_content.user_update' | 'annotation_content' | 'annotation_status.changed' | 'annotation_status' | 'email.received' | 'email' | 'invocation.manual' | 'invocation.scheduled' | 'invocation';
7
+ export type ExtensionEvent = 'annotation_content.confirm' | 'annotation_content.export' | 'annotation_content.initialize' | 'annotation_content.started' | 'annotation_content.updated' | 'annotation_content.user_update' | 'annotation_content' | 'annotation_status.changed' | 'annotation_status' | 'upload.created' | 'upload' | 'email.received' | 'email' | 'invocation.manual' | 'invocation.scheduled' | 'invocation';
7
8
  export type FunctionRuntime = 'nodejs18.x' | 'python3.8' | 'nodejs12.x';
8
9
  export type SideloadValue = 'queues' | 'modifiers' | 'schemas';
9
10
  export type ExtensionSource = 'rossum_store' | 'custom';
@@ -1,10 +1,11 @@
1
1
  import { z } from 'zod';
2
- export declare const extensionEventGroupSchema: z.ZodUnion<[z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation">]>;
2
+ export declare const extensionEventGroupSchema: z.ZodUnion<[z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"upload">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation">]>;
3
3
  export declare const annotationContentActionSchema: z.ZodUnion<[z.ZodLiteral<"confirm">, z.ZodLiteral<"export">, z.ZodLiteral<"initialize">, z.ZodLiteral<"started">, z.ZodLiteral<"updated">, z.ZodLiteral<"user_update">]>;
4
+ export declare const uploadActionSchema: z.ZodLiteral<"created">;
4
5
  export declare const annotationStatusActionSchema: z.ZodLiteral<"changed">;
5
6
  export declare const emailActionSchema: z.ZodLiteral<"received">;
6
7
  export declare const invocationActionSchema: z.ZodUnion<[z.ZodLiteral<"manual">, z.ZodLiteral<"scheduled">]>;
7
- export declare const extensionEventSchema: z.ZodUnion<[z.ZodLiteral<"annotation_content.confirm">, z.ZodLiteral<"annotation_content.export">, z.ZodLiteral<"annotation_content.initialize">, z.ZodLiteral<"annotation_content.started">, z.ZodLiteral<"annotation_content.updated">, z.ZodLiteral<"annotation_content.user_update">, z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status.changed">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"email.received">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation.manual">, z.ZodLiteral<"invocation.scheduled">, z.ZodLiteral<"invocation">]>;
8
+ export declare const extensionEventSchema: z.ZodUnion<[z.ZodLiteral<"annotation_content.confirm">, z.ZodLiteral<"annotation_content.export">, z.ZodLiteral<"annotation_content.initialize">, z.ZodLiteral<"annotation_content.started">, z.ZodLiteral<"annotation_content.updated">, z.ZodLiteral<"annotation_content.user_update">, z.ZodLiteral<"annotation_content">, z.ZodLiteral<"annotation_status.changed">, z.ZodLiteral<"annotation_status">, z.ZodLiteral<"upload.created">, z.ZodLiteral<"upload">, z.ZodLiteral<"email.received">, z.ZodLiteral<"email">, z.ZodLiteral<"invocation.manual">, z.ZodLiteral<"invocation.scheduled">, z.ZodLiteral<"invocation">]>;
8
9
  export declare const functionRuntimeSchema: z.ZodUnion<[z.ZodLiteral<"nodejs18.x">, z.ZodLiteral<"python3.8">, z.ZodLiteral<"nodejs12.x">]>;
9
10
  export declare const sideloadValueSchema: z.ZodUnion<[z.ZodLiteral<"queues">, z.ZodLiteral<"modifiers">, z.ZodLiteral<"schemas">]>;
10
11
  export declare const extensionSourceSchema: z.ZodUnion<[z.ZodLiteral<"rossum_store">, z.ZodLiteral<"custom">]>;
@@ -1,5 +1,5 @@
1
1
  import { HookType } from './hook';
2
- import { AnnotationContentAction, AnnotationStatusAction, EmailAction, InvocationAction } from './hookUtils';
2
+ import { AnnotationContentAction, AnnotationStatusAction, UploadAction, EmailAction, InvocationAction } from './hookUtils';
3
3
  export type LogLevel = 'INFO' | 'WARNING' | 'ERROR';
4
4
  type LogRequest = string;
5
5
  type LogResponse = string;
@@ -13,6 +13,11 @@ type AnnotationStatusLog = LogBase & {
13
13
  event: 'annotation_status';
14
14
  action: AnnotationStatusAction;
15
15
  };
16
+ type UploadLog = LogBase & {
17
+ emailId?: number | null;
18
+ event: 'upload';
19
+ action: UploadAction;
20
+ };
16
21
  type EmailLog = LogBase & {
17
22
  emailId?: number | null;
18
23
  event: 'email';
@@ -33,5 +38,5 @@ type LogBase = {
33
38
  response: LogResponse | null;
34
39
  timestamp: string;
35
40
  };
36
- export type Log = AnnotationContentLog | AnnotationStatusLog | EmailLog | InvocationLog;
41
+ export type Log = AnnotationContentLog | AnnotationStatusLog | UploadLog | EmailLog | InvocationLog;
37
42
  export {};
@@ -114,6 +114,48 @@ export declare const logSchema: z.ZodUnion<[z.ZodIntersection<z.ZodObject<{
114
114
  request: string | null;
115
115
  response: string | null;
116
116
  queueId?: number | null | undefined;
117
+ }>, z.ZodObject<{
118
+ emailId: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
119
+ event: z.ZodLiteral<"upload">;
120
+ action: z.ZodLiteral<"created">;
121
+ }, "strip", z.ZodTypeAny, {
122
+ event: "upload";
123
+ action: "created";
124
+ emailId?: number | null | undefined;
125
+ }, {
126
+ event: "upload";
127
+ action: "created";
128
+ emailId?: number | null | undefined;
129
+ }>>, z.ZodIntersection<z.ZodObject<{
130
+ hookId: z.ZodNumber;
131
+ hookType: z.ZodUnion<[z.ZodLiteral<"webhook">, z.ZodLiteral<"function">]>;
132
+ logLevel: z.ZodUnion<[z.ZodLiteral<"INFO">, z.ZodLiteral<"WARNING">, z.ZodLiteral<"ERROR">]>;
133
+ message: z.ZodString;
134
+ queueId: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
135
+ request: z.ZodNullable<z.ZodString>;
136
+ requestId: z.ZodString;
137
+ response: z.ZodNullable<z.ZodString>;
138
+ timestamp: z.ZodString;
139
+ }, "strip", z.ZodTypeAny, {
140
+ message: string;
141
+ hookId: number;
142
+ requestId: string;
143
+ timestamp: string;
144
+ hookType: "function" | "webhook";
145
+ logLevel: "INFO" | "WARNING" | "ERROR";
146
+ request: string | null;
147
+ response: string | null;
148
+ queueId?: number | null | undefined;
149
+ }, {
150
+ message: string;
151
+ hookId: number;
152
+ requestId: string;
153
+ timestamp: string;
154
+ hookType: "function" | "webhook";
155
+ logLevel: "INFO" | "WARNING" | "ERROR";
156
+ request: string | null;
157
+ response: string | null;
158
+ queueId?: number | null | undefined;
117
159
  }>, z.ZodObject<{
118
160
  emailId: z.ZodNullable<z.ZodOptional<z.ZodNumber>>;
119
161
  event: z.ZodLiteral<"email">;
@@ -2,4 +2,5 @@ export declare const inboxes: {
2
2
  create: (payload: import("./create").CreateInboxPayload) => import("../../utils/requestConfig").ElisRequestConfig<import("../models").Inbox, never, import("./create").CreateInboxPayload>;
3
3
  get: (inboxId: number) => import("../../utils/requestConfig").ElisRequestConfig<import("../models").Inbox, never, never>;
4
4
  patch: (inboxId: number, payload?: import("./patch").InboxPatchPayload) => import("../../utils/requestConfig").ElisRequestConfig<import("../models").Inbox, never, import("./patch").InboxPatchPayload>;
5
+ list: (query: import("./list").ListInboxesQuery) => import("../../utils/requestConfig").ElisRequestConfig<import("../../utils/listResponse").ListResponse<import("../models").Inbox>, import("./list").ListInboxesQuery, never>;
5
6
  };
@@ -0,0 +1,7 @@
1
+ import { ListResponse } from '../../utils/listResponse';
2
+ import { ElisRequestConfig } from '../../utils/requestConfig';
3
+ import { Inbox } from '../models';
4
+ export type ListInboxesQuery = {
5
+ page?: number;
6
+ };
7
+ export declare const list: (query: ListInboxesQuery) => ElisRequestConfig<ListResponse<Inbox>, ListInboxesQuery, never>;
@@ -0,0 +1,8 @@
1
+ import { z } from 'zod';
2
+ export declare const listInboxesQuerySchema: z.ZodObject<{
3
+ page: z.ZodOptional<z.ZodNumber>;
4
+ }, "strip", z.ZodTypeAny, {
5
+ page?: number | undefined;
6
+ }, {
7
+ page?: number | undefined;
8
+ }>;
@@ -0,0 +1,21 @@
1
+ import { Url } from '../../types';
2
+ import { ElisRequestConfig } from '../../utils/requestConfig';
3
+ export type GenerateResponse = {
4
+ emailBody: string;
5
+ };
6
+ type ContextMessage = {
7
+ label: string;
8
+ content: string;
9
+ };
10
+ type ContextOptions = {
11
+ short: boolean;
12
+ friendly: boolean;
13
+ regenerate: boolean;
14
+ };
15
+ export type GenerateRejectionPayload = {
16
+ annotation: Url;
17
+ messages: ContextMessage[];
18
+ options: ContextOptions;
19
+ };
20
+ export declare const generateRejectionEmail: (payload: GenerateRejectionPayload) => ElisRequestConfig<GenerateResponse, never, GenerateRejectionPayload>;
21
+ export {};
@@ -0,0 +1,56 @@
1
+ import { z } from 'zod';
2
+ export declare const generateResponseSchema: z.ZodObject<{
3
+ emailBody: z.ZodString;
4
+ }, "strip", z.ZodTypeAny, {
5
+ emailBody: string;
6
+ }, {
7
+ emailBody: string;
8
+ }>;
9
+ export declare const generateRejectionPayloadSchema: z.ZodObject<{
10
+ annotation: z.ZodString;
11
+ messages: z.ZodArray<z.ZodObject<{
12
+ label: z.ZodString;
13
+ content: z.ZodString;
14
+ }, "strip", z.ZodTypeAny, {
15
+ content: string;
16
+ label: string;
17
+ }, {
18
+ content: string;
19
+ label: string;
20
+ }>, "many">;
21
+ options: z.ZodObject<{
22
+ short: z.ZodBoolean;
23
+ friendly: z.ZodBoolean;
24
+ regenerate: z.ZodBoolean;
25
+ }, "strip", z.ZodTypeAny, {
26
+ short: boolean;
27
+ friendly: boolean;
28
+ regenerate: boolean;
29
+ }, {
30
+ short: boolean;
31
+ friendly: boolean;
32
+ regenerate: boolean;
33
+ }>;
34
+ }, "strip", z.ZodTypeAny, {
35
+ options: {
36
+ short: boolean;
37
+ friendly: boolean;
38
+ regenerate: boolean;
39
+ };
40
+ annotation: string;
41
+ messages: {
42
+ content: string;
43
+ label: string;
44
+ }[];
45
+ }, {
46
+ options: {
47
+ short: boolean;
48
+ friendly: boolean;
49
+ regenerate: boolean;
50
+ };
51
+ annotation: string;
52
+ messages: {
53
+ content: string;
54
+ label: string;
55
+ }[];
56
+ }>;
@@ -2,4 +2,5 @@ export declare const internal: {
2
2
  requestDemo: (payload: import("./requestDemo").RequestDemoPayload) => import("../../utils/requestConfig").ElisRequestConfig<unknown, never, import("./requestDemo").RequestDemoPayload>;
3
3
  requestExtension: (payload: import("./requestExtension").RequestExtensionPayload) => import("../../utils/requestConfig").ElisRequestConfig<unknown, never, import("./requestExtension").RequestExtensionPayload>;
4
4
  domainSettings: (query: import("./domainSettings").DomainSettingsQuery) => import("../../utils/requestConfig").ElisRequestConfig<import("./domainSettings").DomainSettingsResponse, import("./domainSettings").DomainSettingsQuery, never>;
5
+ generateRejectionEmail: (payload: import("./generateRejectionEmail").GenerateRejectionPayload) => import("../../utils/requestConfig").ElisRequestConfig<import("./generateRejectionEmail").GenerateResponse, never, import("./generateRejectionEmail").GenerateRejectionPayload>;
5
6
  };
@@ -1 +1 @@
1
- export type AnnotationStatus = 'importing' | 'failed_import' | 'split' | 'to_review' | 'reviewing' | 'confirmed' | 'rejected' | 'exporting' | 'exported' | 'failed_export' | 'postponed' | 'deleted' | 'purged' | 'in_workflow';
1
+ export type AnnotationStatus = 'created' | 'importing' | 'failed_import' | 'split' | 'to_review' | 'reviewing' | 'confirmed' | 'rejected' | 'exporting' | 'exported' | 'failed_export' | 'postponed' | 'deleted' | 'purged' | 'in_workflow';
@@ -1,2 +1,2 @@
1
1
  import { z } from 'zod';
2
- export declare const annotationStatusSchema: z.ZodUnion<[z.ZodLiteral<"importing">, z.ZodLiteral<"failed_import">, z.ZodLiteral<"split">, z.ZodLiteral<"to_review">, z.ZodLiteral<"reviewing">, z.ZodLiteral<"confirmed">, z.ZodLiteral<"rejected">, z.ZodLiteral<"exporting">, z.ZodLiteral<"exported">, z.ZodLiteral<"failed_export">, z.ZodLiteral<"postponed">, z.ZodLiteral<"deleted">, z.ZodLiteral<"purged">, z.ZodLiteral<"in_workflow">]>;
2
+ export declare const annotationStatusSchema: z.ZodUnion<[z.ZodLiteral<"created">, z.ZodLiteral<"importing">, z.ZodLiteral<"failed_import">, z.ZodLiteral<"split">, z.ZodLiteral<"to_review">, z.ZodLiteral<"reviewing">, z.ZodLiteral<"confirmed">, z.ZodLiteral<"rejected">, z.ZodLiteral<"exporting">, z.ZodLiteral<"exported">, z.ZodLiteral<"failed_export">, z.ZodLiteral<"postponed">, z.ZodLiteral<"deleted">, z.ZodLiteral<"purged">, z.ZodLiteral<"in_workflow">]>;
@@ -24,7 +24,7 @@ export declare const queues: {
24
24
  columns: string;
25
25
  id: string;
26
26
  }>, never>;
27
- upload: (queueId: number, fileName: string, payload: unknown) => import("../../utils/requestConfig").ElisRequestConfig<import("./upload").UploadResponse, never, unknown>;
27
+ upload: (queueId: number, fileName: string, payload: unknown, signal?: AbortSignal | undefined) => import("../../utils/requestConfig").ElisRequestConfig<import("./upload").UploadResponse, never, unknown>;
28
28
  suggestedRecipients: (queueId: number, payload?: import("./suggestedRecipients").SuggestedRecipientsPayload) => import("../../utils/requestConfig").ElisRequestConfig<import("./suggestedRecipients").SuggestedRecipientsResponse, never, import("./suggestedRecipients").SuggestedRecipientsPayload>;
29
29
  duplicate: (queueId: number, payload: import("./duplicate").QueueDuplicatePayload) => import("../../utils/requestConfig").ElisRequestConfig<import("../models").Queue, never, import("./duplicate").QueueDuplicatePayload>;
30
30
  };
@@ -13,7 +13,7 @@ export declare const queuePatchPayloadSchema: z.ZodObject<{
13
13
  sessionTimeout: z.ZodOptional<z.ZodString>;
14
14
  rirUrl: z.ZodOptional<z.ZodNullable<z.ZodString>>;
15
15
  rirParams: z.ZodOptional<z.ZodNullable<z.ZodString>>;
16
- counts: z.ZodOptional<z.ZodRecord<z.ZodUnion<[z.ZodLiteral<"importing">, z.ZodLiteral<"failed_import">, z.ZodLiteral<"split">, z.ZodLiteral<"to_review">, z.ZodLiteral<"reviewing">, z.ZodLiteral<"confirmed">, z.ZodLiteral<"rejected">, z.ZodLiteral<"exporting">, z.ZodLiteral<"exported">, z.ZodLiteral<"failed_export">, z.ZodLiteral<"postponed">, z.ZodLiteral<"deleted">, z.ZodLiteral<"purged">, z.ZodLiteral<"in_workflow">]>, z.ZodNumber>>;
16
+ counts: z.ZodOptional<z.ZodRecord<z.ZodUnion<[z.ZodLiteral<"created">, z.ZodLiteral<"importing">, z.ZodLiteral<"failed_import">, z.ZodLiteral<"split">, z.ZodLiteral<"to_review">, z.ZodLiteral<"reviewing">, z.ZodLiteral<"confirmed">, z.ZodLiteral<"rejected">, z.ZodLiteral<"exporting">, z.ZodLiteral<"exported">, z.ZodLiteral<"failed_export">, z.ZodLiteral<"postponed">, z.ZodLiteral<"deleted">, z.ZodLiteral<"purged">, z.ZodLiteral<"in_workflow">]>, z.ZodNumber>>;
17
17
  defaultScoreThreshold: z.ZodOptional<z.ZodNumber>;
18
18
  automationEnabled: z.ZodOptional<z.ZodBoolean>;
19
19
  automationLevel: z.ZodOptional<z.ZodUnion<[z.ZodLiteral<"always">, z.ZodLiteral<"confident">, z.ZodLiteral<"never">]>>;
@@ -308,7 +308,7 @@ export declare const queuePatchPayloadSchema: z.ZodObject<{
308
308
  sessionTimeout?: string | undefined;
309
309
  rirUrl?: string | null | undefined;
310
310
  rirParams?: string | null | undefined;
311
- counts?: Partial<Record<"importing" | "failed_import" | "split" | "to_review" | "reviewing" | "confirmed" | "rejected" | "exporting" | "exported" | "failed_export" | "postponed" | "deleted" | "purged" | "in_workflow", number>> | undefined;
311
+ counts?: Partial<Record<"created" | "importing" | "failed_import" | "split" | "to_review" | "reviewing" | "confirmed" | "rejected" | "exporting" | "exported" | "failed_export" | "postponed" | "deleted" | "purged" | "in_workflow", number>> | undefined;
312
312
  defaultScoreThreshold?: number | undefined;
313
313
  automationEnabled?: boolean | undefined;
314
314
  automationLevel?: "never" | "always" | "confident" | undefined;
@@ -387,7 +387,7 @@ export declare const queuePatchPayloadSchema: z.ZodObject<{
387
387
  sessionTimeout?: string | undefined;
388
388
  rirUrl?: string | null | undefined;
389
389
  rirParams?: string | null | undefined;
390
- counts?: Partial<Record<"importing" | "failed_import" | "split" | "to_review" | "reviewing" | "confirmed" | "rejected" | "exporting" | "exported" | "failed_export" | "postponed" | "deleted" | "purged" | "in_workflow", number>> | undefined;
390
+ counts?: Partial<Record<"created" | "importing" | "failed_import" | "split" | "to_review" | "reviewing" | "confirmed" | "rejected" | "exporting" | "exported" | "failed_export" | "postponed" | "deleted" | "purged" | "in_workflow", number>> | undefined;
391
391
  defaultScoreThreshold?: number | undefined;
392
392
  automationEnabled?: boolean | undefined;
393
393
  automationLevel?: "never" | "always" | "confident" | undefined;
@@ -11,4 +11,4 @@ export type UploadResponse = {
11
11
  annotation: Url;
12
12
  }>;
13
13
  };
14
- export declare const upload: (queueId: number, fileName: string, payload: unknown) => ElisRequestConfig<UploadResponse, never, unknown>;
14
+ export declare const upload: (queueId: number, fileName: string, payload: unknown, signal?: AbortSignal) => ElisRequestConfig<UploadResponse, never, unknown>;
@@ -13,7 +13,7 @@ export declare const queueSchema: z.ZodObject<{
13
13
  sessionTimeout: z.ZodString;
14
14
  rirUrl: z.ZodNullable<z.ZodString>;
15
15
  rirParams: z.ZodNullable<z.ZodString>;
16
- counts: z.ZodRecord<z.ZodUnion<[z.ZodLiteral<"importing">, z.ZodLiteral<"failed_import">, z.ZodLiteral<"split">, z.ZodLiteral<"to_review">, z.ZodLiteral<"reviewing">, z.ZodLiteral<"confirmed">, z.ZodLiteral<"rejected">, z.ZodLiteral<"exporting">, z.ZodLiteral<"exported">, z.ZodLiteral<"failed_export">, z.ZodLiteral<"postponed">, z.ZodLiteral<"deleted">, z.ZodLiteral<"purged">, z.ZodLiteral<"in_workflow">]>, z.ZodNumber>;
16
+ counts: z.ZodRecord<z.ZodUnion<[z.ZodLiteral<"created">, z.ZodLiteral<"importing">, z.ZodLiteral<"failed_import">, z.ZodLiteral<"split">, z.ZodLiteral<"to_review">, z.ZodLiteral<"reviewing">, z.ZodLiteral<"confirmed">, z.ZodLiteral<"rejected">, z.ZodLiteral<"exporting">, z.ZodLiteral<"exported">, z.ZodLiteral<"failed_export">, z.ZodLiteral<"postponed">, z.ZodLiteral<"deleted">, z.ZodLiteral<"purged">, z.ZodLiteral<"in_workflow">]>, z.ZodNumber>;
17
17
  defaultScoreThreshold: z.ZodNumber;
18
18
  automationEnabled: z.ZodBoolean;
19
19
  automationLevel: z.ZodUnion<[z.ZodLiteral<"always">, z.ZodLiteral<"confident">, z.ZodLiteral<"never">]>;
@@ -363,7 +363,7 @@ export declare const queueSchema: z.ZodObject<{
363
363
  hooks: string[];
364
364
  rirUrl: string | null;
365
365
  rirParams: string | null;
366
- counts: Partial<Record<"importing" | "failed_import" | "split" | "to_review" | "reviewing" | "confirmed" | "rejected" | "exporting" | "exported" | "failed_export" | "postponed" | "deleted" | "purged" | "in_workflow", number>>;
366
+ counts: Partial<Record<"created" | "importing" | "failed_import" | "split" | "to_review" | "reviewing" | "confirmed" | "rejected" | "exporting" | "exported" | "failed_export" | "postponed" | "deleted" | "purged" | "in_workflow", number>>;
367
367
  defaultScoreThreshold: number;
368
368
  automationEnabled: boolean;
369
369
  automationLevel: "never" | "always" | "confident";
@@ -442,7 +442,7 @@ export declare const queueSchema: z.ZodObject<{
442
442
  hooks: string[];
443
443
  rirUrl: string | null;
444
444
  rirParams: string | null;
445
- counts: Partial<Record<"importing" | "failed_import" | "split" | "to_review" | "reviewing" | "confirmed" | "rejected" | "exporting" | "exported" | "failed_export" | "postponed" | "deleted" | "purged" | "in_workflow", number>>;
445
+ counts: Partial<Record<"created" | "importing" | "failed_import" | "split" | "to_review" | "reviewing" | "confirmed" | "rejected" | "exporting" | "exported" | "failed_export" | "postponed" | "deleted" | "purged" | "in_workflow", number>>;
446
446
  defaultScoreThreshold: number;
447
447
  automationEnabled: boolean;
448
448
  automationLevel: "never" | "always" | "confident";
@@ -1,2 +1,2 @@
1
1
  import { z } from 'zod';
2
- export declare const queueCountsSchema: z.ZodRecord<z.ZodUnion<[z.ZodLiteral<"importing">, z.ZodLiteral<"failed_import">, z.ZodLiteral<"split">, z.ZodLiteral<"to_review">, z.ZodLiteral<"reviewing">, z.ZodLiteral<"confirmed">, z.ZodLiteral<"rejected">, z.ZodLiteral<"exporting">, z.ZodLiteral<"exported">, z.ZodLiteral<"failed_export">, z.ZodLiteral<"postponed">, z.ZodLiteral<"deleted">, z.ZodLiteral<"purged">, z.ZodLiteral<"in_workflow">]>, z.ZodNumber>;
2
+ export declare const queueCountsSchema: z.ZodRecord<z.ZodUnion<[z.ZodLiteral<"created">, z.ZodLiteral<"importing">, z.ZodLiteral<"failed_import">, z.ZodLiteral<"split">, z.ZodLiteral<"to_review">, z.ZodLiteral<"reviewing">, z.ZodLiteral<"confirmed">, z.ZodLiteral<"rejected">, z.ZodLiteral<"exporting">, z.ZodLiteral<"exported">, z.ZodLiteral<"failed_export">, z.ZodLiteral<"postponed">, z.ZodLiteral<"deleted">, z.ZodLiteral<"purged">, z.ZodLiteral<"in_workflow">]>, z.ZodNumber>;
@@ -4,4 +4,4 @@ import { AsyncTask } from '../models/asyncTask';
4
4
  export type GetAsyncTaskQuery = {
5
5
  noRedirect: boolean;
6
6
  };
7
- export declare const get: (taskId: ID, query: GetAsyncTaskQuery) => ElisRequestConfig<AsyncTask, GetAsyncTaskQuery, never>;
7
+ export declare const get: (taskId: ID, query: GetAsyncTaskQuery, signal?: AbortSignal) => ElisRequestConfig<AsyncTask, GetAsyncTaskQuery, never>;
@@ -1,3 +1,3 @@
1
1
  export declare const tasks: {
2
- get: (taskId: number, query: import("./get").GetAsyncTaskQuery) => import("../../utils/requestConfig").ElisRequestConfig<import("../models/asyncTask").AsyncTask, import("./get").GetAsyncTaskQuery, never>;
2
+ get: (taskId: number, query: import("./get").GetAsyncTaskQuery, signal?: AbortSignal | undefined) => import("../../utils/requestConfig").ElisRequestConfig<import("../models/asyncTask").AsyncTask, import("./get").GetAsyncTaskQuery, never>;
3
3
  };
@@ -1,5 +1,5 @@
1
1
  import { ID, Url } from '../../utils/codecUtils';
2
- export type AsyncTaskType = 'documents_download';
2
+ export type AsyncTaskType = 'documents_download' | 'upload_created';
3
3
  export type AsyncTaskStatus = 'running' | 'succeeded' | 'failed';
4
4
  export type AsyncTask = {
5
5
  id: ID;
@@ -12,5 +12,6 @@ export type AsyncTask = {
12
12
  resultUrl?: Url | null;
13
13
  content?: {
14
14
  fileName?: string;
15
+ upload?: string;
15
16
  };
16
17
  };
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
- export declare const asyncTaskTypeSchema: z.ZodLiteral<"documents_download">;
2
+ export declare const asyncTaskTypeSchema: z.ZodUnion<[z.ZodLiteral<"documents_download">, z.ZodLiteral<"upload_created">]>;
3
3
  export declare const asyncTaskStatusSchema: z.ZodUnion<[z.ZodLiteral<"running">, z.ZodLiteral<"succeeded">, z.ZodLiteral<"failed">]>;
4
4
  export declare const asyncTaskSchema: z.ZodObject<{
5
5
  id: z.ZodNumber;
@@ -7,18 +7,21 @@ export declare const asyncTaskSchema: z.ZodObject<{
7
7
  code: z.ZodOptional<z.ZodString>;
8
8
  detail: z.ZodNullable<z.ZodString>;
9
9
  expiresAt: z.ZodString;
10
- type: z.ZodLiteral<"documents_download">;
10
+ type: z.ZodUnion<[z.ZodLiteral<"documents_download">, z.ZodLiteral<"upload_created">]>;
11
11
  status: z.ZodUnion<[z.ZodLiteral<"running">, z.ZodLiteral<"succeeded">, z.ZodLiteral<"failed">]>;
12
12
  resultUrl: z.ZodNullable<z.ZodOptional<z.ZodString>>;
13
13
  content: z.ZodOptional<z.ZodObject<{
14
14
  fileName: z.ZodOptional<z.ZodString>;
15
+ upload: z.ZodOptional<z.ZodString>;
15
16
  }, "strip", z.ZodTypeAny, {
16
17
  fileName?: string | undefined;
18
+ upload?: string | undefined;
17
19
  }, {
18
20
  fileName?: string | undefined;
21
+ upload?: string | undefined;
19
22
  }>>;
20
23
  }, "strip", z.ZodTypeAny, {
21
- type: "documents_download";
24
+ type: "documents_download" | "upload_created";
22
25
  status: "running" | "succeeded" | "failed";
23
26
  url: string;
24
27
  id: number;
@@ -28,9 +31,10 @@ export declare const asyncTaskSchema: z.ZodObject<{
28
31
  resultUrl?: string | null | undefined;
29
32
  content?: {
30
33
  fileName?: string | undefined;
34
+ upload?: string | undefined;
31
35
  } | undefined;
32
36
  }, {
33
- type: "documents_download";
37
+ type: "documents_download" | "upload_created";
34
38
  status: "running" | "succeeded" | "failed";
35
39
  url: string;
36
40
  id: number;
@@ -40,5 +44,6 @@ export declare const asyncTaskSchema: z.ZodObject<{
40
44
  resultUrl?: string | null | undefined;
41
45
  content?: {
42
46
  fileName?: string | undefined;
47
+ upload?: string | undefined;
43
48
  } | undefined;
44
49
  }>;
@@ -0,0 +1,3 @@
1
+ import { ElisRequestConfig } from '../../utils/requestConfig';
2
+ import { Upload } from '../models/upload';
3
+ export declare const get: (uploadId: number) => ElisRequestConfig<Upload, never, never>;
@@ -0,0 +1,4 @@
1
+ export declare const uploads: {
2
+ get: (uploadId: number) => import("../../utils/requestConfig").ElisRequestConfig<import("../models").Upload, never, never>;
3
+ post: (queueId: number, data: unknown, name?: string, signal?: AbortSignal | undefined) => import("../../utils/requestConfig").ElisRequestConfig<import("./post").UploadsPostResponse, import("./post").UploadsPostQuery, unknown>;
4
+ };
@@ -0,0 +1,9 @@
1
+ import { Url } from '../../utils/codecUtils';
2
+ import { ElisRequestConfig } from '../../utils/requestConfig';
3
+ export type UploadsPostQuery = {
4
+ queue: number;
5
+ };
6
+ export type UploadsPostResponse = {
7
+ url: Url;
8
+ };
9
+ export declare const post: (queueId: number, data: unknown, name?: string, signal?: AbortSignal) => ElisRequestConfig<UploadsPostResponse, UploadsPostQuery, unknown>;
@@ -0,0 +1,15 @@
1
+ import { z } from 'zod';
2
+ export declare const uploadsPostQuerySchema: z.ZodObject<{
3
+ queue: z.ZodNumber;
4
+ }, "strip", z.ZodTypeAny, {
5
+ queue: number;
6
+ }, {
7
+ queue: number;
8
+ }>;
9
+ export declare const uploadsPostResponseSchema: z.ZodObject<{
10
+ url: z.ZodString;
11
+ }, "strip", z.ZodTypeAny, {
12
+ url: string;
13
+ }, {
14
+ url: string;
15
+ }>;
@@ -0,0 +1 @@
1
+ export * from './upload';
@@ -0,0 +1,13 @@
1
+ import { Url } from '../../utils/codecUtils';
2
+ export type Upload = {
3
+ id: number;
4
+ url: Url;
5
+ organization: Url;
6
+ creator: Url | null;
7
+ createdAt: string;
8
+ queue: Url;
9
+ email: Url | null;
10
+ documents: Url[];
11
+ additionalDocuments: Url[];
12
+ annotations: Url[];
13
+ };
@@ -0,0 +1,35 @@
1
+ import { z } from 'zod';
2
+ export declare const uploadSchema: z.ZodObject<{
3
+ id: z.ZodNumber;
4
+ url: z.ZodString;
5
+ organization: z.ZodString;
6
+ creator: z.ZodNullable<z.ZodString>;
7
+ createdAt: z.ZodString;
8
+ queue: z.ZodString;
9
+ email: z.ZodNullable<z.ZodString>;
10
+ documents: z.ZodArray<z.ZodString, "many">;
11
+ additionalDocuments: z.ZodArray<z.ZodString, "many">;
12
+ annotations: z.ZodArray<z.ZodString, "many">;
13
+ }, "strip", z.ZodTypeAny, {
14
+ annotations: string[];
15
+ url: string;
16
+ queue: string;
17
+ id: number;
18
+ creator: string | null;
19
+ createdAt: string;
20
+ email: string | null;
21
+ organization: string;
22
+ documents: string[];
23
+ additionalDocuments: string[];
24
+ }, {
25
+ annotations: string[];
26
+ url: string;
27
+ queue: string;
28
+ id: number;
29
+ creator: string | null;
30
+ createdAt: string;
31
+ email: string | null;
32
+ organization: string;
33
+ documents: string[];
34
+ additionalDocuments: string[];
35
+ }>;
@@ -10,6 +10,7 @@ type ElisRequestConfigBase = {
10
10
  withRossumRequestOrigin?: boolean;
11
11
  headers?: Record<string, string>;
12
12
  contentType?: ElisContentType;
13
+ signal?: AbortSignal;
13
14
  };
14
15
  type WithQuery<Q> = [Q] extends [never] ? {
15
16
  query?: never;