@vendasta/ai-assistants 0.47.1 → 0.49.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/esm2020/lib/_internal/enums/assistant-type.enum.mjs +18 -0
  2. package/esm2020/lib/_internal/enums/assistant.enum.mjs +1 -12
  3. package/esm2020/lib/_internal/enums/constraints.enum.mjs +19 -0
  4. package/esm2020/lib/_internal/enums/index.mjs +5 -2
  5. package/esm2020/lib/_internal/enums/namespace.enum.mjs +15 -0
  6. package/esm2020/lib/_internal/function.api.service.mjs +6 -2
  7. package/esm2020/lib/_internal/interfaces/api.interface.mjs +1 -1
  8. package/esm2020/lib/_internal/interfaces/constraints.interface.mjs +8 -0
  9. package/esm2020/lib/_internal/interfaces/function.interface.mjs +1 -1
  10. package/esm2020/lib/_internal/interfaces/goal.interface.mjs +1 -1
  11. package/esm2020/lib/_internal/interfaces/index.mjs +1 -1
  12. package/esm2020/lib/_internal/objects/api.mjs +126 -70
  13. package/esm2020/lib/_internal/objects/constraints.mjs +101 -0
  14. package/esm2020/lib/_internal/objects/function.mjs +63 -1
  15. package/esm2020/lib/_internal/objects/goal.mjs +8 -1
  16. package/esm2020/lib/_internal/objects/index.mjs +4 -3
  17. package/esm2020/lib/_internal/prompt-module.api.service.mjs +7 -2
  18. package/fesm2015/vendasta-ai-assistants.mjs +354 -82
  19. package/fesm2015/vendasta-ai-assistants.mjs.map +1 -1
  20. package/fesm2020/vendasta-ai-assistants.mjs +354 -82
  21. package/fesm2020/vendasta-ai-assistants.mjs.map +1 -1
  22. package/lib/_internal/enums/assistant-type.enum.d.ts +10 -0
  23. package/lib/_internal/enums/assistant.enum.d.ts +0 -10
  24. package/lib/_internal/enums/constraints.enum.d.ts +10 -0
  25. package/lib/_internal/enums/index.d.ts +4 -1
  26. package/lib/_internal/enums/namespace.enum.d.ts +7 -0
  27. package/lib/_internal/function.api.service.d.ts +3 -2
  28. package/lib/_internal/interfaces/api.interface.d.ts +29 -19
  29. package/lib/_internal/interfaces/constraints.interface.d.ts +14 -0
  30. package/lib/_internal/interfaces/function.interface.d.ts +11 -0
  31. package/lib/_internal/interfaces/goal.interface.d.ts +2 -0
  32. package/lib/_internal/interfaces/index.d.ts +3 -2
  33. package/lib/_internal/objects/api.d.ts +52 -36
  34. package/lib/_internal/objects/constraints.d.ts +25 -0
  35. package/lib/_internal/objects/function.d.ts +17 -0
  36. package/lib/_internal/objects/goal.d.ts +2 -0
  37. package/lib/_internal/objects/index.d.ts +3 -2
  38. package/lib/_internal/prompt-module.api.service.d.ts +3 -2
  39. package/package.json +1 -1
@@ -27,6 +27,58 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
27
27
  args: [{ providedIn: 'root' }]
28
28
  }] });
29
29
 
