@knowledge-stack/ksapi 2.5.0 → 2.6.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 (108) hide show
  1. package/.openapi-generator/FILES +10 -0
  2. package/README.md +7 -2
  3. package/dist/apis/DocumentsApi.d.ts +9 -0
  4. package/dist/apis/DocumentsApi.js +9 -0
  5. package/dist/apis/SystemJobsApi.d.ts +4 -4
  6. package/dist/apis/SystemJobsApi.js +2 -2
  7. package/dist/apis/TenantInvitationsApi.d.ts +67 -0
  8. package/dist/apis/TenantInvitationsApi.js +112 -0
  9. package/dist/apis/TenantsApi.d.ts +4 -4
  10. package/dist/apis/TenantsApi.js +2 -2
  11. package/dist/apis/index.d.ts +1 -0
  12. package/dist/apis/index.js +1 -0
  13. package/dist/esm/apis/DocumentsApi.d.ts +9 -0
  14. package/dist/esm/apis/DocumentsApi.js +9 -0
  15. package/dist/esm/apis/SystemJobsApi.d.ts +4 -4
  16. package/dist/esm/apis/SystemJobsApi.js +2 -2
  17. package/dist/esm/apis/TenantInvitationsApi.d.ts +67 -0
  18. package/dist/esm/apis/TenantInvitationsApi.js +75 -0
  19. package/dist/esm/apis/TenantsApi.d.ts +4 -4
  20. package/dist/esm/apis/TenantsApi.js +2 -2
  21. package/dist/esm/apis/index.d.ts +1 -0
  22. package/dist/esm/apis/index.js +1 -0
  23. package/dist/esm/models/AcceptTenantInvitationRequest.d.ts +53 -0
  24. package/dist/esm/models/AcceptTenantInvitationRequest.js +48 -0
  25. package/dist/esm/models/AcceptTenantInvitationResponse.d.ts +59 -0
  26. package/dist/esm/models/AcceptTenantInvitationResponse.js +52 -0
  27. package/dist/esm/models/ChunkMetadata.d.ts +12 -0
  28. package/dist/esm/models/ChunkMetadata.js +4 -0
  29. package/dist/esm/models/CreateUploadRequest.d.ts +18 -0
  30. package/dist/esm/models/CreateUploadRequest.js +6 -0
  31. package/dist/esm/models/DocumentVersionMetadata.d.ts +7 -0
  32. package/dist/esm/models/DocumentVersionMetadata.js +3 -0
  33. package/dist/esm/models/DocumentVersionMetadataUpdate.d.ts +7 -0
  34. package/dist/esm/models/DocumentVersionMetadataUpdate.js +3 -0
  35. package/dist/esm/models/EmailMetadata.d.ts +119 -0
  36. package/dist/esm/models/EmailMetadata.js +65 -0
  37. package/dist/esm/models/EmailParty.d.ts +53 -0
  38. package/dist/esm/models/EmailParty.js +46 -0
  39. package/dist/esm/models/EventResponse.d.ts +6 -0
  40. package/dist/esm/models/EventResponse.js +2 -0
  41. package/dist/esm/models/ImageTaxonomy.d.ts +1 -0
  42. package/dist/esm/models/ImageTaxonomy.js +1 -0
  43. package/dist/esm/models/IngestDocumentResponse.d.ts +18 -0
  44. package/dist/esm/models/IngestDocumentResponse.js +6 -0
  45. package/dist/esm/models/SegmentSpan.d.ts +9 -2
  46. package/dist/esm/models/SegmentSpan.js +2 -0
  47. package/dist/esm/models/index.d.ts +4 -0
  48. package/dist/esm/models/index.js +4 -0
  49. package/dist/models/AcceptTenantInvitationRequest.d.ts +53 -0
  50. package/dist/models/AcceptTenantInvitationRequest.js +56 -0
  51. package/dist/models/AcceptTenantInvitationResponse.d.ts +59 -0
  52. package/dist/models/AcceptTenantInvitationResponse.js +60 -0
  53. package/dist/models/ChunkMetadata.d.ts +12 -0
  54. package/dist/models/ChunkMetadata.js +4 -0
  55. package/dist/models/CreateUploadRequest.d.ts +18 -0
  56. package/dist/models/CreateUploadRequest.js +6 -0
  57. package/dist/models/DocumentVersionMetadata.d.ts +7 -0
  58. package/dist/models/DocumentVersionMetadata.js +3 -0
  59. package/dist/models/DocumentVersionMetadataUpdate.d.ts +7 -0
  60. package/dist/models/DocumentVersionMetadataUpdate.js +3 -0
  61. package/dist/models/EmailMetadata.d.ts +119 -0
  62. package/dist/models/EmailMetadata.js +73 -0
  63. package/dist/models/EmailParty.d.ts +53 -0
  64. package/dist/models/EmailParty.js +54 -0
  65. package/dist/models/EventResponse.d.ts +6 -0
  66. package/dist/models/EventResponse.js +2 -0
  67. package/dist/models/ImageTaxonomy.d.ts +1 -0
  68. package/dist/models/ImageTaxonomy.js +1 -0
  69. package/dist/models/IngestDocumentResponse.d.ts +18 -0
  70. package/dist/models/IngestDocumentResponse.js +6 -0
  71. package/dist/models/SegmentSpan.d.ts +9 -2
  72. package/dist/models/SegmentSpan.js +2 -0
  73. package/dist/models/index.d.ts +4 -0
  74. package/dist/models/index.js +4 -0
  75. package/docs/AcceptTenantInvitationRequest.md +36 -0
  76. package/docs/AcceptTenantInvitationResponse.md +38 -0
  77. package/docs/ChunkMetadata.md +4 -0
  78. package/docs/CreateUploadRequest.md +6 -0
  79. package/docs/DocumentVersionMetadata.md +2 -0
  80. package/docs/DocumentVersionMetadataUpdate.md +2 -0
  81. package/docs/DocumentsApi.md +13 -4
  82. package/docs/EmailMetadata.md +57 -0
  83. package/docs/EmailParty.md +37 -0
  84. package/docs/EventResponse.md +2 -0
  85. package/docs/IngestDocumentResponse.md +6 -0
  86. package/docs/SegmentSpan.md +3 -1
  87. package/docs/SystemJobsApi.md +1 -1
  88. package/docs/TenantInvitationsApi.md +85 -0
  89. package/docs/TenantsApi.md +1 -1
  90. package/package.json +1 -1
  91. package/src/apis/DocumentsApi.ts +21 -0
  92. package/src/apis/SystemJobsApi.ts +4 -4
  93. package/src/apis/TenantInvitationsApi.ts +136 -0
  94. package/src/apis/TenantsApi.ts +4 -4
  95. package/src/apis/index.ts +1 -0
  96. package/src/models/AcceptTenantInvitationRequest.ts +93 -0
  97. package/src/models/AcceptTenantInvitationResponse.ts +101 -0
  98. package/src/models/ChunkMetadata.ts +16 -0
  99. package/src/models/CreateUploadRequest.ts +24 -0
  100. package/src/models/DocumentVersionMetadata.ts +15 -0
  101. package/src/models/DocumentVersionMetadataUpdate.ts +15 -0
  102. package/src/models/EmailMetadata.ts +183 -0
  103. package/src/models/EmailParty.ts +91 -0
  104. package/src/models/EventResponse.ts +8 -0
  105. package/src/models/ImageTaxonomy.ts +1 -0
  106. package/src/models/IngestDocumentResponse.ts +24 -0
  107. package/src/models/SegmentSpan.ts +11 -2
  108. package/src/models/index.ts +4 -0
