@iblai/iblai-api 3.61.2-ai-plus → 3.62.0-ai

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 (111) hide show
  1. package/dist/index.cjs.js +398 -1801
  2. package/dist/index.cjs.js.map +1 -1
  3. package/dist/index.esm.js +399 -1800
  4. package/dist/index.esm.js.map +1 -1
  5. package/dist/index.umd.js +398 -1801
  6. package/dist/index.umd.js.map +1 -1
  7. package/dist/types/index.d.ts +2 -41
  8. package/dist/types/models/AIGeneratedImage.d.ts +2 -2
  9. package/dist/types/models/CrawlerPatternTypeEnum.d.ts +8 -0
  10. package/dist/types/models/PatchedRbacRole.d.ts +4 -0
  11. package/dist/types/models/{Provider637Enum.d.ts → ProviderEnum.d.ts} +1 -1
  12. package/dist/types/models/RbacBaseRole.d.ts +5 -1
  13. package/dist/types/models/RbacRole.d.ts +5 -1
  14. package/dist/types/models/RetrieverDocumentEmbedding.d.ts +3 -2
  15. package/dist/types/models/RetrieverDocumentEmbeddingRequest.d.ts +7 -3
  16. package/dist/types/models/TrainDocumentViewRequest.d.ts +7 -3
  17. package/dist/types/models/Voice.d.ts +2 -2
  18. package/dist/types/services/AiMentorService.d.ts +0 -13
  19. package/package.json +1 -1
  20. package/src/core/OpenAPI.ts +1 -1
  21. package/src/index.ts +2 -41
  22. package/src/models/AIGeneratedImage.ts +2 -2
  23. package/src/models/{Provider63aEnum.ts → CrawlerPatternTypeEnum.ts} +5 -3
  24. package/src/models/PatchedRbacRole.ts +4 -0
  25. package/src/models/{Provider637Enum.ts → ProviderEnum.ts} +1 -1
  26. package/src/models/RbacBaseRole.ts +5 -1
  27. package/src/models/RbacRole.ts +5 -1
  28. package/src/models/RetrieverDocumentEmbedding.ts +3 -2
  29. package/src/models/RetrieverDocumentEmbeddingRequest.ts +7 -3
  30. package/src/models/TrainDocumentViewRequest.ts +7 -3
  31. package/src/models/Voice.ts +2 -2
  32. package/src/services/AiMentorService.ts +0 -29
  33. package/dist/types/models/Bot.d.ts +0 -15
  34. package/dist/types/models/BotCommand.d.ts +0 -6
  35. package/dist/types/models/BotCreate.d.ts +0 -12
  36. package/dist/types/models/DataSet.d.ts +0 -21
  37. package/dist/types/models/DataSetCreate.d.ts +0 -12
  38. package/dist/types/models/DataSetStatusEnum.d.ts +0 -12
  39. package/dist/types/models/DiscordConfig.d.ts +0 -7
  40. package/dist/types/models/DiscordUserConfig.d.ts +0 -10
  41. package/dist/types/models/DiscordWebhook.d.ts +0 -6
  42. package/dist/types/models/MentorFromTemplateRequest.d.ts +0 -4
  43. package/dist/types/models/PaginatedDataSetList.d.ts +0 -7
  44. package/dist/types/models/PaginatedTrainingList.d.ts +0 -7
  45. package/dist/types/models/PatchedBotCommand.d.ts +0 -6
  46. package/dist/types/models/PatchedBotCreate.d.ts +0 -12
  47. package/dist/types/models/PatchedDataSet.d.ts +0 -21
  48. package/dist/types/models/PatchedDiscordConfig.d.ts +0 -7
  49. package/dist/types/models/PatchedDiscordUserConfig.d.ts +0 -10
  50. package/dist/types/models/PatchedSlackConfig.d.ts +0 -8
  51. package/dist/types/models/PatchedSlackUserConfig.d.ts +0 -17
  52. package/dist/types/models/PatchedTeamsConfig.d.ts +0 -7
  53. package/dist/types/models/PatchedTrainingCreate.d.ts +0 -31
  54. package/dist/types/models/PatchedWebexConfig.d.ts +0 -10
  55. package/dist/types/models/PatchedWhatsappConfig.d.ts +0 -11
  56. package/dist/types/models/PatchedWhatsappUserConfig.d.ts +0 -10
  57. package/dist/types/models/Provider05cEnum.d.ts +0 -14
  58. package/dist/types/models/Provider63aEnum.d.ts +0 -6
  59. package/dist/types/models/SlackConfig.d.ts +0 -8
  60. package/dist/types/models/SlackUserConfig.d.ts +0 -17
  61. package/dist/types/models/SlackWebhook.d.ts +0 -6
  62. package/dist/types/models/TeamsConfig.d.ts +0 -7
  63. package/dist/types/models/TeamsWebhook.d.ts +0 -17
  64. package/dist/types/models/Training.d.ts +0 -41
  65. package/dist/types/models/TrainingCreate.d.ts +0 -31
  66. package/dist/types/models/WebexConfig.d.ts +0 -10
  67. package/dist/types/models/WebexWebhook.d.ts +0 -4
  68. package/dist/types/models/WhatAppWebHook.d.ts +0 -3
  69. package/dist/types/models/WhatsappConfig.d.ts +0 -11
  70. package/dist/types/models/WhatsappUserConfig.d.ts +0 -10
  71. package/dist/types/services/AiBotService.d.ts +0 -642
  72. package/dist/types/services/AiFinetuningService.d.ts +0 -232
  73. package/src/models/Bot.ts +0 -20
  74. package/src/models/BotCommand.ts +0 -11
  75. package/src/models/BotCreate.ts +0 -17
  76. package/src/models/DataSet.ts +0 -26
  77. package/src/models/DataSetCreate.ts +0 -17
  78. package/src/models/DataSetStatusEnum.ts +0 -16
  79. package/src/models/DiscordConfig.ts +0 -12
  80. package/src/models/DiscordUserConfig.ts +0 -15
  81. package/src/models/DiscordWebhook.ts +0 -11
  82. package/src/models/MentorFromTemplateRequest.ts +0 -9
  83. package/src/models/PaginatedDataSetList.ts +0 -12
  84. package/src/models/PaginatedTrainingList.ts +0 -12
  85. package/src/models/PatchedBotCommand.ts +0 -11
  86. package/src/models/PatchedBotCreate.ts +0 -17
  87. package/src/models/PatchedDataSet.ts +0 -26
  88. package/src/models/PatchedDiscordConfig.ts +0 -12
  89. package/src/models/PatchedDiscordUserConfig.ts +0 -15
  90. package/src/models/PatchedSlackConfig.ts +0 -13
  91. package/src/models/PatchedSlackUserConfig.ts +0 -22
  92. package/src/models/PatchedTeamsConfig.ts +0 -12
  93. package/src/models/PatchedTrainingCreate.ts +0 -36
  94. package/src/models/PatchedWebexConfig.ts +0 -15
  95. package/src/models/PatchedWhatsappConfig.ts +0 -16
  96. package/src/models/PatchedWhatsappUserConfig.ts +0 -15
  97. package/src/models/Provider05cEnum.ts +0 -18
  98. package/src/models/SlackConfig.ts +0 -13
  99. package/src/models/SlackUserConfig.ts +0 -22
  100. package/src/models/SlackWebhook.ts +0 -11
  101. package/src/models/TeamsConfig.ts +0 -12
  102. package/src/models/TeamsWebhook.ts +0 -22
  103. package/src/models/Training.ts +0 -46
  104. package/src/models/TrainingCreate.ts +0 -36
  105. package/src/models/WebexConfig.ts +0 -15
  106. package/src/models/WebexWebhook.ts +0 -9
  107. package/src/models/WhatAppWebHook.ts +0 -8
  108. package/src/models/WhatsappConfig.ts +0 -16
  109. package/src/models/WhatsappUserConfig.ts +0 -15
  110. package/src/services/AiBotService.ts +0 -1330
  111. package/src/services/AiFinetuningService.ts +0 -472
package/dist/index.esm.js CHANGED
@@ -108,7 +108,7 @@ class CancelablePromise {
108
108
 
109
109
  const OpenAPI = {
110
110
  BASE: 'https://base.manager.iblai.app',
111
- VERSION: '3.61.2-ai-plus',
111
+ VERSION: '3.62.0-ai',
112
112
  WITH_CREDENTIALS: false,
113
113
  CREDENTIALS: 'include',
114
114
  TOKEN: undefined,
@@ -248,18 +248,14 @@ var CourseCreationTaskStatusEnum;
248
248
  /* tslint:disable */
249
249
  /* eslint-disable */
250
250
  /**
251
- * * `pending` - Pending
252
- * * `processing` - Processing
253
- * * `completed` - Completed
254
- * * `failed` - Failed
251
+ * * `glob` - Glob
252
+ * * `regex` - Regex
255
253
  */
256
- var DataSetStatusEnum;
257
- (function (DataSetStatusEnum) {
258
- DataSetStatusEnum["PENDING"] = "pending";
259
- DataSetStatusEnum["PROCESSING"] = "processing";
260
- DataSetStatusEnum["COMPLETED"] = "completed";
261
- DataSetStatusEnum["FAILED"] = "failed";
262
- })(DataSetStatusEnum || (DataSetStatusEnum = {}));
254
+ var CrawlerPatternTypeEnum;
255
+ (function (CrawlerPatternTypeEnum) {
256
+ CrawlerPatternTypeEnum["GLOB"] = "glob";
257
+ CrawlerPatternTypeEnum["REGEX"] = "regex";
258
+ })(CrawlerPatternTypeEnum || (CrawlerPatternTypeEnum = {}));
263
259
 
264
260
  /* generated using openapi-typescript-codegen -- do not edit */
265
261
  /* istanbul ignore file */
@@ -541,26 +537,6 @@ var PromptVisibilityEnum;
541
537
  PromptVisibilityEnum["VIEWABLE_BY_ANYONE"] = "viewable_by_anyone";
542
538
  })(PromptVisibilityEnum || (PromptVisibilityEnum = {}));
543
539
 
544
- /* generated using openapi-typescript-codegen -- do not edit */
545
- /* istanbul ignore file */
546
- /* tslint:disable */
547
- /* eslint-disable */
548
- /**
549
- * * `webex` - Webex
550
- * * `slack` - Slack
551
- * * `whatsapp` - Whatsapp
552
- * * `discord` - Discord
553
- * * `teams` - Teams
554
- */
555
- var Provider05cEnum;
556
- (function (Provider05cEnum) {
557
- Provider05cEnum["WEBEX"] = "webex";
558
- Provider05cEnum["SLACK"] = "slack";
559
- Provider05cEnum["WHATSAPP"] = "whatsapp";
560
- Provider05cEnum["DISCORD"] = "discord";
561
- Provider05cEnum["TEAMS"] = "teams";
562
- })(Provider05cEnum || (Provider05cEnum = {}));
563
-
564
540
  /* generated using openapi-typescript-codegen -- do not edit */
565
541
  /* istanbul ignore file */
566
542
  /* tslint:disable */
@@ -570,24 +546,12 @@ var Provider05cEnum;
570
546
  * * `google` - Google
