@stack-spot/portal-network 0.204.1 → 0.205.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +20 -0
- package/dist/api/ai.d.ts +120 -22
- package/dist/api/ai.d.ts.map +1 -1
- package/dist/api/ai.js +80 -26
- package/dist/api/ai.js.map +1 -1
- package/dist/client/ai.d.ts +125 -0
- package/dist/client/ai.d.ts.map +1 -1
- package/dist/client/ai.js +74 -1
- package/dist/client/ai.js.map +1 -1
- package/dist/client/code-shift.d.ts +8 -0
- package/dist/client/code-shift.d.ts.map +1 -1
- package/dist/client/code-shift.js +10 -1
- package/dist/client/code-shift.js.map +1 -1
- package/package.json +1 -1
- package/src/api/ai.ts +192 -36
- package/src/client/ai.ts +56 -0
- package/src/client/code-shift.ts +5 -0
package/src/api/ai.ts
CHANGED
|
@@ -735,6 +735,9 @@ export type ConversationHistoryResponse = {
|
|
|
735
735
|
[key: string]: any;
|
|
736
736
|
} | null;
|
|
737
737
|
updated: string;
|
|
738
|
+
agent_info?: {
|
|
739
|
+
[key: string]: any;
|
|
740
|
+
} | null;
|
|
738
741
|
};
|
|
739
742
|
export type ConversationResponse = {
|
|
740
743
|
id: string;
|
|
@@ -773,8 +776,38 @@ export type DependencyResponse = {
|
|
|
773
776
|
delete_contents?: ContentDependencyResponse[] | null;
|
|
774
777
|
missing_list?: ContentDependencyResponse[] | null;
|
|
775
778
|
};
|
|
779
|
+
export type TokenTypeEnum = "prompt" | "embedding";
|
|
780
|
+
export type AnalyticsTokensDailyUsageResponseSeriesItem = {
|
|
781
|
+
day: number;
|
|
782
|
+
date: string;
|
|
783
|
+
total_tokens: number;
|
|
784
|
+
};
|
|
785
|
+
export type AnalyticsTokensDailyUsageResponse = {
|
|
786
|
+
year: number;
|
|
787
|
+
month: number;
|
|
788
|
+
series: AnalyticsTokensDailyUsageResponseSeriesItem[];
|
|
789
|
+
consumed_tokens: number;
|
|
790
|
+
consumed_tokens_over_last_month?: number | null;
|
|
791
|
+
purchased_token_limit?: number | null;
|
|
792
|
+
purchased_token_limit_over_last_month?: number | null;
|
|
793
|
+
available_tokens?: number | null;
|
|
794
|
+
available_tokens_over_last_month?: number | null;
|
|
795
|
+
limit_consumed?: number | null;
|
|
796
|
+
limit_consumed_over_last_month?: number | null;
|
|
797
|
+
};
|
|
798
|
+
export type AnalyticsTokensRankingUsersResponse = {
|
|
799
|
+
email: string;
|
|
800
|
+
rank: number;
|
|
801
|
+
total_tokens: number;
|
|
802
|
+
total_share: number;
|
|
803
|
+
overage_tokens: number;
|
|
804
|
+
overage_percentage: number;
|
|
805
|
+
};
|
|
806
|
+
export type AnalyticsTokensRankingUsersResponsePaginated = {
|
|
807
|
+
total_pages: number;
|
|
808
|
+
items: AnalyticsTokensRankingUsersResponse[];
|
|
809
|
+
};
|
|
776
810
|
export type SortDirection = "ASC" | "DESC";
|
|
777
|
-
export type FilterMode = "MATCH" | "CONTAINS" | "IN";
|
|
778
811
|
export type ReviewAnswers = {
|
|
779
812
|
id: string;
|
|
780
813
|
memberId: string;
|
|
@@ -838,6 +871,25 @@ export type ChatResponse3 = {
|
|
|
838
871
|
sources: (SourceStackAi | SourceKnowledgeSource | SourceProjectFile3)[];
|
|
839
872
|
message_id: string | null;
|
|
840
873
|
};
|
|
874
|
+
export type QuickCommandListResponseV3 = {
|
|
875
|
+
slug: string;
|
|
876
|
+
name: string;
|
|
877
|
+
"type": QuickCommandTypeRequest;
|
|
878
|
+
description: string;
|
|
879
|
+
studio_id?: string | null;
|
|
880
|
+
preserve_conversation: boolean;
|
|
881
|
+
use_selected_code: boolean;
|
|
882
|
+
return_type?: QuickCommandsReturnType | null;
|
|
883
|
+
creator: string | null;
|
|
884
|
+
visibility_level: string;
|
|
885
|
+
use_only: boolean;
|
|
886
|
+
share_context_between_steps?: boolean;
|
|
887
|
+
id: string;
|
|
888
|
+
};
|
|
889
|
+
export type PaginatedResponseQuickCommandListResponseV3 = {
|
|
890
|
+
total_pages: number;
|
|
891
|
+
items: QuickCommandListResponseV3[];
|
|
892
|
+
};
|
|
841
893
|
/**
|
|
842
894
|
* Metrics
|
|
843
895
|
*/
|
|
@@ -3107,9 +3159,13 @@ export function removeWorkspaceV1QuickCommandsSlugWorkspacesWorkspaceIdRemoveDel
|
|
|
3107
3159
|
/**
|
|
3108
3160
|
* Create Execution
|
|
3109
3161
|
*/
|
|
3110
|
-
export function createExecutionV1QuickCommandsCreateExecutionSlugPost({ slug, conversationId, quickCommandCreateRequest }: {
|
|
3162
|
+
export function createExecutionV1QuickCommandsCreateExecutionSlugPost({ slug, conversationId, authorization, xAccountId, xMemberId, xUsername, quickCommandCreateRequest }: {
|
|
3111
3163
|
slug: string;
|
|
3112
3164
|
conversationId?: string | null;
|
|
3165
|
+
authorization: string;
|
|
3166
|
+
xAccountId?: string | null;
|
|
3167
|
+
xMemberId?: string | null;
|
|
3168
|
+
xUsername?: string | null;
|
|
3113
3169
|
quickCommandCreateRequest?: QuickCommandCreateRequest;
|
|
3114
3170
|
}, opts?: Oazapfts.RequestOpts) {
|
|
3115
3171
|
return oazapfts.ok(oazapfts.fetchJson<{
|
|
@@ -3125,7 +3181,13 @@ export function createExecutionV1QuickCommandsCreateExecutionSlugPost({ slug, co
|
|
|
3125
3181
|
}))}`, oazapfts.json({
|
|
3126
3182
|
...opts,
|
|
3127
3183
|
method: "POST",
|
|
3128
|
-
body: quickCommandCreateRequest
|
|
3184
|
+
body: quickCommandCreateRequest,
|
|
3185
|
+
headers: oazapfts.mergeHeaders(opts?.headers, {
|
|
3186
|
+
authorization,
|
|
3187
|
+
"x-account-id": xAccountId,
|
|
3188
|
+
"x-member-id": xMemberId,
|
|
3189
|
+
"x-username": xUsername
|
|
3190
|
+
})
|
|
3129
3191
|
})));
|
|
3130
3192
|
}
|
|
3131
3193
|
/**
|
|
@@ -3161,8 +3223,12 @@ export function executeV1QuickCommandsExecuteExecutionIdPost({ executionId, auth
|
|
|
3161
3223
|
/**
|
|
3162
3224
|
* Callback
|
|
3163
3225
|
*/
|
|
3164
|
-
export function callbackV1QuickCommandsCallbackExecutionIdGet({ executionId }: {
|
|
3226
|
+
export function callbackV1QuickCommandsCallbackExecutionIdGet({ executionId, authorization, xAccountId, xMemberId, xUsername }: {
|
|
3165
3227
|
executionId: string;
|
|
3228
|
+
authorization: string;
|
|
3229
|
+
xAccountId?: string | null;
|
|
3230
|
+
xMemberId?: string | null;
|
|
3231
|
+
xUsername?: string | null;
|
|
3166
3232
|
}, opts?: Oazapfts.RequestOpts) {
|
|
3167
3233
|
return oazapfts.ok(oazapfts.fetchJson<{
|
|
3168
3234
|
status: 200;
|
|
@@ -3173,7 +3239,13 @@ export function callbackV1QuickCommandsCallbackExecutionIdGet({ executionId }: {
|
|
|
3173
3239
|
status: 422;
|
|
3174
3240
|
data: HttpValidationError;
|
|
3175
3241
|
}>(`/v1/quick-commands/callback/${encodeURIComponent(executionId)}`, {
|
|
3176
|
-
...opts
|
|
3242
|
+
...opts,
|
|
3243
|
+
headers: oazapfts.mergeHeaders(opts?.headers, {
|
|
3244
|
+
authorization,
|
|
3245
|
+
"x-account-id": xAccountId,
|
|
3246
|
+
"x-member-id": xMemberId,
|
|
3247
|
+
"x-username": xUsername
|
|
3248
|
+
})
|
|
3177
3249
|
}));
|
|
3178
3250
|
}
|
|
3179
3251
|
/**
|
|
@@ -3211,9 +3283,13 @@ export function runFetchStepV1QuickCommandsSlugStepsStepSlugFetchRunPost({ slug,
|
|
|
3211
3283
|
/**
|
|
3212
3284
|
* Starts the execution of a step with a user defined script
|
|
3213
3285
|
*/
|
|
3214
|
-
export function startScriptStepV1QuickCommandsSlugStepsStepSlugStartScriptPost({ slug, stepSlug, quickCommandStartScriptRequest }: {
|
|
3286
|
+
export function startScriptStepV1QuickCommandsSlugStepsStepSlugStartScriptPost({ slug, stepSlug, authorization, xAccountId, xMemberId, xUsername, quickCommandStartScriptRequest }: {
|
|
3215
3287
|
slug: string;
|
|
3216
3288
|
stepSlug: string;
|
|
3289
|
+
authorization: string;
|
|
3290
|
+
xAccountId?: string | null;
|
|
3291
|
+
xMemberId?: string | null;
|
|
3292
|
+
xUsername?: string | null;
|
|
3217
3293
|
quickCommandStartScriptRequest: QuickCommandStartScriptRequest;
|
|
3218
3294
|
}, opts?: Oazapfts.RequestOpts) {
|
|
3219
3295
|
return oazapfts.ok(oazapfts.fetchJson<{
|
|
@@ -3227,14 +3303,24 @@ export function startScriptStepV1QuickCommandsSlugStepsStepSlugStartScriptPost({
|
|
|
3227
3303
|
}>(`/v1/quick-commands/${encodeURIComponent(slug)}/steps/${encodeURIComponent(stepSlug)}/start-script`, oazapfts.json({
|
|
3228
3304
|
...opts,
|
|
3229
3305
|
method: "POST",
|
|
3230
|
-
body: quickCommandStartScriptRequest
|
|
3306
|
+
body: quickCommandStartScriptRequest,
|
|
3307
|
+
headers: oazapfts.mergeHeaders(opts?.headers, {
|
|
3308
|
+
authorization,
|
|
3309
|
+
"x-account-id": xAccountId,
|
|
3310
|
+
"x-member-id": xMemberId,
|
|
3311
|
+
"x-username": xUsername
|
|
3312
|
+
})
|
|
3231
3313
|
})));
|
|
3232
3314
|
}
|
|
3233
3315
|
/**
|
|
3234
3316
|
* Get the status of a script execution step
|
|
3235
3317
|
*/
|
|
3236
|
-
export function getScriptExecutionStatusV1QuickCommandsScriptExecutionsScriptExecutionIdGet({ scriptExecutionId }: {
|
|
3318
|
+
export function getScriptExecutionStatusV1QuickCommandsScriptExecutionsScriptExecutionIdGet({ scriptExecutionId, authorization, xAccountId, xMemberId, xUsername }: {
|
|
3237
3319
|
scriptExecutionId: string;
|
|
3320
|
+
authorization: string;
|
|
3321
|
+
xAccountId?: string | null;
|
|
3322
|
+
xMemberId?: string | null;
|
|
3323
|
+
xUsername?: string | null;
|
|
3238
3324
|
}, opts?: Oazapfts.RequestOpts) {
|
|
3239
3325
|
return oazapfts.ok(oazapfts.fetchJson<{
|
|
3240
3326
|
status: 200;
|
|
@@ -3245,7 +3331,13 @@ export function getScriptExecutionStatusV1QuickCommandsScriptExecutionsScriptExe
|
|
|
3245
3331
|
status: 422;
|
|
3246
3332
|
data: HttpValidationError;
|
|
3247
3333
|
}>(`/v1/quick-commands/script-executions/${encodeURIComponent(scriptExecutionId)}`, {
|
|
3248
|
-
...opts
|
|
3334
|
+
...opts,
|
|
3335
|
+
headers: oazapfts.mergeHeaders(opts?.headers, {
|
|
3336
|
+
authorization,
|
|
3337
|
+
"x-account-id": xAccountId,
|
|
3338
|
+
"x-member-id": xMemberId,
|
|
3339
|
+
"x-username": xUsername
|
|
3340
|
+
})
|
|
3249
3341
|
}));
|
|
3250
3342
|
}
|
|
3251
3343
|
/**
|
|
@@ -3534,14 +3626,18 @@ export function getContentDependenciesV1ContentContentTypeContentIdDependenciesG
|
|
|
3534
3626
|
/**
|
|
3535
3627
|
* Tokens Daily Usage
|
|
3536
3628
|
*/
|
|
3537
|
-
export function tokensDailyUsageV1AnalyticsTokensDailyUsageGet({ month, year,
|
|
3629
|
+
export function tokensDailyUsageV1AnalyticsTokensDailyUsageGet({ month, year, tokenType, authorization, xAccountId, xMemberId, xUsername }: {
|
|
3538
3630
|
month: number;
|
|
3539
3631
|
year: number;
|
|
3540
|
-
|
|
3632
|
+
tokenType: TokenTypeEnum;
|
|
3633
|
+
authorization: string;
|
|
3634
|
+
xAccountId?: string | null;
|
|
3635
|
+
xMemberId?: string | null;
|
|
3636
|
+
xUsername?: string | null;
|
|
3541
3637
|
}, opts?: Oazapfts.RequestOpts) {
|
|
3542
3638
|
return oazapfts.ok(oazapfts.fetchJson<{
|
|
3543
3639
|
status: 200;
|
|
3544
|
-
data:
|
|
3640
|
+
data: AnalyticsTokensDailyUsageResponse;
|
|
3545
3641
|
} | {
|
|
3546
3642
|
status: 404;
|
|
3547
3643
|
} | {
|
|
@@ -3550,23 +3646,34 @@ export function tokensDailyUsageV1AnalyticsTokensDailyUsageGet({ month, year, ac
|
|
|
3550
3646
|
}>(`/v1/analytics/tokens/daily-usage${QS.query(QS.explode({
|
|
3551
3647
|
month,
|
|
3552
3648
|
year,
|
|
3553
|
-
|
|
3649
|
+
token_type: tokenType
|
|
3554
3650
|
}))}`, {
|
|
3555
|
-
...opts
|
|
3651
|
+
...opts,
|
|
3652
|
+
headers: oazapfts.mergeHeaders(opts?.headers, {
|
|
3653
|
+
authorization,
|
|
3654
|
+
"x-account-id": xAccountId,
|
|
3655
|
+
"x-member-id": xMemberId,
|
|
3656
|
+
"x-username": xUsername
|
|
3657
|
+
})
|
|
3556
3658
|
}));
|
|
3557
3659
|
}
|
|
3558
3660
|
/**
|
|
3559
3661
|
* Tokens By User
|
|
3560
3662
|
*/
|
|
3561
|
-
export function tokensByUserV1AnalyticsTokensByUserGet({ month, year, page, pageSize }: {
|
|
3663
|
+
export function tokensByUserV1AnalyticsTokensByUserGet({ month, year, tokenType, page, pageSize, authorization, xAccountId, xMemberId, xUsername }: {
|
|
3562
3664
|
month: number;
|
|
3563
3665
|
year: number;
|
|
3666
|
+
tokenType: TokenTypeEnum;
|
|
3564
3667
|
page?: number;
|
|
3565
3668
|
pageSize?: number;
|
|
3669
|
+
authorization: string;
|
|
3670
|
+
xAccountId?: string | null;
|
|
3671
|
+
xMemberId?: string | null;
|
|
3672
|
+
xUsername?: string | null;
|
|
3566
3673
|
}, opts?: Oazapfts.RequestOpts) {
|
|
3567
3674
|
return oazapfts.ok(oazapfts.fetchJson<{
|
|
3568
3675
|
status: 200;
|
|
3569
|
-
data:
|
|
3676
|
+
data: AnalyticsTokensRankingUsersResponsePaginated;
|
|
3570
3677
|
} | {
|
|
3571
3678
|
status: 404;
|
|
3572
3679
|
} | {
|
|
@@ -3575,28 +3682,29 @@ export function tokensByUserV1AnalyticsTokensByUserGet({ month, year, page, page
|
|
|
3575
3682
|
}>(`/v1/analytics/tokens/by-user${QS.query(QS.explode({
|
|
3576
3683
|
month,
|
|
3577
3684
|
year,
|
|
3685
|
+
token_type: tokenType,
|
|
3578
3686
|
page,
|
|
3579
3687
|
page_size: pageSize
|
|
3580
3688
|
}))}`, {
|
|
3581
|
-
...opts
|
|
3689
|
+
...opts,
|
|
3690
|
+
headers: oazapfts.mergeHeaders(opts?.headers, {
|
|
3691
|
+
authorization,
|
|
3692
|
+
"x-account-id": xAccountId,
|
|
3693
|
+
"x-member-id": xMemberId,
|
|
3694
|
+
"x-username": xUsername
|
|
3695
|
+
})
|
|
3582
3696
|
}));
|
|
3583
3697
|
}
|
|
3584
3698
|
/**
|
|
3585
3699
|
* Get Reviews By Resource
|
|
3586
3700
|
*/
|
|
3587
|
-
export function getReviewsByResourceV1ResourcesResourceTypeSlugResourceSlugReviewsGet({ resourceSlug, resourceTypeSlug, size, page, sort, direction,
|
|
3701
|
+
export function getReviewsByResourceV1ResourcesResourceTypeSlugResourceSlugReviewsGet({ resourceSlug, resourceTypeSlug, size, page, sort, direction, authorization, xAccountId, xMemberId, xUsername }: {
|
|
3588
3702
|
resourceSlug: string;
|
|
3589
3703
|
resourceTypeSlug: string;
|
|
3590
3704
|
size?: number | null;
|
|
3591
3705
|
page?: number | null;
|
|
3592
3706
|
sort?: string | null;
|
|
3593
3707
|
direction?: SortDirection | null;
|
|
3594
|
-
search?: string | null;
|
|
3595
|
-
filterMode?: FilterMode | null;
|
|
3596
|
-
filterBy?: string | null;
|
|
3597
|
-
filterValue?: string | null;
|
|
3598
|
-
multiFilterMode?: string | null;
|
|
3599
|
-
filterIn?: string | null;
|
|
3600
3708
|
authorization: string;
|
|
3601
3709
|
xAccountId?: string | null;
|
|
3602
3710
|
xMemberId?: string | null;
|
|
@@ -3614,13 +3722,7 @@ export function getReviewsByResourceV1ResourcesResourceTypeSlugResourceSlugRevie
|
|
|
3614
3722
|
size,
|
|
3615
3723
|
page,
|
|
3616
3724
|
sort,
|
|
3617
|
-
direction
|
|
3618
|
-
search,
|
|
3619
|
-
filterMode,
|
|
3620
|
-
filterBy,
|
|
3621
|
-
filterValue,
|
|
3622
|
-
multiFilterMode,
|
|
3623
|
-
filterIn
|
|
3725
|
+
direction
|
|
3624
3726
|
}))}`, {
|
|
3625
3727
|
...opts,
|
|
3626
3728
|
headers: oazapfts.mergeHeaders(opts?.headers, {
|
|
@@ -3666,7 +3768,9 @@ export function createResourceReviewV1ResourcesResourceTypeSlugResourceSlugRevie
|
|
|
3666
3768
|
/**
|
|
3667
3769
|
* Create Answer For Review
|
|
3668
3770
|
*/
|
|
3669
|
-
export function createAnswerForReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersPost({ reviewId, authorization, xAccountId, xMemberId, xUsername, reviewAnswer }: {
|
|
3771
|
+
export function createAnswerForReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersPost({ resourceSlug, resourceTypeSlug, reviewId, authorization, xAccountId, xMemberId, xUsername, reviewAnswer }: {
|
|
3772
|
+
resourceSlug: string;
|
|
3773
|
+
resourceTypeSlug: string;
|
|
3670
3774
|
reviewId: string;
|
|
3671
3775
|
authorization: string;
|
|
3672
3776
|
xAccountId?: string | null;
|
|
@@ -3697,7 +3801,9 @@ export function createAnswerForReviewV1ResourcesResourceTypeSlugResourceSlugRevi
|
|
|
3697
3801
|
/**
|
|
3698
3802
|
* Update Resource Review
|
|
3699
3803
|
*/
|
|
3700
|
-
export function updateResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdPatch({ reviewId, authorization, xAccountId, xMemberId, xUsername, resourceReviewRequest }: {
|
|
3804
|
+
export function updateResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdPatch({ resourceSlug, resourceTypeSlug, reviewId, authorization, xAccountId, xMemberId, xUsername, resourceReviewRequest }: {
|
|
3805
|
+
resourceSlug: string;
|
|
3806
|
+
resourceTypeSlug: string;
|
|
3701
3807
|
reviewId: string;
|
|
3702
3808
|
authorization: string;
|
|
3703
3809
|
xAccountId?: string | null;
|
|
@@ -3728,7 +3834,9 @@ export function updateResourceReviewV1ResourcesResourceTypeSlugResourceSlugRevie
|
|
|
3728
3834
|
/**
|
|
3729
3835
|
* Delete Resource Review
|
|
3730
3836
|
*/
|
|
3731
|
-
export function deleteResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdDelete({ reviewId, authorization, xAccountId, xMemberId, xUsername }: {
|
|
3837
|
+
export function deleteResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdDelete({ resourceSlug, resourceTypeSlug, reviewId, authorization, xAccountId, xMemberId, xUsername }: {
|
|
3838
|
+
resourceSlug: string;
|
|
3839
|
+
resourceTypeSlug: string;
|
|
3732
3840
|
reviewId: string;
|
|
3733
3841
|
authorization: string;
|
|
3734
3842
|
xAccountId?: string | null;
|
|
@@ -3757,7 +3865,9 @@ export function deleteResourceReviewV1ResourcesResourceTypeSlugResourceSlugRevie
|
|
|
3757
3865
|
/**
|
|
3758
3866
|
* Update Review Comment
|
|
3759
3867
|
*/
|
|
3760
|
-
export function updateReviewCommentV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersAnswerIdPatch({ reviewId, answerId, authorization, xAccountId, xMemberId, xUsername, reviewAnswer }: {
|
|
3868
|
+
export function updateReviewCommentV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersAnswerIdPatch({ resourceSlug, resourceTypeSlug, reviewId, answerId, authorization, xAccountId, xMemberId, xUsername, reviewAnswer }: {
|
|
3869
|
+
resourceSlug: string;
|
|
3870
|
+
resourceTypeSlug: string;
|
|
3761
3871
|
reviewId: string;
|
|
3762
3872
|
answerId: string;
|
|
3763
3873
|
authorization: string;
|
|
@@ -3789,7 +3899,9 @@ export function updateReviewCommentV1ResourcesResourceTypeSlugResourceSlugReview
|
|
|
3789
3899
|
/**
|
|
3790
3900
|
* Delete Review Comment
|
|
3791
3901
|
*/
|
|
3792
|
-
export function deleteReviewCommentV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersAnswerIdDelete({ reviewId, answerId, authorization, xAccountId, xMemberId, xUsername }: {
|
|
3902
|
+
export function deleteReviewCommentV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersAnswerIdDelete({ resourceSlug, resourceTypeSlug, reviewId, answerId, authorization, xAccountId, xMemberId, xUsername }: {
|
|
3903
|
+
resourceSlug: string;
|
|
3904
|
+
resourceTypeSlug: string;
|
|
3793
3905
|
reviewId: string;
|
|
3794
3906
|
answerId: string;
|
|
3795
3907
|
authorization: string;
|
|
@@ -3934,3 +4046,47 @@ export function devAssistantV3V3ChatPost({ authorization, xAccountId, xMemberId,
|
|
|
3934
4046
|
})
|
|
3935
4047
|
})));
|
|
3936
4048
|
}
|
|
4049
|
+
/**
|
|
4050
|
+
* List All
|
|
4051
|
+
*/
|
|
4052
|
+
export function listAllV3QuickCommandsGet({ name, slug, size, page, visibilityList, order, isRemote, types, authorization, xAccountId, xMemberId, xUsername }: {
|
|
4053
|
+
name?: string | null;
|
|
4054
|
+
slug?: string | null;
|
|
4055
|
+
size?: number;
|
|
4056
|
+
page?: number;
|
|
4057
|
+
visibilityList?: VisibilityLevelEnum[] | null;
|
|
4058
|
+
order?: OrderEnum | null;
|
|
4059
|
+
isRemote?: boolean;
|
|
4060
|
+
types?: QuickCommandTypeRequest[] | null;
|
|
4061
|
+
authorization: string;
|
|
4062
|
+
xAccountId?: string | null;
|
|
4063
|
+
xMemberId?: string | null;
|
|
4064
|
+
xUsername?: string | null;
|
|
4065
|
+
}, opts?: Oazapfts.RequestOpts) {
|
|
4066
|
+
return oazapfts.ok(oazapfts.fetchJson<{
|
|
4067
|
+
status: 200;
|
|
4068
|
+
data: PaginatedResponseQuickCommandListResponseV3;
|
|
4069
|
+
} | {
|
|
4070
|
+
status: 404;
|
|
4071
|
+
} | {
|
|
4072
|
+
status: 422;
|
|
4073
|
+
data: HttpValidationError;
|
|
4074
|
+
}>(`/v3/quick-commands${QS.query(QS.explode({
|
|
4075
|
+
name,
|
|
4076
|
+
slug,
|
|
4077
|
+
size,
|
|
4078
|
+
page,
|
|
4079
|
+
visibility_list: visibilityList,
|
|
4080
|
+
order,
|
|
4081
|
+
is_remote: isRemote,
|
|
4082
|
+
types
|
|
4083
|
+
}))}`, {
|
|
4084
|
+
...opts,
|
|
4085
|
+
headers: oazapfts.mergeHeaders(opts?.headers, {
|
|
4086
|
+
authorization,
|
|
4087
|
+
"x-account-id": xAccountId,
|
|
4088
|
+
"x-member-id": xMemberId,
|
|
4089
|
+
"x-username": xUsername
|
|
4090
|
+
})
|
|
4091
|
+
}));
|
|
4092
|
+
}
|
package/src/client/ai.ts
CHANGED
|
@@ -7,13 +7,17 @@ import {
|
|
|
7
7
|
calculateNextStepV1QuickCommandsSlugStepsStepSlugCalculateNextStepPost,
|
|
8
8
|
callbackV1QuickCommandsCallbackExecutionIdGet,
|
|
9
9
|
conversationHistoryV1ConversationsConversationIdGet,
|
|
10
|
+
createAnswerForReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersPost,
|
|
10
11
|
createExecutionV1QuickCommandsCreateExecutionSlugPost,
|
|
12
|
+
createResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsPost,
|
|
11
13
|
currentV1TokensUsageCurrentGet,
|
|
12
14
|
defaults,
|
|
13
15
|
deleteConversationV1ConversationsConversationIdDelete,
|
|
14
16
|
deleteFavoriteV1AiStacksStackIdFavoriteDelete,
|
|
15
17
|
deleteFavoriteV1QuickCommandsSlugFavoriteDelete,
|
|
16
18
|
deleteKnowledgeObjectByCustomIdV1KnowledgeSourcesSlugObjectsCustomIdDelete,
|
|
19
|
+
deleteResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdDelete,
|
|
20
|
+
deleteReviewCommentV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersAnswerIdDelete,
|
|
17
21
|
downloadConversationV1ConversationsConversationIdDownloadGet,
|
|
18
22
|
findKnowledgeObjectByCustomIdV1KnowledgeSourcesSlugObjectsCustomIdGet,
|
|
19
23
|
findKnowledgeSourceV1KnowledgeSourcesSlugGet,
|
|
@@ -23,11 +27,13 @@ import {
|
|
|
23
27
|
getFlagsV1FlagsGet,
|
|
24
28
|
getQuickCommandV1QuickCommandsSlugGet,
|
|
25
29
|
getScriptExecutionStatusV1QuickCommandsScriptExecutionsScriptExecutionIdGet,
|
|
30
|
+
getReviewsByResourceV1ResourcesResourceTypeSlugResourceSlugReviewsGet,
|
|
26
31
|
getUploadFormV1FileUploadFormPost,
|
|
27
32
|
HttpValidationError,
|
|
28
33
|
listAiStacksV1AiStacksGet,
|
|
29
34
|
listAllV1QuickCommandsAllGet,
|
|
30
35
|
listAllV2QuickCommandsAllGet,
|
|
36
|
+
listAllV3QuickCommandsGet,
|
|
31
37
|
listAssociationV1WorkspaceWorkspaceIdGet,
|
|
32
38
|
listConversationsV1ConversationsGet,
|
|
33
39
|
listKnowledgeSourcesV1KnowledgeSourcesGet,
|
|
@@ -42,9 +48,13 @@ import {
|
|
|
42
48
|
startScriptStepV1QuickCommandsSlugStepsStepSlugStartScriptPost,
|
|
43
49
|
totalV1TokensUsageTotalGet,
|
|
44
50
|
updateQuickCommandV1QuickCommandsSlugPatch,
|
|
51
|
+
updateResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdPatch,
|
|
52
|
+
updateReviewCommentV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersAnswerIdPatch,
|
|
45
53
|
updateTitleV1ConversationsConversationIdPatch,
|
|
46
54
|
vectorizeCustomKnowledgeSourceV1KnowledgeSourcesSlugCustomPost,
|
|
47
55
|
} from '../api/ai'
|
|
56
|
+
|
|
57
|
+
|
|
48
58
|
import { StackspotAPIError } from '../error/StackspotAPIError'
|
|
49
59
|
import { ReactQueryNetworkClient } from '../network/ReactQueryNetworkClient'
|
|
50
60
|
import { removeAuthorizationParam } from '../utils/remove-authorization-param'
|
|
@@ -62,6 +72,8 @@ import {
|
|
|
62
72
|
StepChatStep,
|
|
63
73
|
} from './types'
|
|
64
74
|
|
|
75
|
+
const listQAV3WithoutAuthorization = removeAuthorizationParam(listAllV3QuickCommandsGet)
|
|
76
|
+
|
|
65
77
|
class AIClient extends ReactQueryNetworkClient {
|
|
66
78
|
constructor() {
|
|
67
79
|
super(getApiAddresses().ai.url, defaults)
|
|
@@ -127,6 +139,10 @@ class AIClient extends ReactQueryNetworkClient {
|
|
|
127
139
|
* Lists all the quick commands according to filters passed as parameter (including QC with secrets).
|
|
128
140
|
*/
|
|
129
141
|
allQuickCommands = this.query(removeAuthorizationParam(listAllV2QuickCommandsAllGet))
|
|
142
|
+
/**
|
|
143
|
+
* Lists all the quick commands according to filters passed as parameter (including QC with secrets) with pagination.
|
|
144
|
+
*/
|
|
145
|
+
allQuickCommandsV3 = this.infiniteQuery(listQAV3WithoutAuthorization, { accumulator: 'items' })
|
|
130
146
|
/**
|
|
131
147
|
* Gets a quick command by its slug.
|
|
132
148
|
*/
|
|
@@ -273,6 +289,46 @@ class AIClient extends ReactQueryNetworkClient {
|
|
|
273
289
|
*/
|
|
274
290
|
getStatusScriptStep = this.query(removeAuthorizationParam(getScriptExecutionStatusV1QuickCommandsScriptExecutionsScriptExecutionIdGet))
|
|
275
291
|
|
|
292
|
+
/**
|
|
293
|
+
* Get reviews by resource
|
|
294
|
+
*/
|
|
295
|
+
getReviewsByResource = this.query(removeAuthorizationParam(getReviewsByResourceV1ResourcesResourceTypeSlugResourceSlugReviewsGet))
|
|
296
|
+
|
|
297
|
+
/**
|
|
298
|
+
* Create a resource review
|
|
299
|
+
*/
|
|
300
|
+
createResourceReview = this.mutation(removeAuthorizationParam(createResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsPost))
|
|
301
|
+
|
|
302
|
+
/**
|
|
303
|
+
* Create an answer for a review
|
|
304
|
+
*/
|
|
305
|
+
createAnswerForReview = this.mutation(
|
|
306
|
+
removeAuthorizationParam(createAnswerForReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersPost))
|
|
307
|
+
|
|
308
|
+
/**
|
|
309
|
+
* Update a resource review
|
|
310
|
+
*/
|
|
311
|
+
updateResourceReview = this.mutation(
|
|
312
|
+
removeAuthorizationParam(updateResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdPatch))
|
|
313
|
+
|
|
314
|
+
/**
|
|
315
|
+
* Delete a resource review
|
|
316
|
+
*/
|
|
317
|
+
deleteResourceReview = this.mutation(
|
|
318
|
+
removeAuthorizationParam(deleteResourceReviewV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdDelete))
|
|
319
|
+
|
|
320
|
+
/**
|
|
321
|
+
* Update a review comment (answer)
|
|
322
|
+
*/
|
|
323
|
+
updateReviewComment = this.mutation(
|
|
324
|
+
removeAuthorizationParam(updateReviewCommentV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersAnswerIdPatch))
|
|
325
|
+
|
|
326
|
+
/**
|
|
327
|
+
* Delete a review comment (answer)
|
|
328
|
+
*/
|
|
329
|
+
deleteReviewComment = this.mutation(
|
|
330
|
+
removeAuthorizationParam(deleteReviewCommentV1ResourcesResourceTypeSlugResourceSlugReviewsReviewIdAnswersAnswerIdDelete))
|
|
331
|
+
|
|
276
332
|
private static async toolsOfAgent(agentId?: string) {
|
|
277
333
|
try {
|
|
278
334
|
const agent = agentId ? await agentToolsClient.agent.query({ agentId }) : undefined
|
package/src/client/code-shift.ts
CHANGED
|
@@ -75,6 +75,7 @@ import {
|
|
|
75
75
|
createReposBatchServiceV2ReposBatchPost,
|
|
76
76
|
getImportResultV2ReposBatchImportIdGet,
|
|
77
77
|
downloadImportResultV2ReposBatchImportIdDownloadGet,
|
|
78
|
+
deleteModuleServiceV1ModulesModuleIdDelete,
|
|
78
79
|
} from '../api/codeShift'
|
|
79
80
|
import { DefaultAPIError } from '../error/DefaultAPIError'
|
|
80
81
|
import { codeShiftDictionary } from '../error/dictionary/code-shift'
|
|
@@ -144,6 +145,10 @@ class CodeShift extends ReactQueryNetworkClient {
|
|
|
144
145
|
* Gets module by id.
|
|
145
146
|
*/
|
|
146
147
|
module = this.query(removeAuthorizationParam(getModuleV1ModulesModuleIdGet))
|
|
148
|
+
/**
|
|
149
|
+
* Deletes a module by id.
|
|
150
|
+
*/
|
|
151
|
+
deleteModule = this.query(removeAuthorizationParam(deleteModuleServiceV1ModulesModuleIdDelete))
|
|
147
152
|
/**
|
|
148
153
|
* Add a module in favorites.
|
|
149
154
|
*/
|