30
+ // *********************************
31
+ // Code generated by sdkgen
32
+ // DO NOT EDIT!.
33
+ //
34
+ // Enums.
35
+ // *********************************
36
+ var NamespaceType;
37
+ (function (NamespaceType) {
38
+ NamespaceType[NamespaceType["NAMESPACE_TYPE_UNSPECIFIED"] = 0] = "NAMESPACE_TYPE_UNSPECIFIED";
39
+ NamespaceType[NamespaceType["NAMESPACE_TYPE_ACCOUNT_GROUP"] = 1] = "NAMESPACE_TYPE_ACCOUNT_GROUP";
40
+ NamespaceType[NamespaceType["NAMESPACE_TYPE_PARTNER"] = 2] = "NAMESPACE_TYPE_PARTNER";
41
+ NamespaceType[NamespaceType["NAMESPACE_TYPE_SYSTEM"] = 3] = "NAMESPACE_TYPE_SYSTEM";
42
+ NamespaceType[NamespaceType["NAMESPACE_TYPE_GLOBAL"] = 4] = "NAMESPACE_TYPE_GLOBAL";
43
+ })(NamespaceType || (NamespaceType = {}));
44
+
45
+ // *********************************
46
+ // Code generated by sdkgen
47
+ // DO NOT EDIT!.
48
+ //
49
+ // Enums.
50
+ // *********************************
51
+ var AssistantType;
52
+ (function (AssistantType) {
53
+ AssistantType[AssistantType["ASSISTANT_TYPE_UNSPECIFIED"] = 0] = "ASSISTANT_TYPE_UNSPECIFIED";
54
+ AssistantType[AssistantType["ASSISTANT_TYPE_SYSTEM"] = 1] = "ASSISTANT_TYPE_SYSTEM";
55
+ AssistantType[AssistantType["ASSISTANT_TYPE_INBOX"] = 2] = "ASSISTANT_TYPE_INBOX";
56
+ AssistantType[AssistantType["ASSISTANT_TYPE_SOCIAL_MARKETING"] = 3] = "ASSISTANT_TYPE_SOCIAL_MARKETING";
57
+ AssistantType[AssistantType["ASSISTANT_TYPE_VOICE_RECEPTIONIST"] = 4] = "ASSISTANT_TYPE_VOICE_RECEPTIONIST";
58
+ AssistantType[AssistantType["ASSISTANT_TYPE_CUSTOM"] = 5] = "ASSISTANT_TYPE_CUSTOM";
59
+ AssistantType[AssistantType["ASSISTANT_TYPE_SALES_COACH"] = 6] = "ASSISTANT_TYPE_SALES_COACH";
60
+ AssistantType[AssistantType["ASSISTANT_TYPE_REPUTATION_MANAGEMENT_REVIEW_AGENT"] = 7] = "ASSISTANT_TYPE_REPUTATION_MANAGEMENT_REVIEW_AGENT";
61
+ })(AssistantType || (AssistantType = {}));
62
+
63
+ // *********************************
64
+ // Code generated by sdkgen
65
+ // DO NOT EDIT!.
66
+ //
67
+ // Enums.
68
+ // *********************************
69
+ var Action;
70
+ (function (Action) {
71
+ Action[Action["ACTION_UNSPECIFIED"] = 0] = "ACTION_UNSPECIFIED";
72
+ Action[Action["ACTION_ASSIGN"] = 1] = "ACTION_ASSIGN";
73
+ Action[Action["ACTION_VIEW"] = 2] = "ACTION_VIEW";
74
+ })(Action || (Action = {}));
75
+ var Effect;
76
+ (function (Effect) {
77
+ Effect[Effect["EFFECT_UNSPECIFIED"] = 0] = "EFFECT_UNSPECIFIED";
78
+ Effect[Effect["EFFECT_ALLOW"] = 1] = "EFFECT_ALLOW";
79
+ Effect[Effect["EFFECT_DENY"] = 2] = "EFFECT_DENY";
80
+ })(Effect || (Effect = {}));
81
+
30
82
  // *********************************
31
83
  // Code generated by sdkgen
32
84
  // DO NOT EDIT!.
@@ -98,17 +150,6 @@ var ModelVendor;
98
150
  //
99
151
  // Enums.
100
152
  // *********************************
101
- var AssistantType;
102
- (function (AssistantType) {
103
- AssistantType[AssistantType["ASSISTANT_TYPE_UNSPECIFIED"] = 0] = "ASSISTANT_TYPE_UNSPECIFIED";
104
- AssistantType[AssistantType["ASSISTANT_TYPE_SYSTEM"] = 1] = "ASSISTANT_TYPE_SYSTEM";
105
- AssistantType[AssistantType["ASSISTANT_TYPE_INBOX"] = 2] = "ASSISTANT_TYPE_INBOX";
106
- AssistantType[AssistantType["ASSISTANT_TYPE_SOCIAL_MARKETING"] = 3] = "ASSISTANT_TYPE_SOCIAL_MARKETING";
107
- AssistantType[AssistantType["ASSISTANT_TYPE_VOICE_RECEPTIONIST"] = 4] = "ASSISTANT_TYPE_VOICE_RECEPTIONIST";
108
- AssistantType[AssistantType["ASSISTANT_TYPE_CUSTOM"] = 5] = "ASSISTANT_TYPE_CUSTOM";
109
- AssistantType[AssistantType["ASSISTANT_TYPE_SALES_COACH"] = 6] = "ASSISTANT_TYPE_SALES_COACH";
110
- AssistantType[AssistantType["ASSISTANT_TYPE_REPUTATION_MANAGEMENT_REVIEW_AGENT"] = 7] = "ASSISTANT_TYPE_REPUTATION_MANAGEMENT_REVIEW_AGENT";
111
- })(AssistantType || (AssistantType = {}));
112
153
  var VendorModel;