571
547
  * * `elevenlabs` - Elevenlabs
572
548
  */
573
- var Provider637Enum;
574
- (function (Provider637Enum) {
575
- Provider637Enum["OPENAI"] = "openai";
576
- Provider637Enum["GOOGLE"] = "google";
577
- Provider637Enum["ELEVENLABS"] = "elevenlabs";
578
- })(Provider637Enum || (Provider637Enum = {}));
579
-
580
- /* generated using openapi-typescript-codegen -- do not edit */
581
- /* istanbul ignore file */
582
- /* tslint:disable */
583
- /* eslint-disable */
584
- /**
585
- * * `openai` - Openai
586
- */
587
- var Provider63aEnum;
588
- (function (Provider63aEnum) {
589
- Provider63aEnum["OPENAI"] = "openai";
590
- })(Provider63aEnum || (Provider63aEnum = {}));
549
+ var ProviderEnum;
550
+ (function (ProviderEnum) {
551
+ ProviderEnum["OPENAI"] = "openai";
552
+ ProviderEnum["GOOGLE"] = "google";
553
+ ProviderEnum["ELEVENLABS"] = "elevenlabs";
554
+ })(ProviderEnum || (ProviderEnum = {}));
591
555
 
592
556
  /* generated using openapi-typescript-codegen -- do not edit */
593
557
  /* istanbul ignore file */
@@ -9130,1871 +9094,530 @@ class AiAnalyticsService {
9130
9094
  }
9131
9095
  }
9132
9096
 