@@ -4,6 +4,8 @@
4
4
  README.md
5
5
  docs/AcceptDisclaimerRequest.md
6
6
  docs/AcceptInviteResponse.md
7
+ docs/AcceptTenantInvitationRequest.md
8
+ docs/AcceptTenantInvitationResponse.md
7
9
  docs/AccessCheckResponse.md
8
10
  docs/ActivateSkillVersionRequest.md
9
11
  docs/AddMemberRequest.md
@@ -149,6 +151,8 @@ docs/DocxParagraphAnchorInput.md
149
151
  docs/DocxParagraphAnchorOutput.md
150
152
  docs/DownloadArtifact.md
151
153
  docs/EditMemoryChunkRequest.md
154
+ docs/EmailMetadata.md
155
+ docs/EmailParty.md
152
156
  docs/EmailSentResponse.md
153
157
  docs/EmailVerificationRequest.md
154
158
  docs/EnrichedCitation.md
@@ -340,6 +344,7 @@ docs/TemporalWorkflowStatusResponse.md
340
344
  docs/TenantBrandingResponse.md
341
345
  docs/TenantGroupOrder.md
342
346
  docs/TenantGroupsApi.md
347
+ docs/TenantInvitationsApi.md
343
348
  docs/TenantQuotaStateResponse.md
344
349
  docs/TenantResponse.md
345
350
  docs/TenantSettingsResponse.md
@@ -467,6 +472,7 @@ src/apis/SubscriptionsApi.ts
467
472
  src/apis/SystemJobsApi.ts
468
473
  src/apis/TagsApi.ts
469
474
  src/apis/TenantGroupsApi.ts
475
+ src/apis/TenantInvitationsApi.ts
470
476
  src/apis/TenantsApi.ts
471
477
  src/apis/ThreadMessagesApi.ts
472
478
  src/apis/ThreadsApi.ts
@@ -480,6 +486,8 @@ src/apis/index.ts
480
486
  src/index.ts
481
487
  src/models/AcceptDisclaimerRequest.ts
482
488
  src/models/AcceptInviteResponse.ts
489
+ src/models/AcceptTenantInvitationRequest.ts
490
+ src/models/AcceptTenantInvitationResponse.ts
483
491
  src/models/AccessCheckResponse.ts
484
492
  src/models/ActivateSkillVersionRequest.ts
485
493
  src/models/AddMemberRequest.ts
@@ -607,6 +615,8 @@ src/models/DocxParagraphAnchorInput.ts
607
615
  src/models/DocxParagraphAnchorOutput.ts
608
616
  src/models/DownloadArtifact.ts
609
617
  src/models/EditMemoryChunkRequest.ts
618
+ src/models/EmailMetadata.ts
619
+ src/models/EmailParty.ts
610
620
  src/models/EmailSentResponse.ts
611
621
  src/models/EmailVerificationRequest.ts
612
622
  src/models/EnrichedCitation.ts
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # @knowledge-stack/ksapi@2.5.0
1
+ # @knowledge-stack/ksapi@2.6.0
2
2
 
3
3
  A TypeScript SDK client for the localhost API.
4
4
 
