@vendasta/ai-assistants 0.44.0 → 0.45.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/esm2020/lib/_internal/function.api.service.mjs +16 -2
- package/esm2020/lib/_internal/interfaces/function.interface.mjs +1 -1
- package/esm2020/lib/_internal/interfaces/index.mjs +1 -1
- package/esm2020/lib/_internal/objects/function.mjs +208 -1
- package/esm2020/lib/_internal/objects/index.mjs +3 -3
- package/fesm2015/vendasta-ai-assistants.mjs +300 -80
- package/fesm2015/vendasta-ai-assistants.mjs.map +1 -1
- package/fesm2020/vendasta-ai-assistants.mjs +300 -80
- package/fesm2020/vendasta-ai-assistants.mjs.map +1 -1
- package/lib/_internal/function.api.service.d.ts +5 -2
- package/lib/_internal/interfaces/function.interface.d.ts +33 -0
- package/lib/_internal/interfaces/index.d.ts +2 -2
- package/lib/_internal/objects/function.d.ts +54 -0
- package/lib/_internal/objects/index.d.ts +2 -2
- package/package.json +1 -1
|
@@ -298,6 +298,94 @@ function enumStringToValue$c(enumRef, value) {
|
|
|
298
298
|
}
|
|
299
299
|
return enumRef[value];
|
|
300
300
|
}
|
|
301
|
+
class PagedRequestOptions {
|
|
302
|
+
static fromProto(proto) {
|
|
303
|
+
let m = new PagedRequestOptions();
|
|
304
|
+
m = Object.assign(m, proto);
|
|
305
|
+
if (proto.pageSize) {
|
|
306
|
+
m.pageSize = parseInt(proto.pageSize, 10);
|
|
307
|
+
}
|
|
308
|
+
return m;
|
|
309
|
+
}
|
|
310
|
+
constructor(kwargs) {
|
|
311
|
+
if (!kwargs) {
|
|
312
|
+
return;
|
|
313
|
+
}
|
|
314
|
+
Object.assign(this, kwargs);
|
|
315
|
+
}
|
|
316
|
+
toApiJson() {
|
|
317
|
+
const toReturn = {};
|
|
318
|
+
if (typeof this.cursor !== 'undefined') {
|
|
319
|
+
toReturn['cursor'] = this.cursor;
|
|
320
|
+
}
|
|
321
|
+
if (typeof this.pageSize !== 'undefined') {
|
|
322
|
+
toReturn['pageSize'] = this.pageSize;
|
|
323
|
+
}
|
|
324
|
+
return toReturn;
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
class PagedResponseMetadata {
|
|
328
|
+
static fromProto(proto) {
|
|
329
|
+
let m = new PagedResponseMetadata();
|
|
330
|
+
m = Object.assign(m, proto);
|
|
331
|
+
if (proto.totalResults) {
|
|
332
|
+
m.totalResults = parseInt(proto.totalResults, 10);
|
|
333
|
+
}
|
|
334
|
+
return m;
|
|
335
|
+
}
|
|
336
|
+
constructor(kwargs) {
|
|
337
|
+
if (!kwargs) {
|
|
338
|
+
return;
|
|
339
|
+
}
|
|
340
|
+
Object.assign(this, kwargs);
|
|
341
|
+
}
|
|
342
|
+
toApiJson() {
|
|
343
|
+
const toReturn = {};
|
|
344
|
+
if (typeof this.nextCursor !== 'undefined') {
|
|
345
|
+
toReturn['nextCursor'] = this.nextCursor;
|
|
346
|
+
}
|
|
347
|
+
if (typeof this.hasMore !== 'undefined') {
|
|
348
|
+
toReturn['hasMore'] = this.hasMore;
|
|
349
|
+
}
|
|
350
|
+
if (typeof this.totalResults !== 'undefined') {
|
|
351
|
+
toReturn['totalResults'] = this.totalResults;
|
|
352
|
+
}
|
|
353
|
+
return toReturn;
|
|
354
|
+
}
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
function enumStringToValue$b(enumRef, value) {
|
|
358
|
+
if (typeof value === 'number') {
|
|
359
|
+
return value;
|
|
360
|
+
}
|
|
361
|
+
return enumRef[value];
|
|
362
|
+
}
|
|
363
|
+
class ListMCPsRequestFilters {
|
|
364
|
+
static fromProto(proto) {
|
|
365
|
+
let m = new ListMCPsRequestFilters();
|
|
366
|
+
m = Object.assign(m, proto);
|
|
367
|
+
if (proto.namespaces) {
|
|
368
|
+
m.namespaces = proto.namespaces.map(Namespace.fromProto);
|
|
369
|
+
}
|
|
370
|
+
return m;
|
|
371
|
+
}
|
|
372
|
+
constructor(kwargs) {
|
|
373
|
+
if (!kwargs) {
|
|
374
|
+
return;
|
|
375
|
+
}
|
|
376
|
+
Object.assign(this, kwargs);
|
|
377
|
+
}
|
|
378
|
+
toApiJson() {
|
|
379
|
+
const toReturn = {};
|
|
380
|
+
if (typeof this.namespaces !== 'undefined' && this.namespaces !== null) {
|
|
381
|
+
toReturn['namespaces'] = 'toApiJson' in this.namespaces ? this.namespaces.toApiJson() : this.namespaces;
|
|
382
|
+
}
|
|
383
|
+
if (typeof this.mcpIds !== 'undefined') {
|
|
384
|
+
toReturn['mcpIds'] = this.mcpIds;
|
|
385
|
+
}
|
|
386
|
+
return toReturn;
|
|
387
|
+
}
|
|
388
|
+
}
|
|
301
389
|
class Function {
|
|
302
390
|
static fromProto(proto) {
|
|
303
391
|
let m = new Function();
|
|
@@ -452,7 +540,7 @@ class FunctionParameter {
|
|
|
452
540
|
m.items = FunctionParameter.fromProto(proto.items);
|
|
453
541
|
}
|
|
454
542
|
if (proto.location) {
|
|
455
|
-
m.location = enumStringToValue$
|
|
543
|
+
m.location = enumStringToValue$b(FunctionParameterParameterLocation, proto.location);
|
|
456
544
|
}
|
|
457
545
|
return m;
|
|
458
546
|
}
|
|
@@ -488,6 +576,151 @@ class FunctionParameter {
|
|
|
488
576
|
return toReturn;
|
|
489
577
|
}
|
|
490
578
|
}
|
|
579
|
+
class ListMCPToolsRequest {
|
|
580
|
+
static fromProto(proto) {
|
|
581
|
+
let m = new ListMCPToolsRequest();
|
|
582
|
+
m = Object.assign(m, proto);
|
|
583
|
+
if (proto.namespace) {
|
|
584
|
+
m.namespace = Namespace.fromProto(proto.namespace);
|
|
585
|
+
}
|
|
586
|
+
if (proto.authStrategy) {
|
|
587
|
+
m.authStrategy = FunctionAuthStrategy.fromProto(proto.authStrategy);
|
|
588
|
+
}
|
|
589
|
+
if (proto.headers) {
|
|
590
|
+
m.headers = proto.headers.map(FunctionHeader.fromProto);
|
|
591
|
+
}
|
|
592
|
+
return m;
|
|
593
|
+
}
|
|
594
|
+
constructor(kwargs) {
|
|
595
|
+
if (!kwargs) {
|
|
596
|
+
return;
|
|
597
|
+
}
|
|
598
|
+
Object.assign(this, kwargs);
|
|
599
|
+
}
|
|
600
|
+
toApiJson() {
|
|
601
|
+
const toReturn = {};
|
|
602
|
+
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
603
|
+
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
604
|
+
}
|
|
605
|
+
if (typeof this.url !== 'undefined') {
|
|
606
|
+
toReturn['url'] = this.url;
|
|
607
|
+
}
|
|
608
|
+
if (typeof this.authStrategy !== 'undefined' && this.authStrategy !== null) {
|
|
609
|
+
toReturn['authStrategy'] = 'toApiJson' in this.authStrategy ? this.authStrategy.toApiJson() : this.authStrategy;
|
|
610
|
+
}
|
|
611
|
+
if (typeof this.headers !== 'undefined' && this.headers !== null) {
|
|
612
|
+
toReturn['headers'] = 'toApiJson' in this.headers ? this.headers.toApiJson() : this.headers;
|
|
613
|
+
}
|
|
614
|
+
if (typeof this.mcpId !== 'undefined') {
|
|
615
|
+
toReturn['mcpId'] = this.mcpId;
|
|
616
|
+
}
|
|
617
|
+
return toReturn;
|
|
618
|
+
}
|
|
619
|
+
}
|
|
620
|
+
class ListMCPToolsResponse {
|
|
621
|
+
static fromProto(proto) {
|
|
622
|
+
let m = new ListMCPToolsResponse();
|
|
623
|
+
m = Object.assign(m, proto);
|
|
624
|
+
if (proto.functions) {
|
|
625
|
+
m.functions = proto.functions.map(Function.fromProto);
|
|
626
|
+
}
|
|
627
|
+
return m;
|
|
628
|
+
}
|
|
629
|
+
constructor(kwargs) {
|
|
630
|
+
if (!kwargs) {
|
|
631
|
+
return;
|
|
632
|
+
}
|
|
633
|
+
Object.assign(this, kwargs);
|
|
634
|
+
}
|
|
635
|
+
toApiJson() {
|
|
636
|
+
const toReturn = {};
|
|
637
|
+
if (typeof this.functions !== 'undefined' && this.functions !== null) {
|
|
638
|
+
toReturn['functions'] = 'toApiJson' in this.functions ? this.functions.toApiJson() : this.functions;
|
|
639
|
+
}
|
|
640
|
+
return toReturn;
|
|
641
|
+
}
|
|
642
|
+
}
|
|
643
|
+
class ListMCPsRequest {
|
|
644
|
+
static fromProto(proto) {
|
|
645
|
+
let m = new ListMCPsRequest();
|
|
646
|
+
m = Object.assign(m, proto);
|
|
647
|
+
if (proto.filters) {
|
|
648
|
+
m.filters = ListMCPsRequestFilters.fromProto(proto.filters);
|
|
649
|
+
}
|
|
650
|
+
if (proto.pagingOptions) {
|
|
651
|
+
m.pagingOptions = PagedRequestOptions.fromProto(proto.pagingOptions);
|
|
652
|
+
}
|
|
653
|
+
return m;
|
|
654
|
+
}
|
|
655
|
+
constructor(kwargs) {
|
|
656
|
+
if (!kwargs) {
|
|
657
|
+
return;
|
|
658
|
+
}
|
|
659
|
+
Object.assign(this, kwargs);
|
|
660
|
+
}
|
|
661
|
+
toApiJson() {
|
|
662
|
+
const toReturn = {};
|
|
663
|
+
if (typeof this.filters !== 'undefined' && this.filters !== null) {
|
|
664
|
+
toReturn['filters'] = 'toApiJson' in this.filters ? this.filters.toApiJson() : this.filters;
|
|
665
|
+
}
|
|
666
|
+
if (typeof this.pagingOptions !== 'undefined' && this.pagingOptions !== null) {
|
|
667
|
+
toReturn['pagingOptions'] = 'toApiJson' in this.pagingOptions ? this.pagingOptions.toApiJson() : this.pagingOptions;
|
|
668
|
+
}
|
|
669
|
+
return toReturn;
|
|
670
|
+
}
|
|
671
|
+
}
|
|
672
|
+
class ListMCPsResponse {
|
|
673
|
+
static fromProto(proto) {
|
|
674
|
+
let m = new ListMCPsResponse();
|
|
675
|
+
m = Object.assign(m, proto);
|
|
676
|
+
if (proto.mcps) {
|
|
677
|
+
m.mcps = proto.mcps.map(MCP.fromProto);
|
|
678
|
+
}
|
|
679
|
+
if (proto.pagingMetadata) {
|
|
680
|
+
m.pagingMetadata = PagedResponseMetadata.fromProto(proto.pagingMetadata);
|
|
681
|
+
}
|
|
682
|
+
return m;
|
|
683
|
+
}
|
|
684
|
+
constructor(kwargs) {
|
|
685
|
+
if (!kwargs) {
|
|
686
|
+
return;
|
|
687
|
+
}
|
|
688
|
+
Object.assign(this, kwargs);
|
|
689
|
+
}
|
|
690
|
+
toApiJson() {
|
|
691
|
+
const toReturn = {};
|
|
692
|
+
if (typeof this.mcps !== 'undefined' && this.mcps !== null) {
|
|
693
|
+
toReturn['mcps'] = 'toApiJson' in this.mcps ? this.mcps.toApiJson() : this.mcps;
|
|
694
|
+
}
|
|
695
|
+
if (typeof this.pagingMetadata !== 'undefined' && this.pagingMetadata !== null) {
|
|
696
|
+
toReturn['pagingMetadata'] = 'toApiJson' in this.pagingMetadata ? this.pagingMetadata.toApiJson() : this.pagingMetadata;
|
|
697
|
+
}
|
|
698
|
+
return toReturn;
|
|
699
|
+
}
|
|
700
|
+
}
|
|
701
|
+
class MCP {
|
|
702
|
+
static fromProto(proto) {
|
|
703
|
+
let m = new MCP();
|
|
704
|
+
m = Object.assign(m, proto);
|
|
705
|
+
return m;
|
|
706
|
+
}
|
|
707
|
+
constructor(kwargs) {
|
|
708
|
+
if (!kwargs) {
|
|
709
|
+
return;
|
|
710
|
+
}
|
|
711
|
+
Object.assign(this, kwargs);
|
|
712
|
+
}
|
|
713
|
+
toApiJson() {
|
|
714
|
+
const toReturn = {};
|
|
715
|
+
if (typeof this.id !== 'undefined') {
|
|
716
|
+
toReturn['id'] = this.id;
|
|
717
|
+
}
|
|
718
|
+
if (typeof this.url !== 'undefined') {
|
|
719
|
+
toReturn['url'] = this.url;
|
|
720
|
+
}
|
|
721
|
+
return toReturn;
|
|
722
|
+
}
|
|
723
|
+
}
|
|
491
724
|
class FunctionAuthStrategyPlatformManagedFunctionAuthStrategy {
|
|
492
725
|
static fromProto(proto) {
|
|
493
726
|
let m = new FunctionAuthStrategyPlatformManagedFunctionAuthStrategy();
|
|
@@ -525,8 +758,43 @@ class FunctionAuthStrategyUnspecifiedFunctionAuthStrategy {
|
|
|
525
758
|
return toReturn;
|
|
526
759
|
}
|
|
527
760
|
}
|
|
761
|
+
class UpsertMCPRequest {
|
|
762
|
+
static fromProto(proto) {
|
|
763
|
+
let m = new UpsertMCPRequest();
|
|
764
|
+
m = Object.assign(m, proto);
|
|
765
|
+
if (proto.namespace) {
|
|
766
|
+
m.namespace = Namespace.fromProto(proto.namespace);
|
|
767
|
+
}
|
|
768
|
+
if (proto.functions) {
|
|
769
|
+
m.functions = proto.functions.map(Function.fromProto);
|
|
770
|
+
}
|
|
771
|
+
return m;
|
|
772
|
+
}
|
|
773
|
+
constructor(kwargs) {
|
|
774
|
+
if (!kwargs) {
|
|
775
|
+
return;
|
|
776
|
+
}
|
|
777
|
+
Object.assign(this, kwargs);
|
|
778
|
+
}
|
|
779
|
+
toApiJson() {
|
|
780
|
+
const toReturn = {};
|
|
781
|
+
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
782
|
+
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
783
|
+
}
|
|
784
|
+
if (typeof this.url !== 'undefined') {
|
|
785
|
+
toReturn['url'] = this.url;
|
|
786
|
+
}
|
|
787
|
+
if (typeof this.mcpId !== 'undefined') {
|
|
788
|
+
toReturn['mcpId'] = this.mcpId;
|
|
789
|
+
}
|
|
790
|
+
if (typeof this.functions !== 'undefined' && this.functions !== null) {
|
|
791
|
+
toReturn['functions'] = 'toApiJson' in this.functions ? this.functions.toApiJson() : this.functions;
|
|
792
|
+
}
|
|
793
|
+
return toReturn;
|
|
794
|
+
}
|
|
795
|
+
}
|
|
528
796
|
|
|
529
|
-
function enumStringToValue$
|
|
797
|
+
function enumStringToValue$a(enumRef, value) {
|
|
530
798
|
if (typeof value === 'number') {
|
|
531
799
|
return value;
|
|
532
800
|
}
|
|
@@ -729,7 +997,7 @@ class PromptVersion {
|
|
|
729
997
|
}
|
|
730
998
|
}
|
|
731
999
|
|
|
732
|
-
function enumStringToValue$
|
|
1000
|
+
function enumStringToValue$9(enumRef, value) {
|
|
733
1001
|
if (typeof value === 'number') {
|
|
734
1002
|
return value;
|
|
735
1003
|
}
|
|
@@ -743,7 +1011,7 @@ class Goal {
|
|
|
743
1011
|
m.namespace = Namespace.fromProto(proto.namespace);
|
|
744
1012
|
}
|
|
745
1013
|
if (proto.type) {
|
|
746
|
-
m.type = enumStringToValue$
|
|
1014
|
+
m.type = enumStringToValue$9(GoalType, proto.type);
|
|
747
1015
|
}
|
|
748
1016
|
if (proto.promptModules) {
|
|
749
1017
|
m.promptModules = proto.promptModules.map(PromptModule.fromProto);
|
|
@@ -755,7 +1023,7 @@ class Goal {
|
|
|
755
1023
|
m.updated = new Date(proto.updated);
|
|
756
1024
|
}
|
|
757
1025
|
if (proto.supportedChannels) {
|
|
758
|
-
m.supportedChannels = proto.supportedChannels.map((v) => enumStringToValue$
|
|
1026
|
+
m.supportedChannels = proto.supportedChannels.map((v) => enumStringToValue$9(GoalChannel, v));
|
|
759
1027
|
}
|
|
760
1028
|
if (proto.overrideOf) {
|
|
761
1029
|
m.overrideOf = GoalKey.fromProto(proto.overrideOf);
|
|
@@ -836,7 +1104,7 @@ class GoalKey {
|
|
|
836
1104
|
}
|
|
837
1105
|
}
|
|
838
1106
|
|
|
839
|
-
function enumStringToValue$
|
|
1107
|
+
function enumStringToValue$8(enumRef, value) {
|
|
840
1108
|
if (typeof value === 'number') {
|
|
841
1109
|
return value;
|
|
842
1110
|
}
|
|
@@ -866,7 +1134,7 @@ class KeyValuePair {
|
|
|
866
1134
|
}
|
|
867
1135
|
}
|
|
868
1136
|
|
|
869
|
-
function enumStringToValue$
|
|
1137
|
+
function enumStringToValue$7(enumRef, value) {
|
|
870
1138
|
if (typeof value === 'number') {
|
|
871
1139
|
return value;
|
|
872
1140
|
}
|
|
@@ -877,10 +1145,10 @@ class Model {
|
|
|
877
1145
|
let m = new Model();
|
|
878
1146
|
m = Object.assign(m, proto);
|
|
879
1147
|
if (proto.vendor) {
|
|
880
|
-
m.vendor = enumStringToValue$
|
|
1148
|
+
m.vendor = enumStringToValue$7(ModelVendor, proto.vendor);
|
|
881
1149
|
}
|
|
882
1150
|
if (proto.type) {
|
|
883
|
-
m.type = enumStringToValue$
|
|
1151
|
+
m.type = enumStringToValue$7(ModelType, proto.type);
|
|
884
1152
|
}
|
|
885
1153
|
return m;
|
|
886
1154
|
}
|
|
@@ -911,7 +1179,7 @@ class Model {
|
|
|
911
1179
|
}
|
|
912
1180
|
}
|
|
913
1181
|
|
|
914
|
-
function enumStringToValue$
|
|
1182
|
+
function enumStringToValue$6(enumRef, value) {
|
|
915
1183
|
if (typeof value === 'number') {
|
|
916
1184
|
return value;
|
|
917
1185
|
}
|
|
@@ -925,7 +1193,7 @@ class Assistant {
|
|
|
925
1193
|
m.namespace = Namespace.fromProto(proto.namespace);
|
|
926
1194
|
}
|
|
927
1195
|
if (proto.type) {
|
|
928
|
-
m.type = enumStringToValue$
|
|
1196
|
+
m.type = enumStringToValue$6(AssistantType, proto.type);
|
|
929
1197
|
}
|
|
930
1198
|
if (proto.config) {
|
|
931
1199
|
m.config = Config.fromProto(proto.config);
|
|
@@ -1215,7 +1483,7 @@ class ConfigVoiceConfig {
|
|
|
1215
1483
|
let m = new ConfigVoiceConfig();
|
|
1216
1484
|
m = Object.assign(m, proto);
|
|
1217
1485
|
if (proto.vendorModel) {
|
|
1218
|
-
m.vendorModel = enumStringToValue$
|
|
1486
|
+
m.vendorModel = enumStringToValue$6(VendorModel, proto.vendorModel);
|
|
1219
1487
|
}
|
|
1220
1488
|
if (proto.modelConfig) {
|
|
1221
1489
|
m.modelConfig = ModelConfig.fromProto(proto.modelConfig);
|
|
@@ -1240,7 +1508,7 @@ class ConfigVoiceConfig {
|
|
|
1240
1508
|
}
|
|
1241
1509
|
}
|
|
1242
1510
|
|
|
1243
|
-
function enumStringToValue$
|
|
1511
|
+
function enumStringToValue$5(enumRef, value) {
|
|
1244
1512
|
if (typeof value === 'number') {
|
|
1245
1513
|
return value;
|
|
1246
1514
|
}
|
|
@@ -1257,7 +1525,7 @@ class Connection {
|
|
|
1257
1525
|
m.assistantKeys = proto.assistantKeys.map(AssistantKey.fromProto);
|
|
1258
1526
|
}
|
|
1259
1527
|
if (proto.supportedAssistantTypes) {
|
|
1260
|
-
m.supportedAssistantTypes = proto.supportedAssistantTypes.map((v) => enumStringToValue$
|
|
1528
|
+
m.supportedAssistantTypes = proto.supportedAssistantTypes.map((v) => enumStringToValue$5(AssistantType, v));
|
|
1261
1529
|
}
|
|
1262
1530
|
return m;
|
|
1263
1531
|
}
|
|
@@ -1332,7 +1600,7 @@ class ConnectionKey {
|
|
|
1332
1600
|
}
|
|
1333
1601
|
}
|
|
1334
1602
|
|
|
1335
|
-
function enumStringToValue$
|
|
1603
|
+
function enumStringToValue$4(enumRef, value) {
|
|
1336
1604
|
if (typeof value === 'number') {
|
|
1337
1605
|
return value;
|
|
1338
1606
|
}
|
|
@@ -1343,7 +1611,7 @@ class ChatAnswerFunctionExecutionJob {
|
|
|
1343
1611
|
let m = new ChatAnswerFunctionExecutionJob();
|
|
1344
1612
|
m = Object.assign(m, proto);
|
|
1345
1613
|
if (proto.status) {
|
|
1346
|
-
m.status = enumStringToValue$
|
|
1614
|
+
m.status = enumStringToValue$4(ChatAnswerFunctionExecutionJobStatus, proto.status);
|
|
1347
1615
|
}
|
|
1348
1616
|
if (proto.result) {
|
|
1349
1617
|
m.result = ChatAnswerFunctionExecutionJobResult.fromProto(proto.result);
|
|
@@ -1404,7 +1672,7 @@ class ChatMessage {
|
|
|
1404
1672
|
let m = new ChatMessage();
|
|
1405
1673
|
m = Object.assign(m, proto);
|
|
1406
1674
|
if (proto.role) {
|
|
1407
|
-
m.role = enumStringToValue$
|
|
1675
|
+
m.role = enumStringToValue$4(ChatMessageRole, proto.role);
|
|
1408
1676
|
}
|
|
1409
1677
|
return m;
|
|
1410
1678
|
}
|
|
@@ -1496,68 +1764,6 @@ class ContextInfo {
|
|
|
1496
1764
|
}
|
|
1497
1765
|
}
|
|
1498
1766
|
|
|
1499
|
-
function enumStringToValue$4(enumRef, value) {
|
|
1500
|
-
if (typeof value === 'number') {
|
|
1501
|
-
return value;
|
|
1502
|
-
}
|
|
1503
|
-
return enumRef[value];
|
|
1504
|
-
}
|
|
1505
|
-
class PagedRequestOptions {
|
|
1506
|
-
static fromProto(proto) {
|
|
1507
|
-
let m = new PagedRequestOptions();
|
|
1508
|
-
m = Object.assign(m, proto);
|
|
1509
|
-
if (proto.pageSize) {
|
|
1510
|
-
m.pageSize = parseInt(proto.pageSize, 10);
|
|
1511
|
-
}
|
|
1512
|
-
return m;
|
|
1513
|
-
}
|
|
1514
|
-
constructor(kwargs) {
|
|
1515
|
-
if (!kwargs) {
|
|
1516
|
-
return;
|
|
1517
|
-
}
|
|
1518
|
-
Object.assign(this, kwargs);
|
|
1519
|
-
}
|
|
1520
|
-
toApiJson() {
|
|
1521
|
-
const toReturn = {};
|
|
1522
|
-
if (typeof this.cursor !== 'undefined') {
|
|
1523
|
-
toReturn['cursor'] = this.cursor;
|
|
1524
|
-
}
|
|
1525
|
-
if (typeof this.pageSize !== 'undefined') {
|
|
1526
|
-
toReturn['pageSize'] = this.pageSize;
|
|
1527
|
-
}
|
|
1528
|
-
return toReturn;
|
|
1529
|
-
}
|
|
1530
|
-
}
|
|
1531
|
-
class PagedResponseMetadata {
|
|
1532
|
-
static fromProto(proto) {
|
|
1533
|
-
let m = new PagedResponseMetadata();
|
|
1534
|
-
m = Object.assign(m, proto);
|
|
1535
|
-
if (proto.totalResults) {
|
|
1536
|
-
m.totalResults = parseInt(proto.totalResults, 10);
|
|
1537
|
-
}
|
|
1538
|
-
return m;
|
|
1539
|
-
}
|
|
1540
|
-
constructor(kwargs) {
|
|
1541
|
-
if (!kwargs) {
|
|
1542
|
-
return;
|
|
1543
|
-
}
|
|
1544
|
-
Object.assign(this, kwargs);
|
|
1545
|
-
}
|
|
1546
|
-
toApiJson() {
|
|
1547
|
-
const toReturn = {};
|
|
1548
|
-
if (typeof this.nextCursor !== 'undefined') {
|
|
1549
|
-
toReturn['nextCursor'] = this.nextCursor;
|
|
1550
|
-
}
|
|
1551
|
-
if (typeof this.hasMore !== 'undefined') {
|
|
1552
|
-
toReturn['hasMore'] = this.hasMore;
|
|
1553
|
-
}
|
|
1554
|
-
if (typeof this.totalResults !== 'undefined') {
|
|
1555
|
-
toReturn['totalResults'] = this.totalResults;
|
|
1556
|
-
}
|
|
1557
|
-
return toReturn;
|
|
1558
|
-
}
|
|
1559
|
-
}
|
|
1560
|
-
|
|
1561
1767
|
function enumStringToValue$3(enumRef, value) {
|
|
1562
1768
|
if (typeof value === 'number') {
|
|
1563
1769
|
return value;
|
|
@@ -4945,6 +5151,20 @@ class FunctionApiService {
|
|
|
4945
5151
|
const request = (r.toApiJson) ? r : new DeleteFunctionRequest(r);
|
|
4946
5152
|
return this.http.post(this._host + "/ai_assistants.v1alpha1.FunctionService/Delete", request.toApiJson(), Object.assign(Object.assign({}, this.apiOptions()), { observe: 'response' }));
|
|
4947
5153
|
}
|
|
5154
|
+
listMcpTools(r) {
|
|
5155
|
+
const request = (r.toApiJson) ? r : new ListMCPToolsRequest(r);
|
|
5156
|
+
return this.http.post(this._host + "/ai_assistants.v1alpha1.FunctionService/ListMCPTools", request.toApiJson(), this.apiOptions())
|
|
5157
|
+
.pipe(map(resp => ListMCPToolsResponse.fromProto(resp)));
|
|
5158
|
+
}
|
|
5159
|
+
upsertMcp(r) {
|
|
5160
|
+
const request = (r.toApiJson) ? r : new UpsertMCPRequest(r);
|
|
5161
|
+
return this.http.post(this._host + "/ai_assistants.v1alpha1.FunctionService/UpsertMCP", request.toApiJson(), Object.assign(Object.assign({}, this.apiOptions()), { observe: 'response' }));
|
|
5162
|
+
}
|
|
5163
|
+
listMcPs(r) {
|
|
5164
|
+
const request = (r.toApiJson) ? r : new ListMCPsRequest(r);
|
|
5165
|
+
return this.http.post(this._host + "/ai_assistants.v1alpha1.FunctionService/ListMCPs", request.toApiJson(), this.apiOptions())
|
|
5166
|
+
.pipe(map(resp => ListMCPsResponse.fromProto(resp)));
|
|
5167
|
+
}
|
|
4948
5168
|
}
|
|
4949
5169
|
FunctionApiService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: FunctionApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
4950
5170
|
FunctionApiService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: FunctionApiService, providedIn: 'root' });
|
|
@@ -5247,5 +5467,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
5247
5467
|
* Generated bundle index. Do not edit.
|
|
5248
5468
|
*/
|
|
5249
5469
|
|
|
5250
|
-
export { Access, Assistant, AssistantApiService, AssistantKey, AssistantType, BuildDefaultAssistantRequest, BuildDefaultAssistantResponse, CancelTestRunRequest, ChatAnswerFunctionExecutionJob, ChatAnswerFunctionExecutionJobResult, ChatAnswerFunctionExecutionJobStatus, ChatChannel, ChatMessage, ChatMessageRole, ChatUserInfo, Config, ConfigInboxConfig, ConfigVoiceConfig, ConfigurableGoal, Connection, ConnectionApiService, ConnectionKey, ContextInfo, CreateAssistantRequest, CreateAssistantRequestOptions, CreateAssistantResponse, CreateGoalRequest, CreateGoalResponse, CreatePromptModuleRequest, CreatePromptModuleResponse, CreatePromptModuleVersionRequest, CreatePromptModuleVersionRequestOptions, CreatePromptRequest, DeepgramConfig, DeleteAssistantRequest, DeleteConnectionRequest, DeleteFunctionRequest, DeleteGoalRequest, DeletePromptModuleRequest, DeletePromptRequest, DeleteTestCasesRequest, DeployPromptModuleRequest, DeployPromptRequest, ElevenLabsConfig, ExecuteFunctionRequest, ExecuteFunctionResponse, FieldMask, Function, FunctionApiService, FunctionAuthStrategy, FunctionAuthStrategyPlatformManagedFunctionAuthStrategy, FunctionAuthStrategyUnspecifiedFunctionAuthStrategy, FunctionHeader, FunctionKey, FunctionParameter, FunctionParameterParameterLocation, GenerateChatAnswerRequest, GenerateChatAnswerRequestOptions, GenerateChatAnswerResponse, GetAssistantRequest, GetAssistantRequestOptions, GetAssistantResponse, GetChatAnswerFunctionExecutionJobRequest, GetChatAnswerFunctionExecutionJobResponse, GetConnectionRequest, GetConnectionResponse, GetDeployedPromptModuleVersionRequest, GetDeployedPromptModuleVersionResponse, GetDeployedPromptVersionRequest, GetDeployedPromptVersionResponse, GetFunctionRequest, GetFunctionResponse, GetGoalRequest, GetGoalResponse, GetHydratedDeployedPromptModuleVersionRequest, GetHydratedDeployedPromptModuleVersionResponse, GetMultiDeployedPromptVersionRequest, GetMultiDeployedPromptVersionResponse, GetMultiFunctionRequest, GetMultiFunctionResponse, GetMultiGoalRequest, GetMultiGoalResponse, GetMultiHydratedDeployedPromptModuleVersionRequest, GetMultiHydratedDeployedPromptModuleVersionResponse, GetPromptModuleRequest, GetPromptModuleResponse, GetPromptModuleVersionRequest, GetPromptModuleVersionResponse, GetPromptRequest, GetPromptResponse, GetPromptVersionRequest, GetPromptVersionResponse, GetTestRunRequest, GetTestRunResponse, Goal, GoalApiService, GoalChannel, GoalKey, GoalType, GoalsDisabledForAccountGroupRequest, GoalsDisabledForAccountGroupResponse, HostService, IntegrationTestApiService, KeyValuePair, ListAllAssistantsAssociatedToConnectionRequest, ListAllAssistantsAssociatedToConnectionRequestFilters, ListAllAssistantsAssociatedToConnectionResponse, ListAssistantRequest, ListAssistantRequestFilters, ListAssistantResponse, ListAvailableModelsRequest, ListAvailableModelsRequestFilters, ListAvailableModelsResponse, ListConnectionsRequest, ListConnectionsRequestFilters, ListConnectionsResponse, ListFunctionRequest, ListFunctionRequestFilters, ListFunctionResponse, ListGoalsRequest, ListGoalsRequestFilters, ListGoalsResponse, ListPromptModuleRequest, ListPromptModuleRequestFilters, ListPromptModuleResponse, ListPromptModuleVersionsRequest, ListPromptModuleVersionsResponse, ListPromptRequest, ListPromptResponse, ListPromptVersionsRequest, ListPromptVersionsResponse, ListTestCasesByAssistantRequest, ListTestCasesByAssistantResponse, ListTestRunsByAssistantRequest, ListTestRunsByAssistantResponse, MCPOptions, Model, ModelConfig, ModelType, ModelVendor, Namespace, NamespaceAccountGroupNamespace, NamespaceGlobalNamespace, NamespacePartnerNamespace, NamespaceSystemNamespace, OpenAIRealtimeConfig, OpenAIRealtimeConfigTurnDetection, PagedRequestOptions, PagedResponseMetadata, Prompt, PromptApiService, PromptModule, PromptModuleApiService, PromptModuleKey, PromptModuleVersion, PromptVersion, RunTestsRequest, RunTestsResponse, SetAssistantConnectionsRequest, SetAssistantConnectionsRequestConnectionState, SortDirection, SortOptions, TestCase, TestResult, TestResultCitation, TestRun, UpdateAssistantRequest, UpdateGoalRequest, UpdatePromptModuleRequest, UpdatePromptRequest, UpsertAssistantRequest, UpsertAssistantRequestOptions, UpsertAssistantResponse, UpsertConnectionRequest, UpsertFunctionRequest, UpsertGoalRequest, UpsertTestCasesRequest, VendorModel };
|
|
5470
|
+
export { Access, Assistant, AssistantApiService, AssistantKey, AssistantType, BuildDefaultAssistantRequest, BuildDefaultAssistantResponse, CancelTestRunRequest, ChatAnswerFunctionExecutionJob, ChatAnswerFunctionExecutionJobResult, ChatAnswerFunctionExecutionJobStatus, ChatChannel, ChatMessage, ChatMessageRole, ChatUserInfo, Config, ConfigInboxConfig, ConfigVoiceConfig, ConfigurableGoal, Connection, ConnectionApiService, ConnectionKey, ContextInfo, CreateAssistantRequest, CreateAssistantRequestOptions, CreateAssistantResponse, CreateGoalRequest, CreateGoalResponse, CreatePromptModuleRequest, CreatePromptModuleResponse, CreatePromptModuleVersionRequest, CreatePromptModuleVersionRequestOptions, CreatePromptRequest, DeepgramConfig, DeleteAssistantRequest, DeleteConnectionRequest, DeleteFunctionRequest, DeleteGoalRequest, DeletePromptModuleRequest, DeletePromptRequest, DeleteTestCasesRequest, DeployPromptModuleRequest, DeployPromptRequest, ElevenLabsConfig, ExecuteFunctionRequest, ExecuteFunctionResponse, FieldMask, Function, FunctionApiService, FunctionAuthStrategy, FunctionAuthStrategyPlatformManagedFunctionAuthStrategy, FunctionAuthStrategyUnspecifiedFunctionAuthStrategy, FunctionHeader, FunctionKey, FunctionParameter, FunctionParameterParameterLocation, GenerateChatAnswerRequest, GenerateChatAnswerRequestOptions, GenerateChatAnswerResponse, GetAssistantRequest, GetAssistantRequestOptions, GetAssistantResponse, GetChatAnswerFunctionExecutionJobRequest, GetChatAnswerFunctionExecutionJobResponse, GetConnectionRequest, GetConnectionResponse, GetDeployedPromptModuleVersionRequest, GetDeployedPromptModuleVersionResponse, GetDeployedPromptVersionRequest, GetDeployedPromptVersionResponse, GetFunctionRequest, GetFunctionResponse, GetGoalRequest, GetGoalResponse, GetHydratedDeployedPromptModuleVersionRequest, GetHydratedDeployedPromptModuleVersionResponse, GetMultiDeployedPromptVersionRequest, GetMultiDeployedPromptVersionResponse, GetMultiFunctionRequest, GetMultiFunctionResponse, GetMultiGoalRequest, GetMultiGoalResponse, GetMultiHydratedDeployedPromptModuleVersionRequest, GetMultiHydratedDeployedPromptModuleVersionResponse, GetPromptModuleRequest, GetPromptModuleResponse, GetPromptModuleVersionRequest, GetPromptModuleVersionResponse, GetPromptRequest, GetPromptResponse, GetPromptVersionRequest, GetPromptVersionResponse, GetTestRunRequest, GetTestRunResponse, Goal, GoalApiService, GoalChannel, GoalKey, GoalType, GoalsDisabledForAccountGroupRequest, GoalsDisabledForAccountGroupResponse, HostService, IntegrationTestApiService, KeyValuePair, ListAllAssistantsAssociatedToConnectionRequest, ListAllAssistantsAssociatedToConnectionRequestFilters, ListAllAssistantsAssociatedToConnectionResponse, ListAssistantRequest, ListAssistantRequestFilters, ListAssistantResponse, ListAvailableModelsRequest, ListAvailableModelsRequestFilters, ListAvailableModelsResponse, ListConnectionsRequest, ListConnectionsRequestFilters, ListConnectionsResponse, ListFunctionRequest, ListFunctionRequestFilters, ListFunctionResponse, ListGoalsRequest, ListGoalsRequestFilters, ListGoalsResponse, ListMCPToolsRequest, ListMCPToolsResponse, ListMCPsRequest, ListMCPsRequestFilters, ListMCPsResponse, ListPromptModuleRequest, ListPromptModuleRequestFilters, ListPromptModuleResponse, ListPromptModuleVersionsRequest, ListPromptModuleVersionsResponse, ListPromptRequest, ListPromptResponse, ListPromptVersionsRequest, ListPromptVersionsResponse, ListTestCasesByAssistantRequest, ListTestCasesByAssistantResponse, ListTestRunsByAssistantRequest, ListTestRunsByAssistantResponse, MCP, MCPOptions, Model, ModelConfig, ModelType, ModelVendor, Namespace, NamespaceAccountGroupNamespace, NamespaceGlobalNamespace, NamespacePartnerNamespace, NamespaceSystemNamespace, OpenAIRealtimeConfig, OpenAIRealtimeConfigTurnDetection, PagedRequestOptions, PagedResponseMetadata, Prompt, PromptApiService, PromptModule, PromptModuleApiService, PromptModuleKey, PromptModuleVersion, PromptVersion, RunTestsRequest, RunTestsResponse, SetAssistantConnectionsRequest, SetAssistantConnectionsRequestConnectionState, SortDirection, SortOptions, TestCase, TestResult, TestResultCitation, TestRun, UpdateAssistantRequest, UpdateGoalRequest, UpdatePromptModuleRequest, UpdatePromptRequest, UpsertAssistantRequest, UpsertAssistantRequestOptions, UpsertAssistantResponse, UpsertConnectionRequest, UpsertFunctionRequest, UpsertGoalRequest, UpsertMCPRequest, UpsertTestCasesRequest, VendorModel };
|
|
5251
5471
|
//# sourceMappingURL=vendasta-ai-assistants.mjs.map
|