113
154
  (function (VendorModel) {
114
155
  VendorModel[VendorModel["VENDOR_MODEL_UNSPECIFIED"] = 0] = "VENDOR_MODEL_UNSPECIFIED";
@@ -170,7 +211,7 @@ var SortDirection;
170
211
  // Enums Index.
171
212
  // *********************************
172
213
 
173
- function enumStringToValue$d(enumRef, value) {
214
+ function enumStringToValue$e(enumRef, value) {
174
215
  if (typeof value === 'number') {
175
216
  return value;
176
217
  }
@@ -292,6 +333,106 @@ class NamespaceSystemNamespace {
292
333
  }
293
334
  }
294
335
 
336
+ function enumStringToValue$d(enumRef, value) {
337
+ if (typeof value === 'number') {
338
+ return value;
339
+ }
340
+ return enumRef[value];
341
+ }
342
+ class Constraint {
343
+ static fromProto(proto) {
344
+ let m = new Constraint();
345
+ m = Object.assign(m, proto);
346
+ if (proto.action) {
347
+ m.action = enumStringToValue$d(Action, proto.action);
348
+ }
349
+ if (proto.scope) {
350
+ m.scope = Scope.fromProto(proto.scope);
351
+ }
352
+ if (proto.effect) {
353
+ m.effect = enumStringToValue$d(Effect, proto.effect);
354
+ }
355
+ return m;
356
+ }
357
+ constructor(kwargs) {
358
+ if (!kwargs) {
359
+ return;
360
+ }
361
+ Object.assign(this, kwargs);
362
+ }
363
+ toApiJson() {
364
+ const toReturn = {};
365
+ if (typeof this.action !== 'undefined') {
366
+ toReturn['action'] = this.action;
367
+ }
368
+ if (typeof this.scope !== 'undefined' && this.scope !== null) {
369
+ toReturn['scope'] = 'toApiJson' in this.scope ? this.scope.toApiJson() : this.scope;
370
+ }
371
+ if (typeof this.effect !== 'undefined') {
372
+ toReturn['effect'] = this.effect;
373
+ }
374
+ return toReturn;
375
+ }
376
+ }
377
+ class ConstraintFilter {
378
+ static fromProto(proto) {
379
+ let m = new ConstraintFilter();
380
+ m = Object.assign(m, proto);
381
+ if (proto.action) {
382
+ m.action = enumStringToValue$d(Action, proto.action);
383
+ }
384
+ if (proto.scope) {
385
+ m.scope = Scope.fromProto(proto.scope);
386
+ }
387
+ return m;
388
+ }
389
+ constructor(kwargs) {
390
+ if (!kwargs) {
391
+ return;
392
+ }
393
+ Object.assign(this, kwargs);
394
+ }
395
+ toApiJson() {
396
+ const toReturn = {};
397
+ if (typeof this.action !== 'undefined') {
398
+ toReturn['action'] = this.action;
399
+ }
400
+ if (typeof this.scope !== 'undefined' && this.scope !== null) {
401
+ toReturn['scope'] = 'toApiJson' in this.scope ? this.scope.toApiJson() : this.scope;
402
+ }
403
+ return toReturn;
404
+ }
405
+ }
406
+ class Scope {
407
+ static fromProto(proto) {
408
+ let m = new Scope();
409
+ m = Object.assign(m, proto);
410
+ if (proto.assistantNamespaceType) {
411
+ m.assistantNamespaceType = enumStringToValue$d(NamespaceType, proto.assistantNamespaceType);
412
+ }
413
+ if (proto.assistantType) {
414
+ m.assistantType = enumStringToValue$d(AssistantType, proto.assistantType);
415
+ }
416
+ return m;
417
+ }
418
+ constructor(kwargs) {
419
+ if (!kwargs) {
420
+ return;
421
+ }
422
+ Object.assign(this, kwargs);
423
+ }
424
+ toApiJson() {
425
+ const toReturn = {};
426
+ if (typeof this.assistantNamespaceType !== 'undefined') {
427
+ toReturn['assistantNamespaceType'] = this.assistantNamespaceType;
428
+ }
429
+ if (typeof this.assistantType !== 'undefined') {
430
+ toReturn['assistantType'] = this.assistantType;
431
+ }
432
+ return toReturn;
433
+ }
434
+ }
435
+
295
436
  function enumStringToValue$c(enumRef, value) {
296
437
  if (typeof value === 'number') {
297
438
  return value;
@@ -360,6 +501,55 @@ function enumStringToValue$b(enumRef, value) {
360
501
  }
361
502
  return enumRef[value];
362
503
  }
504
+ class FunctionAuthStrategyConnectedIntegrationAuthStrategy {
505
+ static fromProto(proto) {
506
+ let m = new FunctionAuthStrategyConnectedIntegrationAuthStrategy();
507
+ m = Object.assign(m, proto);
508
+ return m;
509
+ }
510
+ constructor(kwargs) {
511
+ if (!kwargs) {
512
+ return;
513
+ }
514
+ Object.assign(this, kwargs);
515
+ }
516
+ toApiJson() {
517
+ const toReturn = {};
518
+ if (typeof this.connectionId !== 'undefined') {
519
+ toReturn['connectionId'] = this.connectionId;
520
+ }
521
+ return toReturn;
522
+ }
523
+ }
524
+ class CreateMCPFromIntegrationRequest {
525
+ static fromProto(proto) {
526
+ let m = new CreateMCPFromIntegrationRequest();
527
+ m = Object.assign(m, proto);
528
+ if (proto.namespace) {
529
+ m.namespace = Namespace.fromProto(proto.namespace);
530
+ }
531
+ return m;
532
+ }
533
+ constructor(kwargs) {
534
+ if (!kwargs) {
535
+ return;
536
+ }
537
+ Object.assign(this, kwargs);
538
+ }
539
+ toApiJson() {
540
+ const toReturn = {};
541
+ if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
542
+ toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
543
+ }
544
+ if (typeof this.mcpId !== 'undefined') {
545
+ toReturn['mcpId'] = this.mcpId;
546
+ }
547
+ if (typeof this.connectionId !== 'undefined') {
548
+ toReturn['connectionId'] = this.connectionId;
549
+ }
550
+ return toReturn;
551
+ }
552
+ }
363
553
  class DeleteMCPRequest {
364
554
  static fromProto(proto) {
365
555
  let m = new DeleteMCPRequest();
@@ -431,6 +621,9 @@ class Function {
431
621
  if (proto.authStrategy) {
432
622
  m.authStrategy = FunctionAuthStrategy.fromProto(proto.authStrategy);
433
623
  }
624
+ if (proto.constraints) {
625
+ m.constraints = proto.constraints.map(Constraint.fromProto);
626
+ }
434
627
  return m;
435
628
  }
436
629
  constructor(kwargs) {
@@ -477,6 +670,9 @@ class Function {
477
670
  if (typeof this.mcpId !== 'undefined') {
478
671
  toReturn['mcpId'] = this.mcpId;
479
672
  }
673
+ if (typeof this.constraints !== 'undefined' && this.constraints !== null) {
674
+ toReturn['constraints'] = 'toApiJson' in this.constraints ? this.constraints.toApiJson() : this.constraints;
675
+ }
480
676
  return toReturn;
481
677
  }
482
678
  }
@@ -490,6 +686,9 @@ class FunctionAuthStrategy {
490
686
  if (proto.platformManaged) {
491
687
  m.platformManaged = FunctionAuthStrategyPlatformManagedFunctionAuthStrategy.fromProto(proto.platformManaged);
492
688
  }
689
+ if (proto.connectedIntegration) {
690
+ m.connectedIntegration = FunctionAuthStrategyConnectedIntegrationAuthStrategy.fromProto(proto.connectedIntegration);
691
+ }
493
692
  return m;
494
693
  }
495
694
  constructor(kwargs) {
@@ -506,6 +705,9 @@ class FunctionAuthStrategy {
506
705
  if (typeof this.platformManaged !== 'undefined' && this.platformManaged !== null) {
507
706
  toReturn['platformManaged'] = 'toApiJson' in this.platformManaged ? this.platformManaged.toApiJson() : this.platformManaged;
508
707
  }
708
+ if (typeof this.connectedIntegration !== 'undefined' && this.connectedIntegration !== null) {
709
+ toReturn['connectedIntegration'] = 'toApiJson' in this.connectedIntegration ? this.connectedIntegration.toApiJson() : this.connectedIntegration;
710
+ }
509
711
  return toReturn;
510
712
  }
511
713
  }
@@ -1078,6 +1280,9 @@ class Goal {
1078
1280
  if (proto.overrideOf) {
1079
1281
  m.overrideOf = GoalKey.fromProto(proto.overrideOf);
1080
1282
  }
1283
+ if (proto.constraints) {
1284
+ m.constraints = proto.constraints.map(Constraint.fromProto);
1285
+ }
1081
1286
  return m;
1082
1287
  }
1083
1288
  constructor(kwargs) {
@@ -1124,6 +1329,9 @@ class Goal {
1124
1329
  if (typeof this.overrideOf !== 'undefined' && this.overrideOf !== null) {
1125
1330
  toReturn['overrideOf'] = 'toApiJson' in this.overrideOf ? this.overrideOf.toApiJson() : this.overrideOf;
1126
1331
  }
1332
+ if (typeof this.constraints !== 'undefined' && this.constraints !== null) {
1333
+ toReturn['constraints'] = 'toApiJson' in this.constraints ? this.constraints.toApiJson() : this.constraints;
1334
+ }
1127
1335
  return toReturn;
1128
1336
  }
1129
1337
  }
@@ -3008,47 +3216,12 @@ class ExecuteFunctionResponse {
3008
3216
  return toReturn;
3009
3217
  }
3010
3218
  }
3011
- class ListFunctionRequestFilters {
3012
- static fromProto(proto) {
3013
- let m = new ListFunctionRequestFilters();
3014
- m = Object.assign(m, proto);
3015
- if (proto.namespace) {
3016
- m.namespace = Namespace.fromProto(proto.namespace);
3017
- }
3018
- if (proto.namespaces) {
3019
- m.namespaces = proto.namespaces.map(Namespace.fromProto);
3020
- }
3021
- return m;
3022
- }
3023
- constructor(kwargs) {
3024
- if (!kwargs) {
3025
- return;
3026
- }
3027
- Object.assign(this, kwargs);
3028
- }
3029
- toApiJson() {
3030
- const toReturn = {};
3031
- if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
3032
- toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
3033
- }
3034
- if (typeof this.namespaces !== 'undefined' && this.namespaces !== null) {
3035
- toReturn['namespaces'] = 'toApiJson' in this.namespaces ? this.namespaces.toApiJson() : this.namespaces;
3036
- }
3037
- if (typeof this.mcpId !== 'undefined') {
3038
- toReturn['mcpId'] = this.mcpId;
3039
- }
3040
- return toReturn;
3041
- }
3042
- }
3043
- class ListAvailableModelsRequestFilters {
3219
+ class ListAllAssistantsAssociatedToConnectionRequestFilters {
3044
3220
  static fromProto(proto) {
3045
- let m = new ListAvailableModelsRequestFilters();
3221
+ let m = new ListAllAssistantsAssociatedToConnectionRequestFilters();
3046
3222
  m = Object.assign(m, proto);
3047
- if (proto.vendor) {
3048
- m.vendor = proto.vendor.map((v) => enumStringToValue(ModelVendor, v));
3049
- }
3050
3223
  if (proto.type) {
3051
- m.type = proto.type.map((v) => enumStringToValue(ModelType, v));
3224
+ m.type = enumStringToValue(AssistantType, proto.type);
3052
3225
  }
3053
3226
  return m;
3054
3227
  }
@@ -3060,9 +3233,6 @@ class ListAvailableModelsRequestFilters {
3060
3233
  }
3061
3234
  toApiJson() {
3062
3235
  const toReturn = {};
3063
- if (typeof this.vendor !== 'undefined') {
3064
- toReturn['vendor'] = this.vendor;
3065
- }
3066
3236
  if (typeof this.type !== 'undefined') {
3067
3237
  toReturn['type'] = this.type;
3068
3238
  }
@@ -3137,6 +3307,9 @@ class ListGoalsRequestFilters {
3137
3307
  if (proto.namespaces) {
3138
3308
  m.namespaces = proto.namespaces.map(Namespace.fromProto);
3139
3309
  }
3310
+ if (proto.constraintFilters) {
3311
+ m.constraintFilters = proto.constraintFilters.map(ConstraintFilter.fromProto);
3312
+ }
3140
3313
  return m;
3141
3314
  }
3142
3315
  constructor(kwargs) {
@@ -3159,15 +3332,21 @@ class ListGoalsRequestFilters {
3159
3332
  if (typeof this.namespaces !== 'undefined' && this.namespaces !== null) {
3160
3333
  toReturn['namespaces'] = 'toApiJson' in this.namespaces ? this.namespaces.toApiJson() : this.namespaces;
3161
3334
  }
3335
+ if (typeof this.constraintFilters !== 'undefined' && this.constraintFilters !== null) {
3336
+ toReturn['constraintFilters'] = 'toApiJson' in this.constraintFilters ? this.constraintFilters.toApiJson() : this.constraintFilters;
3337
+ }
3162
3338
  return toReturn;
3163
3339
  }
3164
3340
  }
3165
- class ListAllAssistantsAssociatedToConnectionRequestFilters {
3341
+ class ListAvailableModelsRequestFilters {
3166
3342
  static fromProto(proto) {
3167
- let m = new ListAllAssistantsAssociatedToConnectionRequestFilters();
3343
+ let m = new ListAvailableModelsRequestFilters();
3168
3344
  m = Object.assign(m, proto);
3345
+ if (proto.vendor) {
3346
+ m.vendor = proto.vendor.map((v) => enumStringToValue(ModelVendor, v));
3347
+ }
3169
3348
  if (proto.type) {
3170
- m.type = enumStringToValue(AssistantType, proto.type);
3349
+ m.type = proto.type.map((v) => enumStringToValue(ModelType, v));
3171
3350
  }
3172
3351
  return m;
3173
3352
  }
@@ -3179,12 +3358,53 @@ class ListAllAssistantsAssociatedToConnectionRequestFilters {
3179
3358
  }
3180
3359
  toApiJson() {
3181
3360
  const toReturn = {};
3361
+ if (typeof this.vendor !== 'undefined') {
3362
+ toReturn['vendor'] = this.vendor;
3363
+ }
3182
3364
  if (typeof this.type !== 'undefined') {
3183
3365
  toReturn['type'] = this.type;
3184
3366
  }
3185
3367
  return toReturn;
3186
3368
  }
3187
3369
  }
3370
+ class ListFunctionRequestFilters {
3371
+ static fromProto(proto) {
3372
+ let m = new ListFunctionRequestFilters();
3373
+ m = Object.assign(m, proto);
3374
+ if (proto.namespace) {
3375
+ m.namespace = Namespace.fromProto(proto.namespace);
3376
+ }
3377
+ if (proto.namespaces) {
3378
+ m.namespaces = proto.namespaces.map(Namespace.fromProto);
3379
+ }
3380
+ if (proto.constraintFilters) {
3381
+ m.constraintFilters = proto.constraintFilters.map(ConstraintFilter.fromProto);
3382
+ }
3383
+ return m;
3384
+ }
3385
+ constructor(kwargs) {
3386
+ if (!kwargs) {
3387
+ return;
3388
+ }
3389
+ Object.assign(this, kwargs);
3390
+ }
3391
+ toApiJson() {
3392
+ const toReturn = {};
3393
+ if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
3394
+ toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
3395
+ }
3396
+ if (typeof this.namespaces !== 'undefined' && this.namespaces !== null) {
3397
+ toReturn['namespaces'] = 'toApiJson' in this.namespaces ? this.namespaces.toApiJson() : this.namespaces;
3398
+ }
3399
+ if (typeof this.mcpId !== 'undefined') {
3400
+ toReturn['mcpId'] = this.mcpId;
3401
+ }
3402
+ if (typeof this.constraintFilters !== 'undefined' && this.constraintFilters !== null) {
3403
+ toReturn['constraintFilters'] = 'toApiJson' in this.constraintFilters ? this.constraintFilters.toApiJson() : this.constraintFilters;
3404
+ }
3405
+ return toReturn;
3406
+ }
3407
+ }
3188
3408
  class ListAssistantRequestFilters {
3189
3409
  static fromProto(proto) {
3190
3410
  let m = new ListAssistantRequestFilters();
@@ -4758,13 +4978,10 @@ class ListPromptVersionsResponse {
4758
4978
  return toReturn;
4759
4979
  }
4760
4980
  }
4761
- class GenerateChatAnswerRequestOptions {
4981
+ class CreatePromptModuleVersionRequestOptions {
4762
4982
  static fromProto(proto) {
4763
- let m = new GenerateChatAnswerRequestOptions();
4983
+ let m = new CreatePromptModuleVersionRequestOptions();
4764
4984
  m = Object.assign(m, proto);
4765
- if (proto.maxTokens) {
4766
- m.maxTokens = parseInt(proto.maxTokens, 10);
4767
- }
4768
4985
  return m;
4769
4986
  }
4770
4987
  constructor(kwargs) {
@@ -4775,21 +4992,15 @@ class GenerateChatAnswerRequestOptions {
4775
4992
  }
4776
4993
  toApiJson() {
4777
4994
  const toReturn = {};
4778
- if (typeof this.includeAllCitations !== 'undefined') {
4779
- toReturn['includeAllCitations'] = this.includeAllCitations;
4780
- }
4781
- if (typeof this.enableAsyncFunctions !== 'undefined') {
4782
- toReturn['enableAsyncFunctions'] = this.enableAsyncFunctions;
4783
- }
4784
- if (typeof this.maxTokens !== 'undefined') {
4785
- toReturn['maxTokens'] = this.maxTokens;
4995
+ if (typeof this.shouldDeploy !== 'undefined') {
4996
+ toReturn['shouldDeploy'] = this.shouldDeploy;
4786
4997
  }
4787
4998
  return toReturn;
4788
4999
  }
4789
5000
  }
4790
- class GetMultiAssistantRequestOptions {
5001
+ class GetAssistantRequestOptions {
4791
5002
  static fromProto(proto) {
4792
- let m = new GetMultiAssistantRequestOptions();
5003
+ let m = new GetAssistantRequestOptions();
4793
5004
  m = Object.assign(m, proto);
4794
5005
  return m;
4795
5006
  }
@@ -4807,10 +5018,13 @@ class GetMultiAssistantRequestOptions {
4807
5018
  return toReturn;
4808
5019
  }
4809
5020
  }
4810
- class CreatePromptModuleVersionRequestOptions {
5021
+ class GenerateChatAnswerRequestOptions {
4811
5022
  static fromProto(proto) {
4812
- let m = new CreatePromptModuleVersionRequestOptions();
5023
+ let m = new GenerateChatAnswerRequestOptions();
4813
5024
  m = Object.assign(m, proto);
5025
+ if (proto.maxTokens) {
5026
+ m.maxTokens = parseInt(proto.maxTokens, 10);
5027
+ }
4814
5028
  return m;
4815
5029
  }
4816
5030
  constructor(kwargs) {
@@ -4821,15 +5035,21 @@ class CreatePromptModuleVersionRequestOptions {
4821
5035
  }
4822
5036
  toApiJson() {
4823
5037
  const toReturn = {};
4824
- if (typeof this.shouldDeploy !== 'undefined') {
4825
- toReturn['shouldDeploy'] = this.shouldDeploy;
5038
+ if (typeof this.includeAllCitations !== 'undefined') {
5039
+ toReturn['includeAllCitations'] = this.includeAllCitations;
5040
+ }
5041
+ if (typeof this.enableAsyncFunctions !== 'undefined') {
5042
+ toReturn['enableAsyncFunctions'] = this.enableAsyncFunctions;
5043
+ }
5044
+ if (typeof this.maxTokens !== 'undefined') {
5045
+ toReturn['maxTokens'] = this.maxTokens;
4826
5046
  }
4827
5047
  return toReturn;
4828
5048
  }
4829
5049
  }
4830
- class CreateAssistantRequestOptions {
5050
+ class UpsertAssistantRequestOptions {
4831
5051
  static fromProto(proto) {
4832
- let m = new CreateAssistantRequestOptions();
5052
+ let m = new UpsertAssistantRequestOptions();
4833
5053
  m = Object.assign(m, proto);
4834
5054
  return m;
4835
5055
  }
@@ -4847,9 +5067,9 @@ class CreateAssistantRequestOptions {
4847
5067
  return toReturn;
4848
5068
  }
4849
5069
  }
4850
- class UpsertAssistantRequestOptions {
5070
+ class CreateAssistantRequestOptions {
4851
5071
  static fromProto(proto) {
4852
- let m = new UpsertAssistantRequestOptions();
5072
+ let m = new CreateAssistantRequestOptions();
4853
5073
  m = Object.assign(m, proto);
4854
5074
  return m;
4855
5075
  }
@@ -4867,9 +5087,9 @@ class UpsertAssistantRequestOptions {
4867
5087
  return toReturn;
4868
5088
  }
4869
5089
  }
4870
- class GetAssistantRequestOptions {
5090
+ class GetMultiAssistantRequestOptions {
4871
5091
  static fromProto(proto) {
4872
- let m = new GetAssistantRequestOptions();
5092
+ let m = new GetMultiAssistantRequestOptions();
4873
5093
  m = Object.assign(m, proto);
4874
5094
  return m;
4875
5095
  }
@@ -5147,6 +5367,49 @@ class UpsertGoalRequest {
5147
5367
  return toReturn;
5148
5368
  }
5149
5369
  }
5370
+ class ValidatePromptModuleRequest {
5371
+ static fromProto(proto) {
5372
+ let m = new ValidatePromptModuleRequest();
5373
+ m = Object.assign(m, proto);
5374
+ return m;
5375
+ }
5376
+ constructor(kwargs) {
5377
+ if (!kwargs) {
5378
+ return;
5379
+ }
5380
+ Object.assign(this, kwargs);
5381
+ }
5382
+ toApiJson() {
5383
+ const toReturn = {};
5384
+ if (typeof this.content !== 'undefined') {
5385
+ toReturn['content'] = this.content;
5386
+ }
5387
+ return toReturn;
5388
+ }
5389
+ }
5390
+ class ValidatePromptModuleResponse {
5391
+ static fromProto(proto) {
5392
+ let m = new ValidatePromptModuleResponse();
5393
+ m = Object.assign(m, proto);
5394
+ return m;
5395
+ }
5396
+ constructor(kwargs) {
5397
+ if (!kwargs) {
5398
+ return;
5399
+ }
5400
+ Object.assign(this, kwargs);
5401
+ }
5402
+ toApiJson() {
5403
+ const toReturn = {};
5404
+ if (typeof this.isValid !== 'undefined') {
5405
+ toReturn['isValid'] = this.isValid;
5406
+ }
5407
+ if (typeof this.errorMessage !== 'undefined') {
5408
+ toReturn['errorMessage'] = this.errorMessage;
5409
+ }
5410
+ return toReturn;
5411
+ }
5412
+ }
5150
5413
 
5151
5414
  // *********************************
5152
5415
  // Code generated by sdkgen
@@ -5357,6 +5620,10 @@ class FunctionApiService {
5357
5620
  const request = (r.toApiJson) ? r : new DeleteMCPRequest(r);
5358
5621
  return this.http.post(this._host + "/ai_assistants.v1alpha1.FunctionService/DeleteMCP", request.toApiJson(), Object.assign(Object.assign({}, this.apiOptions()), { observe: 'response' }));
5359
5622
  }
5623
+ createMcpFromIntegration(r) {
5624
+ const request = (r.toApiJson) ? r : new CreateMCPFromIntegrationRequest(r);
5625
+ return this.http.post(this._host + "/ai_assistants.v1alpha1.FunctionService/CreateMCPFromIntegration", request.toApiJson(), Object.assign(Object.assign({}, this.apiOptions()), { observe: 'response' }));
5626
+ }
5360
5627
  }
5361
5628
  FunctionApiService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: FunctionApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
5362
5629
  FunctionApiService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: FunctionApiService, providedIn: 'root' });
@@ -5566,6 +5833,11 @@ class PromptModuleApiService {
5566
5833
  const request = (r.toApiJson) ? r : new DeletePromptModuleRequest(r);
5567
5834
  return this.http.post(this._host + "/ai_assistants.v1alpha1.PromptModuleService/Delete", request.toApiJson(), Object.assign(Object.assign({}, this.apiOptions()), { observe: 'response' }));
5568
5835
  }
5836
+ validate(r) {
5837
+ const request = (r.toApiJson) ? r : new ValidatePromptModuleRequest(r);
5838
+ return this.http.post(this._host + "/ai_assistants.v1alpha1.PromptModuleService/Validate", request.toApiJson(), this.apiOptions())
5839
+ .pipe(map(resp => ValidatePromptModuleResponse.fromProto(resp)));
5840
+ }
5569
5841
  }
5570
5842
  PromptModuleApiService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PromptModuleApiService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
5571
5843
  PromptModuleApiService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PromptModuleApiService, providedIn: 'root' });
@@ -5659,5 +5931,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
5659
5931
  * Generated bundle index. Do not edit.
5660
5932
  */
5661
5933
 
5662
- export { Access, Assistant, AssistantApiService, AssistantKey, AssistantType, BuildDefaultAssistantRequest, BuildDefaultAssistantResponse, CancelTestRunRequest, ChatAnswerFunctionExecutionJob, ChatAnswerFunctionExecutionJobResult, ChatAnswerFunctionExecutionJobStatus, ChatChannel, ChatContent, 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, DeleteMCPRequest, 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, GetMultiAssistantRequest, GetMultiAssistantRequestOptions, GetMultiAssistantResponse, 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, ImageContent, 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 };
5934
+ export { Access, Action, Assistant, AssistantApiService, AssistantKey, AssistantType, BuildDefaultAssistantRequest, BuildDefaultAssistantResponse, CancelTestRunRequest, ChatAnswerFunctionExecutionJob, ChatAnswerFunctionExecutionJobResult, ChatAnswerFunctionExecutionJobStatus, ChatChannel, ChatContent, ChatMessage, ChatMessageRole, ChatUserInfo, Config, ConfigInboxConfig, ConfigVoiceConfig, ConfigurableGoal, Connection, ConnectionApiService, ConnectionKey, Constraint, ConstraintFilter, ContextInfo, CreateAssistantRequest, CreateAssistantRequestOptions, CreateAssistantResponse, CreateGoalRequest, CreateGoalResponse, CreateMCPFromIntegrationRequest, CreatePromptModuleRequest, CreatePromptModuleResponse, CreatePromptModuleVersionRequest, CreatePromptModuleVersionRequestOptions, CreatePromptRequest, DeepgramConfig, DeleteAssistantRequest, DeleteConnectionRequest, DeleteFunctionRequest, DeleteGoalRequest, DeleteMCPRequest, DeletePromptModuleRequest, DeletePromptRequest, DeleteTestCasesRequest, DeployPromptModuleRequest, DeployPromptRequest, Effect, ElevenLabsConfig, ExecuteFunctionRequest, ExecuteFunctionResponse, FieldMask, Function, FunctionApiService, FunctionAuthStrategy, FunctionAuthStrategyConnectedIntegrationAuthStrategy, 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, GetMultiAssistantRequest, GetMultiAssistantRequestOptions, GetMultiAssistantResponse, 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, ImageContent, 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, NamespaceType, OpenAIRealtimeConfig, OpenAIRealtimeConfigTurnDetection, PagedRequestOptions, PagedResponseMetadata, Prompt, PromptApiService, PromptModule, PromptModuleApiService, PromptModuleKey, PromptModuleVersion, PromptVersion, RunTestsRequest, RunTestsResponse, Scope, SetAssistantConnectionsRequest, SetAssistantConnectionsRequestConnectionState, SortDirection, SortOptions, TestCase, TestResult, TestResultCitation, TestRun, UpdateAssistantRequest, UpdateGoalRequest, UpdatePromptModuleRequest, UpdatePromptRequest, UpsertAssistantRequest, UpsertAssistantRequestOptions, UpsertAssistantResponse, UpsertConnectionRequest, UpsertFunctionRequest, UpsertGoalRequest, UpsertMCPRequest, UpsertTestCasesRequest, ValidatePromptModuleRequest, ValidatePromptModuleResponse, VendorModel };
5663
5935
  //# sourceMappingURL=vendasta-ai-assistants.mjs.map