@@ -236,6 +236,7 @@ All URIs are relative to *http://localhost:8000*
236
236
  *TenantGroupsApi* | [**removeGroupMember**](docs/TenantGroupsApi.md#removegroupmember) | **DELETE** /v1/tenant-groups/{group_id}/members/{user_id} | Remove Group Member Handler
237
237
  *TenantGroupsApi* | [**updateGroupPermission**](docs/TenantGroupsApi.md#updategrouppermissionoperation) | **PATCH** /v1/tenant-groups/{group_id}/permissions/{permission_id} | Update Group Permission Handler
238
238
  *TenantGroupsApi* | [**updateTenantGroup**](docs/TenantGroupsApi.md#updatetenantgroup) | **PATCH** /v1/tenant-groups/{group_id} | Update Tenant Group Handler
239
+ *TenantInvitationsApi* | [**acceptTenantInvitation**](docs/TenantInvitationsApi.md#accepttenantinvitationoperation) | **POST** /v1/tenant-invitations/{invitation_id}/accept | Accept Tenant Invitation Handler
239
240
  *TenantsApi* | [**activateTenantUser**](docs/TenantsApi.md#activatetenantuser) | **POST** /v1/tenants/{tenant_id}/users/{user_id}/activate | Activate Tenant User Handler
240
241
  *TenantsApi* | [**deactivateTenantUser**](docs/TenantsApi.md#deactivatetenantuser) | **POST** /v1/tenants/{tenant_id}/users/{user_id}/deactivate | Deactivate Tenant User Handler
241
242
  *TenantsApi* | [**deleteTenant**](docs/TenantsApi.md#deletetenant) | **DELETE** /v1/tenants/{tenant_id} | Delete Tenant
@@ -306,6 +307,8 @@ All URIs are relative to *http://localhost:8000*
306
307
 
307
308
  - [AcceptDisclaimerRequest](docs/AcceptDisclaimerRequest.md)
308
309
  - [AcceptInviteResponse](docs/AcceptInviteResponse.md)
310
+ - [AcceptTenantInvitationRequest](docs/AcceptTenantInvitationRequest.md)
311
+ - [AcceptTenantInvitationResponse](docs/AcceptTenantInvitationResponse.md)
309
312
  - [AccessCheckResponse](docs/AccessCheckResponse.md)
310
313
  - [ActivateSkillVersionRequest](docs/ActivateSkillVersionRequest.md)
311
314
  - [AddMemberRequest](docs/AddMemberRequest.md)
@@ -433,6 +436,8 @@ All URIs are relative to *http://localhost:8000*
433
436
  - [DocxParagraphAnchorOutput](docs/DocxParagraphAnchorOutput.md)
434
437
  - [DownloadArtifact](docs/DownloadArtifact.md)
435
438
  - [EditMemoryChunkRequest](docs/EditMemoryChunkRequest.md)
439
+ - [EmailMetadata](docs/EmailMetadata.md)
440
+ - [EmailParty](docs/EmailParty.md)
436
441
  - [EmailSentResponse](docs/EmailSentResponse.md)
437
442
  - [EmailVerificationRequest](docs/EmailVerificationRequest.md)
438
443
  - [EnrichedCitation](docs/EnrichedCitation.md)
@@ -720,7 +725,7 @@ and is automatically generated by the
720
725
  [OpenAPI Generator](https://openapi-generator.tech) project:
721
726
 
722
727
  - API version: `0.1.0`
723
- - Package version: `2.5.0`
728
+ - Package version: `2.6.0`
724
729
  - Generator version: `7.21.0`
725
730
  - Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
726
731
 
@@ -43,6 +43,7 @@ export interface IngestDocumentRequest {
43
43
  name?: string | null;
44
44
  tagIds?: Array<string>;
45
45
  idempotencyKey?: string | null;
46
+ emailNestingDepth?: number;
46
47
  ingestionMode?: IngestionMode;
47
48
  chunkType?: ChunkType;
48
49
  secondaryTaxonomy?: ImageTaxonomy;
@@ -72,6 +73,8 @@ export interface ListDocumentsRequest {
72
73
  sortDir?: SortDirection;
73
74
  ownerId?: string | null;
74
75
  documentType?: DocumentType;
76
+ durationMinMs?: number | null;
77
+ durationMaxMs?: number | null;
75
78
  withTags?: boolean;
76
79
  limit?: number;
77
80
  offset?: number;
@@ -274,6 +277,7 @@ export interface DocumentsApiInterface {
274
277
  * @param {string} [name] Document name (defaults to filename)
275
278
  * @param {Array<string>} [tagIds] Tag IDs applied to the created document.
276
279
  * @param {string} [idempotencyKey] Opt-in key: a repeat with the same key at the same (parent, name) replays the existing document instead of a 409.
280
+ * @param {number} [emailNestingDepth] Internal: set by the email member fan-out when a nested email re-enters this endpoint. Leave at 0 for direct uploads.
277
281
  * @param {IngestionMode} [ingestionMode]
278
282
  * @param {ChunkType} [chunkType]
279
283
  * @param {ImageTaxonomy} [secondaryTaxonomy]
@@ -292,6 +296,7 @@ export interface DocumentsApiInterface {
292
296
  * @param {string} [name] Document name (defaults to filename)
293
297
  * @param {Array<string>} [tagIds] Tag IDs applied to the created document.
294
298
  * @param {string} [idempotencyKey] Opt-in key: a repeat with the same key at the same (parent, name) replays the existing document instead of a 409.
299
+ * @param {number} [emailNestingDepth] Internal: set by the email member fan-out when a nested email re-enters this endpoint. Leave at 0 for direct uploads.
295
300
  * @param {IngestionMode} [ingestionMode]
296
301
  * @param {ChunkType} [chunkType]
297
302
  * @param {ImageTaxonomy} [secondaryTaxonomy]
@@ -377,6 +382,8 @@ export interface DocumentsApiInterface {
377
382
  * @param {SortDirection} [sortDir] Sort direction; overrides the column\&#39;s natural default
378
383
  * @param {string} [ownerId] Filter to documents owned by this user
379
384
  * @param {DocumentType} [documentType] Filter to documents of this type
385
+ * @param {number} [durationMinMs] Only media whose active version is at least this long (milliseconds). Non-media documents have no duration and are excluded.
386
+ * @param {number} [durationMaxMs] Only media whose active version is at most this long.
380
387
  * @param {boolean} [withTags] Include tags in the response (default: false)
381
388
  * @param {number} [limit] Number of items per page
382
389
  * @param {number} [offset] Number of items to skip
@@ -396,6 +403,8 @@ export interface DocumentsApiInterface {
396
403
  * @param {SortDirection} [sortDir] Sort direction; overrides the column\&#39;s natural default
397
404
  * @param {string} [ownerId] Filter to documents owned by this user
398
405
  * @param {DocumentType} [documentType] Filter to documents of this type
406
+ * @param {number} [durationMinMs] Only media whose active version is at least this long (milliseconds). Non-media documents have no duration and are excluded.
407
+ * @param {number} [durationMaxMs] Only media whose active version is at most this long.
399
408
  * @param {boolean} [withTags] Include tags in the response (default: false)
400
409
  * @param {number} [limit] Number of items per page
401
410
  * @param {number} [offset] Number of items to skip
@@ -505,6 +505,9 @@ class DocumentsApi extends runtime.BaseAPI {
505
505
  if (requestParameters['idempotencyKey'] != null) {
506
506
  formParams.append('idempotency_key', requestParameters['idempotencyKey']);
507
507
  }
508
+ if (requestParameters['emailNestingDepth'] != null) {
509
+ formParams.append('email_nesting_depth', requestParameters['emailNestingDepth']);
510
+ }
508
511
  if (requestParameters['ingestionMode'] != null) {
509
512
  formParams.append('ingestion_mode', requestParameters['ingestionMode']);
510
513
  }
@@ -741,6 +744,12 @@ class DocumentsApi extends runtime.BaseAPI {
741
744
  if (requestParameters['documentType'] != null) {
742
745
  queryParameters['document_type'] = requestParameters['documentType'];
743
746
  }
747
+ if (requestParameters['durationMinMs'] != null) {
748
+ queryParameters['duration_min_ms'] = requestParameters['durationMinMs'];
749
+ }
750
+ if (requestParameters['durationMaxMs'] != null) {
751
+ queryParameters['duration_max_ms'] = requestParameters['durationMaxMs'];
752
+ }
744
753
  if (requestParameters['withTags'] != null) {
745
754
  queryParameters['with_tags'] = requestParameters['withTags'];
746
755
  }
@@ -129,7 +129,7 @@ export interface SystemJobsApiInterface {
129
129
  */
130
130
  getZipIngestionStatusRequestOpts(requestParameters: GetZipIngestionStatusRequest): Promise<runtime.RequestOpts>;
131
131
  /**
132
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
132
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
133
133
  * @summary Get Zip Ingestion Status Handler
134
134
  * @param {string} workflowId
135
135
  * @param {*} [options] Override http request option.
@@ -138,7 +138,7 @@ export interface SystemJobsApiInterface {
138
138
  */
139
139
  getZipIngestionStatusRaw(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ZipIngestionStatusResponse>>;
140
140
  /**
141
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
141
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
142
142
  * Get Zip Ingestion Status Handler
143
143
  */
144
144
  getZipIngestionStatus(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ZipIngestionStatusResponse>;
@@ -231,12 +231,12 @@ export declare class SystemJobsApi extends runtime.BaseAPI implements SystemJobs
231
231
  */
232
232
  getZipIngestionStatusRequestOpts(requestParameters: GetZipIngestionStatusRequest): Promise<runtime.RequestOpts>;
233
233
  /**
234
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
234
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
235
235
  * Get Zip Ingestion Status Handler
236
236
  */
237
237
  getZipIngestionStatusRaw(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ZipIngestionStatusResponse>>;
238
238
  /**
239
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
239
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
240
240
  * Get Zip Ingestion Status Handler
241
241
  */
242
242
  getZipIngestionStatus(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ZipIngestionStatusResponse>;
@@ -282,7 +282,7 @@ class SystemJobsApi extends runtime.BaseAPI {
282
282
  });
283
283
  }
284
284
  /**
285
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
285
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
286
286
  * Get Zip Ingestion Status Handler
287
287
  */
288
288
  getZipIngestionStatusRaw(requestParameters, initOverrides) {
@@ -293,7 +293,7 @@ class SystemJobsApi extends runtime.BaseAPI {
293
293
  });
294
294
  }
295
295
  /**
296
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
296
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
297
297
  * Get Zip Ingestion Status Handler
298
298
  */
299
299
  getZipIngestionStatus(requestParameters, initOverrides) {
@@ -0,0 +1,67 @@
1
+ /**
2
+ * Knowledge Stack API
3
+ * Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import * as runtime from '../runtime';
13
+ import type { AcceptTenantInvitationRequest, AcceptTenantInvitationResponse } from '../models/index';
14
+ export interface AcceptTenantInvitationOperationRequest {
15
+ invitationId: string;
16
+ acceptTenantInvitationRequest: AcceptTenantInvitationRequest;
17
+ }
18
+ /**
19
+ * TenantInvitationsApi - interface
20
+ *
21
+ * @export
22
+ * @interface TenantInvitationsApiInterface
23
+ */
24
+ export interface TenantInvitationsApiInterface {
25
+ /**
26
+ * Creates request options for acceptTenantInvitation without sending the request
27
+ * @param {string} invitationId
28
+ * @param {AcceptTenantInvitationRequest} acceptTenantInvitationRequest
29
+ * @throws {RequiredError}
30
+ * @memberof TenantInvitationsApiInterface
31
+ */
32
+ acceptTenantInvitationRequestOpts(requestParameters: AcceptTenantInvitationOperationRequest): Promise<runtime.RequestOpts>;
33
+ /**
34
+ * Accept an invitation, creating the customer tenant and its OWNER. New owner: supply ``password`` — the account is created and signed in. Existing owner: accept while signed in as ``owner_email`` (no password).
35
+ * @summary Accept Tenant Invitation Handler
36
+ * @param {string} invitationId
37
+ * @param {AcceptTenantInvitationRequest} acceptTenantInvitationRequest
38
+ * @param {*} [options] Override http request option.
39
+ * @throws {RequiredError}
40
+ * @memberof TenantInvitationsApiInterface
41
+ */
42
+ acceptTenantInvitationRaw(requestParameters: AcceptTenantInvitationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AcceptTenantInvitationResponse>>;
43
+ /**
44
+ * Accept an invitation, creating the customer tenant and its OWNER. New owner: supply ``password`` — the account is created and signed in. Existing owner: accept while signed in as ``owner_email`` (no password).
45
+ * Accept Tenant Invitation Handler
46
+ */
47
+ acceptTenantInvitation(requestParameters: AcceptTenantInvitationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AcceptTenantInvitationResponse>;
48
+ }
49
+ /**
50
+ *
51
+ */
52
+ export declare class TenantInvitationsApi extends runtime.BaseAPI implements TenantInvitationsApiInterface {
53
+ /**
54
+ * Creates request options for acceptTenantInvitation without sending the request
55
+ */
56
+ acceptTenantInvitationRequestOpts(requestParameters: AcceptTenantInvitationOperationRequest): Promise<runtime.RequestOpts>;
57
+ /**
58
+ * Accept an invitation, creating the customer tenant and its OWNER. New owner: supply ``password`` — the account is created and signed in. Existing owner: accept while signed in as ``owner_email`` (no password).
59
+ * Accept Tenant Invitation Handler
60
+ */
61
+ acceptTenantInvitationRaw(requestParameters: AcceptTenantInvitationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<AcceptTenantInvitationResponse>>;
62
+ /**
63
+ * Accept an invitation, creating the customer tenant and its OWNER. New owner: supply ``password`` — the account is created and signed in. Existing owner: accept while signed in as ``owner_email`` (no password).
64
+ * Accept Tenant Invitation Handler
65
+ */
66
+ acceptTenantInvitation(requestParameters: AcceptTenantInvitationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<AcceptTenantInvitationResponse>;
67
+ }
@@ -0,0 +1,112 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Knowledge Stack API
6
+ * Knowledge Stack backend API for authentication and knowledge management. ## Integrating (RPA / machine clients) **Base URL.** Knowledge Stack is self-hosted — point at your own deployment host (see `servers`). The `localhost` entry is for local development only. **Authentication.** Send `Authorization: Bearer <api-key>` on every request. Mint an API key once via `POST /v1/api-keys` from a signed-in browser session; the raw `sk-user-...` secret is returned **only** at creation, so store it then. A key inherits its owning user\'s live tenant role and path permissions — create RPA keys from a least-privilege user, and set `expires_at` for rotation. The `ks_uat` cookie scheme is browser-only and cannot be used by headless clients. **Async work is polled, not pushed.** There are no outbound webhooks. - `POST /v1/documents/ingest` returns `201` immediately with a `workflow_id`; poll `GET /v1/system-jobs/document_versions/{workflow_id}` until `status` is terminal (anything other than `pending`/`processing`). The `Location` response header points at this poll resource. - `POST /v1/workflow-runs/{run_id}/start` returns `202`; poll `GET /v1/workflow-runs/{run_id}` until `execution_state` is `COMPLETED` or `FAILED`. The `Location` header points at the run resource. - `POST /v1/agent/ask` is **synchronous** — it blocks until the agent finishes and returns the answer inline. Use a generous HTTP timeout. **Pagination.** List endpoints accept `limit`/`offset` and return `{items, total, limit, offset}`. **Errors.** Every non-2xx body is `{detail, code, request_id}`. `code` is a stable value from a closed set (see the `ErrorResponse` schema\'s `code` enum) — branch on it rather than parsing `detail`. Quota rejections return `429` with a `Retry-After` header; transient lock contention returns a retryable `503`. Quote `request_id` (also the `x-request-id` response header) to support. **Idempotency.** `POST /v1/workflow-runs` accepts an `idempotency_key` to dedupe retried run creation. `agent/ask` charges one message *before* running and does not refund a client-cancelled call.
7
+ *
8
+ * The version of the OpenAPI document: 0.1.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
16
+ if (k2 === undefined) k2 = k;
17
+ var desc = Object.getOwnPropertyDescriptor(m, k);
18
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
19
+ desc = { enumerable: true, get: function() { return m[k]; } };
20
+ }
21
+ Object.defineProperty(o, k2, desc);
22
+ }) : (function(o, m, k, k2) {
23
+ if (k2 === undefined) k2 = k;
24
+ o[k2] = m[k];
25
+ }));
26
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
27
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
28
+ }) : function(o, v) {
29
+ o["default"] = v;
30
+ });
31
+ var __importStar = (this && this.__importStar) || (function () {
32
+ var ownKeys = function(o) {
33
+ ownKeys = Object.getOwnPropertyNames || function (o) {
34
+ var ar = [];
35
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
36
+ return ar;
37
+ };
38
+ return ownKeys(o);
39
+ };
40
+ return function (mod) {
41
+ if (mod && mod.__esModule) return mod;
42
+ var result = {};
43
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
44
+ __setModuleDefault(result, mod);
45
+ return result;
46
+ };
47
+ })();
48
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
49
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
50
+ return new (P || (P = Promise))(function (resolve, reject) {
51
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
52
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
53
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
54
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
55
+ });
56
+ };
57
+ Object.defineProperty(exports, "__esModule", { value: true });
58
+ exports.TenantInvitationsApi = void 0;
59
+ const runtime = __importStar(require("../runtime"));
60
+ const index_1 = require("../models/index");
61
+ /**
62
+ *
63
+ */
64
+ class TenantInvitationsApi extends runtime.BaseAPI {
65
+ /**
66
+ * Creates request options for acceptTenantInvitation without sending the request
67
+ */
68
+ acceptTenantInvitationRequestOpts(requestParameters) {
69
+ return __awaiter(this, void 0, void 0, function* () {
70
+ if (requestParameters['invitationId'] == null) {
71
+ throw new runtime.RequiredError('invitationId', 'Required parameter "invitationId" was null or undefined when calling acceptTenantInvitation().');
72
+ }
73
+ if (requestParameters['acceptTenantInvitationRequest'] == null) {
74
+ throw new runtime.RequiredError('acceptTenantInvitationRequest', 'Required parameter "acceptTenantInvitationRequest" was null or undefined when calling acceptTenantInvitation().');
75
+ }
76
+ const queryParameters = {};
77
+ const headerParameters = {};
78
+ headerParameters['Content-Type'] = 'application/json';
79
+ let urlPath = `/v1/tenant-invitations/{invitation_id}/accept`;
80
+ urlPath = urlPath.replace(`{${"invitation_id"}}`, encodeURIComponent(String(requestParameters['invitationId'])));
81
+ return {
82
+ path: urlPath,
83
+ method: 'POST',
84
+ headers: headerParameters,
85
+ query: queryParameters,
86
+ body: (0, index_1.AcceptTenantInvitationRequestToJSON)(requestParameters['acceptTenantInvitationRequest']),
87
+ };
88
+ });
89
+ }
90
+ /**
91
+ * Accept an invitation, creating the customer tenant and its OWNER. New owner: supply ``password`` — the account is created and signed in. Existing owner: accept while signed in as ``owner_email`` (no password).
92
+ * Accept Tenant Invitation Handler
93
+ */
94
+ acceptTenantInvitationRaw(requestParameters, initOverrides) {
95
+ return __awaiter(this, void 0, void 0, function* () {
96
+ const requestOptions = yield this.acceptTenantInvitationRequestOpts(requestParameters);
97
+ const response = yield this.request(requestOptions, initOverrides);
98
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.AcceptTenantInvitationResponseFromJSON)(jsonValue));
99
+ });
100
+ }
101
+ /**
102
+ * Accept an invitation, creating the customer tenant and its OWNER. New owner: supply ``password`` — the account is created and signed in. Existing owner: accept while signed in as ``owner_email`` (no password).
103
+ * Accept Tenant Invitation Handler
104
+ */
105
+ acceptTenantInvitation(requestParameters, initOverrides) {
106
+ return __awaiter(this, void 0, void 0, function* () {
107
+ const response = yield this.acceptTenantInvitationRaw(requestParameters, initOverrides);
108
+ return yield response.value();
109
+ });
110
+ }
111
+ }
112
+ exports.TenantInvitationsApi = TenantInvitationsApi;
@@ -125,7 +125,7 @@ export interface TenantsApiInterface {
125
125
  */
126
126
  deleteTenantRequestOpts(requestParameters: DeleteTenantRequest): Promise<runtime.RequestOpts>;
127
127
  /**
128
- * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys and S3 bucket after the DB transaction commits.
128
+ * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys, S3 bucket, and Qdrant vectors after the DB transaction commits.
129
129
  * @summary Delete Tenant
130
130
  * @param {string} tenantId
131
131
  * @param {*} [options] Override http request option.
@@ -134,7 +134,7 @@ export interface TenantsApiInterface {
134
134
  */
135
135
  deleteTenantRaw(requestParameters: DeleteTenantRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
136
136
  /**
137
- * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys and S3 bucket after the DB transaction commits.
137
+ * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys, S3 bucket, and Qdrant vectors after the DB transaction commits.
138
138
  * Delete Tenant
139
139
  */
140
140
  deleteTenant(requestParameters: DeleteTenantRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
@@ -395,12 +395,12 @@ export declare class TenantsApi extends runtime.BaseAPI implements TenantsApiInt
395
395
  */
396
396
  deleteTenantRequestOpts(requestParameters: DeleteTenantRequest): Promise<runtime.RequestOpts>;
397
397
  /**
398
- * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys and S3 bucket after the DB transaction commits.
398
+ * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys, S3 bucket, and Qdrant vectors after the DB transaction commits.
399
399
  * Delete Tenant
400
400
  */
401
401
  deleteTenantRaw(requestParameters: DeleteTenantRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
402
402
  /**
403
- * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys and S3 bucket after the DB transaction commits.
403
+ * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys, S3 bucket, and Qdrant vectors after the DB transaction commits.
404
404
  * Delete Tenant
405
405
  */
406
406
  deleteTenant(requestParameters: DeleteTenantRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
@@ -194,7 +194,7 @@ class TenantsApi extends runtime.BaseAPI {
194
194
  });
195
195
  }
196
196
  /**
197
- * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys and S3 bucket after the DB transaction commits.
197
+ * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys, S3 bucket, and Qdrant vectors after the DB transaction commits.
198
198
  * Delete Tenant
199
199
  */
200
200
  deleteTenantRaw(requestParameters, initOverrides) {
@@ -205,7 +205,7 @@ class TenantsApi extends runtime.BaseAPI {
205
205
  });
206
206
  }
207
207
  /**
208
- * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys and S3 bucket after the DB transaction commits.
208
+ * Delete a tenant. Requires OWNER role in the tenant. Refused (409) while a provider-billed subscription is live — deleting the tenant would not stop Stripe/Ping++ from charging for it; the OWNER must downgrade to free (or let the prepay period expire) first. Deletes the tenant\'s LiteLLM team/keys, S3 bucket, and Qdrant vectors after the DB transaction commits.
209
209
  * Delete Tenant
210
210
  */
211
211
  deleteTenant(requestParameters, initOverrides) {
@@ -30,6 +30,7 @@ export * from './SubscriptionsApi';
30
30
  export * from './SystemJobsApi';
31
31
  export * from './TagsApi';
32
32
  export * from './TenantGroupsApi';
33
+ export * from './TenantInvitationsApi';
33
34
  export * from './TenantsApi';
34
35
  export * from './ThreadMessagesApi';
35
36
  export * from './ThreadsApi';
@@ -48,6 +48,7 @@ __exportStar(require("./SubscriptionsApi"), exports);
48
48
  __exportStar(require("./SystemJobsApi"), exports);
49
49
  __exportStar(require("./TagsApi"), exports);
50
50
  __exportStar(require("./TenantGroupsApi"), exports);
51
+ __exportStar(require("./TenantInvitationsApi"), exports);
51
52
  __exportStar(require("./TenantsApi"), exports);
52
53
  __exportStar(require("./ThreadMessagesApi"), exports);
53
54
  __exportStar(require("./ThreadsApi"), exports);
@@ -43,6 +43,7 @@ export interface IngestDocumentRequest {
43
43
  name?: string | null;
44
44
  tagIds?: Array<string>;
45
45
  idempotencyKey?: string | null;
46
+ emailNestingDepth?: number;
46
47
  ingestionMode?: IngestionMode;
47
48
  chunkType?: ChunkType;
48
49
  secondaryTaxonomy?: ImageTaxonomy;
@@ -72,6 +73,8 @@ export interface ListDocumentsRequest {
72
73
  sortDir?: SortDirection;
73
74
  ownerId?: string | null;
74
75
  documentType?: DocumentType;
76
+ durationMinMs?: number | null;
77
+ durationMaxMs?: number | null;
75
78
  withTags?: boolean;
76
79
  limit?: number;
77
80
  offset?: number;
@@ -274,6 +277,7 @@ export interface DocumentsApiInterface {
274
277
  * @param {string} [name] Document name (defaults to filename)
275
278
  * @param {Array<string>} [tagIds] Tag IDs applied to the created document.
276
279
  * @param {string} [idempotencyKey] Opt-in key: a repeat with the same key at the same (parent, name) replays the existing document instead of a 409.
280
+ * @param {number} [emailNestingDepth] Internal: set by the email member fan-out when a nested email re-enters this endpoint. Leave at 0 for direct uploads.
277
281
  * @param {IngestionMode} [ingestionMode]
278
282
  * @param {ChunkType} [chunkType]
279
283
  * @param {ImageTaxonomy} [secondaryTaxonomy]
@@ -292,6 +296,7 @@ export interface DocumentsApiInterface {
292
296
  * @param {string} [name] Document name (defaults to filename)
293
297
  * @param {Array<string>} [tagIds] Tag IDs applied to the created document.
294
298
  * @param {string} [idempotencyKey] Opt-in key: a repeat with the same key at the same (parent, name) replays the existing document instead of a 409.
299
+ * @param {number} [emailNestingDepth] Internal: set by the email member fan-out when a nested email re-enters this endpoint. Leave at 0 for direct uploads.
295
300
  * @param {IngestionMode} [ingestionMode]
296
301
  * @param {ChunkType} [chunkType]
297
302
  * @param {ImageTaxonomy} [secondaryTaxonomy]
@@ -377,6 +382,8 @@ export interface DocumentsApiInterface {
377
382
  * @param {SortDirection} [sortDir] Sort direction; overrides the column\&#39;s natural default
378
383
  * @param {string} [ownerId] Filter to documents owned by this user
379
384
  * @param {DocumentType} [documentType] Filter to documents of this type
385
+ * @param {number} [durationMinMs] Only media whose active version is at least this long (milliseconds). Non-media documents have no duration and are excluded.
386
+ * @param {number} [durationMaxMs] Only media whose active version is at most this long.
380
387
  * @param {boolean} [withTags] Include tags in the response (default: false)
381
388
  * @param {number} [limit] Number of items per page
382
389
  * @param {number} [offset] Number of items to skip
@@ -396,6 +403,8 @@ export interface DocumentsApiInterface {
396
403
  * @param {SortDirection} [sortDir] Sort direction; overrides the column\&#39;s natural default
397
404
  * @param {string} [ownerId] Filter to documents owned by this user
398
405
  * @param {DocumentType} [documentType] Filter to documents of this type
406
+ * @param {number} [durationMinMs] Only media whose active version is at least this long (milliseconds). Non-media documents have no duration and are excluded.
407
+ * @param {number} [durationMaxMs] Only media whose active version is at most this long.
399
408
  * @param {boolean} [withTags] Include tags in the response (default: false)
400
409
  * @param {number} [limit] Number of items per page
401
410
  * @param {number} [offset] Number of items to skip
@@ -469,6 +469,9 @@ export class DocumentsApi extends runtime.BaseAPI {
469
469
  if (requestParameters['idempotencyKey'] != null) {
470
470
  formParams.append('idempotency_key', requestParameters['idempotencyKey']);
471
471
  }
472
+ if (requestParameters['emailNestingDepth'] != null) {
473
+ formParams.append('email_nesting_depth', requestParameters['emailNestingDepth']);
474
+ }
472
475
  if (requestParameters['ingestionMode'] != null) {
473
476
  formParams.append('ingestion_mode', requestParameters['ingestionMode']);
474
477
  }
@@ -705,6 +708,12 @@ export class DocumentsApi extends runtime.BaseAPI {
705
708
  if (requestParameters['documentType'] != null) {
706
709
  queryParameters['document_type'] = requestParameters['documentType'];
707
710
  }
711
+ if (requestParameters['durationMinMs'] != null) {
712
+ queryParameters['duration_min_ms'] = requestParameters['durationMinMs'];
713
+ }
714
+ if (requestParameters['durationMaxMs'] != null) {
715
+ queryParameters['duration_max_ms'] = requestParameters['durationMaxMs'];
716
+ }
708
717
  if (requestParameters['withTags'] != null) {
709
718
  queryParameters['with_tags'] = requestParameters['withTags'];
710
719
  }
@@ -129,7 +129,7 @@ export interface SystemJobsApiInterface {
129
129
  */
130
130
  getZipIngestionStatusRequestOpts(requestParameters: GetZipIngestionStatusRequest): Promise<runtime.RequestOpts>;
131
131
  /**
132
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
132
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
133
133
  * @summary Get Zip Ingestion Status Handler
134
134
  * @param {string} workflowId
135
135
  * @param {*} [options] Override http request option.
@@ -138,7 +138,7 @@ export interface SystemJobsApiInterface {
138
138
  */
139
139
  getZipIngestionStatusRaw(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ZipIngestionStatusResponse>>;
140
140
  /**
141
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
141
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
142
142
  * Get Zip Ingestion Status Handler
143
143
  */
144
144
  getZipIngestionStatus(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ZipIngestionStatusResponse>;
@@ -231,12 +231,12 @@ export declare class SystemJobsApi extends runtime.BaseAPI implements SystemJobs
231
231
  */
232
232
  getZipIngestionStatusRequestOpts(requestParameters: GetZipIngestionStatusRequest): Promise<runtime.RequestOpts>;
233
233
  /**
234
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
234
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
235
235
  * Get Zip Ingestion Status Handler
236
236
  */
237
237
  getZipIngestionStatusRaw(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ZipIngestionStatusResponse>>;
238
238
  /**
239
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
239
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
240
240
  * Get Zip Ingestion Status Handler
241
241
  */
242
242
  getZipIngestionStatus(requestParameters: GetZipIngestionStatusRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ZipIngestionStatusResponse>;
@@ -246,7 +246,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
246
246
  });
247
247
  }
248
248
  /**
249
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
249
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
250
250
  * Get Zip Ingestion Status Handler
251
251
  */
252
252
  getZipIngestionStatusRaw(requestParameters, initOverrides) {
@@ -257,7 +257,7 @@ export class SystemJobsApi extends runtime.BaseAPI {
257
257
  });
258
258
  }
259
259
  /**
260
- * Get a ZIP fan-out\'s live status + per-member outcomes. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
260
+ * Get a fan-out\'s live status + per-member outcomes. Serves both container fan-outs: a ZIP archive\'s members and an email\'s attachments. Both expose the same ``results`` query, so one endpoint covers them rather than duplicating the tenant check and hydration. Tenant-scoped via the TenantId search attribute (no per-path can_read check — intentionally consistent with the sibling generic Temporal endpoints below; the opaque workflow_id is only handed to the uploader, who had can_write on the target). The per-member results come from the workflow\'s ``results`` query (served from retained history), so once Temporal retention expires this 404s.
261
261
  * Get Zip Ingestion Status Handler
262
262
  */
263
263
  getZipIngestionStatus(requestParameters, initOverrides) {