@iblai/iblai-api 3.45.8-ai-plus → 3.45.9-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.
- package/dist/index.cjs.js +536 -1984
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +537 -1983
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +536 -1984
- package/dist/index.umd.js.map +1 -1
- package/dist/types/index.d.ts +11 -41
- package/dist/types/models/CatalogAutoIncrementResponse.d.ts +11 -11
- package/dist/types/models/CourseReviewPaginatedResponse.d.ts +18 -0
- package/dist/types/models/CourseReviewRequest.d.ts +37 -0
- package/dist/types/models/CourseReviewResponse.d.ts +40 -0
- package/dist/types/models/PaginatedSkill.d.ts +7 -0
- package/dist/types/models/ProgramEnrollmentSearchResponse.d.ts +22 -0
- package/dist/types/models/ProgramMetadataRequest.d.ts +29 -0
- package/dist/types/models/ProgramMetadataResponse.d.ts +29 -0
- package/dist/types/models/ProgramReview.d.ts +41 -0
- package/dist/types/models/ProgramReviewPaginatedResponse.d.ts +22 -0
- package/dist/types/models/ProgramReviewRequest.d.ts +37 -0
- package/dist/types/models/{VoiceProviderEnum.d.ts → ProviderEnum.d.ts} +1 -1
- package/dist/types/models/Voice.d.ts +2 -2
- package/dist/types/services/CatalogService.d.ts +168 -458
- package/package.json +1 -1
- package/src/core/OpenAPI.ts +1 -1
- package/src/index.ts +11 -41
- package/src/models/CatalogAutoIncrementResponse.ts +11 -11
- package/src/models/CourseReviewPaginatedResponse.ts +23 -0
- package/src/models/CourseReviewRequest.ts +42 -0
- package/src/models/CourseReviewResponse.ts +45 -0
- package/src/models/PaginatedSkill.ts +12 -0
- package/src/models/ProgramEnrollmentSearchResponse.ts +27 -0
- package/src/models/ProgramMetadataRequest.ts +34 -0
- package/src/models/ProgramMetadataResponse.ts +34 -0
- package/src/models/ProgramReview.ts +46 -0
- package/src/models/ProgramReviewPaginatedResponse.ts +27 -0
- package/src/models/ProgramReviewRequest.ts +42 -0
- package/src/models/{VoiceProviderEnum.ts → ProviderEnum.ts} +1 -1
- package/src/models/Voice.ts +2 -2
- package/src/services/CatalogService.ts +3415 -3417
- package/dist/types/models/Bot.d.ts +0 -15
- package/dist/types/models/BotCommand.d.ts +0 -6
- package/dist/types/models/BotCreate.d.ts +0 -12
- package/dist/types/models/CourseEligibilityCheckResponse.d.ts +0 -25
- package/dist/types/models/DataSet.d.ts +0 -21
- package/dist/types/models/DataSetCreate.d.ts +0 -12
- package/dist/types/models/DataSetStatusEnum.d.ts +0 -12
- package/dist/types/models/DiscordConfig.d.ts +0 -7
- package/dist/types/models/DiscordUserConfig.d.ts +0 -10
- package/dist/types/models/DiscordWebhook.d.ts +0 -6
- package/dist/types/models/PaginatedDataSetList.d.ts +0 -7
- package/dist/types/models/PaginatedTrainingList.d.ts +0 -7
- package/dist/types/models/PatchedBotCommand.d.ts +0 -6
- package/dist/types/models/PatchedBotCreate.d.ts +0 -12
- package/dist/types/models/PatchedDataSet.d.ts +0 -21
- package/dist/types/models/PatchedDiscordConfig.d.ts +0 -7
- package/dist/types/models/PatchedDiscordUserConfig.d.ts +0 -10
- package/dist/types/models/PatchedSlackConfig.d.ts +0 -8
- package/dist/types/models/PatchedSlackUserConfig.d.ts +0 -17
- package/dist/types/models/PatchedTeamsConfig.d.ts +0 -7
- package/dist/types/models/PatchedTrainingCreate.d.ts +0 -31
- package/dist/types/models/PatchedWebexConfig.d.ts +0 -10
- package/dist/types/models/PatchedWhatsappConfig.d.ts +0 -11
- package/dist/types/models/PatchedWhatsappUserConfig.d.ts +0 -10
- package/dist/types/models/Provider05cEnum.d.ts +0 -14
- package/dist/types/models/Provider63aEnum.d.ts +0 -6
- package/dist/types/models/SlackConfig.d.ts +0 -8
- package/dist/types/models/SlackUserConfig.d.ts +0 -17
- package/dist/types/models/SlackWebhook.d.ts +0 -6
- package/dist/types/models/TeamsConfig.d.ts +0 -7
- package/dist/types/models/TeamsWebhook.d.ts +0 -17
- package/dist/types/models/Training.d.ts +0 -41
- package/dist/types/models/TrainingCreate.d.ts +0 -31
- package/dist/types/models/WebexConfig.d.ts +0 -10
- package/dist/types/models/WebexWebhook.d.ts +0 -4
- package/dist/types/models/WhatAppWebHook.d.ts +0 -3
- package/dist/types/models/WhatsappConfig.d.ts +0 -11
- package/dist/types/models/WhatsappUserConfig.d.ts +0 -10
- package/dist/types/services/AiBotService.d.ts +0 -486
- package/dist/types/services/AiFinetuningService.d.ts +0 -162
- package/src/models/Bot.ts +0 -20
- package/src/models/BotCommand.ts +0 -11
- package/src/models/BotCreate.ts +0 -17
- package/src/models/CourseEligibilityCheckResponse.ts +0 -30
- package/src/models/DataSet.ts +0 -26
- package/src/models/DataSetCreate.ts +0 -17
- package/src/models/DataSetStatusEnum.ts +0 -16
- package/src/models/DiscordConfig.ts +0 -12
- package/src/models/DiscordUserConfig.ts +0 -15
- package/src/models/DiscordWebhook.ts +0 -11
- package/src/models/PaginatedDataSetList.ts +0 -12
- package/src/models/PaginatedTrainingList.ts +0 -12
- package/src/models/PatchedBotCommand.ts +0 -11
- package/src/models/PatchedBotCreate.ts +0 -17
- package/src/models/PatchedDataSet.ts +0 -26
- package/src/models/PatchedDiscordConfig.ts +0 -12
- package/src/models/PatchedDiscordUserConfig.ts +0 -15
- package/src/models/PatchedSlackConfig.ts +0 -13
- package/src/models/PatchedSlackUserConfig.ts +0 -22
- package/src/models/PatchedTeamsConfig.ts +0 -12
- package/src/models/PatchedTrainingCreate.ts +0 -36
- package/src/models/PatchedWebexConfig.ts +0 -15
- package/src/models/PatchedWhatsappConfig.ts +0 -16
- package/src/models/PatchedWhatsappUserConfig.ts +0 -15
- package/src/models/Provider05cEnum.ts +0 -18
- package/src/models/Provider63aEnum.ts +0 -10
- package/src/models/SlackConfig.ts +0 -13
- package/src/models/SlackUserConfig.ts +0 -22
- package/src/models/SlackWebhook.ts +0 -11
- package/src/models/TeamsConfig.ts +0 -12
- package/src/models/TeamsWebhook.ts +0 -22
- package/src/models/Training.ts +0 -46
- package/src/models/TrainingCreate.ts +0 -36
- package/src/models/WebexConfig.ts +0 -15
- package/src/models/WebexWebhook.ts +0 -9
- package/src/models/WhatAppWebHook.ts +0 -8
- package/src/models/WhatsappConfig.ts +0 -16
- package/src/models/WhatsappUserConfig.ts +0 -15
- package/src/services/AiBotService.ts +0 -1174
- package/src/services/AiFinetuningService.ts +0 -402
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.45.
|
|
111
|
+
VERSION: '3.45.9-ai',
|
|
112
112
|
WITH_CREDENTIALS: false,
|
|
113
113
|
CREDENTIALS: 'include',
|
|
114
114
|
TOKEN: undefined,
|
|
@@ -229,24 +229,6 @@ var CourseCreationTaskStatusEnum;
|
|
|
229
229
|
CourseCreationTaskStatusEnum["IN_PROGRESS"] = "In Progress";
|
|
230
230
|
})(CourseCreationTaskStatusEnum || (CourseCreationTaskStatusEnum = {}));
|
|
231
231
|
|
|
232
|
-
/* generated using openapi-typescript-codegen -- do not edit */
|
|
233
|
-
/* istanbul ignore file */
|
|
234
|
-
/* tslint:disable */
|
|
235
|
-
/* eslint-disable */
|
|
236
|
-
/**
|
|
237
|
-
* * `pending` - Pending
|
|
238
|
-
* * `processing` - Processing
|
|
239
|
-
* * `completed` - Completed
|
|
240
|
-
* * `failed` - Failed
|
|
241
|
-
*/
|
|
242
|
-
var DataSetStatusEnum;
|
|
243
|
-
(function (DataSetStatusEnum) {
|
|
244
|
-
DataSetStatusEnum["PENDING"] = "pending";
|
|
245
|
-
DataSetStatusEnum["PROCESSING"] = "processing";
|
|
246
|
-
DataSetStatusEnum["COMPLETED"] = "completed";
|
|
247
|
-
DataSetStatusEnum["FAILED"] = "failed";
|
|
248
|
-
})(DataSetStatusEnum || (DataSetStatusEnum = {}));
|
|
249
|
-
|
|
250
232
|
/* generated using openapi-typescript-codegen -- do not edit */
|
|
251
233
|
/* istanbul ignore file */
|
|
252
234
|
/* tslint:disable */
|
|
@@ -529,37 +511,21 @@ var PromptVisibilityEnum;
|
|
|
529
511
|
PromptVisibilityEnum["VIEWABLE_BY_ANYONE"] = "viewable_by_anyone";
|
|
530
512
|
})(PromptVisibilityEnum || (PromptVisibilityEnum = {}));
|
|
531
513
|
|
|
532
|
-
/* generated using openapi-typescript-codegen -- do not edit */
|
|
533
|
-
/* istanbul ignore file */
|
|
534
|
-
/* tslint:disable */
|
|
535
|
-
/* eslint-disable */
|
|
536
|
-
/**
|
|
537
|
-
* * `webex` - Webex
|
|
538
|
-
* * `slack` - Slack
|
|
539
|
-
* * `whatsapp` - Whatsapp
|
|
540
|
-
* * `discord` - Discord
|
|
541
|
-
* * `teams` - Teams
|
|
542
|
-
*/
|
|
543
|
-
var Provider05cEnum;
|
|
544
|
-
(function (Provider05cEnum) {
|
|
545
|
-
Provider05cEnum["WEBEX"] = "webex";
|
|
546
|
-
Provider05cEnum["SLACK"] = "slack";
|
|
547
|
-
Provider05cEnum["WHATSAPP"] = "whatsapp";
|
|
548
|
-
Provider05cEnum["DISCORD"] = "discord";
|
|
549
|
-
Provider05cEnum["TEAMS"] = "teams";
|
|
550
|
-
})(Provider05cEnum || (Provider05cEnum = {}));
|
|
551
|
-
|
|
552
514
|
/* generated using openapi-typescript-codegen -- do not edit */
|
|
553
515
|
/* istanbul ignore file */
|
|
554
516
|
/* tslint:disable */
|
|
555
517
|
/* eslint-disable */
|
|
556
518
|
/**
|
|
557
519
|
* * `openai` - Openai
|
|
520
|
+
* * `google` - Google
|
|
521
|
+
* * `elevenlabs` - Elevenlabs
|
|
558
522
|
*/
|
|
559
|
-
var
|
|
560
|
-
(function (
|
|
561
|
-
|
|
562
|
-
|
|
523
|
+
var ProviderEnum;
|
|
524
|
+
(function (ProviderEnum) {
|
|
525
|
+
ProviderEnum["OPENAI"] = "openai";
|
|
526
|
+
ProviderEnum["GOOGLE"] = "google";
|
|
527
|
+
ProviderEnum["ELEVENLABS"] = "elevenlabs";
|
|
528
|
+
})(ProviderEnum || (ProviderEnum = {}));
|
|
563
529
|
|
|
564
530
|
/* generated using openapi-typescript-codegen -- do not edit */
|
|
565
531
|
/* istanbul ignore file */
|
|
@@ -729,22 +695,6 @@ var TypeC42Enum;
|
|
|
729
695
|
TypeC42Enum["ASSESSMENT"] = "assessment";
|
|
730
696
|
})(TypeC42Enum || (TypeC42Enum = {}));
|
|
731
697
|
|
|
732
|
-
/* generated using openapi-typescript-codegen -- do not edit */
|
|
733
|
-
/* istanbul ignore file */
|
|
734
|
-
/* tslint:disable */
|
|
735
|
-
/* eslint-disable */
|
|
736
|
-
/**
|
|
737
|
-
* * `openai` - Openai
|
|
738
|
-
* * `google` - Google
|
|
739
|
-
* * `elevenlabs` - Elevenlabs
|
|
740
|
-
*/
|
|
741
|
-
var VoiceProviderEnum;
|
|
742
|
-
(function (VoiceProviderEnum) {
|
|
743
|
-
VoiceProviderEnum["OPENAI"] = "openai";
|
|
744
|
-
VoiceProviderEnum["GOOGLE"] = "google";
|
|
745
|
-
VoiceProviderEnum["ELEVENLABS"] = "elevenlabs";
|
|
746
|
-
})(VoiceProviderEnum || (VoiceProviderEnum = {}));
|
|
747
|
-
|
|
748
698
|
/* generated using openapi-typescript-codegen -- do not edit */
|
|
749
699
|
/* istanbul ignore file */
|
|
750
700
|
/* tslint:disable */
|
|
@@ -5788,1541 +5738,257 @@ class AiAnalyticsService {
|
|
|
5788
5738
|
}
|
|
5789
5739
|
}
|
|
5790
5740
|
|
|
5791
|
-
class
|
|
5741
|
+
class AiIndexService {
|
|
5792
5742
|
/**
|
|
5793
|
-
*
|
|
5743
|
+
* Retrieve details of a specific document embedding.
|
|
5744
|
+
*
|
|
5745
|
+
* This endpoint returns detailed information about a specific
|
|
5746
|
+
* document embedding identified by its ID.
|
|
5747
|
+
*
|
|
5748
|
+
* Args:
|
|
5749
|
+
* request: The HTTP request.
|
|
5750
|
+
* org: Organization key identifier.
|
|
5751
|
+
* document_id: The ID of the document embedding to retrieve.
|
|
5752
|
+
*
|
|
5753
|
+
* Returns:
|
|
5754
|
+
* Response: Detailed information about the document embedding.
|
|
5755
|
+
*
|
|
5756
|
+
* Raises:
|
|
5757
|
+
* NotFound: If the specified document embedding does not exist.
|
|
5758
|
+
* @param documentId
|
|
5794
5759
|
* @param org
|
|
5795
|
-
* @
|
|
5760
|
+
* @param userId
|
|
5761
|
+
* @returns RetrieverDocumentEmbedding
|
|
5796
5762
|
* @throws ApiError
|
|
5797
5763
|
*/
|
|
5798
|
-
static
|
|
5764
|
+
static aiIndexOrgsUsersDocumentsRetrieve(documentId, org, userId) {
|
|
5799
5765
|
return request(OpenAPI, {
|
|
5800
5766
|
method: 'GET',
|
|
5801
|
-
url: '/api/ai-
|
|
5767
|
+
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
|
|
5802
5768
|
path: {
|
|
5803
|
-
'
|
|
5769
|
+
'document_id': documentId,
|
|
5770
|
+
'org': org,
|
|
5771
|
+
'user_id': userId
|
|
5772
|
+
},
|
|
5773
|
+
errors: {
|
|
5774
|
+
404: `Document not found`
|
|
5804
5775
|
}
|
|
5805
5776
|
});
|
|
5806
5777
|
}
|
|
5807
5778
|
/**
|
|
5808
|
-
*
|
|
5779
|
+
* Update a specific document embedding.
|
|
5780
|
+
*
|
|
5781
|
+
* This endpoint allows updating various properties of a document embedding,
|
|
5782
|
+
* including its name, type, pathway, and training status.
|
|
5783
|
+
*
|
|
5784
|
+
* Args:
|
|
5785
|
+
* request: The HTTP request containing the updated document data.
|
|
5786
|
+
* org: Organization key identifier.
|
|
5787
|
+
* document_id: The ID of the document embedding to update.
|
|
5788
|
+
*
|
|
5789
|
+
* Returns:
|
|
5790
|
+
* Response: The updated document embedding information.
|
|
5791
|
+
*
|
|
5792
|
+
* Raises:
|
|
5793
|
+
* BadRequest: If the provided data is invalid.
|
|
5794
|
+
* NotFound: If the specified document embedding does not exist.
|
|
5795
|
+
* @param documentId
|
|
5809
5796
|
* @param org
|
|
5810
|
-
* @param
|
|
5811
|
-
* @
|
|
5797
|
+
* @param userId
|
|
5798
|
+
* @param formData
|
|
5799
|
+
* @returns RetrieverDocumentEmbedding
|
|
5812
5800
|
* @throws ApiError
|
|
5813
5801
|
*/
|
|
5814
|
-
static
|
|
5802
|
+
static aiIndexOrgsUsersDocumentsUpdate(documentId, org, userId, formData) {
|
|
5815
5803
|
return request(OpenAPI, {
|
|
5816
|
-
method: '
|
|
5817
|
-
url: '/api/ai-
|
|
5804
|
+
method: 'PUT',
|
|
5805
|
+
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
|
|
5818
5806
|
path: {
|
|
5819
|
-
'
|
|
5807
|
+
'document_id': documentId,
|
|
5808
|
+
'org': org,
|
|
5809
|
+
'user_id': userId
|
|
5820
5810
|
},
|
|
5821
|
-
|
|
5822
|
-
mediaType: '
|
|
5823
|
-
|
|
5824
|
-
|
|
5825
|
-
|
|
5826
|
-
* Create slash commands for a specific bot
|
|
5827
|
-
* eg. /iblai-baseline
|
|
5828
|
-
* @param org
|
|
5829
|
-
* @returns BotCommand
|
|
5830
|
-
* @throws ApiError
|
|
5831
|
-
*/
|
|
5832
|
-
static aiBotV1BotsBotCommandsList(org) {
|
|
5833
|
-
return request(OpenAPI, {
|
|
5834
|
-
method: 'GET',
|
|
5835
|
-
url: '/api/ai-bot/v1/bots/{org}/bot-commands/',
|
|
5836
|
-
path: {
|
|
5837
|
-
'org': org
|
|
5811
|
+
formData: formData,
|
|
5812
|
+
mediaType: 'multipart/form-data',
|
|
5813
|
+
errors: {
|
|
5814
|
+
400: `Invalid request data`,
|
|
5815
|
+
404: `Document not found`
|
|
5838
5816
|
}
|
|
5839
5817
|
});
|
|
5840
5818
|
}
|
|
5841
5819
|
/**
|
|
5842
|
-
*
|
|
5843
|
-
*
|
|
5820
|
+
* Delete a specific document embedding.
|
|
5821
|
+
*
|
|
5822
|
+
* This endpoint removes a document embedding from the system,
|
|
5823
|
+
* including untraining it from any associated pathways.
|
|
5824
|
+
*
|
|
5825
|
+
* Args:
|
|
5826
|
+
* request: The HTTP request.
|
|
5827
|
+
* org: Organization key identifier.
|
|
5828
|
+
* document_id: The ID of the document embedding to delete.
|
|
5829
|
+
*
|
|
5830
|
+
* Returns:
|
|
5831
|
+
* Response: An empty response with a 204 status code if successful.
|
|
5832
|
+
*
|
|
5833
|
+
* Raises:
|
|
5834
|
+
* NotFound: If the specified document embedding does not exist.
|
|
5835
|
+
* @param documentId
|
|
5844
5836
|
* @param org
|
|
5845
|
-
* @param
|
|
5846
|
-
* @returns
|
|
5837
|
+
* @param userId
|
|
5838
|
+
* @returns void
|
|
5847
5839
|
* @throws ApiError
|
|
5848
5840
|
*/
|
|
5849
|
-
static
|
|
5841
|
+
static aiIndexOrgsUsersDocumentsDestroy(documentId, org, userId) {
|
|
5850
5842
|
return request(OpenAPI, {
|
|
5851
|
-
method: '
|
|
5852
|
-
url: '/api/ai-
|
|
5843
|
+
method: 'DELETE',
|
|
5844
|
+
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
|
|
5853
5845
|
path: {
|
|
5854
|
-
'
|
|
5846
|
+
'document_id': documentId,
|
|
5847
|
+
'org': org,
|
|
5848
|
+
'user_id': userId
|
|
5855
5849
|
},
|
|
5856
|
-
|
|
5857
|
-
|
|
5850
|
+
errors: {
|
|
5851
|
+
404: `Document not found`
|
|
5852
|
+
}
|
|
5858
5853
|
});
|
|
5859
5854
|
}
|
|
5860
5855
|
/**
|
|
5861
|
-
*
|
|
5862
|
-
*
|
|
5863
|
-
* @param id A unique integer value identifying this bot command.
|
|
5856
|
+
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
5857
|
+
* @param documentId
|
|
5864
5858
|
* @param org
|
|
5865
|
-
* @
|
|
5859
|
+
* @param userId
|
|
5860
|
+
* @returns DocumentSettingsResponse
|
|
5866
5861
|
* @throws ApiError
|
|
5867
5862
|
*/
|
|
5868
|
-
static
|
|
5863
|
+
static aiIndexOrgsUsersDocumentsSettingsRetrieve(documentId, org, userId) {
|
|
5869
5864
|
return request(OpenAPI, {
|
|
5870
5865
|
method: 'GET',
|
|
5871
|
-
url: '/api/ai-
|
|
5866
|
+
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/settings/',
|
|
5872
5867
|
path: {
|
|
5873
|
-
'
|
|
5874
|
-
'org': org
|
|
5868
|
+
'document_id': documentId,
|
|
5869
|
+
'org': org,
|
|
5870
|
+
'user_id': userId
|
|
5875
5871
|
}
|
|
5876
5872
|
});
|
|
5877
5873
|
}
|
|
5878
5874
|
/**
|
|
5879
|
-
*
|
|
5880
|
-
*
|
|
5881
|
-
* @param id A unique integer value identifying this bot command.
|
|
5875
|
+
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
5876
|
+
* @param documentId
|
|
5882
5877
|
* @param org
|
|
5878
|
+
* @param userId
|
|
5883
5879
|
* @param requestBody
|
|
5884
|
-
* @returns
|
|
5880
|
+
* @returns DocumentSettingsResponse
|
|
5885
5881
|
* @throws ApiError
|
|
5886
5882
|
*/
|
|
5887
|
-
static
|
|
5883
|
+
static aiIndexOrgsUsersDocumentsSettingsCreate(documentId, org, userId, requestBody) {
|
|
5888
5884
|
return request(OpenAPI, {
|
|
5889
|
-
method: '
|
|
5890
|
-
url: '/api/ai-
|
|
5885
|
+
method: 'POST',
|
|
5886
|
+
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/settings/',
|
|
5891
5887
|
path: {
|
|
5892
|
-
'
|
|
5893
|
-
'org': org
|
|
5888
|
+
'document_id': documentId,
|
|
5889
|
+
'org': org,
|
|
5890
|
+
'user_id': userId
|
|
5894
5891
|
},
|
|
5895
5892
|
body: requestBody,
|
|
5896
5893
|
mediaType: 'application/json'
|
|
5897
5894
|
});
|
|
5898
5895
|
}
|
|
5899
5896
|
/**
|
|
5900
|
-
*
|
|
5901
|
-
*
|
|
5902
|
-
*
|
|
5897
|
+
* Train a graph-based document through a worker process.
|
|
5898
|
+
*
|
|
5899
|
+
* This endpoint queues graph-based documents for training through a
|
|
5900
|
+
* specialized worker process that handles knowledge graph processing.
|
|
5901
|
+
*
|
|
5902
|
+
* Args:
|
|
5903
|
+
* request: The HTTP request containing the document information.
|
|
5904
|
+
* org: Organization key identifier.
|
|
5905
|
+
*
|
|
5906
|
+
* Returns:
|
|
5907
|
+
* Response: A confirmation that the document was queued for training,
|
|
5908
|
+
* including a task ID for tracking the progress.
|
|
5909
|
+
*
|
|
5910
|
+
* Raises:
|
|
5911
|
+
* ValidationError: If the request data is invalid.
|
|
5912
|
+
* BadRequest: If there was an error processing the document.
|
|
5903
5913
|
* @param org
|
|
5904
|
-
* @param
|
|
5905
|
-
* @
|
|
5914
|
+
* @param userId
|
|
5915
|
+
* @param formData
|
|
5916
|
+
* @returns TrainDocumentViewResponse
|
|
5906
5917
|
* @throws ApiError
|
|
5907
5918
|
*/
|
|
5908
|
-
static
|
|
5919
|
+
static aiIndexOrgsUsersDocumentsGraphTrainCreate(org, userId, formData) {
|
|
5909
5920
|
return request(OpenAPI, {
|
|
5910
|
-
method: '
|
|
5911
|
-
url: '/api/ai-
|
|
5921
|
+
method: 'POST',
|
|
5922
|
+
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/graph-train/',
|
|
5912
5923
|
path: {
|
|
5913
|
-
'
|
|
5914
|
-
'
|
|
5924
|
+
'org': org,
|
|
5925
|
+
'user_id': userId
|
|
5915
5926
|
},
|
|
5916
|
-
|
|
5917
|
-
mediaType: '
|
|
5918
|
-
|
|
5919
|
-
|
|
5920
|
-
/**
|
|
5921
|
-
* Create slash commands for a specific bot
|
|
5922
|
-
* eg. /iblai-baseline
|
|
5923
|
-
* @param id A unique integer value identifying this bot command.
|
|
5924
|
-
* @param org
|
|
5925
|
-
* @returns void
|
|
5926
|
-
* @throws ApiError
|
|
5927
|
-
*/
|
|
5928
|
-
static aiBotV1BotsBotCommandsDestroy(id, org) {
|
|
5929
|
-
return request(OpenAPI, {
|
|
5930
|
-
method: 'DELETE',
|
|
5931
|
-
url: '/api/ai-bot/v1/bots/{org}/bot-commands/{id}/',
|
|
5932
|
-
path: {
|
|
5933
|
-
'id': id,
|
|
5934
|
-
'org': org
|
|
5927
|
+
formData: formData,
|
|
5928
|
+
mediaType: 'multipart/form-data',
|
|
5929
|
+
errors: {
|
|
5930
|
+
400: `Invalid request data or document processing error`
|
|
5935
5931
|
}
|
|
5936
5932
|
});
|
|
5937
5933
|
}
|
|
5938
5934
|
/**
|
|
5939
|
-
*
|
|
5940
|
-
*
|
|
5935
|
+
* Retrieve a list of document embeddings for a specific pathway.
|
|
5936
|
+
*
|
|
5937
|
+
* This endpoint returns a paginated list of all document embeddings
|
|
5938
|
+
* that have been created for the specified pathway within the organization.
|
|
5939
|
+
*
|
|
5940
|
+
* Args:
|
|
5941
|
+
* request: The HTTP request.
|
|
5942
|
+
* org: Organization key identifier.
|
|
5943
|
+
* pathway: The pathway to retrieve document embeddings for.
|
|
5944
|
+
*
|
|
5945
|
+
* Returns:
|
|
5946
|
+
* Response: A paginated list of document embeddings for the pathway.
|
|
5941
5947
|
* @param org
|
|
5942
|
-
* @
|
|
5948
|
+
* @param pathway
|
|
5949
|
+
* @param userId
|
|
5950
|
+
* @returns RetrieverDocumentEmbedding
|
|
5943
5951
|
* @throws ApiError
|
|
5944
5952
|
*/
|
|
5945
|
-
static
|
|
5953
|
+
static aiIndexOrgsUsersDocumentsPathwaysList(org, pathway, userId) {
|
|
5946
5954
|
return request(OpenAPI, {
|
|
5947
5955
|
method: 'GET',
|
|
5948
|
-
url: '/api/ai-
|
|
5956
|
+
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/pathways/{pathway}/',
|
|
5949
5957
|
path: {
|
|
5950
|
-
'
|
|
5951
|
-
'
|
|
5958
|
+
'org': org,
|
|
5959
|
+
'pathway': pathway,
|
|
5960
|
+
'user_id': userId
|
|
5952
5961
|
}
|
|
5953
5962
|
});
|
|
5954
5963
|
}
|
|
5955
5964
|
/**
|
|
5956
|
-
*
|
|
5957
|
-
*
|
|
5965
|
+
* Retrieve resource documents similar to the given query.
|
|
5966
|
+
*
|
|
5967
|
+
* This endpoint performs a semantic search to find documents that are
|
|
5968
|
+
* relevant to the provided query within the specified pathway.
|
|
5969
|
+
*
|
|
5970
|
+
* Args:
|
|
5971
|
+
* request: The HTTP request containing the search query.
|
|
5972
|
+
* org: Organization key identifier.
|
|
5973
|
+
*
|
|
5974
|
+
* Returns:
|
|
5975
|
+
* Response: A list of documents relevant to the search query.
|
|
5976
|
+
*
|
|
5977
|
+
* Raises:
|
|
5978
|
+
* ValidationError: If the request data is invalid.
|
|
5958
5979
|
* @param org
|
|
5980
|
+
* @param userId
|
|
5959
5981
|
* @param requestBody
|
|
5960
|
-
* @returns
|
|
5982
|
+
* @returns RetrieverResponseSearch
|
|
5961
5983
|
* @throws ApiError
|
|
5962
5984
|
*/
|
|
5963
|
-
static
|
|
5985
|
+
static aiIndexOrgsUsersDocumentsSearchCreate(org, userId, requestBody) {
|
|
5964
5986
|
return request(OpenAPI, {
|
|
5965
|
-
method: '
|
|
5966
|
-
url: '/api/ai-
|
|
5987
|
+
method: 'POST',
|
|
5988
|
+
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/search/',
|
|
5967
5989
|
path: {
|
|
5968
|
-
'
|
|
5969
|
-
'
|
|
5970
|
-
},
|
|
5971
|
-
body: requestBody,
|
|
5972
|
-
mediaType: 'application/json'
|
|
5973
|
-
});
|
|
5974
|
-
}
|
|
5975
|
-
/**
|
|
5976
|
-
* Create modify and update bot information for a specific tenant.
|
|
5977
|
-
* @param id A unique integer value identifying this bot.
|
|
5978
|
-
* @param org
|
|
5979
|
-
* @param requestBody
|
|
5980
|
-
* @returns BotCreate
|
|
5981
|
-
* @throws ApiError
|
|
5982
|
-
*/
|
|
5983
|
-
static aiBotV1BotsBotPartialUpdate(id, org, requestBody) {
|
|
5984
|
-
return request(OpenAPI, {
|
|
5985
|
-
method: 'PATCH',
|
|
5986
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/',
|
|
5987
|
-
path: {
|
|
5988
|
-
'id': id,
|
|
5989
|
-
'org': org
|
|
5990
|
-
},
|
|
5991
|
-
body: requestBody,
|
|
5992
|
-
mediaType: 'application/json'
|
|
5993
|
-
});
|
|
5994
|
-
}
|
|
5995
|
-
/**
|
|
5996
|
-
* Create modify and update bot information for a specific tenant.
|
|
5997
|
-
* @param id A unique integer value identifying this bot.
|
|
5998
|
-
* @param org
|
|
5999
|
-
* @returns void
|
|
6000
|
-
* @throws ApiError
|
|
6001
|
-
*/
|
|
6002
|
-
static aiBotV1BotsBotDestroy(id, org) {
|
|
6003
|
-
return request(OpenAPI, {
|
|
6004
|
-
method: 'DELETE',
|
|
6005
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/',
|
|
6006
|
-
path: {
|
|
6007
|
-
'id': id,
|
|
6008
|
-
'org': org
|
|
6009
|
-
}
|
|
6010
|
-
});
|
|
6011
|
-
}
|
|
6012
|
-
/**
|
|
6013
|
-
* Create modify and update bot information for a specific tenant.
|
|
6014
|
-
* @param id A unique integer value identifying this bot.
|
|
6015
|
-
* @param org
|
|
6016
|
-
* @returns DiscordConfig
|
|
6017
|
-
* @throws ApiError
|
|
6018
|
-
*/
|
|
6019
|
-
static aiBotV1BotsBotConfigDiscordRetrieve(id, org) {
|
|
6020
|
-
return request(OpenAPI, {
|
|
6021
|
-
method: 'GET',
|
|
6022
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/discord/',
|
|
6023
|
-
path: {
|
|
6024
|
-
'id': id,
|
|
6025
|
-
'org': org
|
|
6026
|
-
}
|
|
6027
|
-
});
|
|
6028
|
-
}
|
|
6029
|
-
/**
|
|
6030
|
-
* Create modify and update bot information for a specific tenant.
|
|
6031
|
-
* @param id A unique integer value identifying this bot.
|
|
6032
|
-
* @param org
|
|
6033
|
-
* @param requestBody
|
|
6034
|
-
* @returns DiscordConfig
|
|
6035
|
-
* @throws ApiError
|
|
6036
|
-
*/
|
|
6037
|
-
static aiBotV1BotsBotConfigDiscordPartialUpdate(id, org, requestBody) {
|
|
6038
|
-
return request(OpenAPI, {
|
|
6039
|
-
method: 'PATCH',
|
|
6040
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/discord/',
|
|
6041
|
-
path: {
|
|
6042
|
-
'id': id,
|
|
6043
|
-
'org': org
|
|
6044
|
-
},
|
|
6045
|
-
body: requestBody,
|
|
6046
|
-
mediaType: 'application/json'
|
|
6047
|
-
});
|
|
6048
|
-
}
|
|
6049
|
-
/**
|
|
6050
|
-
* Create modify and update bot information for a specific tenant.
|
|
6051
|
-
* @param id A unique integer value identifying this bot.
|
|
6052
|
-
* @param org
|
|
6053
|
-
* @returns SlackConfig
|
|
6054
|
-
* @throws ApiError
|
|
6055
|
-
*/
|
|
6056
|
-
static aiBotV1BotsBotConfigSlackRetrieve(id, org) {
|
|
6057
|
-
return request(OpenAPI, {
|
|
6058
|
-
method: 'GET',
|
|
6059
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/slack/',
|
|
6060
|
-
path: {
|
|
6061
|
-
'id': id,
|
|
6062
|
-
'org': org
|
|
6063
|
-
}
|
|
6064
|
-
});
|
|
6065
|
-
}
|
|
6066
|
-
/**
|
|
6067
|
-
* Create modify and update bot information for a specific tenant.
|
|
6068
|
-
* @param id A unique integer value identifying this bot.
|
|
6069
|
-
* @param org
|
|
6070
|
-
* @param requestBody
|
|
6071
|
-
* @returns SlackConfig
|
|
6072
|
-
* @throws ApiError
|
|
6073
|
-
*/
|
|
6074
|
-
static aiBotV1BotsBotConfigSlackUpdateCreate(id, org, requestBody) {
|
|
6075
|
-
return request(OpenAPI, {
|
|
6076
|
-
method: 'POST',
|
|
6077
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/slack/update/',
|
|
6078
|
-
path: {
|
|
6079
|
-
'id': id,
|
|
6080
|
-
'org': org
|
|
6081
|
-
},
|
|
6082
|
-
body: requestBody,
|
|
6083
|
-
mediaType: 'application/json'
|
|
6084
|
-
});
|
|
6085
|
-
}
|
|
6086
|
-
/**
|
|
6087
|
-
* Create modify and update bot information for a specific tenant.
|
|
6088
|
-
* @param id A unique integer value identifying this bot.
|
|
6089
|
-
* @param org
|
|
6090
|
-
* @param requestBody
|
|
6091
|
-
* @returns SlackConfig
|
|
6092
|
-
* @throws ApiError
|
|
6093
|
-
*/
|
|
6094
|
-
static aiBotV1BotsBotConfigSlackUpdateUpdate(id, org, requestBody) {
|
|
6095
|
-
return request(OpenAPI, {
|
|
6096
|
-
method: 'PUT',
|
|
6097
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/slack/update/',
|
|
6098
|
-
path: {
|
|
6099
|
-
'id': id,
|
|
6100
|
-
'org': org
|
|
6101
|
-
},
|
|
6102
|
-
body: requestBody,
|
|
6103
|
-
mediaType: 'application/json'
|
|
6104
|
-
});
|
|
6105
|
-
}
|
|
6106
|
-
/**
|
|
6107
|
-
* Create modify and update bot information for a specific tenant.
|
|
6108
|
-
* @param id A unique integer value identifying this bot.
|
|
6109
|
-
* @param org
|
|
6110
|
-
* @param requestBody
|
|
6111
|
-
* @returns SlackConfig
|
|
6112
|
-
* @throws ApiError
|
|
6113
|
-
*/
|
|
6114
|
-
static aiBotV1BotsBotConfigSlackUpdatePartialUpdate(id, org, requestBody) {
|
|
6115
|
-
return request(OpenAPI, {
|
|
6116
|
-
method: 'PATCH',
|
|
6117
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/slack/update/',
|
|
6118
|
-
path: {
|
|
6119
|
-
'id': id,
|
|
6120
|
-
'org': org
|
|
6121
|
-
},
|
|
6122
|
-
body: requestBody,
|
|
6123
|
-
mediaType: 'application/json'
|
|
6124
|
-
});
|
|
6125
|
-
}
|
|
6126
|
-
/**
|
|
6127
|
-
* Create modify and update bot information for a specific tenant.
|
|
6128
|
-
* @param id A unique integer value identifying this bot.
|
|
6129
|
-
* @param org
|
|
6130
|
-
* @returns TeamsConfig
|
|
6131
|
-
* @throws ApiError
|
|
6132
|
-
*/
|
|
6133
|
-
static aiBotV1BotsBotConfigTeamsRetrieve(id, org) {
|
|
6134
|
-
return request(OpenAPI, {
|
|
6135
|
-
method: 'GET',
|
|
6136
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/teams/',
|
|
6137
|
-
path: {
|
|
6138
|
-
'id': id,
|
|
6139
|
-
'org': org
|
|
6140
|
-
}
|
|
6141
|
-
});
|
|
6142
|
-
}
|
|
6143
|
-
/**
|
|
6144
|
-
* Create modify and update bot information for a specific tenant.
|
|
6145
|
-
* @param id A unique integer value identifying this bot.
|
|
6146
|
-
* @param org
|
|
6147
|
-
* @param requestBody
|
|
6148
|
-
* @returns TeamsConfig
|
|
6149
|
-
* @throws ApiError
|
|
6150
|
-
*/
|
|
6151
|
-
static aiBotV1BotsBotConfigTeamsUpdateCreate(id, org, requestBody) {
|
|
6152
|
-
return request(OpenAPI, {
|
|
6153
|
-
method: 'POST',
|
|
6154
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/teams/update/',
|
|
6155
|
-
path: {
|
|
6156
|
-
'id': id,
|
|
6157
|
-
'org': org
|
|
6158
|
-
},
|
|
6159
|
-
body: requestBody,
|
|
6160
|
-
mediaType: 'application/json'
|
|
6161
|
-
});
|
|
6162
|
-
}
|
|
6163
|
-
/**
|
|
6164
|
-
* Create modify and update bot information for a specific tenant.
|
|
6165
|
-
* @param id A unique integer value identifying this bot.
|
|
6166
|
-
* @param org
|
|
6167
|
-
* @param requestBody
|
|
6168
|
-
* @returns TeamsConfig
|
|
6169
|
-
* @throws ApiError
|
|
6170
|
-
*/
|
|
6171
|
-
static aiBotV1BotsBotConfigTeamsUpdateUpdate(id, org, requestBody) {
|
|
6172
|
-
return request(OpenAPI, {
|
|
6173
|
-
method: 'PUT',
|
|
6174
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/teams/update/',
|
|
6175
|
-
path: {
|
|
6176
|
-
'id': id,
|
|
6177
|
-
'org': org
|
|
6178
|
-
},
|
|
6179
|
-
body: requestBody,
|
|
6180
|
-
mediaType: 'application/json'
|
|
6181
|
-
});
|
|
6182
|
-
}
|
|
6183
|
-
/**
|
|
6184
|
-
* Create modify and update bot information for a specific tenant.
|
|
6185
|
-
* @param id A unique integer value identifying this bot.
|
|
6186
|
-
* @param org
|
|
6187
|
-
* @param requestBody
|
|
6188
|
-
* @returns TeamsConfig
|
|
6189
|
-
* @throws ApiError
|
|
6190
|
-
*/
|
|
6191
|
-
static aiBotV1BotsBotConfigTeamsUpdatePartialUpdate(id, org, requestBody) {
|
|
6192
|
-
return request(OpenAPI, {
|
|
6193
|
-
method: 'PATCH',
|
|
6194
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/teams/update/',
|
|
6195
|
-
path: {
|
|
6196
|
-
'id': id,
|
|
6197
|
-
'org': org
|
|
6198
|
-
},
|
|
6199
|
-
body: requestBody,
|
|
6200
|
-
mediaType: 'application/json'
|
|
6201
|
-
});
|
|
6202
|
-
}
|
|
6203
|
-
/**
|
|
6204
|
-
* Create modify and update bot information for a specific tenant.
|
|
6205
|
-
* @param id A unique integer value identifying this bot.
|
|
6206
|
-
* @param org
|
|
6207
|
-
* @returns WebexConfig
|
|
6208
|
-
* @throws ApiError
|
|
6209
|
-
*/
|
|
6210
|
-
static aiBotV1BotsBotConfigWebexRetrieve(id, org) {
|
|
6211
|
-
return request(OpenAPI, {
|
|
6212
|
-
method: 'GET',
|
|
6213
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/webex/',
|
|
6214
|
-
path: {
|
|
6215
|
-
'id': id,
|
|
6216
|
-
'org': org
|
|
6217
|
-
}
|
|
6218
|
-
});
|
|
6219
|
-
}
|
|
6220
|
-
/**
|
|
6221
|
-
* Create modify and update bot information for a specific tenant.
|
|
6222
|
-
* @param id A unique integer value identifying this bot.
|
|
6223
|
-
* @param org
|
|
6224
|
-
* @param requestBody
|
|
6225
|
-
* @returns WebexConfig
|
|
6226
|
-
* @throws ApiError
|
|
6227
|
-
*/
|
|
6228
|
-
static aiBotV1BotsBotConfigWebexPartialUpdate(id, org, requestBody) {
|
|
6229
|
-
return request(OpenAPI, {
|
|
6230
|
-
method: 'PATCH',
|
|
6231
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/webex/',
|
|
6232
|
-
path: {
|
|
6233
|
-
'id': id,
|
|
6234
|
-
'org': org
|
|
6235
|
-
},
|
|
6236
|
-
body: requestBody,
|
|
6237
|
-
mediaType: 'application/json'
|
|
6238
|
-
});
|
|
6239
|
-
}
|
|
6240
|
-
/**
|
|
6241
|
-
* Create modify and update bot information for a specific tenant.
|
|
6242
|
-
* @param id A unique integer value identifying this bot.
|
|
6243
|
-
* @param org
|
|
6244
|
-
* @returns WhatsappConfig
|
|
6245
|
-
* @throws ApiError
|
|
6246
|
-
*/
|
|
6247
|
-
static aiBotV1BotsBotConfigWhatsappRetrieve(id, org) {
|
|
6248
|
-
return request(OpenAPI, {
|
|
6249
|
-
method: 'GET',
|
|
6250
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/config/whatsapp/',
|
|
6251
|
-
path: {
|
|
6252
|
-
'id': id,
|
|
6253
|
-
'org': org
|
|
6254
|
-
}
|
|
6255
|
-
});
|
|
6256
|
-
}
|
|
6257
|
-
/**
|
|
6258
|
-
* Create modify and update bot information for a specific tenant.
|
|
6259
|
-
* @param id A unique integer value identifying this bot.
|
|
6260
|
-
* @param org
|
|
6261
|
-
* @param requestBody
|
|
6262
|
-
* @returns WhatsappConfig
|
|
6263
|
-
* @throws ApiError
|
|
6264
|
-
*/
|
|
6265
|
-
static aiBotV1BotsBotWhatsappConfigUpdate(id, org, requestBody) {
|
|
6266
|
-
return request(OpenAPI, {
|
|
6267
|
-
method: 'PUT',
|
|
6268
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/whatsapp-config/',
|
|
6269
|
-
path: {
|
|
6270
|
-
'id': id,
|
|
6271
|
-
'org': org
|
|
6272
|
-
},
|
|
6273
|
-
body: requestBody,
|
|
6274
|
-
mediaType: 'application/json'
|
|
6275
|
-
});
|
|
6276
|
-
}
|
|
6277
|
-
/**
|
|
6278
|
-
* Create modify and update bot information for a specific tenant.
|
|
6279
|
-
* @param id A unique integer value identifying this bot.
|
|
6280
|
-
* @param org
|
|
6281
|
-
* @param requestBody
|
|
6282
|
-
* @returns WhatsappConfig
|
|
6283
|
-
* @throws ApiError
|
|
6284
|
-
*/
|
|
6285
|
-
static aiBotV1BotsBotWhatsappConfigPartialUpdate(id, org, requestBody) {
|
|
6286
|
-
return request(OpenAPI, {
|
|
6287
|
-
method: 'PATCH',
|
|
6288
|
-
url: '/api/ai-bot/v1/bots/{org}/bot/{id}/whatsapp-config/',
|
|
6289
|
-
path: {
|
|
6290
|
-
'id': id,
|
|
6291
|
-
'org': org
|
|
6292
|
-
},
|
|
6293
|
-
body: requestBody,
|
|
6294
|
-
mediaType: 'application/json'
|
|
6295
|
-
});
|
|
6296
|
-
}
|
|
6297
|
-
/**
|
|
6298
|
-
* Setup discord user id linkage with discord bots
|
|
6299
|
-
* this will be used to authenticate the user when interracting with discord bots.
|
|
6300
|
-
* the user id can be copied from the discord app after tapping on the user profile.
|
|
6301
|
-
* @param org
|
|
6302
|
-
* @returns DiscordUserConfig
|
|
6303
|
-
* @throws ApiError
|
|
6304
|
-
*/
|
|
6305
|
-
static aiBotV1BotsDiscordUserConfigList(org) {
|
|
6306
|
-
return request(OpenAPI, {
|
|
6307
|
-
method: 'GET',
|
|
6308
|
-
url: '/api/ai-bot/v1/bots/{org}/discord-user-config/',
|
|
6309
|
-
path: {
|
|
6310
|
-
'org': org
|
|
6311
|
-
}
|
|
6312
|
-
});
|
|
6313
|
-
}
|
|
6314
|
-
/**
|
|
6315
|
-
* Setup discord user id linkage with discord bots
|
|
6316
|
-
* this will be used to authenticate the user when interracting with discord bots.
|
|
6317
|
-
* the user id can be copied from the discord app after tapping on the user profile.
|
|
6318
|
-
* @param org
|
|
6319
|
-
* @param requestBody
|
|
6320
|
-
* @returns DiscordUserConfig
|
|
6321
|
-
* @throws ApiError
|
|
6322
|
-
*/
|
|
6323
|
-
static aiBotV1BotsDiscordUserConfigCreate(org, requestBody) {
|
|
6324
|
-
return request(OpenAPI, {
|
|
6325
|
-
method: 'POST',
|
|
6326
|
-
url: '/api/ai-bot/v1/bots/{org}/discord-user-config/',
|
|
6327
|
-
path: {
|
|
6328
|
-
'org': org
|
|
6329
|
-
},
|
|
6330
|
-
body: requestBody,
|
|
6331
|
-
mediaType: 'application/json'
|
|
6332
|
-
});
|
|
6333
|
-
}
|
|
6334
|
-
/**
|
|
6335
|
-
* Setup discord user id linkage with discord bots
|
|
6336
|
-
* this will be used to authenticate the user when interracting with discord bots.
|
|
6337
|
-
* the user id can be copied from the discord app after tapping on the user profile.
|
|
6338
|
-
* @param id A unique integer value identifying this discord user config.
|
|
6339
|
-
* @param org
|
|
6340
|
-
* @returns DiscordUserConfig
|
|
6341
|
-
* @throws ApiError
|
|
6342
|
-
*/
|
|
6343
|
-
static aiBotV1BotsDiscordUserConfigRetrieve(id, org) {
|
|
6344
|
-
return request(OpenAPI, {
|
|
6345
|
-
method: 'GET',
|
|
6346
|
-
url: '/api/ai-bot/v1/bots/{org}/discord-user-config/{id}/',
|
|
6347
|
-
path: {
|
|
6348
|
-
'id': id,
|
|
6349
|
-
'org': org
|
|
6350
|
-
}
|
|
6351
|
-
});
|
|
6352
|
-
}
|
|
6353
|
-
/**
|
|
6354
|
-
* Setup discord user id linkage with discord bots
|
|
6355
|
-
* this will be used to authenticate the user when interracting with discord bots.
|
|
6356
|
-
* the user id can be copied from the discord app after tapping on the user profile.
|
|
6357
|
-
* @param id A unique integer value identifying this discord user config.
|
|
6358
|
-
* @param org
|
|
6359
|
-
* @param requestBody
|
|
6360
|
-
* @returns DiscordUserConfig
|
|
6361
|
-
* @throws ApiError
|
|
6362
|
-
*/
|
|
6363
|
-
static aiBotV1BotsDiscordUserConfigUpdate(id, org, requestBody) {
|
|
6364
|
-
return request(OpenAPI, {
|
|
6365
|
-
method: 'PUT',
|
|
6366
|
-
url: '/api/ai-bot/v1/bots/{org}/discord-user-config/{id}/',
|
|
6367
|
-
path: {
|
|
6368
|
-
'id': id,
|
|
6369
|
-
'org': org
|
|
6370
|
-
},
|
|
6371
|
-
body: requestBody,
|
|
6372
|
-
mediaType: 'application/json'
|
|
6373
|
-
});
|
|
6374
|
-
}
|
|
6375
|
-
/**
|
|
6376
|
-
* Setup discord user id linkage with discord bots
|
|
6377
|
-
* this will be used to authenticate the user when interracting with discord bots.
|
|
6378
|
-
* the user id can be copied from the discord app after tapping on the user profile.
|
|
6379
|
-
* @param id A unique integer value identifying this discord user config.
|
|
6380
|
-
* @param org
|
|
6381
|
-
* @param requestBody
|
|
6382
|
-
* @returns DiscordUserConfig
|
|
6383
|
-
* @throws ApiError
|
|
6384
|
-
*/
|
|
6385
|
-
static aiBotV1BotsDiscordUserConfigPartialUpdate(id, org, requestBody) {
|
|
6386
|
-
return request(OpenAPI, {
|
|
6387
|
-
method: 'PATCH',
|
|
6388
|
-
url: '/api/ai-bot/v1/bots/{org}/discord-user-config/{id}/',
|
|
6389
|
-
path: {
|
|
6390
|
-
'id': id,
|
|
6391
|
-
'org': org
|
|
6392
|
-
},
|
|
6393
|
-
body: requestBody,
|
|
6394
|
-
mediaType: 'application/json'
|
|
6395
|
-
});
|
|
6396
|
-
}
|
|
6397
|
-
/**
|
|
6398
|
-
* Setup discord user id linkage with discord bots
|
|
6399
|
-
* this will be used to authenticate the user when interracting with discord bots.
|
|
6400
|
-
* the user id can be copied from the discord app after tapping on the user profile.
|
|
6401
|
-
* @param id A unique integer value identifying this discord user config.
|
|
6402
|
-
* @param org
|
|
6403
|
-
* @returns void
|
|
6404
|
-
* @throws ApiError
|
|
6405
|
-
*/
|
|
6406
|
-
static aiBotV1BotsDiscordUserConfigDestroy(id, org) {
|
|
6407
|
-
return request(OpenAPI, {
|
|
6408
|
-
method: 'DELETE',
|
|
6409
|
-
url: '/api/ai-bot/v1/bots/{org}/discord-user-config/{id}/',
|
|
6410
|
-
path: {
|
|
6411
|
-
'id': id,
|
|
6412
|
-
'org': org
|
|
6413
|
-
}
|
|
6414
|
-
});
|
|
6415
|
-
}
|
|
6416
|
-
/**
|
|
6417
|
-
* Setup slack username and domain linkage with slack bots
|
|
6418
|
-
* this will be used to authenticate the user when interracting with slack bots.
|
|
6419
|
-
* @param org
|
|
6420
|
-
* @returns SlackUserConfig
|
|
6421
|
-
* @throws ApiError
|
|
6422
|
-
*/
|
|
6423
|
-
static aiBotV1BotsSlackUserConfigList(org) {
|
|
6424
|
-
return request(OpenAPI, {
|
|
6425
|
-
method: 'GET',
|
|
6426
|
-
url: '/api/ai-bot/v1/bots/{org}/slack-user-config/',
|
|
6427
|
-
path: {
|
|
6428
|
-
'org': org
|
|
6429
|
-
}
|
|
6430
|
-
});
|
|
6431
|
-
}
|
|
6432
|
-
/**
|
|
6433
|
-
* Setup slack username and domain linkage with slack bots
|
|
6434
|
-
* this will be used to authenticate the user when interracting with slack bots.
|
|
6435
|
-
* @param org
|
|
6436
|
-
* @param requestBody
|
|
6437
|
-
* @returns SlackUserConfig
|
|
6438
|
-
* @throws ApiError
|
|
6439
|
-
*/
|
|
6440
|
-
static aiBotV1BotsSlackUserConfigCreate(org, requestBody) {
|
|
6441
|
-
return request(OpenAPI, {
|
|
6442
|
-
method: 'POST',
|
|
6443
|
-
url: '/api/ai-bot/v1/bots/{org}/slack-user-config/',
|
|
6444
|
-
path: {
|
|
6445
|
-
'org': org
|
|
6446
|
-
},
|
|
6447
|
-
body: requestBody,
|
|
6448
|
-
mediaType: 'application/json'
|
|
6449
|
-
});
|
|
6450
|
-
}
|
|
6451
|
-
/**
|
|
6452
|
-
* Setup slack username and domain linkage with slack bots
|
|
6453
|
-
* this will be used to authenticate the user when interracting with slack bots.
|
|
6454
|
-
* @param id A unique integer value identifying this slack user config.
|
|
6455
|
-
* @param org
|
|
6456
|
-
* @returns SlackUserConfig
|
|
6457
|
-
* @throws ApiError
|
|
6458
|
-
*/
|
|
6459
|
-
static aiBotV1BotsSlackUserConfigRetrieve(id, org) {
|
|
6460
|
-
return request(OpenAPI, {
|
|
6461
|
-
method: 'GET',
|
|
6462
|
-
url: '/api/ai-bot/v1/bots/{org}/slack-user-config/{id}/',
|
|
6463
|
-
path: {
|
|
6464
|
-
'id': id,
|
|
6465
|
-
'org': org
|
|
6466
|
-
}
|
|
6467
|
-
});
|
|
6468
|
-
}
|
|
6469
|
-
/**
|
|
6470
|
-
* Setup slack username and domain linkage with slack bots
|
|
6471
|
-
* this will be used to authenticate the user when interracting with slack bots.
|
|
6472
|
-
* @param id A unique integer value identifying this slack user config.
|
|
6473
|
-
* @param org
|
|
6474
|
-
* @param requestBody
|
|
6475
|
-
* @returns SlackUserConfig
|
|
6476
|
-
* @throws ApiError
|
|
6477
|
-
*/
|
|
6478
|
-
static aiBotV1BotsSlackUserConfigUpdate(id, org, requestBody) {
|
|
6479
|
-
return request(OpenAPI, {
|
|
6480
|
-
method: 'PUT',
|
|
6481
|
-
url: '/api/ai-bot/v1/bots/{org}/slack-user-config/{id}/',
|
|
6482
|
-
path: {
|
|
6483
|
-
'id': id,
|
|
6484
|
-
'org': org
|
|
6485
|
-
},
|
|
6486
|
-
body: requestBody,
|
|
6487
|
-
mediaType: 'application/json'
|
|
6488
|
-
});
|
|
6489
|
-
}
|
|
6490
|
-
/**
|
|
6491
|
-
* Setup slack username and domain linkage with slack bots
|
|
6492
|
-
* this will be used to authenticate the user when interracting with slack bots.
|
|
6493
|
-
* @param id A unique integer value identifying this slack user config.
|
|
6494
|
-
* @param org
|
|
6495
|
-
* @param requestBody
|
|
6496
|
-
* @returns SlackUserConfig
|
|
6497
|
-
* @throws ApiError
|
|
6498
|
-
*/
|
|
6499
|
-
static aiBotV1BotsSlackUserConfigPartialUpdate(id, org, requestBody) {
|
|
6500
|
-
return request(OpenAPI, {
|
|
6501
|
-
method: 'PATCH',
|
|
6502
|
-
url: '/api/ai-bot/v1/bots/{org}/slack-user-config/{id}/',
|
|
6503
|
-
path: {
|
|
6504
|
-
'id': id,
|
|
6505
|
-
'org': org
|
|
6506
|
-
},
|
|
6507
|
-
body: requestBody,
|
|
6508
|
-
mediaType: 'application/json'
|
|
6509
|
-
});
|
|
6510
|
-
}
|
|
6511
|
-
/**
|
|
6512
|
-
* Setup slack username and domain linkage with slack bots
|
|
6513
|
-
* this will be used to authenticate the user when interracting with slack bots.
|
|
6514
|
-
* @param id A unique integer value identifying this slack user config.
|
|
6515
|
-
* @param org
|
|
6516
|
-
* @returns void
|
|
6517
|
-
* @throws ApiError
|
|
6518
|
-
*/
|
|
6519
|
-
static aiBotV1BotsSlackUserConfigDestroy(id, org) {
|
|
6520
|
-
return request(OpenAPI, {
|
|
6521
|
-
method: 'DELETE',
|
|
6522
|
-
url: '/api/ai-bot/v1/bots/{org}/slack-user-config/{id}/',
|
|
6523
|
-
path: {
|
|
6524
|
-
'id': id,
|
|
6525
|
-
'org': org
|
|
6526
|
-
}
|
|
6527
|
-
});
|
|
6528
|
-
}
|
|
6529
|
-
/**
|
|
6530
|
-
* Setup phone number linkage with whatsapp bots
|
|
6531
|
-
* This phone number will be used to authenticate and allow access to whatsapp bots.
|
|
6532
|
-
* @param org
|
|
6533
|
-
* @returns WhatsappUserConfig
|
|
6534
|
-
* @throws ApiError
|
|
6535
|
-
*/
|
|
6536
|
-
static aiBotV1BotsWhatsappUserConfigList(org) {
|
|
6537
|
-
return request(OpenAPI, {
|
|
6538
|
-
method: 'GET',
|
|
6539
|
-
url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/',
|
|
6540
|
-
path: {
|
|
6541
|
-
'org': org
|
|
6542
|
-
}
|
|
6543
|
-
});
|
|
6544
|
-
}
|
|
6545
|
-
/**
|
|
6546
|
-
* Setup phone number linkage with whatsapp bots
|
|
6547
|
-
* This phone number will be used to authenticate and allow access to whatsapp bots.
|
|
6548
|
-
* @param org
|
|
6549
|
-
* @param requestBody
|
|
6550
|
-
* @returns WhatsappUserConfig
|
|
6551
|
-
* @throws ApiError
|
|
6552
|
-
*/
|
|
6553
|
-
static aiBotV1BotsWhatsappUserConfigCreate(org, requestBody) {
|
|
6554
|
-
return request(OpenAPI, {
|
|
6555
|
-
method: 'POST',
|
|
6556
|
-
url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/',
|
|
6557
|
-
path: {
|
|
6558
|
-
'org': org
|
|
6559
|
-
},
|
|
6560
|
-
body: requestBody,
|
|
6561
|
-
mediaType: 'application/json'
|
|
6562
|
-
});
|
|
6563
|
-
}
|
|
6564
|
-
/**
|
|
6565
|
-
* Setup phone number linkage with whatsapp bots
|
|
6566
|
-
* This phone number will be used to authenticate and allow access to whatsapp bots.
|
|
6567
|
-
* @param id A unique integer value identifying this whatsapp user config.
|
|
6568
|
-
* @param org
|
|
6569
|
-
* @returns WhatsappUserConfig
|
|
6570
|
-
* @throws ApiError
|
|
6571
|
-
*/
|
|
6572
|
-
static aiBotV1BotsWhatsappUserConfigRetrieve(id, org) {
|
|
6573
|
-
return request(OpenAPI, {
|
|
6574
|
-
method: 'GET',
|
|
6575
|
-
url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/{id}/',
|
|
6576
|
-
path: {
|
|
6577
|
-
'id': id,
|
|
6578
|
-
'org': org
|
|
6579
|
-
}
|
|
6580
|
-
});
|
|
6581
|
-
}
|
|
6582
|
-
/**
|
|
6583
|
-
* Setup phone number linkage with whatsapp bots
|
|
6584
|
-
* This phone number will be used to authenticate and allow access to whatsapp bots.
|
|
6585
|
-
* @param id A unique integer value identifying this whatsapp user config.
|
|
6586
|
-
* @param org
|
|
6587
|
-
* @param requestBody
|
|
6588
|
-
* @returns WhatsappUserConfig
|
|
6589
|
-
* @throws ApiError
|
|
6590
|
-
*/
|
|
6591
|
-
static aiBotV1BotsWhatsappUserConfigUpdate(id, org, requestBody) {
|
|
6592
|
-
return request(OpenAPI, {
|
|
6593
|
-
method: 'PUT',
|
|
6594
|
-
url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/{id}/',
|
|
6595
|
-
path: {
|
|
6596
|
-
'id': id,
|
|
6597
|
-
'org': org
|
|
6598
|
-
},
|
|
6599
|
-
body: requestBody,
|
|
6600
|
-
mediaType: 'application/json'
|
|
6601
|
-
});
|
|
6602
|
-
}
|
|
6603
|
-
/**
|
|
6604
|
-
* Setup phone number linkage with whatsapp bots
|
|
6605
|
-
* This phone number will be used to authenticate and allow access to whatsapp bots.
|
|
6606
|
-
* @param id A unique integer value identifying this whatsapp user config.
|
|
6607
|
-
* @param org
|
|
6608
|
-
* @param requestBody
|
|
6609
|
-
* @returns WhatsappUserConfig
|
|
6610
|
-
* @throws ApiError
|
|
6611
|
-
*/
|
|
6612
|
-
static aiBotV1BotsWhatsappUserConfigPartialUpdate(id, org, requestBody) {
|
|
6613
|
-
return request(OpenAPI, {
|
|
6614
|
-
method: 'PATCH',
|
|
6615
|
-
url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/{id}/',
|
|
6616
|
-
path: {
|
|
6617
|
-
'id': id,
|
|
6618
|
-
'org': org
|
|
6619
|
-
},
|
|
6620
|
-
body: requestBody,
|
|
6621
|
-
mediaType: 'application/json'
|
|
6622
|
-
});
|
|
6623
|
-
}
|
|
6624
|
-
/**
|
|
6625
|
-
* Setup phone number linkage with whatsapp bots
|
|
6626
|
-
* This phone number will be used to authenticate and allow access to whatsapp bots.
|
|
6627
|
-
* @param id A unique integer value identifying this whatsapp user config.
|
|
6628
|
-
* @param org
|
|
6629
|
-
* @returns void
|
|
6630
|
-
* @throws ApiError
|
|
6631
|
-
*/
|
|
6632
|
-
static aiBotV1BotsWhatsappUserConfigDestroy(id, org) {
|
|
6633
|
-
return request(OpenAPI, {
|
|
6634
|
-
method: 'DELETE',
|
|
6635
|
-
url: '/api/ai-bot/v1/bots/{org}/whatsapp-user-config/{id}/',
|
|
6636
|
-
path: {
|
|
6637
|
-
'id': id,
|
|
6638
|
-
'org': org
|
|
6639
|
-
}
|
|
6640
|
-
});
|
|
6641
|
-
}
|
|
6642
|
-
/**
|
|
6643
|
-
* Webhook endpoint to receive and process discord messages.
|
|
6644
|
-
* @param name
|
|
6645
|
-
* @param org
|
|
6646
|
-
* @param requestBody
|
|
6647
|
-
* @returns DiscordWebhook
|
|
6648
|
-
* @throws ApiError
|
|
6649
|
-
*/
|
|
6650
|
-
static aiBotV1BotsWebhooksDiscordCreate(name, org, requestBody) {
|
|
6651
|
-
return request(OpenAPI, {
|
|
6652
|
-
method: 'POST',
|
|
6653
|
-
url: '/api/ai-bot/v1/bots/webhooks/{org}/discord/{name}/',
|
|
6654
|
-
path: {
|
|
6655
|
-
'name': name,
|
|
6656
|
-
'org': org
|
|
6657
|
-
},
|
|
6658
|
-
body: requestBody,
|
|
6659
|
-
mediaType: 'application/json'
|
|
6660
|
-
});
|
|
6661
|
-
}
|
|
6662
|
-
/**
|
|
6663
|
-
* @param name
|
|
6664
|
-
* @param org
|
|
6665
|
-
* @param requestBody
|
|
6666
|
-
* @returns SlackWebhook
|
|
6667
|
-
* @throws ApiError
|
|
6668
|
-
*/
|
|
6669
|
-
static aiBotV1BotsWebhooksSlackCreate(name, org, requestBody) {
|
|
6670
|
-
return request(OpenAPI, {
|
|
6671
|
-
method: 'POST',
|
|
6672
|
-
url: '/api/ai-bot/v1/bots/webhooks/{org}/slack/{name}/',
|
|
6673
|
-
path: {
|
|
6674
|
-
'name': name,
|
|
6675
|
-
'org': org
|
|
6676
|
-
},
|
|
6677
|
-
body: requestBody,
|
|
6678
|
-
mediaType: 'application/json'
|
|
6679
|
-
});
|
|
6680
|
-
}
|
|
6681
|
-
/**
|
|
6682
|
-
* @param name
|
|
6683
|
-
* @param org
|
|
6684
|
-
* @param requestBody
|
|
6685
|
-
* @returns TeamsWebhook
|
|
6686
|
-
* @throws ApiError
|
|
6687
|
-
*/
|
|
6688
|
-
static aiBotV1BotsWebhooksTeamsCreate(name, org, requestBody) {
|
|
6689
|
-
return request(OpenAPI, {
|
|
6690
|
-
method: 'POST',
|
|
6691
|
-
url: '/api/ai-bot/v1/bots/webhooks/{org}/teams/{name}/',
|
|
6692
|
-
path: {
|
|
6693
|
-
'name': name,
|
|
6694
|
-
'org': org
|
|
6695
|
-
},
|
|
6696
|
-
body: requestBody,
|
|
6697
|
-
mediaType: 'application/json'
|
|
6698
|
-
});
|
|
6699
|
-
}
|
|
6700
|
-
/**
|
|
6701
|
-
* Webhook endpoint to receive and process discord messages.
|
|
6702
|
-
* @param name
|
|
6703
|
-
* @param org
|
|
6704
|
-
* @param requestBody
|
|
6705
|
-
* @returns WebexWebhook
|
|
6706
|
-
* @throws ApiError
|
|
6707
|
-
*/
|
|
6708
|
-
static aiBotV1BotsWebhooksWebexCreate(name, org, requestBody) {
|
|
6709
|
-
return request(OpenAPI, {
|
|
6710
|
-
method: 'POST',
|
|
6711
|
-
url: '/api/ai-bot/v1/bots/webhooks/{org}/webex/{name}/',
|
|
6712
|
-
path: {
|
|
6713
|
-
'name': name,
|
|
6714
|
-
'org': org
|
|
6715
|
-
},
|
|
6716
|
-
body: requestBody,
|
|
6717
|
-
mediaType: 'application/json'
|
|
6718
|
-
});
|
|
6719
|
-
}
|
|
6720
|
-
/**
|
|
6721
|
-
* Respond to whatsapp's webhook challenge.
|
|
6722
|
-
* Parameters Required include the tenant key (org) and the name of the bot: (name)
|
|
6723
|
-
* @param name
|
|
6724
|
-
* @param org
|
|
6725
|
-
* @returns WhatAppWebHook
|
|
6726
|
-
* @throws ApiError
|
|
6727
|
-
*/
|
|
6728
|
-
static aiBotV1BotsWebhooksWhatsappRetrieve(name, org) {
|
|
6729
|
-
return request(OpenAPI, {
|
|
6730
|
-
method: 'GET',
|
|
6731
|
-
url: '/api/ai-bot/v1/bots/webhooks/{org}/whatsapp/{name}/',
|
|
6732
|
-
path: {
|
|
6733
|
-
'name': name,
|
|
6734
|
-
'org': org
|
|
6735
|
-
}
|
|
6736
|
-
});
|
|
6737
|
-
}
|
|
6738
|
-
/**
|
|
6739
|
-
* Accept and process webhook events from whatsapp.
|
|
6740
|
-
* @param name
|
|
6741
|
-
* @param org
|
|
6742
|
-
* @param requestBody
|
|
6743
|
-
* @returns WhatAppWebHook
|
|
6744
|
-
* @throws ApiError
|
|
6745
|
-
*/
|
|
6746
|
-
static aiBotV1BotsWebhooksWhatsappCreate(name, org, requestBody) {
|
|
6747
|
-
return request(OpenAPI, {
|
|
6748
|
-
method: 'POST',
|
|
6749
|
-
url: '/api/ai-bot/v1/bots/webhooks/{org}/whatsapp/{name}/',
|
|
6750
|
-
path: {
|
|
6751
|
-
'name': name,
|
|
6752
|
-
'org': org
|
|
6753
|
-
},
|
|
6754
|
-
body: requestBody,
|
|
6755
|
-
mediaType: 'application/json'
|
|
6756
|
-
});
|
|
6757
|
-
}
|
|
6758
|
-
}
|
|
6759
|
-
|
|
6760
|
-
class AiFinetuningService {
|
|
6761
|
-
/**
|
|
6762
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6763
|
-
* @param org
|
|
6764
|
-
* @param username
|
|
6765
|
-
* @param dateCreated
|
|
6766
|
-
* @param numDataPoints
|
|
6767
|
-
* @param ordering Which field to use when ordering the results.
|
|
6768
|
-
* @param page A page number within the paginated result set.
|
|
6769
|
-
* @param pageSize Number of results to return per page.
|
|
6770
|
-
* @param retryAttempts
|
|
6771
|
-
* @param search A search term.
|
|
6772
|
-
* @param status * `pending` - Pending
|
|
6773
|
-
* * `processing` - Processing
|
|
6774
|
-
* * `completed` - Completed
|
|
6775
|
-
* * `failed` - Failed
|
|
6776
|
-
* @returns PaginatedDataSetList
|
|
6777
|
-
* @throws ApiError
|
|
6778
|
-
*/
|
|
6779
|
-
static aiFinetuningV1OrgUserDatasetsList(org, username, dateCreated, numDataPoints, ordering, page, pageSize, retryAttempts, search, status) {
|
|
6780
|
-
return request(OpenAPI, {
|
|
6781
|
-
method: 'GET',
|
|
6782
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/',
|
|
6783
|
-
path: {
|
|
6784
|
-
'org': org,
|
|
6785
|
-
'username': username
|
|
6786
|
-
},
|
|
6787
|
-
query: {
|
|
6788
|
-
'date_created': dateCreated,
|
|
6789
|
-
'num_data_points': numDataPoints,
|
|
6790
|
-
'ordering': ordering,
|
|
6791
|
-
'page': page,
|
|
6792
|
-
'page_size': pageSize,
|
|
6793
|
-
'retry_attempts': retryAttempts,
|
|
6794
|
-
'search': search,
|
|
6795
|
-
'status': status
|
|
6796
|
-
}
|
|
6797
|
-
});
|
|
6798
|
-
}
|
|
6799
|
-
/**
|
|
6800
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6801
|
-
* @param org
|
|
6802
|
-
* @param username
|
|
6803
|
-
* @param requestBody
|
|
6804
|
-
* @returns DataSetCreate
|
|
6805
|
-
* @throws ApiError
|
|
6806
|
-
*/
|
|
6807
|
-
static aiFinetuningV1OrgUserDatasetsCreate(org, username, requestBody) {
|
|
6808
|
-
return request(OpenAPI, {
|
|
6809
|
-
method: 'POST',
|
|
6810
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/',
|
|
6811
|
-
path: {
|
|
6812
|
-
'org': org,
|
|
6813
|
-
'username': username
|
|
6814
|
-
},
|
|
6815
|
-
body: requestBody,
|
|
6816
|
-
mediaType: 'application/json'
|
|
6817
|
-
});
|
|
6818
|
-
}
|
|
6819
|
-
/**
|
|
6820
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6821
|
-
* @param id A UUID string identifying this data set.
|
|
6822
|
-
* @param org
|
|
6823
|
-
* @param username
|
|
6824
|
-
* @returns DataSet
|
|
6825
|
-
* @throws ApiError
|
|
6826
|
-
*/
|
|
6827
|
-
static aiFinetuningV1OrgUserDatasetsRetrieve(id, org, username) {
|
|
6828
|
-
return request(OpenAPI, {
|
|
6829
|
-
method: 'GET',
|
|
6830
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/{id}/',
|
|
6831
|
-
path: {
|
|
6832
|
-
'id': id,
|
|
6833
|
-
'org': org,
|
|
6834
|
-
'username': username
|
|
6835
|
-
}
|
|
6836
|
-
});
|
|
6837
|
-
}
|
|
6838
|
-
/**
|
|
6839
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6840
|
-
* @param id A UUID string identifying this data set.
|
|
6841
|
-
* @param org
|
|
6842
|
-
* @param username
|
|
6843
|
-
* @param requestBody
|
|
6844
|
-
* @returns DataSet
|
|
6845
|
-
* @throws ApiError
|
|
6846
|
-
*/
|
|
6847
|
-
static aiFinetuningV1OrgUserDatasetsUpdate(id, org, username, requestBody) {
|
|
6848
|
-
return request(OpenAPI, {
|
|
6849
|
-
method: 'PUT',
|
|
6850
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/{id}/',
|
|
6851
|
-
path: {
|
|
6852
|
-
'id': id,
|
|
6853
|
-
'org': org,
|
|
6854
|
-
'username': username
|
|
6855
|
-
},
|
|
6856
|
-
body: requestBody,
|
|
6857
|
-
mediaType: 'application/json'
|
|
6858
|
-
});
|
|
6859
|
-
}
|
|
6860
|
-
/**
|
|
6861
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6862
|
-
* @param id A UUID string identifying this data set.
|
|
6863
|
-
* @param org
|
|
6864
|
-
* @param username
|
|
6865
|
-
* @param requestBody
|
|
6866
|
-
* @returns DataSet
|
|
6867
|
-
* @throws ApiError
|
|
6868
|
-
*/
|
|
6869
|
-
static aiFinetuningV1OrgUserDatasetsPartialUpdate(id, org, username, requestBody) {
|
|
6870
|
-
return request(OpenAPI, {
|
|
6871
|
-
method: 'PATCH',
|
|
6872
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/{id}/',
|
|
6873
|
-
path: {
|
|
6874
|
-
'id': id,
|
|
6875
|
-
'org': org,
|
|
6876
|
-
'username': username
|
|
6877
|
-
},
|
|
6878
|
-
body: requestBody,
|
|
6879
|
-
mediaType: 'application/json'
|
|
6880
|
-
});
|
|
6881
|
-
}
|
|
6882
|
-
/**
|
|
6883
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6884
|
-
* @param id A UUID string identifying this data set.
|
|
6885
|
-
* @param org
|
|
6886
|
-
* @param username
|
|
6887
|
-
* @returns void
|
|
6888
|
-
* @throws ApiError
|
|
6889
|
-
*/
|
|
6890
|
-
static aiFinetuningV1OrgUserDatasetsDestroy(id, org, username) {
|
|
6891
|
-
return request(OpenAPI, {
|
|
6892
|
-
method: 'DELETE',
|
|
6893
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/datasets/{id}/',
|
|
6894
|
-
path: {
|
|
6895
|
-
'id': id,
|
|
6896
|
-
'org': org,
|
|
6897
|
-
'username': username
|
|
6898
|
-
}
|
|
6899
|
-
});
|
|
6900
|
-
}
|
|
6901
|
-
/**
|
|
6902
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6903
|
-
* @param org
|
|
6904
|
-
* @param username
|
|
6905
|
-
* @param baseModelName
|
|
6906
|
-
* @param dataset
|
|
6907
|
-
* @param dateCreated
|
|
6908
|
-
* @param fineTunedModel
|
|
6909
|
-
* @param lastModified
|
|
6910
|
-
* @param ordering Which field to use when ordering the results.
|
|
6911
|
-
* @param page A page number within the paginated result set.
|
|
6912
|
-
* @param pageSize Number of results to return per page.
|
|
6913
|
-
* @param preprocessDataset
|
|
6914
|
-
* @param provider * `openai` - Openai
|
|
6915
|
-
* @param search A search term.
|
|
6916
|
-
* @param status * `pending` - Pending
|
|
6917
|
-
* * `processing` - Processing
|
|
6918
|
-
* * `completed` - Completed
|
|
6919
|
-
* * `cancelled` - Cancelled
|
|
6920
|
-
* * `failed` - Failed
|
|
6921
|
-
* @returns PaginatedTrainingList
|
|
6922
|
-
* @throws ApiError
|
|
6923
|
-
*/
|
|
6924
|
-
static aiFinetuningV1OrgUserTrainingsList(org, username, baseModelName, dataset, dateCreated, fineTunedModel, lastModified, ordering, page, pageSize, preprocessDataset, provider, search, status) {
|
|
6925
|
-
return request(OpenAPI, {
|
|
6926
|
-
method: 'GET',
|
|
6927
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/',
|
|
6928
|
-
path: {
|
|
6929
|
-
'org': org,
|
|
6930
|
-
'username': username
|
|
6931
|
-
},
|
|
6932
|
-
query: {
|
|
6933
|
-
'base_model_name': baseModelName,
|
|
6934
|
-
'dataset': dataset,
|
|
6935
|
-
'date_created': dateCreated,
|
|
6936
|
-
'fine_tuned_model': fineTunedModel,
|
|
6937
|
-
'last_modified': lastModified,
|
|
6938
|
-
'ordering': ordering,
|
|
6939
|
-
'page': page,
|
|
6940
|
-
'page_size': pageSize,
|
|
6941
|
-
'preprocess_dataset': preprocessDataset,
|
|
6942
|
-
'provider': provider,
|
|
6943
|
-
'search': search,
|
|
6944
|
-
'status': status
|
|
6945
|
-
}
|
|
6946
|
-
});
|
|
6947
|
-
}
|
|
6948
|
-
/**
|
|
6949
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6950
|
-
* @param org
|
|
6951
|
-
* @param username
|
|
6952
|
-
* @param requestBody
|
|
6953
|
-
* @returns TrainingCreate
|
|
6954
|
-
* @throws ApiError
|
|
6955
|
-
*/
|
|
6956
|
-
static aiFinetuningV1OrgUserTrainingsCreate(org, username, requestBody) {
|
|
6957
|
-
return request(OpenAPI, {
|
|
6958
|
-
method: 'POST',
|
|
6959
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/',
|
|
6960
|
-
path: {
|
|
6961
|
-
'org': org,
|
|
6962
|
-
'username': username
|
|
6963
|
-
},
|
|
6964
|
-
body: requestBody,
|
|
6965
|
-
mediaType: 'application/json'
|
|
6966
|
-
});
|
|
6967
|
-
}
|
|
6968
|
-
/**
|
|
6969
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6970
|
-
* @param id A UUID string identifying this training.
|
|
6971
|
-
* @param org
|
|
6972
|
-
* @param username
|
|
6973
|
-
* @returns Training
|
|
6974
|
-
* @throws ApiError
|
|
6975
|
-
*/
|
|
6976
|
-
static aiFinetuningV1OrgUserTrainingsRetrieve(id, org, username) {
|
|
6977
|
-
return request(OpenAPI, {
|
|
6978
|
-
method: 'GET',
|
|
6979
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/{id}/',
|
|
6980
|
-
path: {
|
|
6981
|
-
'id': id,
|
|
6982
|
-
'org': org,
|
|
6983
|
-
'username': username
|
|
6984
|
-
}
|
|
6985
|
-
});
|
|
6986
|
-
}
|
|
6987
|
-
/**
|
|
6988
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
6989
|
-
* @param id A UUID string identifying this training.
|
|
6990
|
-
* @param org
|
|
6991
|
-
* @param username
|
|
6992
|
-
* @param requestBody
|
|
6993
|
-
* @returns TrainingCreate
|
|
6994
|
-
* @throws ApiError
|
|
6995
|
-
*/
|
|
6996
|
-
static aiFinetuningV1OrgUserTrainingsUpdate(id, org, username, requestBody) {
|
|
6997
|
-
return request(OpenAPI, {
|
|
6998
|
-
method: 'PUT',
|
|
6999
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/{id}/',
|
|
7000
|
-
path: {
|
|
7001
|
-
'id': id,
|
|
7002
|
-
'org': org,
|
|
7003
|
-
'username': username
|
|
7004
|
-
},
|
|
7005
|
-
body: requestBody,
|
|
7006
|
-
mediaType: 'application/json'
|
|
7007
|
-
});
|
|
7008
|
-
}
|
|
7009
|
-
/**
|
|
7010
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
7011
|
-
* @param id A UUID string identifying this training.
|
|
7012
|
-
* @param org
|
|
7013
|
-
* @param username
|
|
7014
|
-
* @param requestBody
|
|
7015
|
-
* @returns TrainingCreate
|
|
7016
|
-
* @throws ApiError
|
|
7017
|
-
*/
|
|
7018
|
-
static aiFinetuningV1OrgUserTrainingsPartialUpdate(id, org, username, requestBody) {
|
|
7019
|
-
return request(OpenAPI, {
|
|
7020
|
-
method: 'PATCH',
|
|
7021
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/{id}/',
|
|
7022
|
-
path: {
|
|
7023
|
-
'id': id,
|
|
7024
|
-
'org': org,
|
|
7025
|
-
'username': username
|
|
7026
|
-
},
|
|
7027
|
-
body: requestBody,
|
|
7028
|
-
mediaType: 'application/json'
|
|
7029
|
-
});
|
|
7030
|
-
}
|
|
7031
|
-
/**
|
|
7032
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
7033
|
-
* @param id A UUID string identifying this training.
|
|
7034
|
-
* @param org
|
|
7035
|
-
* @param username
|
|
7036
|
-
* @returns void
|
|
7037
|
-
* @throws ApiError
|
|
7038
|
-
*/
|
|
7039
|
-
static aiFinetuningV1OrgUserTrainingsDestroy(id, org, username) {
|
|
7040
|
-
return request(OpenAPI, {
|
|
7041
|
-
method: 'DELETE',
|
|
7042
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/{id}/',
|
|
7043
|
-
path: {
|
|
7044
|
-
'id': id,
|
|
7045
|
-
'org': org,
|
|
7046
|
-
'username': username
|
|
7047
|
-
}
|
|
7048
|
-
});
|
|
7049
|
-
}
|
|
7050
|
-
/**
|
|
7051
|
-
* Retrieves a paginated list of completed fine-tuned models, excluding those without a fine-tuned model.
|
|
7052
|
-
* Filtering and pagination is allowed.
|
|
7053
|
-
*
|
|
7054
|
-
* NB: This is only a helper endpoint. The same functionality can be achieved with the appropriate filters using the
|
|
7055
|
-
* training list endpoint.
|
|
7056
|
-
* Returns:
|
|
7057
|
-
* Response: A paginated response containing the serialized fine-tuned models.
|
|
7058
|
-
* @param org
|
|
7059
|
-
* @param username
|
|
7060
|
-
* @returns Training
|
|
7061
|
-
* @throws ApiError
|
|
7062
|
-
*/
|
|
7063
|
-
static aiFinetuningV1OrgUserTrainingsFinetunedModelsRetrieve(org, username) {
|
|
7064
|
-
return request(OpenAPI, {
|
|
7065
|
-
method: 'GET',
|
|
7066
|
-
url: '/api/ai-finetuning/v1/org/{org}/user/{username}/trainings/finetuned-models/',
|
|
7067
|
-
path: {
|
|
7068
|
-
'org': org,
|
|
7069
|
-
'username': username
|
|
7070
|
-
}
|
|
7071
|
-
});
|
|
7072
|
-
}
|
|
7073
|
-
}
|
|
7074
|
-
|
|
7075
|
-
class AiIndexService {
|
|
7076
|
-
/**
|
|
7077
|
-
* Retrieve details of a specific document embedding.
|
|
7078
|
-
*
|
|
7079
|
-
* This endpoint returns detailed information about a specific
|
|
7080
|
-
* document embedding identified by its ID.
|
|
7081
|
-
*
|
|
7082
|
-
* Args:
|
|
7083
|
-
* request: The HTTP request.
|
|
7084
|
-
* org: Organization key identifier.
|
|
7085
|
-
* document_id: The ID of the document embedding to retrieve.
|
|
7086
|
-
*
|
|
7087
|
-
* Returns:
|
|
7088
|
-
* Response: Detailed information about the document embedding.
|
|
7089
|
-
*
|
|
7090
|
-
* Raises:
|
|
7091
|
-
* NotFound: If the specified document embedding does not exist.
|
|
7092
|
-
* @param documentId
|
|
7093
|
-
* @param org
|
|
7094
|
-
* @param userId
|
|
7095
|
-
* @returns RetrieverDocumentEmbedding
|
|
7096
|
-
* @throws ApiError
|
|
7097
|
-
*/
|
|
7098
|
-
static aiIndexOrgsUsersDocumentsRetrieve(documentId, org, userId) {
|
|
7099
|
-
return request(OpenAPI, {
|
|
7100
|
-
method: 'GET',
|
|
7101
|
-
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
|
|
7102
|
-
path: {
|
|
7103
|
-
'document_id': documentId,
|
|
7104
|
-
'org': org,
|
|
7105
|
-
'user_id': userId
|
|
7106
|
-
},
|
|
7107
|
-
errors: {
|
|
7108
|
-
404: `Document not found`
|
|
7109
|
-
}
|
|
7110
|
-
});
|
|
7111
|
-
}
|
|
7112
|
-
/**
|
|
7113
|
-
* Update a specific document embedding.
|
|
7114
|
-
*
|
|
7115
|
-
* This endpoint allows updating various properties of a document embedding,
|
|
7116
|
-
* including its name, type, pathway, and training status.
|
|
7117
|
-
*
|
|
7118
|
-
* Args:
|
|
7119
|
-
* request: The HTTP request containing the updated document data.
|
|
7120
|
-
* org: Organization key identifier.
|
|
7121
|
-
* document_id: The ID of the document embedding to update.
|
|
7122
|
-
*
|
|
7123
|
-
* Returns:
|
|
7124
|
-
* Response: The updated document embedding information.
|
|
7125
|
-
*
|
|
7126
|
-
* Raises:
|
|
7127
|
-
* BadRequest: If the provided data is invalid.
|
|
7128
|
-
* NotFound: If the specified document embedding does not exist.
|
|
7129
|
-
* @param documentId
|
|
7130
|
-
* @param org
|
|
7131
|
-
* @param userId
|
|
7132
|
-
* @param formData
|
|
7133
|
-
* @returns RetrieverDocumentEmbedding
|
|
7134
|
-
* @throws ApiError
|
|
7135
|
-
*/
|
|
7136
|
-
static aiIndexOrgsUsersDocumentsUpdate(documentId, org, userId, formData) {
|
|
7137
|
-
return request(OpenAPI, {
|
|
7138
|
-
method: 'PUT',
|
|
7139
|
-
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
|
|
7140
|
-
path: {
|
|
7141
|
-
'document_id': documentId,
|
|
7142
|
-
'org': org,
|
|
7143
|
-
'user_id': userId
|
|
7144
|
-
},
|
|
7145
|
-
formData: formData,
|
|
7146
|
-
mediaType: 'multipart/form-data',
|
|
7147
|
-
errors: {
|
|
7148
|
-
400: `Invalid request data`,
|
|
7149
|
-
404: `Document not found`
|
|
7150
|
-
}
|
|
7151
|
-
});
|
|
7152
|
-
}
|
|
7153
|
-
/**
|
|
7154
|
-
* Delete a specific document embedding.
|
|
7155
|
-
*
|
|
7156
|
-
* This endpoint removes a document embedding from the system,
|
|
7157
|
-
* including untraining it from any associated pathways.
|
|
7158
|
-
*
|
|
7159
|
-
* Args:
|
|
7160
|
-
* request: The HTTP request.
|
|
7161
|
-
* org: Organization key identifier.
|
|
7162
|
-
* document_id: The ID of the document embedding to delete.
|
|
7163
|
-
*
|
|
7164
|
-
* Returns:
|
|
7165
|
-
* Response: An empty response with a 204 status code if successful.
|
|
7166
|
-
*
|
|
7167
|
-
* Raises:
|
|
7168
|
-
* NotFound: If the specified document embedding does not exist.
|
|
7169
|
-
* @param documentId
|
|
7170
|
-
* @param org
|
|
7171
|
-
* @param userId
|
|
7172
|
-
* @returns void
|
|
7173
|
-
* @throws ApiError
|
|
7174
|
-
*/
|
|
7175
|
-
static aiIndexOrgsUsersDocumentsDestroy(documentId, org, userId) {
|
|
7176
|
-
return request(OpenAPI, {
|
|
7177
|
-
method: 'DELETE',
|
|
7178
|
-
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/',
|
|
7179
|
-
path: {
|
|
7180
|
-
'document_id': documentId,
|
|
7181
|
-
'org': org,
|
|
7182
|
-
'user_id': userId
|
|
7183
|
-
},
|
|
7184
|
-
errors: {
|
|
7185
|
-
404: `Document not found`
|
|
7186
|
-
}
|
|
7187
|
-
});
|
|
7188
|
-
}
|
|
7189
|
-
/**
|
|
7190
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
7191
|
-
* @param documentId
|
|
7192
|
-
* @param org
|
|
7193
|
-
* @param userId
|
|
7194
|
-
* @returns DocumentSettingsResponse
|
|
7195
|
-
* @throws ApiError
|
|
7196
|
-
*/
|
|
7197
|
-
static aiIndexOrgsUsersDocumentsSettingsRetrieve(documentId, org, userId) {
|
|
7198
|
-
return request(OpenAPI, {
|
|
7199
|
-
method: 'GET',
|
|
7200
|
-
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/settings/',
|
|
7201
|
-
path: {
|
|
7202
|
-
'document_id': documentId,
|
|
7203
|
-
'org': org,
|
|
7204
|
-
'user_id': userId
|
|
7205
|
-
}
|
|
7206
|
-
});
|
|
7207
|
-
}
|
|
7208
|
-
/**
|
|
7209
|
-
* Mixin that includes the StudentTokenAuthentication and IsPlatformAdmin
|
|
7210
|
-
* @param documentId
|
|
7211
|
-
* @param org
|
|
7212
|
-
* @param userId
|
|
7213
|
-
* @param requestBody
|
|
7214
|
-
* @returns DocumentSettingsResponse
|
|
7215
|
-
* @throws ApiError
|
|
7216
|
-
*/
|
|
7217
|
-
static aiIndexOrgsUsersDocumentsSettingsCreate(documentId, org, userId, requestBody) {
|
|
7218
|
-
return request(OpenAPI, {
|
|
7219
|
-
method: 'POST',
|
|
7220
|
-
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/{document_id}/settings/',
|
|
7221
|
-
path: {
|
|
7222
|
-
'document_id': documentId,
|
|
7223
|
-
'org': org,
|
|
7224
|
-
'user_id': userId
|
|
7225
|
-
},
|
|
7226
|
-
body: requestBody,
|
|
7227
|
-
mediaType: 'application/json'
|
|
7228
|
-
});
|
|
7229
|
-
}
|
|
7230
|
-
/**
|
|
7231
|
-
* Train a graph-based document through a worker process.
|
|
7232
|
-
*
|
|
7233
|
-
* This endpoint queues graph-based documents for training through a
|
|
7234
|
-
* specialized worker process that handles knowledge graph processing.
|
|
7235
|
-
*
|
|
7236
|
-
* Args:
|
|
7237
|
-
* request: The HTTP request containing the document information.
|
|
7238
|
-
* org: Organization key identifier.
|
|
7239
|
-
*
|
|
7240
|
-
* Returns:
|
|
7241
|
-
* Response: A confirmation that the document was queued for training,
|
|
7242
|
-
* including a task ID for tracking the progress.
|
|
7243
|
-
*
|
|
7244
|
-
* Raises:
|
|
7245
|
-
* ValidationError: If the request data is invalid.
|
|
7246
|
-
* BadRequest: If there was an error processing the document.
|
|
7247
|
-
* @param org
|
|
7248
|
-
* @param userId
|
|
7249
|
-
* @param formData
|
|
7250
|
-
* @returns TrainDocumentViewResponse
|
|
7251
|
-
* @throws ApiError
|
|
7252
|
-
*/
|
|
7253
|
-
static aiIndexOrgsUsersDocumentsGraphTrainCreate(org, userId, formData) {
|
|
7254
|
-
return request(OpenAPI, {
|
|
7255
|
-
method: 'POST',
|
|
7256
|
-
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/graph-train/',
|
|
7257
|
-
path: {
|
|
7258
|
-
'org': org,
|
|
7259
|
-
'user_id': userId
|
|
7260
|
-
},
|
|
7261
|
-
formData: formData,
|
|
7262
|
-
mediaType: 'multipart/form-data',
|
|
7263
|
-
errors: {
|
|
7264
|
-
400: `Invalid request data or document processing error`
|
|
7265
|
-
}
|
|
7266
|
-
});
|
|
7267
|
-
}
|
|
7268
|
-
/**
|
|
7269
|
-
* Retrieve a list of document embeddings for a specific pathway.
|
|
7270
|
-
*
|
|
7271
|
-
* This endpoint returns a paginated list of all document embeddings
|
|
7272
|
-
* that have been created for the specified pathway within the organization.
|
|
7273
|
-
*
|
|
7274
|
-
* Args:
|
|
7275
|
-
* request: The HTTP request.
|
|
7276
|
-
* org: Organization key identifier.
|
|
7277
|
-
* pathway: The pathway to retrieve document embeddings for.
|
|
7278
|
-
*
|
|
7279
|
-
* Returns:
|
|
7280
|
-
* Response: A paginated list of document embeddings for the pathway.
|
|
7281
|
-
* @param org
|
|
7282
|
-
* @param pathway
|
|
7283
|
-
* @param userId
|
|
7284
|
-
* @returns RetrieverDocumentEmbedding
|
|
7285
|
-
* @throws ApiError
|
|
7286
|
-
*/
|
|
7287
|
-
static aiIndexOrgsUsersDocumentsPathwaysList(org, pathway, userId) {
|
|
7288
|
-
return request(OpenAPI, {
|
|
7289
|
-
method: 'GET',
|
|
7290
|
-
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/pathways/{pathway}/',
|
|
7291
|
-
path: {
|
|
7292
|
-
'org': org,
|
|
7293
|
-
'pathway': pathway,
|
|
7294
|
-
'user_id': userId
|
|
7295
|
-
}
|
|
7296
|
-
});
|
|
7297
|
-
}
|
|
7298
|
-
/**
|
|
7299
|
-
* Retrieve resource documents similar to the given query.
|
|
7300
|
-
*
|
|
7301
|
-
* This endpoint performs a semantic search to find documents that are
|
|
7302
|
-
* relevant to the provided query within the specified pathway.
|
|
7303
|
-
*
|
|
7304
|
-
* Args:
|
|
7305
|
-
* request: The HTTP request containing the search query.
|
|
7306
|
-
* org: Organization key identifier.
|
|
7307
|
-
*
|
|
7308
|
-
* Returns:
|
|
7309
|
-
* Response: A list of documents relevant to the search query.
|
|
7310
|
-
*
|
|
7311
|
-
* Raises:
|
|
7312
|
-
* ValidationError: If the request data is invalid.
|
|
7313
|
-
* @param org
|
|
7314
|
-
* @param userId
|
|
7315
|
-
* @param requestBody
|
|
7316
|
-
* @returns RetrieverResponseSearch
|
|
7317
|
-
* @throws ApiError
|
|
7318
|
-
*/
|
|
7319
|
-
static aiIndexOrgsUsersDocumentsSearchCreate(org, userId, requestBody) {
|
|
7320
|
-
return request(OpenAPI, {
|
|
7321
|
-
method: 'POST',
|
|
7322
|
-
url: '/api/ai-index/orgs/{org}/users/{user_id}/documents/search/',
|
|
7323
|
-
path: {
|
|
7324
|
-
'org': org,
|
|
7325
|
-
'user_id': userId
|
|
5990
|
+
'org': org,
|
|
5991
|
+
'user_id': userId
|
|
7326
5992
|
},
|
|
7327
5993
|
body: requestBody,
|
|
7328
5994
|
mediaType: 'application/json',
|
|
@@ -17549,7 +16215,7 @@ class CatalogService {
|
|
|
17549
16215
|
}
|
|
17550
16216
|
/**
|
|
17551
16217
|
* Remove a course from the database.
|
|
17552
|
-
* @param courseId
|
|
16218
|
+
* @param courseId The unique identifier for the course to be deleted
|
|
17553
16219
|
* @param org Filter courses by their associated organization
|
|
17554
16220
|
* @param slug Filter courses by their slug (case-insensitive)
|
|
17555
16221
|
* @returns CourseDeleteResponse
|
|
@@ -17600,7 +16266,7 @@ class CatalogService {
|
|
|
17600
16266
|
* @param org Organization of the course
|
|
17601
16267
|
* @param userId User ID to check eligibility for
|
|
17602
16268
|
* @param username Username to check eligibility for
|
|
17603
|
-
* @returns
|
|
16269
|
+
* @returns any
|
|
17604
16270
|
* @throws ApiError
|
|
17605
16271
|
*/
|
|
17606
16272
|
static catalogEligibilityCoursesCheckRetrieve(courseId, localOnly, org, userId, username) {
|
|
@@ -18034,7 +16700,7 @@ class CatalogService {
|
|
|
18034
16700
|
* @param sort Field to sort results by
|
|
18035
16701
|
* @param userId Filter enrollments by user ID
|
|
18036
16702
|
* @param username Filter enrollments by username
|
|
18037
|
-
* @returns
|
|
16703
|
+
* @returns ProgramEnrollmentSearchResponse
|
|
18038
16704
|
* @throws ApiError
|
|
18039
16705
|
*/
|
|
18040
16706
|
static catalogEnrollmentProgramsSearchRetrieve(includeDefaultPlatform, org, page, pageSize, platformKey, programId, programType, slug, sort = '-id', userId, username) {
|
|
@@ -18131,13 +16797,19 @@ class CatalogService {
|
|
|
18131
16797
|
}
|
|
18132
16798
|
/**
|
|
18133
16799
|
* Retrieve auto increment information for a specific platform.
|
|
16800
|
+
* @param key Platform key identifier
|
|
16801
|
+
* @param org Platform organization identifier
|
|
18134
16802
|
* @returns CatalogAutoIncrementResponse
|
|
18135
16803
|
* @throws ApiError
|
|
18136
16804
|
*/
|
|
18137
|
-
static catalogIncrementRetrieve() {
|
|
16805
|
+
static catalogIncrementRetrieve(key, org) {
|
|
18138
16806
|
return request(OpenAPI, {
|
|
18139
16807
|
method: 'GET',
|
|
18140
16808
|
url: '/api/catalog/increment/',
|
|
16809
|
+
query: {
|
|
16810
|
+
'key': key,
|
|
16811
|
+
'org': org
|
|
16812
|
+
},
|
|
18141
16813
|
errors: {
|
|
18142
16814
|
404: `No response body`
|
|
18143
16815
|
}
|
|
@@ -18146,7 +16818,7 @@ class CatalogService {
|
|
|
18146
16818
|
/**
|
|
18147
16819
|
* Update auto increment information and retrieve a new ID for a specific platform.
|
|
18148
16820
|
* @param requestBody
|
|
18149
|
-
* @returns
|
|
16821
|
+
* @returns number
|
|
18150
16822
|
* @throws ApiError
|
|
18151
16823
|
*/
|
|
18152
16824
|
static catalogIncrementCreate(requestBody) {
|
|
@@ -18154,11 +16826,7 @@ class CatalogService {
|
|
|
18154
16826
|
method: 'POST',
|
|
18155
16827
|
url: '/api/catalog/increment/',
|
|
18156
16828
|
body: requestBody,
|
|
18157
|
-
mediaType: 'application/json'
|
|
18158
|
-
errors: {
|
|
18159
|
-
400: `No response body`,
|
|
18160
|
-
500: `No response body`
|
|
18161
|
-
}
|
|
16829
|
+
mediaType: 'application/json'
|
|
18162
16830
|
});
|
|
18163
16831
|
}
|
|
18164
16832
|
/**
|
|
@@ -20500,184 +19168,178 @@ class CatalogService {
|
|
|
20500
19168
|
});
|
|
20501
19169
|
}
|
|
20502
19170
|
/**
|
|
20503
|
-
*
|
|
20504
|
-
*
|
|
20505
|
-
*
|
|
20506
|
-
*
|
|
20507
|
-
*
|
|
20508
|
-
*
|
|
20509
|
-
* If the program cannot be found, a 404 status code is returned.
|
|
20510
|
-
*
|
|
20511
|
-
* Params:
|
|
20512
|
-
* program_id: The unique identifier for the program.
|
|
20513
|
-
* org: The organization associated with the program.
|
|
20514
|
-
*
|
|
20515
|
-
* Returns:
|
|
20516
|
-
* A JSON response containing the program metadata if successful, or an
|
|
20517
|
-
* appropriate error status code.
|
|
20518
|
-
*
|
|
20519
|
-
* TODO: program-key compatibility
|
|
20520
|
-
* @returns any No response body
|
|
19171
|
+
* Retrieve metadata for a specified program
|
|
19172
|
+
* @param programId The unique identifier for the program
|
|
19173
|
+
* @param org The organization associated with the program
|
|
19174
|
+
* @param platformKey Platform key identifier (alternative to org)
|
|
19175
|
+
* @param programKey Program key (alternative to program_id + org)
|
|
19176
|
+
* @returns ProgramMetadataResponse
|
|
20521
19177
|
* @throws ApiError
|
|
20522
19178
|
*/
|
|
20523
|
-
static catalogMetadataProgramRetrieve() {
|
|
19179
|
+
static catalogMetadataProgramRetrieve(programId, org, platformKey, programKey) {
|
|
20524
19180
|
return request(OpenAPI, {
|
|
20525
19181
|
method: 'GET',
|
|
20526
|
-
url: '/api/catalog/metadata/program/'
|
|
19182
|
+
url: '/api/catalog/metadata/program/',
|
|
19183
|
+
query: {
|
|
19184
|
+
'org': org,
|
|
19185
|
+
'platform_key': platformKey,
|
|
19186
|
+
'program_id': programId,
|
|
19187
|
+
'program_key': programKey
|
|
19188
|
+
},
|
|
19189
|
+
errors: {
|
|
19190
|
+
400: `Missing or invalid parameters`,
|
|
19191
|
+
401: `Unauthorized`,
|
|
19192
|
+
403: `Permission denied`,
|
|
19193
|
+
404: `Program not found`
|
|
19194
|
+
}
|
|
20527
19195
|
});
|
|
20528
19196
|
}
|
|
20529
19197
|
/**
|
|
20530
|
-
*
|
|
20531
|
-
*
|
|
20532
|
-
*
|
|
20533
|
-
*
|
|
20534
|
-
*
|
|
20535
|
-
*
|
|
20536
|
-
*
|
|
20537
|
-
* field parameter is provided, a 404 status code is returned as field
|
|
20538
|
-
* updates are not supported.
|
|
20539
|
-
*
|
|
20540
|
-
* Params:
|
|
20541
|
-
* program_id: The unique identifier for the program.
|
|
20542
|
-
* org: The organization associated with the program.
|
|
20543
|
-
* metadata: The new metadata to update the program with.
|
|
20544
|
-
* update (optional): A flag indicating whether to update the metadata.
|
|
20545
|
-
*
|
|
20546
|
-
* Returns:
|
|
20547
|
-
* A JSON response containing the updated program metadata if successful,
|
|
20548
|
-
* or an appropriate error status code.
|
|
20549
|
-
*
|
|
20550
|
-
* TODO: program-key compatibility
|
|
20551
|
-
* @returns any No response body
|
|
19198
|
+
* Update metadata for a specified program
|
|
19199
|
+
* @param programId The unique identifier for the program
|
|
19200
|
+
* @param requestBody
|
|
19201
|
+
* @param org The organization associated with the program
|
|
19202
|
+
* @param platformKey Platform key identifier (alternative to org)
|
|
19203
|
+
* @param programKey Program key (alternative to program_id + org)
|
|
19204
|
+
* @returns ProgramMetadataResponse
|
|
20552
19205
|
* @throws ApiError
|
|
20553
19206
|
*/
|
|
20554
|
-
static catalogMetadataProgramCreate() {
|
|
19207
|
+
static catalogMetadataProgramCreate(programId, requestBody, org, platformKey, programKey) {
|
|
20555
19208
|
return request(OpenAPI, {
|
|
20556
19209
|
method: 'POST',
|
|
20557
|
-
url: '/api/catalog/metadata/program/'
|
|
19210
|
+
url: '/api/catalog/metadata/program/',
|
|
19211
|
+
query: {
|
|
19212
|
+
'org': org,
|
|
19213
|
+
'platform_key': platformKey,
|
|
19214
|
+
'program_id': programId,
|
|
19215
|
+
'program_key': programKey
|
|
19216
|
+
},
|
|
19217
|
+
body: requestBody,
|
|
19218
|
+
mediaType: 'application/json',
|
|
19219
|
+
errors: {
|
|
19220
|
+
400: `Missing or invalid parameters`,
|
|
19221
|
+
401: `Unauthorized`,
|
|
19222
|
+
403: `Permission denied`,
|
|
19223
|
+
404: `Program not found`
|
|
19224
|
+
}
|
|
20558
19225
|
});
|
|
20559
19226
|
}
|
|
20560
19227
|
/**
|
|
20561
|
-
*
|
|
20562
|
-
*
|
|
20563
|
-
*
|
|
20564
|
-
*
|
|
20565
|
-
*
|
|
20566
|
-
*
|
|
20567
|
-
*
|
|
20568
|
-
* Params:
|
|
20569
|
-
* - program_id: The unique identifier for the program.
|
|
20570
|
-
* - org: The organization associated with the program.
|
|
20571
|
-
*
|
|
20572
|
-
* Returns:
|
|
20573
|
-
* - 200: Successfully retrieved the program metadata.
|
|
20574
|
-
* - 400: Bad request if the program ID is not provided.
|
|
20575
|
-
* - 404: Not found if the program or its metadata cannot be retrieved.
|
|
20576
|
-
*
|
|
20577
|
-
* TODO: Implement program-key compatibility for enhanced querying.
|
|
20578
|
-
* @returns any No response body
|
|
19228
|
+
* Retrieve public metadata for a specified program
|
|
19229
|
+
* @param programId The unique identifier for the program
|
|
19230
|
+
* @param org The organization associated with the program
|
|
19231
|
+
* @param platformKey Platform key identifier (alternative to org)
|
|
19232
|
+
* @param programKey Program key (alternative to program_id + org)
|
|
19233
|
+
* @returns ProgramMetadataResponse
|
|
20579
19234
|
* @throws ApiError
|
|
20580
19235
|
*/
|
|
20581
|
-
static catalogMetadataProgramPublicRetrieve() {
|
|
19236
|
+
static catalogMetadataProgramPublicRetrieve(programId, org, platformKey, programKey) {
|
|
20582
19237
|
return request(OpenAPI, {
|
|
20583
19238
|
method: 'GET',
|
|
20584
|
-
url: '/api/catalog/metadata/program-public/'
|
|
19239
|
+
url: '/api/catalog/metadata/program-public/',
|
|
19240
|
+
query: {
|
|
19241
|
+
'org': org,
|
|
19242
|
+
'platform_key': platformKey,
|
|
19243
|
+
'program_id': programId,
|
|
19244
|
+
'program_key': programKey
|
|
19245
|
+
},
|
|
19246
|
+
errors: {
|
|
19247
|
+
400: `Missing or invalid parameters`,
|
|
19248
|
+
404: `Program not found or no public metadata available`
|
|
19249
|
+
}
|
|
20585
19250
|
});
|
|
20586
19251
|
}
|
|
20587
19252
|
/**
|
|
20588
|
-
*
|
|
20589
|
-
* Query public program metadata.
|
|
20590
|
-
*
|
|
20591
|
-
* This method retrieves public metadata for a specified program. It requires
|
|
20592
|
-
* a program ID and optionally an organization to identify the program. The
|
|
20593
|
-
* metadata is filtered to include only public fields.
|
|
20594
|
-
*
|
|
20595
|
-
* Params:
|
|
20596
|
-
* - program_id: The unique identifier for the program.
|
|
20597
|
-
* - org: The organization associated with the program.
|
|
20598
|
-
*
|
|
20599
|
-
* Returns:
|
|
20600
|
-
* - 200: Successfully retrieved the program metadata.
|
|
20601
|
-
* - 400: Bad request if the program ID is not provided.
|
|
20602
|
-
* - 404: Not found if the program or its metadata cannot be retrieved.
|
|
20603
|
-
*
|
|
20604
|
-
* TODO: Implement program-key compatibility for enhanced querying.
|
|
19253
|
+
* Retrieve public metadata for a specified program
|
|
20605
19254
|
* @param field
|
|
20606
|
-
* @
|
|
19255
|
+
* @param programId The unique identifier for the program
|
|
19256
|
+
* @param org The organization associated with the program
|
|
19257
|
+
* @param platformKey Platform key identifier (alternative to org)
|
|
19258
|
+
* @param programKey Program key (alternative to program_id + org)
|
|
19259
|
+
* @returns ProgramMetadataResponse
|
|
20607
19260
|
* @throws ApiError
|
|
20608
19261
|
*/
|
|
20609
|
-
static catalogMetadataProgramPublicRetrieve2(field) {
|
|
19262
|
+
static catalogMetadataProgramPublicRetrieve2(field, programId, org, platformKey, programKey) {
|
|
20610
19263
|
return request(OpenAPI, {
|
|
20611
19264
|
method: 'GET',
|
|
20612
19265
|
url: '/api/catalog/metadata/program-public/{field}/',
|
|
20613
19266
|
path: {
|
|
20614
19267
|
'field': field
|
|
19268
|
+
},
|
|
19269
|
+
query: {
|
|
19270
|
+
'org': org,
|
|
19271
|
+
'platform_key': platformKey,
|
|
19272
|
+
'program_id': programId,
|
|
19273
|
+
'program_key': programKey
|
|
19274
|
+
},
|
|
19275
|
+
errors: {
|
|
19276
|
+
400: `Missing or invalid parameters`,
|
|
19277
|
+
404: `Program not found or no public metadata available`
|
|
20615
19278
|
}
|
|
20616
19279
|
});
|
|
20617
19280
|
}
|
|
20618
19281
|
/**
|
|
20619
|
-
*
|
|
20620
|
-
* Query program metadata.
|
|
20621
|
-
*
|
|
20622
|
-
* This method retrieves metadata for a specified program. The program is
|
|
20623
|
-
* identified by its program_id and organization (org). If the program_id
|
|
20624
|
-
* is not provided, a 400 status code is returned indicating a bad request.
|
|
20625
|
-
* If the program cannot be found, a 404 status code is returned.
|
|
20626
|
-
*
|
|
20627
|
-
* Params:
|
|
20628
|
-
* program_id: The unique identifier for the program.
|
|
20629
|
-
* org: The organization associated with the program.
|
|
20630
|
-
*
|
|
20631
|
-
* Returns:
|
|
20632
|
-
* A JSON response containing the program metadata if successful, or an
|
|
20633
|
-
* appropriate error status code.
|
|
20634
|
-
*
|
|
20635
|
-
* TODO: program-key compatibility
|
|
19282
|
+
* Retrieve metadata for a specified program
|
|
20636
19283
|
* @param field
|
|
20637
|
-
* @
|
|
19284
|
+
* @param programId The unique identifier for the program
|
|
19285
|
+
* @param org The organization associated with the program
|
|
19286
|
+
* @param platformKey Platform key identifier (alternative to org)
|
|
19287
|
+
* @param programKey Program key (alternative to program_id + org)
|
|
19288
|
+
* @returns ProgramMetadataResponse
|
|
20638
19289
|
* @throws ApiError
|
|
20639
19290
|
*/
|
|
20640
|
-
static catalogMetadataProgramRetrieve2(field) {
|
|
19291
|
+
static catalogMetadataProgramRetrieve2(field, programId, org, platformKey, programKey) {
|
|
20641
19292
|
return request(OpenAPI, {
|
|
20642
19293
|
method: 'GET',
|
|
20643
19294
|
url: '/api/catalog/metadata/program/{field}/',
|
|
20644
19295
|
path: {
|
|
20645
19296
|
'field': field
|
|
19297
|
+
},
|
|
19298
|
+
query: {
|
|
19299
|
+
'org': org,
|
|
19300
|
+
'platform_key': platformKey,
|
|
19301
|
+
'program_id': programId,
|
|
19302
|
+
'program_key': programKey
|
|
19303
|
+
},
|
|
19304
|
+
errors: {
|
|
19305
|
+
400: `Missing or invalid parameters`,
|
|
19306
|
+
401: `Unauthorized`,
|
|
19307
|
+
403: `Permission denied`,
|
|
19308
|
+
404: `Program not found`
|
|
20646
19309
|
}
|
|
20647
19310
|
});
|
|
20648
19311
|
}
|
|
20649
19312
|
/**
|
|
20650
|
-
*
|
|
20651
|
-
* Update program metadata.
|
|
20652
|
-
*
|
|
20653
|
-
* This method updates the metadata for a specified program. The program is
|
|
20654
|
-
* identified by its program_id and organization (org). If the program_id
|
|
20655
|
-
* is not provided, a 400 status code is returned indicating a bad request.
|
|
20656
|
-
* If the program cannot be found, a 404 status code is returned. If the
|
|
20657
|
-
* field parameter is provided, a 404 status code is returned as field
|
|
20658
|
-
* updates are not supported.
|
|
20659
|
-
*
|
|
20660
|
-
* Params:
|
|
20661
|
-
* program_id: The unique identifier for the program.
|
|
20662
|
-
* org: The organization associated with the program.
|
|
20663
|
-
* metadata: The new metadata to update the program with.
|
|
20664
|
-
* update (optional): A flag indicating whether to update the metadata.
|
|
20665
|
-
*
|
|
20666
|
-
* Returns:
|
|
20667
|
-
* A JSON response containing the updated program metadata if successful,
|
|
20668
|
-
* or an appropriate error status code.
|
|
20669
|
-
*
|
|
20670
|
-
* TODO: program-key compatibility
|
|
19313
|
+
* Update metadata for a specified program
|
|
20671
19314
|
* @param field
|
|
20672
|
-
* @
|
|
19315
|
+
* @param programId The unique identifier for the program
|
|
19316
|
+
* @param requestBody
|
|
19317
|
+
* @param org The organization associated with the program
|
|
19318
|
+
* @param platformKey Platform key identifier (alternative to org)
|
|
19319
|
+
* @param programKey Program key (alternative to program_id + org)
|
|
19320
|
+
* @returns ProgramMetadataResponse
|
|
20673
19321
|
* @throws ApiError
|
|
20674
19322
|
*/
|
|
20675
|
-
static catalogMetadataProgramCreate2(field) {
|
|
19323
|
+
static catalogMetadataProgramCreate2(field, programId, requestBody, org, platformKey, programKey) {
|
|
20676
19324
|
return request(OpenAPI, {
|
|
20677
19325
|
method: 'POST',
|
|
20678
19326
|
url: '/api/catalog/metadata/program/{field}/',
|
|
20679
19327
|
path: {
|
|
20680
19328
|
'field': field
|
|
19329
|
+
},
|
|
19330
|
+
query: {
|
|
19331
|
+
'org': org,
|
|
19332
|
+
'platform_key': platformKey,
|
|
19333
|
+
'program_id': programId,
|
|
19334
|
+
'program_key': programKey
|
|
19335
|
+
},
|
|
19336
|
+
body: requestBody,
|
|
19337
|
+
mediaType: 'application/json',
|
|
19338
|
+
errors: {
|
|
19339
|
+
400: `Missing or invalid parameters`,
|
|
19340
|
+
401: `Unauthorized`,
|
|
19341
|
+
403: `Permission denied`,
|
|
19342
|
+
404: `Program not found`
|
|
20681
19343
|
}
|
|
20682
19344
|
});
|
|
20683
19345
|
}
|
|
@@ -21104,25 +19766,65 @@ class CatalogService {
|
|
|
21104
19766
|
}
|
|
21105
19767
|
/**
|
|
21106
19768
|
* Retrieve pathways matching query. Limited parameters.
|
|
19769
|
+
* @param itemId Item ID associated with the pathway
|
|
19770
|
+
* @param name Pathway name
|
|
19771
|
+
* @param pathwayId Pathway ID
|
|
19772
|
+
* @param pathwayUuid Pathway UUID
|
|
19773
|
+
* @param platformKey Platform key
|
|
19774
|
+
* @param slug Pathway slug (case-insensitive)
|
|
19775
|
+
* @param userId User ID of the pathway owner
|
|
19776
|
+
* @param username Username of the pathway owner
|
|
19777
|
+
* @param visible Whether the pathway is visible
|
|
21107
19778
|
* @returns Pathway
|
|
21108
19779
|
* @throws ApiError
|
|
21109
19780
|
*/
|
|
21110
|
-
static catalogPathwaysList() {
|
|
19781
|
+
static catalogPathwaysList(itemId, name, pathwayId, pathwayUuid, platformKey, slug, userId, username, visible) {
|
|
21111
19782
|
return request(OpenAPI, {
|
|
21112
19783
|
method: 'GET',
|
|
21113
|
-
url: '/api/catalog/pathways/'
|
|
19784
|
+
url: '/api/catalog/pathways/',
|
|
19785
|
+
query: {
|
|
19786
|
+
'item_id': itemId,
|
|
19787
|
+
'name': name,
|
|
19788
|
+
'pathway_id': pathwayId,
|
|
19789
|
+
'pathway_uuid': pathwayUuid,
|
|
19790
|
+
'platform_key': platformKey,
|
|
19791
|
+
'slug': slug,
|
|
19792
|
+
'user_id': userId,
|
|
19793
|
+
'username': username,
|
|
19794
|
+
'visible': visible
|
|
19795
|
+
}
|
|
21114
19796
|
});
|
|
21115
19797
|
}
|
|
21116
19798
|
/**
|
|
21117
19799
|
* Add or update a pathway.
|
|
21118
19800
|
* @param requestBody
|
|
19801
|
+
* @param itemId Item ID associated with the pathway
|
|
19802
|
+
* @param name Pathway name
|
|
19803
|
+
* @param pathwayId Pathway ID
|
|
19804
|
+
* @param pathwayUuid Pathway UUID
|
|
19805
|
+
* @param platformKey Platform key
|
|
19806
|
+
* @param slug Pathway slug (case-insensitive)
|
|
19807
|
+
* @param userId User ID of the pathway owner
|
|
19808
|
+
* @param username Username of the pathway owner
|
|
19809
|
+
* @param visible Whether the pathway is visible
|
|
21119
19810
|
* @returns Pathway
|
|
21120
19811
|
* @throws ApiError
|
|
21121
19812
|
*/
|
|
21122
|
-
static catalogPathwaysCreate(requestBody) {
|
|
19813
|
+
static catalogPathwaysCreate(requestBody, itemId, name, pathwayId, pathwayUuid, platformKey, slug, userId, username, visible) {
|
|
21123
19814
|
return request(OpenAPI, {
|
|
21124
19815
|
method: 'POST',
|
|
21125
19816
|
url: '/api/catalog/pathways/',
|
|
19817
|
+
query: {
|
|
19818
|
+
'item_id': itemId,
|
|
19819
|
+
'name': name,
|
|
19820
|
+
'pathway_id': pathwayId,
|
|
19821
|
+
'pathway_uuid': pathwayUuid,
|
|
19822
|
+
'platform_key': platformKey,
|
|
19823
|
+
'slug': slug,
|
|
19824
|
+
'user_id': userId,
|
|
19825
|
+
'username': username,
|
|
19826
|
+
'visible': visible
|
|
19827
|
+
},
|
|
21126
19828
|
body: requestBody,
|
|
21127
19829
|
mediaType: 'application/json',
|
|
21128
19830
|
errors: {
|
|
@@ -21132,13 +19834,33 @@ class CatalogService {
|
|
|
21132
19834
|
}
|
|
21133
19835
|
/**
|
|
21134
19836
|
* Remove a pathway from the database.
|
|
19837
|
+
* @param pathwayId Pathway ID to delete
|
|
19838
|
+
* @param userId User ID of the pathway owner
|
|
19839
|
+
* @param itemId Item ID associated with the pathway
|
|
19840
|
+
* @param name Pathway name
|
|
19841
|
+
* @param pathwayUuid Pathway UUID
|
|
19842
|
+
* @param platformKey Platform key
|
|
19843
|
+
* @param slug Pathway slug (case-insensitive)
|
|
19844
|
+
* @param username Username of the pathway owner
|
|
19845
|
+
* @param visible Whether the pathway is visible
|
|
21135
19846
|
* @returns PathwayDeleteResponse
|
|
21136
19847
|
* @throws ApiError
|
|
21137
19848
|
*/
|
|
21138
|
-
static catalogPathwaysDestroy() {
|
|
19849
|
+
static catalogPathwaysDestroy(pathwayId, userId, itemId, name, pathwayUuid, platformKey, slug, username, visible) {
|
|
21139
19850
|
return request(OpenAPI, {
|
|
21140
19851
|
method: 'DELETE',
|
|
21141
19852
|
url: '/api/catalog/pathways/',
|
|
19853
|
+
query: {
|
|
19854
|
+
'item_id': itemId,
|
|
19855
|
+
'name': name,
|
|
19856
|
+
'pathway_id': pathwayId,
|
|
19857
|
+
'pathway_uuid': pathwayUuid,
|
|
19858
|
+
'platform_key': platformKey,
|
|
19859
|
+
'slug': slug,
|
|
19860
|
+
'user_id': userId,
|
|
19861
|
+
'username': username,
|
|
19862
|
+
'visible': visible
|
|
19863
|
+
},
|
|
21142
19864
|
errors: {
|
|
21143
19865
|
400: `No response body`
|
|
21144
19866
|
}
|
|
@@ -21146,13 +19868,27 @@ class CatalogService {
|
|
|
21146
19868
|
}
|
|
21147
19869
|
/**
|
|
21148
19870
|
* Retrieve programs matching query parameters. Limited parameters include program_id, name, slug, enabled, and org.
|
|
19871
|
+
* @param courseId Course ID contained in the program
|
|
19872
|
+
* @param enabled Whether the program is enabled
|
|
19873
|
+
* @param name Program name
|
|
19874
|
+
* @param org Organization of the program
|
|
19875
|
+
* @param programId Program ID
|
|
19876
|
+
* @param slug Program slug (case-insensitive)
|
|
21149
19877
|
* @returns Program
|
|
21150
19878
|
* @throws ApiError
|
|
21151
19879
|
*/
|
|
21152
|
-
static catalogProgramsList() {
|
|
19880
|
+
static catalogProgramsList(courseId, enabled, name, org, programId, slug) {
|
|
21153
19881
|
return request(OpenAPI, {
|
|
21154
19882
|
method: 'GET',
|
|
21155
|
-
url: '/api/catalog/programs/'
|
|
19883
|
+
url: '/api/catalog/programs/',
|
|
19884
|
+
query: {
|
|
19885
|
+
'course_id': courseId,
|
|
19886
|
+
'enabled': enabled,
|
|
19887
|
+
'name': name,
|
|
19888
|
+
'org': org,
|
|
19889
|
+
'program_id': programId,
|
|
19890
|
+
'slug': slug
|
|
19891
|
+
}
|
|
21156
19892
|
});
|
|
21157
19893
|
}
|
|
21158
19894
|
/**
|
|
@@ -21174,13 +19910,19 @@ class CatalogService {
|
|
|
21174
19910
|
}
|
|
21175
19911
|
/**
|
|
21176
19912
|
* Remove a program from the database. Requires program_id and org as parameters.
|
|
19913
|
+
* @param org Organization of the program
|
|
19914
|
+
* @param programId Program ID to delete
|
|
21177
19915
|
* @returns ProgramDeleteResponse
|
|
21178
19916
|
* @throws ApiError
|
|
21179
19917
|
*/
|
|
21180
|
-
static catalogProgramsDestroy() {
|
|
19918
|
+
static catalogProgramsDestroy(org, programId) {
|
|
21181
19919
|
return request(OpenAPI, {
|
|
21182
19920
|
method: 'DELETE',
|
|
21183
19921
|
url: '/api/catalog/programs/',
|
|
19922
|
+
query: {
|
|
19923
|
+
'org': org,
|
|
19924
|
+
'program_id': programId
|
|
19925
|
+
},
|
|
21184
19926
|
errors: {
|
|
21185
19927
|
400: `No response body`
|
|
21186
19928
|
}
|
|
@@ -21295,12 +20037,12 @@ class CatalogService {
|
|
|
21295
20037
|
}
|
|
21296
20038
|
/**
|
|
21297
20039
|
* Remove a resource from the database.
|
|
21298
|
-
* @param id Resource ID
|
|
20040
|
+
* @param id Resource ID to delete
|
|
21299
20041
|
* @param itemId Item ID associated with the resource
|
|
21300
20042
|
* @param key Platform key
|
|
21301
20043
|
* @param name Resource name
|
|
21302
20044
|
* @param org Platform organization
|
|
21303
|
-
* @param platformKey Platform key
|
|
20045
|
+
* @param platformKey Platform key
|
|
21304
20046
|
* @param platformOrg Platform organization (alternative to org)
|
|
21305
20047
|
* @param resourceType Type of resource
|
|
21306
20048
|
* @param userId User ID who owns the resource
|
|
@@ -21327,63 +20069,38 @@ class CatalogService {
|
|
|
21327
20069
|
});
|
|
21328
20070
|
}
|
|
21329
20071
|
/**
|
|
21330
|
-
*
|
|
21331
|
-
*
|
|
21332
|
-
*
|
|
21333
|
-
*
|
|
21334
|
-
*
|
|
21335
|
-
*
|
|
21336
|
-
*
|
|
21337
|
-
*
|
|
21338
|
-
*
|
|
21339
|
-
*
|
|
21340
|
-
*
|
|
21341
|
-
|
|
21342
|
-
|
|
21343
|
-
* page_size (int, optional): Number of items per page
|
|
21344
|
-
*
|
|
21345
|
-
* Methods:
|
|
21346
|
-
* GET: Retrieve a paginated list of course reviews with filtering
|
|
21347
|
-
*
|
|
21348
|
-
* Returns:
|
|
21349
|
-
* GET: A paginated JSON response containing course reviews:
|
|
21350
|
-
* {
|
|
21351
|
-
* "count": 15,
|
|
21352
|
-
* "next": "https://api.example.com/api/catalog/reviews/course/?page=2",
|
|
21353
|
-
* "previous": null,
|
|
21354
|
-
* "results": [
|
|
21355
|
-
* {
|
|
21356
|
-
* "user_id": 123,
|
|
21357
|
-
* "username": "student1",
|
|
21358
|
-
* "content": "This course was excellent and very informative.",
|
|
21359
|
-
* "rating": 4.5,
|
|
21360
|
-
* "title": "Great Course!",
|
|
21361
|
-
* "visible": true,
|
|
21362
|
-
* "created": "2023-01-15T10:30:00Z",
|
|
21363
|
-
* "modified": "2023-01-15T10:30:00Z",
|
|
21364
|
-
* "course_id": "course-v1:org+course+run"
|
|
21365
|
-
* },
|
|
21366
|
-
* ...
|
|
21367
|
-
* ]
|
|
21368
|
-
* }
|
|
21369
|
-
*
|
|
21370
|
-
* Error Responses:
|
|
21371
|
-
* 400 Bad Request: If required parameters are missing or invalid
|
|
21372
|
-
* 401 Unauthorized: If the user is not authenticated
|
|
21373
|
-
* 403 Forbidden: If the user does not have permission to access this resource
|
|
21374
|
-
* 500 Internal Server Error: If an unexpected error occurs
|
|
21375
|
-
*
|
|
21376
|
-
* Access Control:
|
|
21377
|
-
* - Requires IsDMAdmin, IsPlatformAdminReadOnly, or IsPlatformAdminForCourse permission
|
|
21378
|
-
* - Platform admins can view reviews for courses in their platform (read-only)
|
|
21379
|
-
* - DM admins can view all reviews
|
|
21380
|
-
* @returns any No response body
|
|
21381
|
-
* @throws ApiError
|
|
21382
|
-
*/
|
|
21383
|
-
static catalogReviewsCourseRetrieve() {
|
|
20072
|
+
* Retrieve a paginated list of course reviews with filtering options
|
|
20073
|
+
* @param courseId Filter reviews by course ID
|
|
20074
|
+
* @param org Alias for platform_org
|
|
20075
|
+
* @param page Page number for pagination
|
|
20076
|
+
* @param pageSize Number of items per page
|
|
20077
|
+
* @param platformKey Filter reviews by platform key
|
|
20078
|
+
* @param platformOrg Filter reviews by platform organization
|
|
20079
|
+
* @param sort Field to sort results by (default: '-id')
|
|
20080
|
+
* @param userId Filter reviews by user ID
|
|
20081
|
+
* @returns CourseReviewPaginatedResponse
|
|
20082
|
+
* @throws ApiError
|
|
20083
|
+
*/
|
|
20084
|
+
static catalogReviewsCourseRetrieve(courseId, org, page, pageSize, platformKey, platformOrg, sort = '-id', userId) {
|
|
21384
20085
|
return request(OpenAPI, {
|
|
21385
20086
|
method: 'GET',
|
|
21386
|
-
url: '/api/catalog/reviews/course/'
|
|
20087
|
+
url: '/api/catalog/reviews/course/',
|
|
20088
|
+
query: {
|
|
20089
|
+
'course_id': courseId,
|
|
20090
|
+
'org': org,
|
|
20091
|
+
'page': page,
|
|
20092
|
+
'page_size': pageSize,
|
|
20093
|
+
'platform_key': platformKey,
|
|
20094
|
+
'platform_org': platformOrg,
|
|
20095
|
+
'sort': sort,
|
|
20096
|
+
'user_id': userId
|
|
20097
|
+
},
|
|
20098
|
+
errors: {
|
|
20099
|
+
400: `Invalid parameters`,
|
|
20100
|
+
401: `Unauthorized`,
|
|
20101
|
+
403: `Permission denied`,
|
|
20102
|
+
500: `Internal server error`
|
|
20103
|
+
}
|
|
21387
20104
|
});
|
|
21388
20105
|
}
|
|
21389
20106
|
/**
|
|
@@ -21406,177 +20123,83 @@ class CatalogService {
|
|
|
21406
20123
|
});
|
|
21407
20124
|
}
|
|
21408
20125
|
/**
|
|
21409
|
-
*
|
|
21410
|
-
*
|
|
21411
|
-
*
|
|
21412
|
-
*
|
|
21413
|
-
|
|
21414
|
-
|
|
21415
|
-
* DELETE: Delete a course review
|
|
21416
|
-
*
|
|
21417
|
-
* Request Body (POST):
|
|
21418
|
-
* A JSON object containing:
|
|
21419
|
-
* - course_id (str, required): The course ID to review
|
|
21420
|
-
* - username (str, required): The username of the reviewer
|
|
21421
|
-
* - rating (float, optional): The rating value (typically 1-5)
|
|
21422
|
-
* - title (str, optional): The review title
|
|
21423
|
-
* - content (str, optional): The review content/text
|
|
21424
|
-
* - visible (bool, optional): Whether the review is visible (default: true)
|
|
21425
|
-
*
|
|
21426
|
-
* Query Parameters (DELETE):
|
|
21427
|
-
* course_id (str, required): The course ID of the review to delete
|
|
21428
|
-
* username (str, required): The username of the reviewer
|
|
21429
|
-
*
|
|
21430
|
-
* Returns:
|
|
21431
|
-
* POST: A JSON response containing the created/updated review:
|
|
21432
|
-
* {
|
|
21433
|
-
* "user_id": 123,
|
|
21434
|
-
* "username": "student1",
|
|
21435
|
-
* "content": "This course was excellent and very informative.",
|
|
21436
|
-
* "rating": 4.5,
|
|
21437
|
-
* "title": "Great Course!",
|
|
21438
|
-
* "visible": true,
|
|
21439
|
-
* "created": "2023-01-15T10:30:00Z",
|
|
21440
|
-
* "modified": "2023-01-15T10:30:00Z",
|
|
21441
|
-
* "course_id": "course-v1:org+course+run"
|
|
21442
|
-
* }
|
|
21443
|
-
*
|
|
21444
|
-
* DELETE: A success response with status 200
|
|
21445
|
-
*
|
|
21446
|
-
* Error Responses:
|
|
21447
|
-
* 400 Bad Request: If required parameters are missing or invalid
|
|
21448
|
-
* 401 Unauthorized: If the user is not authenticated
|
|
21449
|
-
* 403 Forbidden: If the user does not have permission to manage this review
|
|
21450
|
-
* 500 Internal Server Error: If an unexpected error occurs during review operations
|
|
21451
|
-
*
|
|
21452
|
-
* Access Control:
|
|
21453
|
-
* - Requires IsDMAdmin or IsEdxUserReadWriteDelete permission
|
|
21454
|
-
* - Users can create, update, or delete their own reviews
|
|
21455
|
-
* - DM admins can manage all reviews
|
|
21456
|
-
* @returns any No response body
|
|
21457
|
-
* @throws ApiError
|
|
21458
|
-
*/
|
|
21459
|
-
static catalogReviewsCourseUpdateCreate() {
|
|
20126
|
+
* Create or update a course review
|
|
20127
|
+
* @param requestBody
|
|
20128
|
+
* @returns CourseReviewResponse
|
|
20129
|
+
* @throws ApiError
|
|
20130
|
+
*/
|
|
20131
|
+
static catalogReviewsCourseUpdateCreate(requestBody) {
|
|
21460
20132
|
return request(OpenAPI, {
|
|
21461
20133
|
method: 'POST',
|
|
21462
|
-
url: '/api/catalog/reviews/course/update/'
|
|
20134
|
+
url: '/api/catalog/reviews/course/update/',
|
|
20135
|
+
body: requestBody,
|
|
20136
|
+
mediaType: 'application/json',
|
|
20137
|
+
errors: {
|
|
20138
|
+
400: `Invalid parameters`,
|
|
20139
|
+
401: `Unauthorized`,
|
|
20140
|
+
403: `Permission denied`,
|
|
20141
|
+
500: `Review could not be saved`
|
|
20142
|
+
}
|
|
21463
20143
|
});
|
|
21464
20144
|
}
|
|
21465
20145
|
/**
|
|
21466
|
-
*
|
|
21467
|
-
*
|
|
21468
|
-
*
|
|
21469
|
-
*
|
|
21470
|
-
*
|
|
21471
|
-
*
|
|
21472
|
-
|
|
21473
|
-
|
|
21474
|
-
* Request Body (POST):
|
|
21475
|
-
* A JSON object containing:
|
|
21476
|
-
* - course_id (str, required): The course ID to review
|
|
21477
|
-
* - username (str, required): The username of the reviewer
|
|
21478
|
-
* - rating (float, optional): The rating value (typically 1-5)
|
|
21479
|
-
* - title (str, optional): The review title
|
|
21480
|
-
* - content (str, optional): The review content/text
|
|
21481
|
-
* - visible (bool, optional): Whether the review is visible (default: true)
|
|
21482
|
-
*
|
|
21483
|
-
* Query Parameters (DELETE):
|
|
21484
|
-
* course_id (str, required): The course ID of the review to delete
|
|
21485
|
-
* username (str, required): The username of the reviewer
|
|
21486
|
-
*
|
|
21487
|
-
* Returns:
|
|
21488
|
-
* POST: A JSON response containing the created/updated review:
|
|
21489
|
-
* {
|
|
21490
|
-
* "user_id": 123,
|
|
21491
|
-
* "username": "student1",
|
|
21492
|
-
* "content": "This course was excellent and very informative.",
|
|
21493
|
-
* "rating": 4.5,
|
|
21494
|
-
* "title": "Great Course!",
|
|
21495
|
-
* "visible": true,
|
|
21496
|
-
* "created": "2023-01-15T10:30:00Z",
|
|
21497
|
-
* "modified": "2023-01-15T10:30:00Z",
|
|
21498
|
-
* "course_id": "course-v1:org+course+run"
|
|
21499
|
-
* }
|
|
21500
|
-
*
|
|
21501
|
-
* DELETE: A success response with status 200
|
|
21502
|
-
*
|
|
21503
|
-
* Error Responses:
|
|
21504
|
-
* 400 Bad Request: If required parameters are missing or invalid
|
|
21505
|
-
* 401 Unauthorized: If the user is not authenticated
|
|
21506
|
-
* 403 Forbidden: If the user does not have permission to manage this review
|
|
21507
|
-
* 500 Internal Server Error: If an unexpected error occurs during review operations
|
|
21508
|
-
*
|
|
21509
|
-
* Access Control:
|
|
21510
|
-
* - Requires IsDMAdmin or IsEdxUserReadWriteDelete permission
|
|
21511
|
-
* - Users can create, update, or delete their own reviews
|
|
21512
|
-
* - DM admins can manage all reviews
|
|
21513
|
-
* @returns void
|
|
21514
|
-
* @throws ApiError
|
|
21515
|
-
*/
|
|
21516
|
-
static catalogReviewsCourseUpdateDestroy() {
|
|
20146
|
+
* Delete a course review
|
|
20147
|
+
* @param courseId The course ID of the review to delete
|
|
20148
|
+
* @param username The username of the reviewer
|
|
20149
|
+
* @param userId The user ID of the reviewer (alternative to username)
|
|
20150
|
+
* @returns any Review successfully deleted
|
|
20151
|
+
* @throws ApiError
|
|
20152
|
+
*/
|
|
20153
|
+
static catalogReviewsCourseUpdateDestroy(courseId, username, userId) {
|
|
21517
20154
|
return request(OpenAPI, {
|
|
21518
20155
|
method: 'DELETE',
|
|
21519
|
-
url: '/api/catalog/reviews/course/update/'
|
|
20156
|
+
url: '/api/catalog/reviews/course/update/',
|
|
20157
|
+
query: {
|
|
20158
|
+
'course_id': courseId,
|
|
20159
|
+
'user_id': userId,
|
|
20160
|
+
'username': username
|
|
20161
|
+
},
|
|
20162
|
+
errors: {
|
|
20163
|
+
400: `Invalid parameters`,
|
|
20164
|
+
401: `Unauthorized`,
|
|
20165
|
+
403: `Permission denied`,
|
|
20166
|
+
500: `Review could not be deleted`
|
|
20167
|
+
}
|
|
21520
20168
|
});
|
|
21521
20169
|
}
|
|
21522
20170
|
/**
|
|
21523
|
-
*
|
|
21524
|
-
*
|
|
21525
|
-
*
|
|
21526
|
-
*
|
|
21527
|
-
*
|
|
21528
|
-
*
|
|
21529
|
-
*
|
|
21530
|
-
*
|
|
21531
|
-
*
|
|
21532
|
-
*
|
|
21533
|
-
*
|
|
21534
|
-
|
|
21535
|
-
|
|
21536
|
-
* page_size (int, optional): Number of items per page
|
|
21537
|
-
*
|
|
21538
|
-
* Methods:
|
|
21539
|
-
* GET: Retrieve a paginated list of program reviews with filtering
|
|
21540
|
-
*
|
|
21541
|
-
* Returns:
|
|
21542
|
-
* GET: A paginated JSON response containing program reviews:
|
|
21543
|
-
* {
|
|
21544
|
-
* "count": 15,
|
|
21545
|
-
* "next": "https://api.example.com/api/catalog/reviews/program/?page=2",
|
|
21546
|
-
* "previous": null,
|
|
21547
|
-
* "results": [
|
|
21548
|
-
* {
|
|
21549
|
-
* "user_id": 123,
|
|
21550
|
-
* "username": "student1",
|
|
21551
|
-
* "content": "This program was comprehensive and well-structured.",
|
|
21552
|
-
* "rating": 4.5,
|
|
21553
|
-
* "title": "Excellent Program",
|
|
21554
|
-
* "visible": true,
|
|
21555
|
-
* "created": "2023-01-15T10:30:00Z",
|
|
21556
|
-
* "modified": "2023-01-15T10:30:00Z",
|
|
21557
|
-
* "program_key": "program-v1:org+program123"
|
|
21558
|
-
* },
|
|
21559
|
-
* ...
|
|
21560
|
-
* ]
|
|
21561
|
-
* }
|
|
21562
|
-
*
|
|
21563
|
-
* Error Responses:
|
|
21564
|
-
* 400 Bad Request: If required parameters are missing or invalid
|
|
21565
|
-
* 401 Unauthorized: If the user is not authenticated
|
|
21566
|
-
* 403 Forbidden: If the user does not have permission to access this resource
|
|
21567
|
-
* 500 Internal Server Error: If an unexpected error occurs
|
|
21568
|
-
*
|
|
21569
|
-
* Access Control:
|
|
21570
|
-
* - Requires IsDMAdmin, IsPlatformAdminReadOnly, or IsPlatformAdminForProgram permission
|
|
21571
|
-
* - Platform admins can view reviews for programs in their platform (read-only)
|
|
21572
|
-
* - DM admins can view all reviews
|
|
21573
|
-
* @returns any No response body
|
|
21574
|
-
* @throws ApiError
|
|
21575
|
-
*/
|
|
21576
|
-
static catalogReviewsProgramRetrieve() {
|
|
20171
|
+
* Retrieve a paginated list of program reviews with filtering options
|
|
20172
|
+
* @param org Alias for platform_org
|
|
20173
|
+
* @param page Page number for pagination
|
|
20174
|
+
* @param pageSize Number of items per page
|
|
20175
|
+
* @param platformKey Filter reviews by platform key
|
|
20176
|
+
* @param platformOrg Filter reviews by platform organization
|
|
20177
|
+
* @param programId Filter reviews by program ID
|
|
20178
|
+
* @param sort Field to sort results by (default: '-id')
|
|
20179
|
+
* @param userId Filter reviews by user ID
|
|
20180
|
+
* @returns ProgramReviewPaginatedResponse
|
|
20181
|
+
* @throws ApiError
|
|
20182
|
+
*/
|
|
20183
|
+
static catalogReviewsProgramRetrieve(org, page, pageSize, platformKey, platformOrg, programId, sort = '-id', userId) {
|
|
21577
20184
|
return request(OpenAPI, {
|
|
21578
20185
|
method: 'GET',
|
|
21579
|
-
url: '/api/catalog/reviews/program/'
|
|
20186
|
+
url: '/api/catalog/reviews/program/',
|
|
20187
|
+
query: {
|
|
20188
|
+
'org': org,
|
|
20189
|
+
'page': page,
|
|
20190
|
+
'page_size': pageSize,
|
|
20191
|
+
'platform_key': platformKey,
|
|
20192
|
+
'platform_org': platformOrg,
|
|
20193
|
+
'program_id': programId,
|
|
20194
|
+
'sort': sort,
|
|
20195
|
+
'user_id': userId
|
|
20196
|
+
},
|
|
20197
|
+
errors: {
|
|
20198
|
+
400: `Invalid parameters`,
|
|
20199
|
+
401: `Unauthorized`,
|
|
20200
|
+
403: `Permission denied`,
|
|
20201
|
+
500: `Internal server error`
|
|
20202
|
+
}
|
|
21580
20203
|
});
|
|
21581
20204
|
}
|
|
21582
20205
|
/**
|
|
@@ -21599,117 +20222,48 @@ class CatalogService {
|
|
|
21599
20222
|
});
|
|
21600
20223
|
}
|
|
21601
20224
|
/**
|
|
21602
|
-
*
|
|
21603
|
-
*
|
|
21604
|
-
*
|
|
21605
|
-
*
|
|
21606
|
-
|
|
21607
|
-
|
|
21608
|
-
* DELETE: Delete a program review
|
|
21609
|
-
*
|
|
21610
|
-
* Request Body (POST):
|
|
21611
|
-
* A JSON object containing:
|
|
21612
|
-
* - program_key (str, required): The program key to review (format: program-v1:org+program_id)
|
|
21613
|
-
* - username (str, required): The username of the reviewer
|
|
21614
|
-
* - rating (float, optional): The rating value (typically 1-5)
|
|
21615
|
-
* - title (str, optional): The review title
|
|
21616
|
-
* - content (str, optional): The review content/text
|
|
21617
|
-
* - visible (bool, optional): Whether the review is visible (default: true)
|
|
21618
|
-
*
|
|
21619
|
-
* Query Parameters (DELETE):
|
|
21620
|
-
* program_key (str, required): The program key of the review to delete
|
|
21621
|
-
* username (str, required): The username of the reviewer
|
|
21622
|
-
*
|
|
21623
|
-
* Returns:
|
|
21624
|
-
* POST: A JSON response containing the created/updated review:
|
|
21625
|
-
* {
|
|
21626
|
-
* "user_id": 123,
|
|
21627
|
-
* "username": "student1",
|
|
21628
|
-
* "content": "This program was comprehensive and well-structured.",
|
|
21629
|
-
* "rating": 4.5,
|
|
21630
|
-
* "title": "Excellent Program",
|
|
21631
|
-
* "visible": true,
|
|
21632
|
-
* "created": "2023-01-15T10:30:00Z",
|
|
21633
|
-
* "modified": "2023-01-15T10:30:00Z",
|
|
21634
|
-
* "program_key": "program-v1:org+program123"
|
|
21635
|
-
* }
|
|
21636
|
-
*
|
|
21637
|
-
* DELETE: A success response with status 200
|
|
21638
|
-
*
|
|
21639
|
-
* Error Responses:
|
|
21640
|
-
* 400 Bad Request: If required parameters are missing or invalid
|
|
21641
|
-
* 401 Unauthorized: If the user is not authenticated
|
|
21642
|
-
* 403 Forbidden: If the user does not have permission to manage this review
|
|
21643
|
-
* 500 Internal Server Error: If an unexpected error occurs during review operations
|
|
21644
|
-
*
|
|
21645
|
-
* Access Control:
|
|
21646
|
-
* - Requires IsDMAdmin or IsEdxUserReadWriteDelete permission
|
|
21647
|
-
* - Users can create, update, or delete their own reviews
|
|
21648
|
-
* - DM admins can manage all reviews
|
|
21649
|
-
* @returns any No response body
|
|
21650
|
-
* @throws ApiError
|
|
21651
|
-
*/
|
|
21652
|
-
static catalogReviewsProgramUpdateCreate() {
|
|
20225
|
+
* Create or update a program review
|
|
20226
|
+
* @param requestBody
|
|
20227
|
+
* @returns ProgramReview
|
|
20228
|
+
* @throws ApiError
|
|
20229
|
+
*/
|
|
20230
|
+
static catalogReviewsProgramUpdateCreate(requestBody) {
|
|
21653
20231
|
return request(OpenAPI, {
|
|
21654
20232
|
method: 'POST',
|
|
21655
|
-
url: '/api/catalog/reviews/program/update/'
|
|
20233
|
+
url: '/api/catalog/reviews/program/update/',
|
|
20234
|
+
body: requestBody,
|
|
20235
|
+
mediaType: 'application/json',
|
|
20236
|
+
errors: {
|
|
20237
|
+
400: `Invalid parameters`,
|
|
20238
|
+
401: `Unauthorized`,
|
|
20239
|
+
403: `Permission denied`,
|
|
20240
|
+
500: `Review could not be saved`
|
|
20241
|
+
}
|
|
21656
20242
|
});
|
|
21657
20243
|
}
|
|
21658
20244
|
/**
|
|
21659
|
-
*
|
|
21660
|
-
*
|
|
21661
|
-
*
|
|
21662
|
-
*
|
|
21663
|
-
*
|
|
21664
|
-
*
|
|
21665
|
-
|
|
21666
|
-
|
|
21667
|
-
* Request Body (POST):
|
|
21668
|
-
* A JSON object containing:
|
|
21669
|
-
* - program_key (str, required): The program key to review (format: program-v1:org+program_id)
|
|
21670
|
-
* - username (str, required): The username of the reviewer
|
|
21671
|
-
* - rating (float, optional): The rating value (typically 1-5)
|
|
21672
|
-
* - title (str, optional): The review title
|
|
21673
|
-
* - content (str, optional): The review content/text
|
|
21674
|
-
* - visible (bool, optional): Whether the review is visible (default: true)
|
|
21675
|
-
*
|
|
21676
|
-
* Query Parameters (DELETE):
|
|
21677
|
-
* program_key (str, required): The program key of the review to delete
|
|
21678
|
-
* username (str, required): The username of the reviewer
|
|
21679
|
-
*
|
|
21680
|
-
* Returns:
|
|
21681
|
-
* POST: A JSON response containing the created/updated review:
|
|
21682
|
-
* {
|
|
21683
|
-
* "user_id": 123,
|
|
21684
|
-
* "username": "student1",
|
|
21685
|
-
* "content": "This program was comprehensive and well-structured.",
|
|
21686
|
-
* "rating": 4.5,
|
|
21687
|
-
* "title": "Excellent Program",
|
|
21688
|
-
* "visible": true,
|
|
21689
|
-
* "created": "2023-01-15T10:30:00Z",
|
|
21690
|
-
* "modified": "2023-01-15T10:30:00Z",
|
|
21691
|
-
* "program_key": "program-v1:org+program123"
|
|
21692
|
-
* }
|
|
21693
|
-
*
|
|
21694
|
-
* DELETE: A success response with status 200
|
|
21695
|
-
*
|
|
21696
|
-
* Error Responses:
|
|
21697
|
-
* 400 Bad Request: If required parameters are missing or invalid
|
|
21698
|
-
* 401 Unauthorized: If the user is not authenticated
|
|
21699
|
-
* 403 Forbidden: If the user does not have permission to manage this review
|
|
21700
|
-
* 500 Internal Server Error: If an unexpected error occurs during review operations
|
|
21701
|
-
*
|
|
21702
|
-
* Access Control:
|
|
21703
|
-
* - Requires IsDMAdmin or IsEdxUserReadWriteDelete permission
|
|
21704
|
-
* - Users can create, update, or delete their own reviews
|
|
21705
|
-
* - DM admins can manage all reviews
|
|
21706
|
-
* @returns void
|
|
21707
|
-
* @throws ApiError
|
|
21708
|
-
*/
|
|
21709
|
-
static catalogReviewsProgramUpdateDestroy() {
|
|
20245
|
+
* Delete a program review
|
|
20246
|
+
* @param programKey The program key of the review to delete
|
|
20247
|
+
* @param username The username of the reviewer
|
|
20248
|
+
* @param userId The user ID of the reviewer (alternative to username)
|
|
20249
|
+
* @returns any Review successfully deleted
|
|
20250
|
+
* @throws ApiError
|
|
20251
|
+
*/
|
|
20252
|
+
static catalogReviewsProgramUpdateDestroy(programKey, username, userId) {
|
|
21710
20253
|
return request(OpenAPI, {
|
|
21711
20254
|
method: 'DELETE',
|
|
21712
|
-
url: '/api/catalog/reviews/program/update/'
|
|
20255
|
+
url: '/api/catalog/reviews/program/update/',
|
|
20256
|
+
query: {
|
|
20257
|
+
'program_key': programKey,
|
|
20258
|
+
'user_id': userId,
|
|
20259
|
+
'username': username
|
|
20260
|
+
},
|
|
20261
|
+
errors: {
|
|
20262
|
+
400: `Invalid parameters`,
|
|
20263
|
+
401: `Unauthorized`,
|
|
20264
|
+
403: `Permission denied`,
|
|
20265
|
+
500: `Review could not be deleted`
|
|
20266
|
+
}
|
|
21713
20267
|
});
|
|
21714
20268
|
}
|
|
21715
20269
|
/**
|
|
@@ -21924,7 +20478,7 @@ class CatalogService {
|
|
|
21924
20478
|
* @param platformKey Platform key
|
|
21925
20479
|
* @param slug Skill slug
|
|
21926
20480
|
* @param sort Field to sort results by
|
|
21927
|
-
* @returns
|
|
20481
|
+
* @returns PaginatedSkill
|
|
21928
20482
|
* @throws ApiError
|
|
21929
20483
|
*/
|
|
21930
20484
|
static catalogSkillsRetrieve(id, name, nameIexact, page, pageSize, platformKey, slug, sort = 'id') {
|
|
@@ -21945,6 +20499,7 @@ class CatalogService {
|
|
|
21945
20499
|
}
|
|
21946
20500
|
/**
|
|
21947
20501
|
* Add or update a skill.
|
|
20502
|
+
* @param requestBody
|
|
21948
20503
|
* @param id Skill ID
|
|
21949
20504
|
* @param name Skill name
|
|
21950
20505
|
* @param nameIexact Exact match for skill name (case insensitive)
|
|
@@ -21953,11 +20508,10 @@ class CatalogService {
|
|
|
21953
20508
|
* @param platformKey Platform key
|
|
21954
20509
|
* @param slug Skill slug
|
|
21955
20510
|
* @param sort Field to sort results by
|
|
21956
|
-
* @
|
|
21957
|
-
* @returns Skill
|
|
20511
|
+
* @returns PaginatedSkill
|
|
21958
20512
|
* @throws ApiError
|
|
21959
20513
|
*/
|
|
21960
|
-
static catalogSkillsCreate(id, name, nameIexact, page, pageSize, platformKey, slug, sort = 'id'
|
|
20514
|
+
static catalogSkillsCreate(requestBody, id, name, nameIexact, page, pageSize, platformKey, slug, sort = 'id') {
|
|
21961
20515
|
return request(OpenAPI, {
|
|
21962
20516
|
method: 'POST',
|
|
21963
20517
|
url: '/api/catalog/skills/',
|
|
@@ -33740,5 +32294,5 @@ class UserGroupsService {
|
|
|
33740
32294
|
}
|
|
33741
32295
|
}
|
|
33742
32296
|
|
|
33743
|
-
export { AcceptanceEnum, AccessEnum, AiAccountService, AiAnalyticsService,
|
|
32297
|
+
export { AcceptanceEnum, AccessEnum, AiAccountService, AiAnalyticsService, AiIndexService, AiMarketingService, AiMediaService, AiMentorService, AiPromptService, AlignMentorBubbleEnum, AnalyticsService, ApiError, AudienceService, BlankEnum, CancelError, CancelablePromise, CareerService, CatalogService, CeleryHeartbeatFailStatusEnum, CeleryHeartbeatStatusEnum, ComponentBlockTypeEnum, CoreService, CourseCreationTaskStatusEnum, CredentialsService, DepartmentsService, EngagementService, FeaturesService, FinanceService, GooglePayAccountResponseStatusEnum, GreetingMethodEnum, InstitutionTypeEnum, ItemTypeEnum, KindEnum, MediaResourcesService, MediaTypeEnum, MentorVisibilityEnum, ModeEnum, NotificationBuilderService, NotificationService, NotificationSourceTypeEnum, NotificationStatusEnum, OpenAPI, OrgsService, OverviewService, PerformanceService, PeriodicAgentLogStatusEnum, PerlearnerService, PlatformListStatusEnum, PlatformService, PreviousAgentStatusEnum, ProgramTypeEnum, PromptVisibilityEnum, ProviderAssociationService, ProviderEnum, ProvidersService, ProvisionService, RatingEnum, RecommendationsService, ReportsService, ResourceScrappedDataStatusEnum, RolesService, SearchService, ServiceService, SkillsService, StateEnum, Status6eeEnum, StepStatusEnum, TargetSystemEnum, ThemeEnum, TrainingStatusEnum, TransportEnum, TypeC42Enum, UserGroupsService };
|
|
33744
32298
|
//# sourceMappingURL=index.esm.js.map
|