9133
- class AiBotService {
9097
+ class AiIndexService {
9134
9098
  /**
9135
- * Create modify and update bot information for a specific tenant.
9136
- * @returns Bot
9099
+ * Retrieve details of a specific document embedding.
9100
+ *
9101
+ * This endpoint returns detailed information about a specific
9102
+ * document embedding identified by its ID.
9103
+ *
9104
+ * Args:
9105
+ * request: The HTTP request.
9106
+ * org: Organization key identifier.
9107
+ * document_id: The ID of the document embedding to retrieve.
9108
+ *
9109
+ * Returns:
9110
+ * Response: Detailed information about the document embedding.
9111
+ *
9112
+ * Raises:
9113
+ * NotFound: If the specified document embedding does not exist.
9114
+ * @returns RetrieverDocumentEmbedding
9137
9115
  * @throws ApiError
9138
9116
  */
9139
- static aiBotV1BotsBotList({
9140
- org
9117
+ static aiIndexOrgsUsersDocumentsRetrieve({
9118
+ documentId,
9119
+ org,
9120
+ userId
9141
9121
  }) {
9142
9122
  return request(OpenAPI, {
9143
9123
  method: 'GET',
9144
- url: '/api/ai-bot/v1/bots/{org}/bot/',
9124
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
9145
9125
  path: {
9146
- 'org': org
9126
+ 'document_id': documentId,
9127
+ 'org': org,
9128
+ 'user_id': userId
9129
+ },
9130
+ errors: {
9131
+ 404: `Document not found`
9147
9132
  }
9148
9133
  });
9149
9134
  }
9150
9135
  /**
9151
- * Create modify and update bot information for a specific tenant.
9152
- * @returns BotCreate
9136
+ * Update a specific document embedding.
9137
+ *
9138
+ * This endpoint allows updating various properties of a document embedding,
9139
+ * including its name, type, pathway, and training status.
9140
+ *
9141
+ * Args:
9142
+ * request: The HTTP request containing the updated document data.
9143
+ * org: Organization key identifier.
9144
+ * document_id: The ID of the document embedding to update.
9145
+ *
9146
+ * Returns:
9147
+ * Response: The updated document embedding information.
9148
+ *
9149
+ * Raises:
9150
+ * BadRequest: If the provided data is invalid.
9151
+ * NotFound: If the specified document embedding does not exist.
9152
+ * @returns RetrieverDocumentEmbedding
9153
9153
  * @throws ApiError
9154
9154
  */
9155
- static aiBotV1BotsBotCreate({
9155
+ static aiIndexOrgsUsersDocumentsUpdate({
9156
+ documentId,
9156
9157
  org,
9157
- requestBody
9158
+ userId,
9159
+ formData
9158
9160
  }) {
9159
9161
  return request(OpenAPI, {
9160
- method: 'POST',
9161
- url: '/api/ai-bot/v1/bots/{org}/bot/',
9162
+ method: 'PUT',
9163
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
9162
9164
  path: {
9163
- 'org': org
9165
+ 'document_id': documentId,
9166
+ 'org': org,
9167
+ 'user_id': userId
9164
9168
  },
9165
- body: requestBody,
9166
- mediaType: 'application/json'
9167
- });
9168
- }
9169
- /**
9170
- * Create slash commands for a specific bot
9171
- * eg. /iblai-baseline
9172
- * @returns BotCommand
9173
- * @throws ApiError
9174
- */
9175
- static aiBotV1BotsBotCommandsList({
9176
- org
9177
- }) {
9178
- return request(OpenAPI, {
9179
- method: 'GET',
9180
- url: '/api/ai-bot/v1/bots/{org}/bot-commands/',
9181
- path: {
9182
- 'org': org
9169
+ formData: formData,
9170
+ mediaType: 'multipart/form-data',
9171
+ errors: {
9172
+ 400: `Invalid request data`,
9173
+ 404: `Document not found`
9183
9174
  }
9184
9175
  });
9185
9176
  }
9186
9177
  /**
9187
- * Create slash commands for a specific bot
9188
- * eg. /iblai-baseline
9189
- * @returns BotCommand
9178
+ * Delete a specific document embedding.
9179
+ *
9180
+ * This endpoint removes a document embedding from the system,
9181
+ * including untraining it from any associated pathways.
9182
+ *
9183
+ * Args:
9184
+ * request: The HTTP request.
9185
+ * org: Organization key identifier.
9186
+ * document_id: The ID of the document embedding to delete.
9187
+ *
9188
+ * Returns:
9189
+ * Response: An empty response with a 204 status code if successful.
9190
+ *
9191
+ * Raises:
9192
+ * NotFound: If the specified document embedding does not exist.
9193
+ * @returns void
9190
9194
  * @throws ApiError
9191
9195
  */
9192
- static aiBotV1BotsBotCommandsCreate({
9196
+ static aiIndexOrgsUsersDocumentsDestroy({
9197
+ documentId,
9193
9198
  org,
9194
- requestBody
9199
+ userId
9195
9200
  }) {
9196
9201
  return request(OpenAPI, {
9197
- method: 'POST',
9198
- url: '/api/ai-bot/v1/bots/{org}/bot-commands/',
9202
+ method: 'DELETE',
9203
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
9199
9204
  path: {
9200
- 'org': org
9205
+ 'document_id': documentId,
9206
+ 'org': org,
9207
+ 'user_id': userId
9201
9208
  },
9202
- body: requestBody,
9203
- mediaType: 'application/json'
9209
+ errors: {
9210
+ 404: `Document not found`
9211
+ }
9204
9212
  });
9205
9213
  }
9206
9214
  /**
9207
- * Create slash commands for a specific bot
9208
- * eg. /iblai-baseline
9209
- * @returns BotCommand
9215
+ * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
9216
+ * @returns DocumentSettingsResponse
9210
9217
  * @throws ApiError
9211
9218
  */
9212
- static aiBotV1BotsBotCommandsRetrieve({
9213
- id,
9214
- org
9219
+ static aiIndexOrgsUsersDocumentsSettingsRetrieve({
9220
+ documentId,
9221
+ org,
9222
+ userId
9215
9223
  }) {
9216
9224
  return request(OpenAPI, {
9217
9225
  method: 'GET',
9218
- url: '/api/ai-bot/v1/bots/{org}/bot-commands/{id}/',
9226
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/settings/',
9219
9227
  path: {
9220
- 'id': id,
9221
- 'org': org
9228
+ 'document_id': documentId,
9229
+ 'org': org,
9230
+ 'user_id': userId
9222
9231
  }
9223
9232
  });
9224
9233
  }
9225
9234
  /**
9226
- * Create slash commands for a specific bot
9227
- * eg. /iblai-baseline
9228
- * @returns BotCommand
9235
+ * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
9236
+ * @returns DocumentSettingsResponse
9229
9237
  * @throws ApiError
9230
9238
  */
9231
- static aiBotV1BotsBotCommandsUpdate({
9232
- id,
9239
+ static aiIndexOrgsUsersDocumentsSettingsCreate({
9240
+ documentId,
9233
9241
  org,
9242
+ userId,
9234
9243
  requestBody
9235
9244
  }) {
9236
9245
  return request(OpenAPI, {
9237
- method: 'PUT',
9238
- url: '/api/ai-bot/v1/bots/{org}/bot-commands/{id}/',
9246
+ method: 'POST',
9247
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/settings/',
9239
9248
  path: {
9240
- 'id': id,
9241
- 'org': org
9249
+ 'document_id': documentId,
9250
+ 'org': org,
9251
+ 'user_id': userId
9242
9252
  },
9243
9253
  body: requestBody,
9244
9254
  mediaType: 'application/json'
9245
9255
  });
9246
9256
  }
9247
9257
  /**
9248
- * Create slash commands for a specific bot
9249
- * eg. /iblai-baseline
9250
- * @returns BotCommand
9258
+ * Train a graph-based document through a worker process.
9259
+ *
9260
+ * This endpoint queues graph-based documents for training through a
9261
+ * specialized worker process that handles knowledge graph processing.
9262
+ *
9263
+ * Args:
9264
+ * request: The HTTP request containing the document information.
9265
+ * org: Organization key identifier.
9266
+ *
9267
+ * Returns:
9268
+ * Response: A confirmation that the document was queued for training,
9269
+ * including a task ID for tracking the progress.
9270
+ *
9271
+ * Raises:
9272
+ * ValidationError: If the request data is invalid.
9273
+ * BadRequest: If there was an error processing the document.
9274
+ * @returns TrainDocumentViewResponse
9251
9275
  * @throws ApiError
9252
9276
  */
9253
- static aiBotV1BotsBotCommandsPartialUpdate({
9254
- id,
9277
+ static aiIndexOrgsUsersDocumentsGraphTrainCreate({
9255
9278
  org,
9256
- requestBody
9279
+ userId,
9280
+ formData
9257
9281
  }) {
9258
9282
  return request(OpenAPI, {
9259
- method: 'PATCH',
9260
- url: '/api/ai-bot/v1/bots/{org}/bot-commands/{id}/',
9283
+ method: 'POST',
9284
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/graph-train/',
9261
9285
  path: {
9262
- 'id': id,
9263
- 'org': org
9286
+ 'org': org,
9287
+ 'user_id': userId
9264
9288
  },
9265
- body: requestBody,
9266
- mediaType: 'application/json'
9267
- });
9268
- }
9269
- /**
9270
- * Create slash commands for a specific bot
9271
- * eg. /iblai-baseline
9272
- * @returns void
9273
- * @throws ApiError
9274
- */
9275
- static aiBotV1BotsBotCommandsDestroy({
9276
- id,
9277
- org
9278
- }) {
9279
- return request(OpenAPI, {
9280
- method: 'DELETE',
9281
- url: '/api/ai-bot/v1/bots/{org}/bot-commands/{id}/',
9282
- path: {
9283
- 'id': id,
9284
- 'org': org
9289
+ formData: formData,
9290
+ mediaType: 'multipart/form-data',
9291
+ errors: {
9292
+ 400: `Invalid request data or document processing error`
9285
9293
  }
9286
9294
  });
9287
9295
  }
9288
9296
  /**
9289
- * Create modify and update bot information for a specific tenant.
9290
- * @returns Bot
9291
- * @throws ApiError
9292
- */
9293
- static aiBotV1BotsBotRetrieve({
9294
- id,
9295
- org
9297
+ * Description:
9298
+ * Retrieves a list of document embeddings for a specific pathway with optional search and pagination.
9299
+ *
9300
+ * Methods:
9301
+ * - GET: Retrieves document embeddings that match the specified search criteria and are paginated according to offset and limit.
9302
+ *
9303
+ * Parameters:
9304
+ * - search (str): Search query to filter document names or URLs.
9305
+ * - offset (int): Offset number for pagination.
9306
+ * - limit (int): Limit number for pagination.
9307
+ *
9308
+ * Returns:
9309
+ * - GET: A paginated list of document embeddings with their details.
9310
+ * {
9311
+ * "count": 10,
9312
+ * "next": "http://api.example.com/retriever_documents/?offset=10&limit=2",
9313
+ * "previous": "http://api.example.com/retriever_documents/?offset=0&limit=2",
9314
+ * "results": [
9315
+ * {
9316
+ * "document_name": "Document2",
9317
+ * "platform_key": "example_platform",
9318
+ * "pathway": "example_pathway"
9319
+ * }
9320
+ * ]
9321
+ * }
9322
+ *
9323
+ * Error Responses:
9324
+ * - 400 Bad Request: Invalid query parameters.
9325
+ * - 404 Not Found: No document embeddings found for the specified criteria.
9326
+ * @returns PaginatedRetrieverDocumentEmbeddingList
9327
+ * @throws ApiError
9328
+ */
9329
+ static aiIndexOrgsUsersDocumentsPathwaysList({
9330
+ org,
9331
+ pathway,
9332
+ userId,
9333
+ limit,
9334
+ offset,
9335
+ search
9296
9336
  }) {
9297
9337
  return request(OpenAPI, {
9298
9338
  method: 'GET',
9299
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/',
9339
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/pathways/{pathway}/',
9300
9340
  path: {
9301
- 'id': id,
9302
- 'org': org
9341
+ 'org': org,
9342
+ 'pathway': pathway,
9343
+ 'user_id': userId
9344
+ },
9345
+ query: {
9346
+ 'limit': limit,
9347
+ 'offset': offset,
9348
+ 'search': search
9303
9349
  }
9304
9350
  });
9305
9351
  }
9306
9352
  /**
9307
- * Create modify and update bot information for a specific tenant.
9308
- * @returns BotCreate
9353
+ * Retrieve resource documents similar to the given query.
9354
+ *
9355
+ * This endpoint performs a semantic search to find documents that are
9356
+ * relevant to the provided query within the specified pathway.
9357
+ *
9358
+ * Args:
9359
+ * request: The HTTP request containing the search query.
9360
+ * org: Organization key identifier.
9361
+ *
9362
+ * Returns:
9363
+ * Response: A list of documents relevant to the search query.
9364
+ *
9365
+ * Raises:
9366
+ * ValidationError: If the request data is invalid.
9367
+ * @returns RetrieverResponseSearch
9309
9368
  * @throws ApiError
9310
9369
  */
9311
- static aiBotV1BotsBotUpdate({
9312
- id,
9370
+ static aiIndexOrgsUsersDocumentsSearchCreate({
9313
9371
  org,
9372
+ userId,
9314
9373
  requestBody
9315
9374
  }) {
9316
9375
  return request(OpenAPI, {
9317
- method: 'PUT',
9318
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/',
9376
+ method: 'POST',
9377
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/search/',
9319
9378
  path: {
9320
- 'id': id,
9321
- 'org': org
9379
+ 'org': org,
9380
+ 'user_id': userId
9322
9381
  },
9323
9382
  body: requestBody,
9324
- mediaType: 'application/json'
9383
+ mediaType: 'application/json',
9384
+ errors: {
9385
+ 400: `Invalid request data`
9386
+ }
9325
9387
  });
9326
9388
  }
9327
9389
  /**
9328
- * Create modify and update bot information for a specific tenant.
9329
- * @returns BotCreate
9390
+ * Retrieve document sources related to a given query.
9391
+ *
9392
+ * This endpoint performs a semantic search to find document sources
9393
+ * that are relevant to the provided query within the specified pathway,
9394
+ * and returns them along with confidence levels.
9395
+ *
9396
+ * Args:
9397
+ * request: The HTTP request containing the search query.
9398
+ * org: Organization key identifier.
9399
+ *
9400
+ * Returns:
9401
+ * Response: A list of document sources with confidence levels.
9402
+ *
9403
+ * Raises:
9404
+ * ValidationError: If the request data is invalid.
9405
+ * @returns RetrieverRequestSearchDocument
9330
9406
  * @throws ApiError
9331
9407
  */
9332
- static aiBotV1BotsBotPartialUpdate({
9333
- id,
9408
+ static aiIndexOrgsUsersDocumentsSourcesCreate({
9334
9409
  org,
9410
+ userId,
9335
9411
  requestBody
9336
9412
  }) {
9337
9413
  return request(OpenAPI, {
9338
- method: 'PATCH',
9339
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/',
9414
+ method: 'POST',
9415
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/sources/',
9340
9416
  path: {
9341
- 'id': id,
9342
- 'org': org
9417
+ 'org': org,
9418
+ 'user_id': userId
9343
9419
  },
9344
9420
  body: requestBody,
9345
- mediaType: 'application/json'
9346
- });
9347
- }
9348
- /**
9349
- * Create modify and update bot information for a specific tenant.
9350
- * @returns void
9351
- * @throws ApiError
9352
- */
9353
- static aiBotV1BotsBotDestroy({
9354
- id,
9355
- org
9356
- }) {
9357
- return request(OpenAPI, {
9358
- method: 'DELETE',
9359
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/',
9360
- path: {
9361
- 'id': id,
9362
- 'org': org
9421
+ mediaType: 'application/json',
9422
+ errors: {
9423
+ 400: `Invalid request data`
9363
9424
  }
9364
9425
  });
9365
9426
  }
9366
9427
  /**
9367
- * Create modify and update bot information for a specific tenant.
9368
- * @returns DiscordConfig
9428
+ * Check the status of a document training task.
9429
+ *
9430
+ * This endpoint retrieves the current status of an asynchronous
9431
+ * document training task that was previously initiated.
9432
+ *
9433
+ * Args:
9434
+ * request: The HTTP request.
9435
+ * org: Organization key identifier.
9436
+ * task_id: The ID of the training task to check.
9437
+ *
9438
+ * Returns:
9439
+ * Response: The current status of the document training task,
9440
+ * which can be "pending", "completed", or "failed".
9441
+ * @returns CheckDocumentTrainingStatus
9369
9442
  * @throws ApiError
9370
9443
  */
9371
- static aiBotV1BotsBotConfigDiscordRetrieve({
9372
- id,
9373
- org
9444
+ static aiIndexOrgsUsersDocumentsTasksRetrieve({
9445
+ org,
9446
+ taskId,
9447
+ userId
9374
9448
  }) {
9375
9449
  return request(OpenAPI, {
9376
9450
  method: 'GET',
9377
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/discord/',
9451
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/tasks/{task_id}/',
9378
9452
  path: {
9379
- 'id': id,
9380
- 'org': org
9453
+ 'org': org,
9454
+ 'task_id': taskId,
9455
+ 'user_id': userId
9381
9456
  }
9382
9457
  });
9383
9458
  }
9384
9459
  /**
9385
- * Create modify and update bot information for a specific tenant.
9386
- * @returns DiscordConfig
9460
+ * Train a document through a worker process.
9461
+ *
9462
+ * This endpoint queues larger documents for training through a worker
9463
+ * process, which is more suitable for handling documents that would
9464
+ * take too long to process directly.
9465
+ *
9466
+ * Args:
9467
+ * request: The HTTP request containing the document information.
9468
+ * org: Organization key identifier.
9469
+ *
9470
+ * Returns:
9471
+ * Response: A confirmation that the document was queued for training,
9472
+ * including a task ID for tracking the progress.
9473
+ *
9474
+ * Raises:
9475
+ * ValidationError: If the request data is invalid.
9476
+ * BadRequest: If there was an error processing the document.
9477
+ * @returns TrainDocumentViewResponse
9387
9478
  * @throws ApiError
9388
9479
  */
9389
- static aiBotV1BotsBotConfigDiscordPartialUpdate({
9390
- id,
9480
+ static aiIndexOrgsUsersDocumentsTrainCreate({
9391
9481
  org,
9392
- requestBody
9482
+ userId,
9483
+ formData
9393
9484
  }) {
9394
9485
  return request(OpenAPI, {
9395
- method: 'PATCH',
9396
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/discord/',
9486
+ method: 'POST',
9487
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/train/',
9397
9488
  path: {
9398
- 'id': id,
9399
- 'org': org
9489
+ 'org': org,
9490
+ 'user_id': userId
9400
9491
  },
9401
- body: requestBody,
9402
- mediaType: 'application/json'
9492
+ formData: formData,
9493
+ mediaType: 'multipart/form-data',
9494
+ errors: {
9495
+ 400: `Invalid request data`
9496
+ }
9403
9497
  });
9404
9498
  }
9405
9499
  /**
9406
- * Create modify and update bot information for a specific tenant.
9407
- * @returns SlackConfig
9500
+ * Train a document directly without using a worker.
9501
+ *
9502
+ * This endpoint is designed for training smaller documents directly
9503
+ * without queuing them through a worker process. For larger documents,
9504
+ * use the TrainDocumentView endpoint instead.
9505
+ *
9506
+ * Args:
9507
+ * request: The HTTP request containing the document information.
9508
+ * org: Organization key identifier.
9509
+ *
9510
+ * Returns:
9511
+ * Response: A confirmation that the document was trained successfully.
9512
+ *
9513
+ * Raises:
9514
+ * ValidationError: If the request data is invalid.
9515
+ * BadRequest: If the document training failed.
9516
+ * @returns RetreiverTrainViewResponse
9408
9517
  * @throws ApiError
9409
9518
  */
9410
- static aiBotV1BotsBotConfigSlackRetrieve({
9411
- id,
9412
- org
9519
+ static aiIndexOrgsUsersDocumentsTrainRetrieverCreate({
9520
+ org,
9521
+ userId,
9522
+ formData
9413
9523
  }) {
9414
9524
  return request(OpenAPI, {
9415
- method: 'GET',
9416
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/slack/',
9525
+ method: 'POST',
9526
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/train/retriever/',
9417
9527
  path: {
9418
- 'id': id,
9419
- 'org': org
9528
+ 'org': org,
9529
+ 'user_id': userId
9530
+ },
9531
+ formData: formData,
9532
+ mediaType: 'multipart/form-data',
9533
+ errors: {
9534
+ 400: `Invalid request data or training failed`
9420
9535
  }
9421
9536
  });
9422
9537
  }
9423
9538
  /**
9424
- * Create modify and update bot information for a specific tenant.
9425
- * @returns SlackConfig
9426
- * @throws ApiError
9427
- */
9428
- static aiBotV1BotsBotConfigSlackUpdateCreate({
9429
- id,
9539
+ * Description:
9540
+ * Submit a document file in a chat session. Checks file type, size, and ensures the session exists, then processes the file.
9541
+ * Process document for use in a specific chat session.
9542
+ * which will be processed and made available for the AI to reference
9543
+ * when responding to queries in that session.
9544
+ *
9545
+ * Methods:
9546
+ * - POST: Submits a document or media file for training within a specified chat session.
9547
+ *
9548
+ * Parameters:
9549
+ * - org (str):
9550
+ * - session_id (str): UUID of the chat session for which the document is being submitted.
9551
+ * - *args, **kwargs: Additional arguments.
9552
+ * - file (file): Multipart file input.
9553
+ *
9554
+ * Returns:
9555
+ * - POST: Returns a JSON message with the result of the upload process. Response code 200 on success.
9556
+ * {
9557
+ * "message": "File processed."
9558
+ * }
9559
+ *
9560
+ * Error Responses:
9561
+ * - 400 Bad Request:
9562
+ * - "File field is required" if the 'file' parameter is missing.
9563
+ * - "invalid file object" if the file object is not valid.
9564
+ * - Specific error message if an exception occurs while saving to Redis.
9565
+ * - 404 Not Found:
9566
+ * - "Session not found" if the provided session_id does not match any existing session.
9567
+ * - 413 Request Entity Too Large:
9568
+ * - "file is too large" including specific limits for document and media files if the file exceeds size limits.
9569
+ *
9570
+ * Access Control:
9571
+ * Requires authentication with a Bearer token in the Authorization header. The user associated with the session must exist and be authorized for the request.
9572
+ * @returns TrainChatSessionDocumentView
9573
+ * @throws ApiError
9574
+ */
9575
+ static aiIndexOrgsUsersDocumentsTrainSessionsCreate({
9430
9576
  org,
9431
- requestBody
9577
+ sessionId,
9578
+ userId,
9579
+ formData
9432
9580
  }) {
9433
9581
  return request(OpenAPI, {
9434
9582
  method: 'POST',
9435
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/slack/update/',
9583
+ url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/train/sessions/{session_id}/',
9436
9584
  path: {
9437
- 'id': id,
9438
- 'org': org
9585
+ 'org': org,
9586
+ 'session_id': sessionId,
9587
+ 'user_id': userId
9439
9588
  },
9440
- body: requestBody,
9441
- mediaType: 'application/json'
9589
+ formData: formData,
9590
+ mediaType: 'multipart/form-data',
9591
+ errors: {
9592
+ 400: `Invalid file or processing error`,
9593
+ 413: `File too large`
9594
+ }
9442
9595
  });
9443
9596
  }
9444
9597
  /**
9445
- * Create modify and update bot information for a specific tenant.
9446
- * @returns SlackConfig
9598
+ * Retrieve detailed information about a specific scraped resource.
9599
+ *
9600
+ * This endpoint returns the complete scraped data for a specific resource
9601
+ * identified by its ID.
9602
+ *
9603
+ * Args:
9604
+ * request: The HTTP request.
9605
+ * org: Organization key identifier.
9606
+ * user_id: The username of the user associated with the resource.
9607
+ * resource_id: The ID of the resource to retrieve.
9608
+ *
9609
+ * Returns:
9610
+ * Response: The complete scraped data for the specified resource.
9611
+ *
9612
+ * Raises:
9613
+ * NotFound: If the specified resource data does not exist.
9614
+ * @returns ResourceScrappedData
9447
9615
  * @throws ApiError
9448
9616
  */
9449
- static aiBotV1BotsBotConfigSlackUpdateUpdate({
9450
- id,
9617
+ static aiIndexOrgsUsersResourceDataScrappedRetrieve({
9451
9618
  org,
9452
- requestBody
9453
- }) {
9454
- return request(OpenAPI, {
9455
- method: 'PUT',
9456
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/slack/update/',
9457
- path: {
9458
- 'id': id,
9459
- 'org': org
9460
- },
9461
- body: requestBody,
9462
- mediaType: 'application/json'
9463
- });
9464
- }
9465
- /**
9466
- * Create modify and update bot information for a specific tenant.
9467
- * @returns SlackConfig
9468
- * @throws ApiError
9469
- */
9470
- static aiBotV1BotsBotConfigSlackUpdatePartialUpdate({
9471
- id,
9472
- org,
9473
- requestBody
9474
- }) {
9475
- return request(OpenAPI, {
9476
- method: 'PATCH',
9477
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/slack/update/',
9478
- path: {
9479
- 'id': id,
9480
- 'org': org
9481
- },
9482
- body: requestBody,
9483
- mediaType: 'application/json'
9484
- });
9485
- }
9486
- /**
9487
- * Create modify and update bot information for a specific tenant.
9488
- * @returns TeamsConfig
9489
- * @throws ApiError
9490
- */
9491
- static aiBotV1BotsBotConfigTeamsRetrieve({
9492
- id,
9493
- org
9494
- }) {
9495
- return request(OpenAPI, {
9496
- method: 'GET',
9497
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/teams/',
9498
- path: {
9499
- 'id': id,
9500
- 'org': org
9501
- }
9502
- });
9503
- }
9504
- /**
9505
- * Create modify and update bot information for a specific tenant.
9506
- * @returns TeamsConfig
9507
- * @throws ApiError
9508
- */
9509
- static aiBotV1BotsBotConfigTeamsUpdateCreate({
9510
- id,
9511
- org,
9512
- requestBody
9513
- }) {
9514
- return request(OpenAPI, {
9515
- method: 'POST',
9516
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/teams/update/',
9517
- path: {
9518
- 'id': id,
9519
- 'org': org
9520
- },
9521
- body: requestBody,
9522
- mediaType: 'application/json'
9523
- });
9524
- }
9525
- /**
9526
- * Create modify and update bot information for a specific tenant.
9527
- * @returns TeamsConfig
9528
- * @throws ApiError
9529
- */
9530
- static aiBotV1BotsBotConfigTeamsUpdateUpdate({
9531
- id,
9532
- org,
9533
- requestBody
9534
- }) {
9535
- return request(OpenAPI, {
9536
- method: 'PUT',
9537
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/teams/update/',
9538
- path: {
9539
- 'id': id,
9540
- 'org': org
9541
- },
9542
- body: requestBody,
9543
- mediaType: 'application/json'
9544
- });
9545
- }
9546
- /**
9547
- * Create modify and update bot information for a specific tenant.
9548
- * @returns TeamsConfig
9549
- * @throws ApiError
9550
- */
9551
- static aiBotV1BotsBotConfigTeamsUpdatePartialUpdate({
9552
- id,
9553
- org,
9554
- requestBody
9555
- }) {
9556
- return request(OpenAPI, {
9557
- method: 'PATCH',
9558
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/teams/update/',
9559
- path: {
9560
- 'id': id,
9561
- 'org': org
9562
- },
9563
- body: requestBody,
9564
- mediaType: 'application/json'
9565
- });
9566
- }
9567
- /**
9568
- * Create modify and update bot information for a specific tenant.
9569
- * @returns WebexConfig
9570
- * @throws ApiError
9571
- */
9572
- static aiBotV1BotsBotConfigWebexRetrieve({
9573
- id,
9574
- org
9575
- }) {
9576
- return request(OpenAPI, {
9577
- method: 'GET',
9578
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/webex/',
9579
- path: {
9580
- 'id': id,
9581
- 'org': org
9582
- }
9583
- });
9584
- }
9585
- /**
9586
- * Create modify and update bot information for a specific tenant.
9587
- * @returns WebexConfig
9588
- * @throws ApiError
9589
- */
9590
- static aiBotV1BotsBotConfigWebexPartialUpdate({
9591
- id,
9592
- org,
9593
- requestBody
9594
- }) {
9595
- return request(OpenAPI, {
9596
- method: 'PATCH',
9597
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/webex/',
9598
- path: {
9599
- 'id': id,
9600
- 'org': org
9601
- },
9602
- body: requestBody,
9603
- mediaType: 'application/json'
9604
- });
9605
- }
9606
- /**
9607
- * Create modify and update bot information for a specific tenant.
9608
- * @returns WhatsappConfig
9609
- * @throws ApiError
9610
- */
9611
- static aiBotV1BotsBotConfigWhatsappRetrieve({
9612
- id,
9613
- org
9614
- }) {
9615
- return request(OpenAPI, {
9616
- method: 'GET',
9617
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/whatsapp/',
9618
- path: {
9619
- 'id': id,
9620
- 'org': org
9621
- }
9622
- });
9623
- }
9624
- /**
9625
- * Create modify and update bot information for a specific tenant.
9626
- * @returns WhatsappConfig
9627
- * @throws ApiError
9628
- */
9629
- static aiBotV1BotsBotWhatsappConfigUpdate({
9630
- id,
9631
- org,
9632
- requestBody
9633
- }) {
9634
- return request(OpenAPI, {
9635
- method: 'PUT',
9636
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/whatsapp-config/',
9637
- path: {
9638
- 'id': id,
9639
- 'org': org
9640
- },
9641
- body: requestBody,
9642
- mediaType: 'application/json'
9643
- });
9644
- }
9645
- /**
9646
- * Create modify and update bot information for a specific tenant.
9647
- * @returns WhatsappConfig
9648
- * @throws ApiError
9649
- */
9650
- static aiBotV1BotsBotWhatsappConfigPartialUpdate({
9651
- id,
9652
- org,
9653
- requestBody
9654
- }) {
9655
- return request(OpenAPI, {
9656
- method: 'PATCH',
9657
- url: '/api/ai-bot/v1/bots/{org}/bot/{id}/whatsapp-config/',
9658
- path: {
9659
- 'id': id,
9660
- 'org': org
9661
- },
9662
- body: requestBody,
9663
- mediaType: 'application/json'
9664
- });
9665
- }
9666
- /**
9667
- * Setup discord user id linkage with discord bots
9668
- * this will be used to authenticate the user when interracting with discord bots.
9669
- * the user id can be copied from the discord app after tapping on the user profile.
9670
- * @returns DiscordUserConfig
9671
- * @throws ApiError
9672
- */
9673
- static aiBotV1BotsDiscordUserConfigList({
9674
- org
9675
- }) {
9676
- return request(OpenAPI, {
9677
- method: 'GET',
9678
- url: '/api/ai-bot/v1/bots/{org}/discord-user-config/',
9679
- path: {
9680
- 'org': org
9681
- }
9682
- });
9683
- }
9684
- /**
9685
- * Setup discord user id linkage with discord bots
9686
- * this will be used to authenticate the user when interracting with discord bots.
9687
- * the user id can be copied from the discord app after tapping on the user profile.
9688
- * @returns DiscordUserConfig
9689
- * @throws ApiError
9690
- */
9691
- static aiBotV1BotsDiscordUserConfigCreate({
9692
- org,
9693
- requestBody
9694
- }) {
9695
- return request(OpenAPI, {
9696
- method: 'POST',
9697
- url: '/api/ai-bot/v1/bots/{org}/discord-user-config/',
9698
- path: {
9699
- 'org': org
9700
- },
9701
- body: requestBody,
9702
- mediaType: 'application/json'
9703
- });
9704
- }
9705
- /**
9706
- * Setup discord user id linkage with discord bots
9707
- * this will be used to authenticate the user when interracting with discord bots.
9708
- * the user id can be copied from the discord app after tapping on the user profile.
9709
- * @returns DiscordUserConfig
9710
- * @throws ApiError
9711
- */
9712
- static aiBotV1BotsDiscordUserConfigRetrieve({
9713
- id,
9714
- org
9715
- }) {
9716
- return request(OpenAPI, {
9717
- method: 'GET',
9718
- url: '/api/ai-bot/v1/bots/{org}/discord-user-config/{id}/',
9719
- path: {
9720
- 'id': id,
9721
- 'org': org
9722
- }
9723
- });
9724
- }
9725
- /**
9726
- * Setup discord user id linkage with discord bots
9727
- * this will be used to authenticate the user when interracting with discord bots.
9728
- * the user id can be copied from the discord app after tapping on the user profile.
9729
- * @returns DiscordUserConfig
9730
- * @throws ApiError
9731
- */
9732
- static aiBotV1BotsDiscordUserConfigUpdate({
9733
- id,
9734
- org,
9735
- requestBody
9736
- }) {
9737
- return request(OpenAPI, {
9738
- method: 'PUT',
9739
- url: '/api/ai-bot/v1/bots/{org}/discord-user-config/{id}/',
9740
- path: {
9741
- 'id': id,
9742
- 'org': org
9743
- },
9744
- body: requestBody,
9745
- mediaType: 'application/json'
9746
- });
9747
- }
9748
- /**
9749
- * Setup discord user id linkage with discord bots
9750
- * this will be used to authenticate the user when interracting with discord bots.
9751
- * the user id can be copied from the discord app after tapping on the user profile.
9752
- * @returns DiscordUserConfig
9753
- * @throws ApiError
9754
- */
9755
- static aiBotV1BotsDiscordUserConfigPartialUpdate({
9756
- id,
9757
- org,
9758
- requestBody
9759
- }) {
9760
- return request(OpenAPI, {
9761
- method: 'PATCH',
9762
- url: '/api/ai-bot/v1/bots/{org}/discord-user-config/{id}/',
9763
- path: {
9764
- 'id': id,
9765
- 'org': org
9766
- },
9767
- body: requestBody,
9768
- mediaType: 'application/json'
9769
- });
9770
- }
9771
- /**
9772
- * Setup discord user id linkage with discord bots
9773
- * this will be used to authenticate the user when interracting with discord bots.
9774
- * the user id can be copied from the discord app after tapping on the user profile.
9775
- * @returns void
9776
- * @throws ApiError
9777
- */
9778
- static aiBotV1BotsDiscordUserConfigDestroy({
9779
- id,
9780
- org
9781
- }) {
9782
- return request(OpenAPI, {
9783
- method: 'DELETE',
9784
- url: '/api/ai-bot/v1/bots/{org}/discord-user-config/{id}/',
9785
- path: {
9786
- 'id': id,
9787
- 'org': org
9788
- }
9789
- });
9790
- }
9791
- /**
9792
- * Setup slack username and domain linkage with slack bots
9793
- * this will be used to authenticate the user when interracting with slack bots.
9794
- * @returns SlackUserConfig
9795
- * @throws ApiError
9796
- */
9797
- static aiBotV1BotsSlackUserConfigList({
9798
- org
9799
- }) {
9800
- return request(OpenAPI, {
9801
- method: 'GET',
9802
- url: '/api/ai-bot/v1/bots/{org}/slack-user-config/',
9803
- path: {
9804
- 'org': org
9805
- }
9806
- });
9807
- }
9808
- /**
9809
- * Setup slack username and domain linkage with slack bots
9810
- * this will be used to authenticate the user when interracting with slack bots.
9811
- * @returns SlackUserConfig
9812
- * @throws ApiError
9813
- */
9814
- static aiBotV1BotsSlackUserConfigCreate({
9815
- org,
9816
- requestBody
9817
- }) {
9818
- return request(OpenAPI, {
9819
- method: 'POST',
9820
- url: '/api/ai-bot/v1/bots/{org}/slack-user-config/',
9821
- path: {
9822
- 'org': org
9823
- },
9824
- body: requestBody,
9825
- mediaType: 'application/json'
9826
- });
9827
- }
9828
- /**
9829
- * Setup slack username and domain linkage with slack bots
9830
- * this will be used to authenticate the user when interracting with slack bots.
9831
- * @returns SlackUserConfig
9832
- * @throws ApiError
9833
- */
9834
- static aiBotV1BotsSlackUserConfigRetrieve({
9835
- id,
9836
- org
9837
- }) {
9838
- return request(OpenAPI, {
9839
- method: 'GET',
9840
- url: '/api/ai-bot/v1/bots/{org}/slack-user-config/{id}/',
9841
- path: {
9842
- 'id': id,
9843
- 'org': org
9844
- }
9845
- });
9846
- }
9847
- /**
9848
- * Setup slack username and domain linkage with slack bots
9849
- * this will be used to authenticate the user when interracting with slack bots.
9850
- * @returns SlackUserConfig
9851
- * @throws ApiError
9852
- */
9853
- static aiBotV1BotsSlackUserConfigUpdate({
9854
- id,
9855
- org,
9856
- requestBody
9857
- }) {
9858
- return request(OpenAPI, {
9859
- method: 'PUT',
9860
- url: '/api/ai-bot/v1/bots/{org}/slack-user-config/{id}/',
9861
- path: {
9862
- 'id': id,
9863
- 'org': org
9864
- },
9865
- body: requestBody,
9866
- mediaType: 'application/json'
9867
- });
9868
- }
9869
- /**
9870
- * Setup slack username and domain linkage with slack bots
9871
- * this will be used to authenticate the user when interracting with slack bots.
9872
- * @returns SlackUserConfig
9873
- * @throws ApiError
9874
- */
9875
- static aiBotV1BotsSlackUserConfigPartialUpdate({
9876
- id,
9877
- org,
9878
- requestBody
9879
- }) {
9880
- return request(OpenAPI, {
9881
- method: 'PATCH',
9882
- url: '/api/ai-bot/v1/bots/{org}/slack-user-config/{id}/',
9883
- path: {
9884
- 'id': id,
9885
- 'org': org
9886
- },
9887
- body: requestBody,
9888
- mediaType: 'application/json'
9889
- });
9890
- }
9891
- /**
9892
- * Setup slack username and domain linkage with slack bots
9893
- * this will be used to authenticate the user when interracting with slack bots.
9894
- * @returns void
9895
- * @throws ApiError
9896
- */
9897
- static aiBotV1BotsSlackUserConfigDestroy({
9898
- id,
9899
- org
9900
- }) {
9901
- return request(OpenAPI, {
9902
- method: 'DELETE',
9903
- url: '/api/ai-bot/v1/bots/{org}/slack-user-config/{id}/',
9904
- path: {
9905
- 'id': id,
9906
- 'org': org
9907
- }
9908
- });
9909
- }
9910
- /**
9911
- * Setup phone number linkage with whatsapp bots
9912
- * This phone number will be used to authenticate and allow access to whatsapp bots.
9913
- * @returns WhatsappUserConfig
9914
- * @throws ApiError
9915
- */
9916
- static aiBotV1BotsWhatsappUserConfigList({
9917
- org
9918
- }) {
9919
- return request(OpenAPI, {
9920
- method: 'GET',
9921
- url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/',
9922
- path: {
9923
- 'org': org
9924
- }
9925
- });
9926
- }
9927
- /**
9928
- * Setup phone number linkage with whatsapp bots
9929
- * This phone number will be used to authenticate and allow access to whatsapp bots.
9930
- * @returns WhatsappUserConfig
9931
- * @throws ApiError
9932
- */
9933
- static aiBotV1BotsWhatsappUserConfigCreate({
9934
- org,
9935
- requestBody
9936
- }) {
9937
- return request(OpenAPI, {
9938
- method: 'POST',
9939
- url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/',
9940
- path: {
9941
- 'org': org
9942
- },
9943
- body: requestBody,
9944
- mediaType: 'application/json'
9945
- });
9946
- }
9947
- /**
9948
- * Setup phone number linkage with whatsapp bots
9949
- * This phone number will be used to authenticate and allow access to whatsapp bots.
9950
- * @returns WhatsappUserConfig
9951
- * @throws ApiError
9952
- */
9953
- static aiBotV1BotsWhatsappUserConfigRetrieve({
9954
- id,
9955
- org
9956
- }) {
9957
- return request(OpenAPI, {
9958
- method: 'GET',
9959
- url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/{id}/',
9960
- path: {
9961
- 'id': id,
9962
- 'org': org
9963
- }
9964
- });
9965
- }
9966
- /**
9967
- * Setup phone number linkage with whatsapp bots
9968
- * This phone number will be used to authenticate and allow access to whatsapp bots.
9969
- * @returns WhatsappUserConfig
9970
- * @throws ApiError
9971
- */
9972
- static aiBotV1BotsWhatsappUserConfigUpdate({
9973
- id,
9974
- org,
9975
- requestBody
9976
- }) {
9977
- return request(OpenAPI, {
9978
- method: 'PUT',
9979
- url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/{id}/',
9980
- path: {
9981
- 'id': id,
9982
- 'org': org
9983
- },
9984
- body: requestBody,
9985
- mediaType: 'application/json'
9986
- });
9987
- }
9988
- /**
9989
- * Setup phone number linkage with whatsapp bots
9990
- * This phone number will be used to authenticate and allow access to whatsapp bots.
9991
- * @returns WhatsappUserConfig
9992
- * @throws ApiError
9993
- */
9994
- static aiBotV1BotsWhatsappUserConfigPartialUpdate({
9995
- id,
9996
- org,
9997
- requestBody
9998
- }) {
9999
- return request(OpenAPI, {
10000
- method: 'PATCH',
10001
- url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/{id}/',
10002
- path: {
10003
- 'id': id,
10004
- 'org': org
10005
- },
10006
- body: requestBody,
10007
- mediaType: 'application/json'
10008
- });
10009
- }
10010
- /**
10011
- * Setup phone number linkage with whatsapp bots
10012
- * This phone number will be used to authenticate and allow access to whatsapp bots.
10013
- * @returns void
10014
- * @throws ApiError
10015
- */
10016
- static aiBotV1BotsWhatsappUserConfigDestroy({
10017
- id,
10018
- org
10019
- }) {
10020
- return request(OpenAPI, {
10021
- method: 'DELETE',
10022
- url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/{id}/',
10023
- path: {
10024
- 'id': id,
10025
- 'org': org
10026
- }
10027
- });
10028
- }
10029
- /**
10030
- * Webhook endpoint to receive and process discord messages.
10031
- * @returns DiscordWebhook
10032
- * @throws ApiError
10033
- */
10034
- static aiBotV1BotsWebhooksDiscordCreate({
10035
- name,
10036
- org,
10037
- requestBody
10038
- }) {
10039
- return request(OpenAPI, {
10040
- method: 'POST',
10041
- url: '/api/ai-bot/v1/bots/webhooks/{org}/discord/{name}/',
10042
- path: {
10043
- 'name': name,
10044
- 'org': org
10045
- },
10046
- body: requestBody,
10047
- mediaType: 'application/json'
10048
- });
10049
- }
10050
- /**
10051
- * @returns SlackWebhook
10052
- * @throws ApiError
10053
- */
10054
- static aiBotV1BotsWebhooksSlackCreate({
10055
- name,
10056
- org,
10057
- requestBody
10058
- }) {
10059
- return request(OpenAPI, {
10060
- method: 'POST',
10061
- url: '/api/ai-bot/v1/bots/webhooks/{org}/slack/{name}/',
10062
- path: {
10063
- 'name': name,
10064
- 'org': org
10065
- },
10066
- body: requestBody,
10067
- mediaType: 'application/json'
10068
- });
10069
- }
10070
- /**
10071
- * @returns TeamsWebhook
10072
- * @throws ApiError
10073
- */
10074
- static aiBotV1BotsWebhooksTeamsCreate({
10075
- name,
10076
- org,
10077
- requestBody
10078
- }) {
10079
- return request(OpenAPI, {
10080
- method: 'POST',
10081
- url: '/api/ai-bot/v1/bots/webhooks/{org}/teams/{name}/',
10082
- path: {
10083
- 'name': name,
10084
- 'org': org
10085
- },
10086
- body: requestBody,
10087
- mediaType: 'application/json'
10088
- });
10089
- }
10090
- /**
10091
- * Webhook endpoint to receive and process discord messages.
10092
- * @returns WebexWebhook
10093
- * @throws ApiError
10094
- */
10095
- static aiBotV1BotsWebhooksWebexCreate({
10096
- name,
10097
- org,
10098
- requestBody
10099
- }) {
10100
- return request(OpenAPI, {
10101
- method: 'POST',
10102
- url: '/api/ai-bot/v1/bots/webhooks/{org}/webex/{name}/',
10103
- path: {
10104
- 'name': name,
10105
- 'org': org
10106
- },
10107
- body: requestBody,
10108
- mediaType: 'application/json'
10109
- });
10110
- }
10111
- /**
10112
- * Respond to whatsapp's webhook challenge.
10113
- * Parameters Required include the tenant key (org) and the name of the bot: (name)
10114
- * @returns WhatAppWebHook
10115
- * @throws ApiError
10116
- */
10117
- static aiBotV1BotsWebhooksWhatsappRetrieve({
10118
- name,
10119
- org
10120
- }) {
10121
- return request(OpenAPI, {
10122
- method: 'GET',
10123
- url: '/api/ai-bot/v1/bots/webhooks/{org}/whatsapp/{name}/',
10124
- path: {
10125
- 'name': name,
10126
- 'org': org
10127
- }
10128
- });
10129
- }
10130
- /**
10131
- * Accept and process webhook events from whatsapp.
10132
- * @returns WhatAppWebHook
10133
- * @throws ApiError
10134
- */
10135
- static aiBotV1BotsWebhooksWhatsappCreate({
10136
- name,
10137
- org,
10138
- requestBody
10139
- }) {
10140
- return request(OpenAPI, {
10141
- method: 'POST',
10142
- url: '/api/ai-bot/v1/bots/webhooks/{org}/whatsapp/{name}/',
10143
- path: {
10144
- 'name': name,
10145
- 'org': org
10146
- },
10147
- body: requestBody,
10148
- mediaType: 'application/json'
10149
- });
10150
- }
10151
- }
10152
-
10153
- class AiFinetuningService {
10154
- /**
10155
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10156
- * @returns PaginatedDataSetList
10157
- * @throws ApiError
10158
- */
10159
- static aiFinetuningV1OrgUserDatasetsList({
10160
- org,
10161
- username,
10162
- dateCreated,
10163
- numDataPoints,
10164
- ordering,
10165
- page,
10166
- pageSize,
10167
- retryAttempts,
10168
- search,
10169
- status
10170
- }) {
10171
- return request(OpenAPI, {
10172
- method: 'GET',
10173
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/',
10174
- path: {
10175
- 'org': org,
10176
- 'username': username
10177
- },
10178
- query: {
10179
- 'date_created': dateCreated,
10180
- 'num_data_points': numDataPoints,
10181
- 'ordering': ordering,
10182
- 'page': page,
10183
- 'page_size': pageSize,
10184
- 'retry_attempts': retryAttempts,
10185
- 'search': search,
10186
- 'status': status
10187
- }
10188
- });
10189
- }
10190
- /**
10191
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10192
- * @returns DataSetCreate
10193
- * @throws ApiError
10194
- */
10195
- static aiFinetuningV1OrgUserDatasetsCreate({
10196
- org,
10197
- username,
10198
- requestBody
10199
- }) {
10200
- return request(OpenAPI, {
10201
- method: 'POST',
10202
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/',
10203
- path: {
10204
- 'org': org,
10205
- 'username': username
10206
- },
10207
- body: requestBody,
10208
- mediaType: 'application/json'
10209
- });
10210
- }
10211
- /**
10212
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10213
- * @returns DataSet
10214
- * @throws ApiError
10215
- */
10216
- static aiFinetuningV1OrgUserDatasetsRetrieve({
10217
- id,
10218
- org,
10219
- username
10220
- }) {
10221
- return request(OpenAPI, {
10222
- method: 'GET',
10223
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/{id}/',
10224
- path: {
10225
- 'id': id,
10226
- 'org': org,
10227
- 'username': username
10228
- }
10229
- });
10230
- }
10231
- /**
10232
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10233
- * @returns DataSet
10234
- * @throws ApiError
10235
- */
10236
- static aiFinetuningV1OrgUserDatasetsUpdate({
10237
- id,
10238
- org,
10239
- username,
10240
- requestBody
10241
- }) {
10242
- return request(OpenAPI, {
10243
- method: 'PUT',
10244
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/{id}/',
10245
- path: {
10246
- 'id': id,
10247
- 'org': org,
10248
- 'username': username
10249
- },
10250
- body: requestBody,
10251
- mediaType: 'application/json'
10252
- });
10253
- }
10254
- /**
10255
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10256
- * @returns DataSet
10257
- * @throws ApiError
10258
- */
10259
- static aiFinetuningV1OrgUserDatasetsPartialUpdate({
10260
- id,
10261
- org,
10262
- username,
10263
- requestBody
10264
- }) {
10265
- return request(OpenAPI, {
10266
- method: 'PATCH',
10267
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/{id}/',
10268
- path: {
10269
- 'id': id,
10270
- 'org': org,
10271
- 'username': username
10272
- },
10273
- body: requestBody,
10274
- mediaType: 'application/json'
10275
- });
10276
- }
10277
- /**
10278
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10279
- * @returns void
10280
- * @throws ApiError
10281
- */
10282
- static aiFinetuningV1OrgUserDatasetsDestroy({
10283
- id,
10284
- org,
10285
- username
10286
- }) {
10287
- return request(OpenAPI, {
10288
- method: 'DELETE',
10289
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/{id}/',
10290
- path: {
10291
- 'id': id,
10292
- 'org': org,
10293
- 'username': username
10294
- }
10295
- });
10296
- }
10297
- /**
10298
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10299
- * @returns PaginatedTrainingList
10300
- * @throws ApiError
10301
- */
10302
- static aiFinetuningV1OrgUserTrainingsList({
10303
- org,
10304
- username,
10305
- baseModelName,
10306
- dataset,
10307
- dateCreated,
10308
- fineTunedModel,
10309
- lastModified,
10310
- ordering,
10311
- page,
10312
- pageSize,
10313
- preprocessDataset,
10314
- provider,
10315
- search,
10316
- status
10317
- }) {
10318
- return request(OpenAPI, {
10319
- method: 'GET',
10320
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/',
10321
- path: {
10322
- 'org': org,
10323
- 'username': username
10324
- },
10325
- query: {
10326
- 'base_model_name': baseModelName,
10327
- 'dataset': dataset,
10328
- 'date_created': dateCreated,
10329
- 'fine_tuned_model': fineTunedModel,
10330
- 'last_modified': lastModified,
10331
- 'ordering': ordering,
10332
- 'page': page,
10333
- 'page_size': pageSize,
10334
- 'preprocess_dataset': preprocessDataset,
10335
- 'provider': provider,
10336
- 'search': search,
10337
- 'status': status
10338
- }
10339
- });
10340
- }
10341
- /**
10342
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10343
- * @returns TrainingCreate
10344
- * @throws ApiError
10345
- */
10346
- static aiFinetuningV1OrgUserTrainingsCreate({
10347
- org,
10348
- username,
10349
- requestBody
10350
- }) {
10351
- return request(OpenAPI, {
10352
- method: 'POST',
10353
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/',
10354
- path: {
10355
- 'org': org,
10356
- 'username': username
10357
- },
10358
- body: requestBody,
10359
- mediaType: 'application/json'
10360
- });
10361
- }
10362
- /**
10363
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10364
- * @returns Training
10365
- * @throws ApiError
10366
- */
10367
- static aiFinetuningV1OrgUserTrainingsRetrieve({
10368
- id,
10369
- org,
10370
- username
10371
- }) {
10372
- return request(OpenAPI, {
10373
- method: 'GET',
10374
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/{id}/',
10375
- path: {
10376
- 'id': id,
10377
- 'org': org,
10378
- 'username': username
10379
- }
10380
- });
10381
- }
10382
- /**
10383
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10384
- * @returns TrainingCreate
10385
- * @throws ApiError
10386
- */
10387
- static aiFinetuningV1OrgUserTrainingsUpdate({
10388
- id,
10389
- org,
10390
- username,
10391
- requestBody
10392
- }) {
10393
- return request(OpenAPI, {
10394
- method: 'PUT',
10395
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/{id}/',
10396
- path: {
10397
- 'id': id,
10398
- 'org': org,
10399
- 'username': username
10400
- },
10401
- body: requestBody,
10402
- mediaType: 'application/json'
10403
- });
10404
- }
10405
- /**
10406
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10407
- * @returns TrainingCreate
10408
- * @throws ApiError
10409
- */
10410
- static aiFinetuningV1OrgUserTrainingsPartialUpdate({
10411
- id,
10412
- org,
10413
- username,
10414
- requestBody
10415
- }) {
10416
- return request(OpenAPI, {
10417
- method: 'PATCH',
10418
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/{id}/',
10419
- path: {
10420
- 'id': id,
10421
- 'org': org,
10422
- 'username': username
10423
- },
10424
- body: requestBody,
10425
- mediaType: 'application/json'
10426
- });
10427
- }
10428
- /**
10429
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10430
- * @returns void
10431
- * @throws ApiError
10432
- */
10433
- static aiFinetuningV1OrgUserTrainingsDestroy({
10434
- id,
10435
- org,
10436
- username
10437
- }) {
10438
- return request(OpenAPI, {
10439
- method: 'DELETE',
10440
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/{id}/',
10441
- path: {
10442
- 'id': id,
10443
- 'org': org,
10444
- 'username': username
10445
- }
10446
- });
10447
- }
10448
- /**
10449
- * Retrieves a paginated list of completed fine-tuned models, excluding those without a fine-tuned model.
10450
- * Filtering and pagination is allowed.
10451
- *
10452
- * NB: This is only a helper endpoint. The same functionality can be achieved with the appropriate filters using the
10453
- * training list endpoint.
10454
- * Returns:
10455
- * Response: A paginated response containing the serialized fine-tuned models.
10456
- * @returns Training
10457
- * @throws ApiError
10458
- */
10459
- static aiFinetuningV1OrgUserTrainingsFinetunedModelsRetrieve({
10460
- org,
10461
- username
10462
- }) {
10463
- return request(OpenAPI, {
10464
- method: 'GET',
10465
- url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/finetuned-models/',
10466
- path: {
10467
- 'org': org,
10468
- 'username': username
10469
- }
10470
- });
10471
- }
10472
- }
10473
-
10474
- class AiIndexService {
10475
- /**
10476
- * Retrieve details of a specific document embedding.
10477
- *
10478
- * This endpoint returns detailed information about a specific
10479
- * document embedding identified by its ID.
10480
- *
10481
- * Args:
10482
- * request: The HTTP request.
10483
- * org: Organization key identifier.
10484
- * document_id: The ID of the document embedding to retrieve.
10485
- *
10486
- * Returns:
10487
- * Response: Detailed information about the document embedding.
10488
- *
10489
- * Raises:
10490
- * NotFound: If the specified document embedding does not exist.
10491
- * @returns RetrieverDocumentEmbedding
10492
- * @throws ApiError
10493
- */
10494
- static aiIndexOrgsUsersDocumentsRetrieve({
10495
- documentId,
10496
- org,
10497
- userId
10498
- }) {
10499
- return request(OpenAPI, {
10500
- method: 'GET',
10501
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
10502
- path: {
10503
- 'document_id': documentId,
10504
- 'org': org,
10505
- 'user_id': userId
10506
- },
10507
- errors: {
10508
- 404: `Document not found`
10509
- }
10510
- });
10511
- }
10512
- /**
10513
- * Update a specific document embedding.
10514
- *
10515
- * This endpoint allows updating various properties of a document embedding,
10516
- * including its name, type, pathway, and training status.
10517
- *
10518
- * Args:
10519
- * request: The HTTP request containing the updated document data.
10520
- * org: Organization key identifier.
10521
- * document_id: The ID of the document embedding to update.
10522
- *
10523
- * Returns:
10524
- * Response: The updated document embedding information.
10525
- *
10526
- * Raises:
10527
- * BadRequest: If the provided data is invalid.
10528
- * NotFound: If the specified document embedding does not exist.
10529
- * @returns RetrieverDocumentEmbedding
10530
- * @throws ApiError
10531
- */
10532
- static aiIndexOrgsUsersDocumentsUpdate({
10533
- documentId,
10534
- org,
10535
- userId,
10536
- formData
10537
- }) {
10538
- return request(OpenAPI, {
10539
- method: 'PUT',
10540
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
10541
- path: {
10542
- 'document_id': documentId,
10543
- 'org': org,
10544
- 'user_id': userId
10545
- },
10546
- formData: formData,
10547
- mediaType: 'multipart/form-data',
10548
- errors: {
10549
- 400: `Invalid request data`,
10550
- 404: `Document not found`
10551
- }
10552
- });
10553
- }
10554
- /**
10555
- * Delete a specific document embedding.
10556
- *
10557
- * This endpoint removes a document embedding from the system,
10558
- * including untraining it from any associated pathways.
10559
- *
10560
- * Args:
10561
- * request: The HTTP request.
10562
- * org: Organization key identifier.
10563
- * document_id: The ID of the document embedding to delete.
10564
- *
10565
- * Returns:
10566
- * Response: An empty response with a 204 status code if successful.
10567
- *
10568
- * Raises:
10569
- * NotFound: If the specified document embedding does not exist.
10570
- * @returns void
10571
- * @throws ApiError
10572
- */
10573
- static aiIndexOrgsUsersDocumentsDestroy({
10574
- documentId,
10575
- org,
10576
- userId
10577
- }) {
10578
- return request(OpenAPI, {
10579
- method: 'DELETE',
10580
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
10581
- path: {
10582
- 'document_id': documentId,
10583
- 'org': org,
10584
- 'user_id': userId
10585
- },
10586
- errors: {
10587
- 404: `Document not found`
10588
- }
10589
- });
10590
- }
10591
- /**
10592
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10593
- * @returns DocumentSettingsResponse
10594
- * @throws ApiError
10595
- */
10596
- static aiIndexOrgsUsersDocumentsSettingsRetrieve({
10597
- documentId,
10598
- org,
10599
- userId
10600
- }) {
10601
- return request(OpenAPI, {
10602
- method: 'GET',
10603
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/settings/',
10604
- path: {
10605
- 'document_id': documentId,
10606
- 'org': org,
10607
- 'user_id': userId
10608
- }
10609
- });
10610
- }
10611
- /**
10612
- * Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
10613
- * @returns DocumentSettingsResponse
10614
- * @throws ApiError
10615
- */
10616
- static aiIndexOrgsUsersDocumentsSettingsCreate({
10617
- documentId,
10618
- org,
10619
- userId,
10620
- requestBody
10621
- }) {
10622
- return request(OpenAPI, {
10623
- method: 'POST',
10624
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/settings/',
10625
- path: {
10626
- 'document_id': documentId,
10627
- 'org': org,
10628
- 'user_id': userId
10629
- },
10630
- body: requestBody,
10631
- mediaType: 'application/json'
10632
- });
10633
- }
10634
- /**
10635
- * Train a graph-based document through a worker process.
10636
- *
10637
- * This endpoint queues graph-based documents for training through a
10638
- * specialized worker process that handles knowledge graph processing.
10639
- *
10640
- * Args:
10641
- * request: The HTTP request containing the document information.
10642
- * org: Organization key identifier.
10643
- *
10644
- * Returns:
10645
- * Response: A confirmation that the document was queued for training,
10646
- * including a task ID for tracking the progress.
10647
- *
10648
- * Raises:
10649
- * ValidationError: If the request data is invalid.
10650
- * BadRequest: If there was an error processing the document.
10651
- * @returns TrainDocumentViewResponse
10652
- * @throws ApiError
10653
- */
10654
- static aiIndexOrgsUsersDocumentsGraphTrainCreate({
10655
- org,
10656
- userId,
10657
- formData
10658
- }) {
10659
- return request(OpenAPI, {
10660
- method: 'POST',
10661
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/graph-train/',
10662
- path: {
10663
- 'org': org,
10664
- 'user_id': userId
10665
- },
10666
- formData: formData,
10667
- mediaType: 'multipart/form-data',
10668
- errors: {
10669
- 400: `Invalid request data or document processing error`
10670
- }
10671
- });
10672
- }
10673
- /**
10674
- * Description:
10675
- * Retrieves a list of document embeddings for a specific pathway with optional search and pagination.
10676
- *
10677
- * Methods:
10678
- * - GET: Retrieves document embeddings that match the specified search criteria and are paginated according to offset and limit.
10679
- *
10680
- * Parameters:
10681
- * - search (str): Search query to filter document names or URLs.
10682
- * - offset (int): Offset number for pagination.
10683
- * - limit (int): Limit number for pagination.
10684
- *
10685
- * Returns:
10686
- * - GET: A paginated list of document embeddings with their details.
10687
- * {
10688
- * "count": 10,
10689
- * "next": "http://api.example.com/retriever_documents/?offset=10&limit=2",
10690
- * "previous": "http://api.example.com/retriever_documents/?offset=0&limit=2",
10691
- * "results": [
10692
- * {
10693
- * "document_name": "Document2",
10694
- * "platform_key": "example_platform",
10695
- * "pathway": "example_pathway"
10696
- * }
10697
- * ]
10698
- * }
10699
- *
10700
- * Error Responses:
10701
- * - 400 Bad Request: Invalid query parameters.
10702
- * - 404 Not Found: No document embeddings found for the specified criteria.
10703
- * @returns PaginatedRetrieverDocumentEmbeddingList
10704
- * @throws ApiError
10705
- */
10706
- static aiIndexOrgsUsersDocumentsPathwaysList({
10707
- org,
10708
- pathway,
10709
- userId,
10710
- limit,
10711
- offset,
10712
- search
10713
- }) {
10714
- return request(OpenAPI, {
10715
- method: 'GET',
10716
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/pathways/{pathway}/',
10717
- path: {
10718
- 'org': org,
10719
- 'pathway': pathway,
10720
- 'user_id': userId
10721
- },
10722
- query: {
10723
- 'limit': limit,
10724
- 'offset': offset,
10725
- 'search': search
10726
- }
10727
- });
10728
- }
10729
- /**
10730
- * Retrieve resource documents similar to the given query.
10731
- *
10732
- * This endpoint performs a semantic search to find documents that are
10733
- * relevant to the provided query within the specified pathway.
10734
- *
10735
- * Args:
10736
- * request: The HTTP request containing the search query.
10737
- * org: Organization key identifier.
10738
- *
10739
- * Returns:
10740
- * Response: A list of documents relevant to the search query.
10741
- *
10742
- * Raises:
10743
- * ValidationError: If the request data is invalid.
10744
- * @returns RetrieverResponseSearch
10745
- * @throws ApiError
10746
- */
10747
- static aiIndexOrgsUsersDocumentsSearchCreate({
10748
- org,
10749
- userId,
10750
- requestBody
10751
- }) {
10752
- return request(OpenAPI, {
10753
- method: 'POST',
10754
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/search/',
10755
- path: {
10756
- 'org': org,
10757
- 'user_id': userId
10758
- },
10759
- body: requestBody,
10760
- mediaType: 'application/json',
10761
- errors: {
10762
- 400: `Invalid request data`
10763
- }
10764
- });
10765
- }
10766
- /**
10767
- * Retrieve document sources related to a given query.
10768
- *
10769
- * This endpoint performs a semantic search to find document sources
10770
- * that are relevant to the provided query within the specified pathway,
10771
- * and returns them along with confidence levels.
10772
- *
10773
- * Args:
10774
- * request: The HTTP request containing the search query.
10775
- * org: Organization key identifier.
10776
- *
10777
- * Returns:
10778
- * Response: A list of document sources with confidence levels.
10779
- *
10780
- * Raises:
10781
- * ValidationError: If the request data is invalid.
10782
- * @returns RetrieverRequestSearchDocument
10783
- * @throws ApiError
10784
- */
10785
- static aiIndexOrgsUsersDocumentsSourcesCreate({
10786
- org,
10787
- userId,
10788
- requestBody
10789
- }) {
10790
- return request(OpenAPI, {
10791
- method: 'POST',
10792
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/sources/',
10793
- path: {
10794
- 'org': org,
10795
- 'user_id': userId
10796
- },
10797
- body: requestBody,
10798
- mediaType: 'application/json',
10799
- errors: {
10800
- 400: `Invalid request data`
10801
- }
10802
- });
10803
- }
10804
- /**
10805
- * Check the status of a document training task.
10806
- *
10807
- * This endpoint retrieves the current status of an asynchronous
10808
- * document training task that was previously initiated.
10809
- *
10810
- * Args:
10811
- * request: The HTTP request.
10812
- * org: Organization key identifier.
10813
- * task_id: The ID of the training task to check.
10814
- *
10815
- * Returns:
10816
- * Response: The current status of the document training task,
10817
- * which can be "pending", "completed", or "failed".
10818
- * @returns CheckDocumentTrainingStatus
10819
- * @throws ApiError
10820
- */
10821
- static aiIndexOrgsUsersDocumentsTasksRetrieve({
10822
- org,
10823
- taskId,
10824
- userId
10825
- }) {
10826
- return request(OpenAPI, {
10827
- method: 'GET',
10828
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/tasks/{task_id}/',
10829
- path: {
10830
- 'org': org,
10831
- 'task_id': taskId,
10832
- 'user_id': userId
10833
- }
10834
- });
10835
- }
10836
- /**
10837
- * Train a document through a worker process.
10838
- *
10839
- * This endpoint queues larger documents for training through a worker
10840
- * process, which is more suitable for handling documents that would
10841
- * take too long to process directly.
10842
- *
10843
- * Args:
10844
- * request: The HTTP request containing the document information.
10845
- * org: Organization key identifier.
10846
- *
10847
- * Returns:
10848
- * Response: A confirmation that the document was queued for training,
10849
- * including a task ID for tracking the progress.
10850
- *
10851
- * Raises:
10852
- * ValidationError: If the request data is invalid.
10853
- * BadRequest: If there was an error processing the document.
10854
- * @returns TrainDocumentViewResponse
10855
- * @throws ApiError
10856
- */
10857
- static aiIndexOrgsUsersDocumentsTrainCreate({
10858
- org,
10859
- userId,
10860
- formData
10861
- }) {
10862
- return request(OpenAPI, {
10863
- method: 'POST',
10864
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/train/',
10865
- path: {
10866
- 'org': org,
10867
- 'user_id': userId
10868
- },
10869
- formData: formData,
10870
- mediaType: 'multipart/form-data',
10871
- errors: {
10872
- 400: `Invalid request data`
10873
- }
10874
- });
10875
- }
10876
- /**
10877
- * Train a document directly without using a worker.
10878
- *
10879
- * This endpoint is designed for training smaller documents directly
10880
- * without queuing them through a worker process. For larger documents,
10881
- * use the TrainDocumentView endpoint instead.
10882
- *
10883
- * Args:
10884
- * request: The HTTP request containing the document information.
10885
- * org: Organization key identifier.
10886
- *
10887
- * Returns:
10888
- * Response: A confirmation that the document was trained successfully.
10889
- *
10890
- * Raises:
10891
- * ValidationError: If the request data is invalid.
10892
- * BadRequest: If the document training failed.
10893
- * @returns RetreiverTrainViewResponse
10894
- * @throws ApiError
10895
- */
10896
- static aiIndexOrgsUsersDocumentsTrainRetrieverCreate({
10897
- org,
10898
- userId,
10899
- formData
10900
- }) {
10901
- return request(OpenAPI, {
10902
- method: 'POST',
10903
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/train/retriever/',
10904
- path: {
10905
- 'org': org,
10906
- 'user_id': userId
10907
- },
10908
- formData: formData,
10909
- mediaType: 'multipart/form-data',
10910
- errors: {
10911
- 400: `Invalid request data or training failed`
10912
- }
10913
- });
10914
- }
10915
- /**
10916
- * Description:
10917
- * Submit a document file in a chat session. Checks file type, size, and ensures the session exists, then processes the file.
10918
- * Process document for use in a specific chat session.
10919
- * which will be processed and made available for the AI to reference
10920
- * when responding to queries in that session.
10921
- *
10922
- * Methods:
10923
- * - POST: Submits a document or media file for training within a specified chat session.
10924
- *
10925
- * Parameters:
10926
- * - org (str):
10927
- * - session_id (str): UUID of the chat session for which the document is being submitted.
10928
- * - *args, **kwargs: Additional arguments.
10929
- * - file (file): Multipart file input.
10930
- *
10931
- * Returns:
10932
- * - POST: Returns a JSON message with the result of the upload process. Response code 200 on success.
10933
- * {
10934
- * "message": "File processed."
10935
- * }
10936
- *
10937
- * Error Responses:
10938
- * - 400 Bad Request:
10939
- * - "File field is required" if the 'file' parameter is missing.
10940
- * - "invalid file object" if the file object is not valid.
10941
- * - Specific error message if an exception occurs while saving to Redis.
10942
- * - 404 Not Found:
10943
- * - "Session not found" if the provided session_id does not match any existing session.
10944
- * - 413 Request Entity Too Large:
10945
- * - "file is too large" including specific limits for document and media files if the file exceeds size limits.
10946
- *
10947
- * Access Control:
10948
- * Requires authentication with a Bearer token in the Authorization header. The user associated with the session must exist and be authorized for the request.
10949
- * @returns TrainChatSessionDocumentView
10950
- * @throws ApiError
10951
- */
10952
- static aiIndexOrgsUsersDocumentsTrainSessionsCreate({
10953
- org,
10954
- sessionId,
10955
- userId,
10956
- formData
10957
- }) {
10958
- return request(OpenAPI, {
10959
- method: 'POST',
10960
- url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/train/sessions/{session_id}/',
10961
- path: {
10962
- 'org': org,
10963
- 'session_id': sessionId,
10964
- 'user_id': userId
10965
- },
10966
- formData: formData,
10967
- mediaType: 'multipart/form-data',
10968
- errors: {
10969
- 400: `Invalid file or processing error`,
10970
- 413: `File too large`
10971
- }
10972
- });
10973
- }
10974
- /**
10975
- * Retrieve detailed information about a specific scraped resource.
10976
- *
10977
- * This endpoint returns the complete scraped data for a specific resource
10978
- * identified by its ID.
10979
- *
10980
- * Args:
10981
- * request: The HTTP request.
10982
- * org: Organization key identifier.
10983
- * user_id: The username of the user associated with the resource.
10984
- * resource_id: The ID of the resource to retrieve.
10985
- *
10986
- * Returns:
10987
- * Response: The complete scraped data for the specified resource.
10988
- *
10989
- * Raises:
10990
- * NotFound: If the specified resource data does not exist.
10991
- * @returns ResourceScrappedData
10992
- * @throws ApiError
10993
- */
10994
- static aiIndexOrgsUsersResourceDataScrappedRetrieve({
10995
- org,
10996
- resourceId,
10997
- userId
9619
+ resourceId,
9620
+ userId
10998
9621
  }) {
10999
9622
  return request(OpenAPI, {
11000
9623
  method: 'GET',
@@ -11850,7 +10473,6 @@ class AiMentorService {
11850
10473
  }
11851
10474
  /**
11852
10475
  * Create a new mentor.
11853
- *
11854
10476
  * Body Parameters:
11855
10477
  * - name: Mentor name.
11856
10478
  * - unique_id: Unique identifier.
@@ -15451,29 +14073,6 @@ class AiMentorService {
15451
14073
  }
15452
14074
  });
15453
14075
  }
15454
- /**
15455
- * View to create a mentor from a template
15456
- *
15457
- * Accessible to only tenant admins.
15458
- * @returns Mentor
15459
- * @throws ApiError
15460
- */
15461
- static aiMentorOrgsUsersMentorFromTemplateCreate({
15462
- org,
15463
- userId,
15464
- requestBody
15465
- }) {
15466
- return request(OpenAPI, {
15467
- method: 'POST',
15468
- url: '/api/ai-mentor/orgs/{org}/users/{user_id}/mentor-from-template/',
15469
- path: {
15470
- 'org': org,
15471
- 'user_id': userId
15472
- },
15473
- body: requestBody,
15474
- mediaType: 'application/json'
15475
- });
15476
- }
15477
14076
  /**
15478
14077
  * Retrieve available LLMs for a user.
15479
14078
  * @returns LLMResponse
@@ -35024,5 +33623,5 @@ class SkillsService {
35024
33623
  }
35025
33624
  }
35026
33625
 
35027
- export { AcceptanceEnum, AccessEnum, AiAccountService, AiAnalyticsService, AiBotService, AiFinetuningService, AiIndexService, AiMarketingService, AiMediaService, AiMentorService, AiPromptService, AlignMentorBubbleEnum, ApiError, BlankEnum, CallConfigurationModeEnum, CancelError, CancelablePromise, CareerService, CatalogService, CeleryHeartbeatFailStatusEnum, CeleryHeartbeatStatusEnum, CommerceService, ComponentBlockTypeEnum, CoreService, CourseCreationTaskStatusEnum, CredentialsService, DataSetStatusEnum, FeaturesService, GooglePayAccountResponseStatusEnum, GreetingMethodEnum, InstitutionTypeEnum, ItemTypeEnum, KindEnum, LlmProviderEnum, MediaService, MediaTypeEnum, MentorVisibilityEnum, NotificationSourceTypeEnum, NotificationStatusEnum, NotificationsService, OpenAPI, PeriodicAgentLogStatusEnum, PlatformListStatusEnum, PreviousAgentStatusEnum, ProgramTypeEnum, PromptVisibilityEnum, Provider05cEnum, Provider637Enum, Provider63aEnum, RatingEnum, RecommendationsService, ReportsService, ResourceScrappedDataStatusEnum, ScimService, SearchService, SkillsService, StateEnum, Status6eeEnum, StepStatusEnum, StripeCheckoutSessionRequestModeEnum, SttProviderEnum, TargetSystemEnum, ThemeEnum, TrainingStatusEnum, TransportEnum, TtsProviderEnum, TypeC42Enum };
33626
+ export { AcceptanceEnum, AccessEnum, AiAccountService, AiAnalyticsService, AiIndexService, AiMarketingService, AiMediaService, AiMentorService, AiPromptService, AlignMentorBubbleEnum, ApiError, BlankEnum, CallConfigurationModeEnum, CancelError, CancelablePromise, CareerService, CatalogService, CeleryHeartbeatFailStatusEnum, CeleryHeartbeatStatusEnum, CommerceService, ComponentBlockTypeEnum, CoreService, CourseCreationTaskStatusEnum, CrawlerPatternTypeEnum, CredentialsService, FeaturesService, GooglePayAccountResponseStatusEnum, GreetingMethodEnum, InstitutionTypeEnum, ItemTypeEnum, KindEnum, LlmProviderEnum, MediaService, MediaTypeEnum, MentorVisibilityEnum, NotificationSourceTypeEnum, NotificationStatusEnum, NotificationsService, OpenAPI, PeriodicAgentLogStatusEnum, PlatformListStatusEnum, PreviousAgentStatusEnum, ProgramTypeEnum, PromptVisibilityEnum, ProviderEnum, RatingEnum, RecommendationsService, ReportsService, ResourceScrappedDataStatusEnum, ScimService, SearchService, SkillsService, StateEnum, Status6eeEnum, StepStatusEnum, StripeCheckoutSessionRequestModeEnum, SttProviderEnum, TargetSystemEnum, ThemeEnum, TrainingStatusEnum, TransportEnum, TtsProviderEnum, TypeC42Enum };
35028
33627
  //# sourceMappingURL=index.esm.js.map