@vendasta/ai-assistants 0.20.0 → 1.0.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/enums/answer.enum.mjs +3 -1
- package/esm2020/lib/_internal/goal.api.service.mjs +11 -2
- package/esm2020/lib/_internal/interfaces/api.interface.mjs +1 -1
- package/esm2020/lib/_internal/interfaces/assistant.interface.mjs +1 -1
- package/esm2020/lib/_internal/interfaces/index.mjs +1 -1
- package/esm2020/lib/_internal/objects/api.mjs +130 -44
- package/esm2020/lib/_internal/objects/assistant.mjs +8 -30
- package/esm2020/lib/_internal/objects/index.mjs +4 -4
- package/esm2020/lib/_internal/prompt-module.api.service.mjs +4 -3
- package/fesm2015/vendasta-ai-assistants.mjs +183 -108
- package/fesm2015/vendasta-ai-assistants.mjs.map +1 -1
- package/fesm2020/vendasta-ai-assistants.mjs +183 -108
- package/fesm2020/vendasta-ai-assistants.mjs.map +1 -1
- package/lib/_internal/enums/answer.enum.d.ts +3 -1
- package/lib/_internal/goal.api.service.d.ts +4 -2
- package/lib/_internal/interfaces/api.interface.d.ts +24 -12
- package/lib/_internal/interfaces/assistant.interface.d.ts +2 -5
- package/lib/_internal/interfaces/index.d.ts +3 -3
- package/lib/_internal/objects/api.d.ts +47 -23
- package/lib/_internal/objects/assistant.d.ts +2 -8
- package/lib/_internal/objects/index.d.ts +3 -3
- package/lib/_internal/prompt-module.api.service.d.ts +2 -2
- package/package.json +1 -1
|
@@ -95,6 +95,8 @@ var ChatChannel;
|
|
|
95
95
|
ChatChannel[ChatChannel["CHAT_CHANNEL_WEB"] = 2] = "CHAT_CHANNEL_WEB";
|
|
96
96
|
ChatChannel[ChatChannel["CHAT_CHANNEL_SMS"] = 3] = "CHAT_CHANNEL_SMS";
|
|
97
97
|
ChatChannel[ChatChannel["CHAT_CHANNEL_WHATSAPP"] = 4] = "CHAT_CHANNEL_WHATSAPP";
|
|
98
|
+
ChatChannel[ChatChannel["CHAT_CHANNEL_FACEBOOK"] = 5] = "CHAT_CHANNEL_FACEBOOK";
|
|
99
|
+
ChatChannel[ChatChannel["CHAT_CHANNEL_INSTAGRAM"] = 7] = "CHAT_CHANNEL_INSTAGRAM";
|
|
98
100
|
})(ChatChannel || (ChatChannel = {}));
|
|
99
101
|
var ChatMessageRole;
|
|
100
102
|
(function (ChatMessageRole) {
|
|
@@ -750,6 +752,36 @@ function enumStringToValue$6(enumRef, value) {
|
|
|
750
752
|
}
|
|
751
753
|
return enumRef[value];
|
|
752
754
|
}
|
|
755
|
+
class KeyValuePair {
|
|
756
|
+
static fromProto(proto) {
|
|
757
|
+
let m = new KeyValuePair();
|
|
758
|
+
m = Object.assign(m, proto);
|
|
759
|
+
return m;
|
|
760
|
+
}
|
|
761
|
+
constructor(kwargs) {
|
|
762
|
+
if (!kwargs) {
|
|
763
|
+
return;
|
|
764
|
+
}
|
|
765
|
+
Object.assign(this, kwargs);
|
|
766
|
+
}
|
|
767
|
+
toApiJson() {
|
|
768
|
+
const toReturn = {};
|
|
769
|
+
if (typeof this.key !== 'undefined') {
|
|
770
|
+
toReturn['key'] = this.key;
|
|
771
|
+
}
|
|
772
|
+
if (typeof this.value !== 'undefined') {
|
|
773
|
+
toReturn['value'] = this.value;
|
|
774
|
+
}
|
|
775
|
+
return toReturn;
|
|
776
|
+
}
|
|
777
|
+
}
|
|
778
|
+
|
|
779
|
+
function enumStringToValue$5(enumRef, value) {
|
|
780
|
+
if (typeof value === 'number') {
|
|
781
|
+
return value;
|
|
782
|
+
}
|
|
783
|
+
return enumRef[value];
|
|
784
|
+
}
|
|
753
785
|
class Assistant {
|
|
754
786
|
static fromProto(proto) {
|
|
755
787
|
let m = new Assistant();
|
|
@@ -758,7 +790,7 @@ class Assistant {
|
|
|
758
790
|
m.namespace = Namespace.fromProto(proto.namespace);
|
|
759
791
|
}
|
|
760
792
|
if (proto.type) {
|
|
761
|
-
m.type = enumStringToValue$
|
|
793
|
+
m.type = enumStringToValue$5(AssistantType, proto.type);
|
|
762
794
|
}
|
|
763
795
|
if (proto.config) {
|
|
764
796
|
m.config = Config.fromProto(proto.config);
|
|
@@ -826,29 +858,6 @@ class AssistantKey {
|
|
|
826
858
|
return toReturn;
|
|
827
859
|
}
|
|
828
860
|
}
|
|
829
|
-
class BookingConfig {
|
|
830
|
-
static fromProto(proto) {
|
|
831
|
-
let m = new BookingConfig();
|
|
832
|
-
m = Object.assign(m, proto);
|
|
833
|
-
return m;
|
|
834
|
-
}
|
|
835
|
-
constructor(kwargs) {
|
|
836
|
-
if (!kwargs) {
|
|
837
|
-
return;
|
|
838
|
-
}
|
|
839
|
-
Object.assign(this, kwargs);
|
|
840
|
-
}
|
|
841
|
-
toApiJson() {
|
|
842
|
-
const toReturn = {};
|
|
843
|
-
if (typeof this.calendarId !== 'undefined') {
|
|
844
|
-
toReturn['calendarId'] = this.calendarId;
|
|
845
|
-
}
|
|
846
|
-
if (typeof this.meetingTypeId !== 'undefined') {
|
|
847
|
-
toReturn['meetingTypeId'] = this.meetingTypeId;
|
|
848
|
-
}
|
|
849
|
-
return toReturn;
|
|
850
|
-
}
|
|
851
|
-
}
|
|
852
861
|
class Config {
|
|
853
862
|
static fromProto(proto) {
|
|
854
863
|
let m = new Config();
|
|
@@ -885,6 +894,9 @@ class ConfigurableGoal {
|
|
|
885
894
|
if (proto.goal) {
|
|
886
895
|
m.goal = Goal.fromProto(proto.goal);
|
|
887
896
|
}
|
|
897
|
+
if (proto.configuration) {
|
|
898
|
+
m.configuration = proto.configuration.map(KeyValuePair.fromProto);
|
|
899
|
+
}
|
|
888
900
|
return m;
|
|
889
901
|
}
|
|
890
902
|
constructor(kwargs) {
|
|
@@ -898,6 +910,9 @@ class ConfigurableGoal {
|
|
|
898
910
|
if (typeof this.goal !== 'undefined' && this.goal !== null) {
|
|
899
911
|
toReturn['goal'] = 'toApiJson' in this.goal ? this.goal.toApiJson() : this.goal;
|
|
900
912
|
}
|
|
913
|
+
if (typeof this.configuration !== 'undefined' && this.configuration !== null) {
|
|
914
|
+
toReturn['configuration'] = 'toApiJson' in this.configuration ? this.configuration.toApiJson() : this.configuration;
|
|
915
|
+
}
|
|
901
916
|
return toReturn;
|
|
902
917
|
}
|
|
903
918
|
}
|
|
@@ -925,9 +940,6 @@ class ConfigInboxConfig {
|
|
|
925
940
|
static fromProto(proto) {
|
|
926
941
|
let m = new ConfigInboxConfig();
|
|
927
942
|
m = Object.assign(m, proto);
|
|
928
|
-
if (proto.bookingConfig) {
|
|
929
|
-
m.bookingConfig = BookingConfig.fromProto(proto.bookingConfig);
|
|
930
|
-
}
|
|
931
943
|
return m;
|
|
932
944
|
}
|
|
933
945
|
constructor(kwargs) {
|
|
@@ -944,9 +956,6 @@ class ConfigInboxConfig {
|
|
|
944
956
|
if (typeof this.additionalInstructions !== 'undefined') {
|
|
945
957
|
toReturn['additionalInstructions'] = this.additionalInstructions;
|
|
946
958
|
}
|
|
947
|
-
if (typeof this.bookingConfig !== 'undefined' && this.bookingConfig !== null) {
|
|
948
|
-
toReturn['bookingConfig'] = 'toApiJson' in this.bookingConfig ? this.bookingConfig.toApiJson() : this.bookingConfig;
|
|
949
|
-
}
|
|
950
959
|
return toReturn;
|
|
951
960
|
}
|
|
952
961
|
}
|
|
@@ -1036,7 +1045,7 @@ class ConfigVoiceConfig {
|
|
|
1036
1045
|
let m = new ConfigVoiceConfig();
|
|
1037
1046
|
m = Object.assign(m, proto);
|
|
1038
1047
|
if (proto.vendorModel) {
|
|
1039
|
-
m.vendorModel = enumStringToValue$
|
|
1048
|
+
m.vendorModel = enumStringToValue$5(VendorModel, proto.vendorModel);
|
|
1040
1049
|
}
|
|
1041
1050
|
if (proto.modelConfig) {
|
|
1042
1051
|
m.modelConfig = ModelConfig.fromProto(proto.modelConfig);
|
|
@@ -1061,7 +1070,7 @@ class ConfigVoiceConfig {
|
|
|
1061
1070
|
}
|
|
1062
1071
|
}
|
|
1063
1072
|
|
|
1064
|
-
function enumStringToValue$
|
|
1073
|
+
function enumStringToValue$4(enumRef, value) {
|
|
1065
1074
|
if (typeof value === 'number') {
|
|
1066
1075
|
return value;
|
|
1067
1076
|
}
|
|
@@ -1078,7 +1087,7 @@ class Connection {
|
|
|
1078
1087
|
m.assistantKeys = proto.assistantKeys.map(AssistantKey.fromProto);
|
|
1079
1088
|
}
|
|
1080
1089
|
if (proto.supportedAssistantTypes) {
|
|
1081
|
-
m.supportedAssistantTypes = proto.supportedAssistantTypes.map((v) => enumStringToValue$
|
|
1090
|
+
m.supportedAssistantTypes = proto.supportedAssistantTypes.map((v) => enumStringToValue$4(AssistantType, v));
|
|
1082
1091
|
}
|
|
1083
1092
|
return m;
|
|
1084
1093
|
}
|
|
@@ -1153,36 +1162,6 @@ class ConnectionKey {
|
|
|
1153
1162
|
}
|
|
1154
1163
|
}
|
|
1155
1164
|
|
|
1156
|
-
function enumStringToValue$4(enumRef, value) {
|
|
1157
|
-
if (typeof value === 'number') {
|
|
1158
|
-
return value;
|
|
1159
|
-
}
|
|
1160
|
-
return enumRef[value];
|
|
1161
|
-
}
|
|
1162
|
-
class KeyValuePair {
|
|
1163
|
-
static fromProto(proto) {
|
|
1164
|
-
let m = new KeyValuePair();
|
|
1165
|
-
m = Object.assign(m, proto);
|
|
1166
|
-
return m;
|
|
1167
|
-
}
|
|
1168
|
-
constructor(kwargs) {
|
|
1169
|
-
if (!kwargs) {
|
|
1170
|
-
return;
|
|
1171
|
-
}
|
|
1172
|
-
Object.assign(this, kwargs);
|
|
1173
|
-
}
|
|
1174
|
-
toApiJson() {
|
|
1175
|
-
const toReturn = {};
|
|
1176
|
-
if (typeof this.key !== 'undefined') {
|
|
1177
|
-
toReturn['key'] = this.key;
|
|
1178
|
-
}
|
|
1179
|
-
if (typeof this.value !== 'undefined') {
|
|
1180
|
-
toReturn['value'] = this.value;
|
|
1181
|
-
}
|
|
1182
|
-
return toReturn;
|
|
1183
|
-
}
|
|
1184
|
-
}
|
|
1185
|
-
|
|
1186
1165
|
function enumStringToValue$3(enumRef, value) {
|
|
1187
1166
|
if (typeof value === 'number') {
|
|
1188
1167
|
return value;
|
|
@@ -1500,6 +1479,49 @@ class SetAssistantConnectionsRequestConnectionState {
|
|
|
1500
1479
|
return toReturn;
|
|
1501
1480
|
}
|
|
1502
1481
|
}
|
|
1482
|
+
class CreateGoalRequest {
|
|
1483
|
+
static fromProto(proto) {
|
|
1484
|
+
let m = new CreateGoalRequest();
|
|
1485
|
+
m = Object.assign(m, proto);
|
|
1486
|
+
if (proto.goal) {
|
|
1487
|
+
m.goal = Goal.fromProto(proto.goal);
|
|
1488
|
+
}
|
|
1489
|
+
return m;
|
|
1490
|
+
}
|
|
1491
|
+
constructor(kwargs) {
|
|
1492
|
+
if (!kwargs) {
|
|
1493
|
+
return;
|
|
1494
|
+
}
|
|
1495
|
+
Object.assign(this, kwargs);
|
|
1496
|
+
}
|
|
1497
|
+
toApiJson() {
|
|
1498
|
+
const toReturn = {};
|
|
1499
|
+
if (typeof this.goal !== 'undefined' && this.goal !== null) {
|
|
1500
|
+
toReturn['goal'] = 'toApiJson' in this.goal ? this.goal.toApiJson() : this.goal;
|
|
1501
|
+
}
|
|
1502
|
+
return toReturn;
|
|
1503
|
+
}
|
|
1504
|
+
}
|
|
1505
|
+
class CreateGoalResponse {
|
|
1506
|
+
static fromProto(proto) {
|
|
1507
|
+
let m = new CreateGoalResponse();
|
|
1508
|
+
m = Object.assign(m, proto);
|
|
1509
|
+
return m;
|
|
1510
|
+
}
|
|
1511
|
+
constructor(kwargs) {
|
|
1512
|
+
if (!kwargs) {
|
|
1513
|
+
return;
|
|
1514
|
+
}
|
|
1515
|
+
Object.assign(this, kwargs);
|
|
1516
|
+
}
|
|
1517
|
+
toApiJson() {
|
|
1518
|
+
const toReturn = {};
|
|
1519
|
+
if (typeof this.id !== 'undefined') {
|
|
1520
|
+
toReturn['id'] = this.id;
|
|
1521
|
+
}
|
|
1522
|
+
return toReturn;
|
|
1523
|
+
}
|
|
1524
|
+
}
|
|
1503
1525
|
class CreatePromptModuleRequest {
|
|
1504
1526
|
static fromProto(proto) {
|
|
1505
1527
|
let m = new CreatePromptModuleRequest();
|
|
@@ -1538,6 +1560,26 @@ class CreatePromptModuleRequest {
|
|
|
1538
1560
|
return toReturn;
|
|
1539
1561
|
}
|
|
1540
1562
|
}
|
|
1563
|
+
class CreatePromptModuleResponse {
|
|
1564
|
+
static fromProto(proto) {
|
|
1565
|
+
let m = new CreatePromptModuleResponse();
|
|
1566
|
+
m = Object.assign(m, proto);
|
|
1567
|
+
return m;
|
|
1568
|
+
}
|
|
1569
|
+
constructor(kwargs) {
|
|
1570
|
+
if (!kwargs) {
|
|
1571
|
+
return;
|
|
1572
|
+
}
|
|
1573
|
+
Object.assign(this, kwargs);
|
|
1574
|
+
}
|
|
1575
|
+
toApiJson() {
|
|
1576
|
+
const toReturn = {};
|
|
1577
|
+
if (typeof this.id !== 'undefined') {
|
|
1578
|
+
toReturn['id'] = this.id;
|
|
1579
|
+
}
|
|
1580
|
+
return toReturn;
|
|
1581
|
+
}
|
|
1582
|
+
}
|
|
1541
1583
|
class CreatePromptModuleVersionRequest {
|
|
1542
1584
|
static fromProto(proto) {
|
|
1543
1585
|
let m = new CreatePromptModuleVersionRequest();
|
|
@@ -1804,13 +1846,16 @@ class DeployPromptRequest {
|
|
|
1804
1846
|
return toReturn;
|
|
1805
1847
|
}
|
|
1806
1848
|
}
|
|
1807
|
-
class
|
|
1849
|
+
class ListConnectionsRequestFilters {
|
|
1808
1850
|
static fromProto(proto) {
|
|
1809
|
-
let m = new
|
|
1851
|
+
let m = new ListConnectionsRequestFilters();
|
|
1810
1852
|
m = Object.assign(m, proto);
|
|
1811
1853
|
if (proto.namespace) {
|
|
1812
1854
|
m.namespace = Namespace.fromProto(proto.namespace);
|
|
1813
1855
|
}
|
|
1856
|
+
if (proto.assistantType) {
|
|
1857
|
+
m.assistantType = enumStringToValue(AssistantType, proto.assistantType);
|
|
1858
|
+
}
|
|
1814
1859
|
return m;
|
|
1815
1860
|
}
|
|
1816
1861
|
constructor(kwargs) {
|
|
@@ -1824,19 +1869,19 @@ class ListPromptModuleRequestFilters {
|
|
|
1824
1869
|
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
1825
1870
|
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
1826
1871
|
}
|
|
1872
|
+
if (typeof this.assistantType !== 'undefined') {
|
|
1873
|
+
toReturn['assistantType'] = this.assistantType;
|
|
1874
|
+
}
|
|
1827
1875
|
return toReturn;
|
|
1828
1876
|
}
|
|
1829
1877
|
}
|
|
1830
|
-
class
|
|
1878
|
+
class ListPromptModuleRequestFilters {
|
|
1831
1879
|
static fromProto(proto) {
|
|
1832
|
-
let m = new
|
|
1880
|
+
let m = new ListPromptModuleRequestFilters();
|
|
1833
1881
|
m = Object.assign(m, proto);
|
|
1834
1882
|
if (proto.namespace) {
|
|
1835
1883
|
m.namespace = Namespace.fromProto(proto.namespace);
|
|
1836
1884
|
}
|
|
1837
|
-
if (proto.assistantType) {
|
|
1838
|
-
m.assistantType = enumStringToValue(AssistantType, proto.assistantType);
|
|
1839
|
-
}
|
|
1840
1885
|
return m;
|
|
1841
1886
|
}
|
|
1842
1887
|
constructor(kwargs) {
|
|
@@ -1850,19 +1895,13 @@ class ListConnectionsRequestFilters {
|
|
|
1850
1895
|
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
1851
1896
|
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
1852
1897
|
}
|
|
1853
|
-
if (typeof this.assistantType !== 'undefined') {
|
|
1854
|
-
toReturn['assistantType'] = this.assistantType;
|
|
1855
|
-
}
|
|
1856
1898
|
return toReturn;
|
|
1857
1899
|
}
|
|
1858
1900
|
}
|
|
1859
|
-
class
|
|
1901
|
+
class ListAllAssistantsAssociatedToConnectionRequestFilters {
|
|
1860
1902
|
static fromProto(proto) {
|
|
1861
|
-
let m = new
|
|
1903
|
+
let m = new ListAllAssistantsAssociatedToConnectionRequestFilters();
|
|
1862
1904
|
m = Object.assign(m, proto);
|
|
1863
|
-
if (proto.namespace) {
|
|
1864
|
-
m.namespace = Namespace.fromProto(proto.namespace);
|
|
1865
|
-
}
|
|
1866
1905
|
if (proto.type) {
|
|
1867
1906
|
m.type = enumStringToValue(AssistantType, proto.type);
|
|
1868
1907
|
}
|
|
@@ -1876,27 +1915,21 @@ class ListAssistantRequestFilters {
|
|
|
1876
1915
|
}
|
|
1877
1916
|
toApiJson() {
|
|
1878
1917
|
const toReturn = {};
|
|
1879
|
-
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
1880
|
-
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
1881
|
-
}
|
|
1882
1918
|
if (typeof this.type !== 'undefined') {
|
|
1883
1919
|
toReturn['type'] = this.type;
|
|
1884
1920
|
}
|
|
1885
1921
|
return toReturn;
|
|
1886
1922
|
}
|
|
1887
1923
|
}
|
|
1888
|
-
class
|
|
1924
|
+
class ListAssistantRequestFilters {
|
|
1889
1925
|
static fromProto(proto) {
|
|
1890
|
-
let m = new
|
|
1926
|
+
let m = new ListAssistantRequestFilters();
|
|
1891
1927
|
m = Object.assign(m, proto);
|
|
1892
1928
|
if (proto.namespace) {
|
|
1893
1929
|
m.namespace = Namespace.fromProto(proto.namespace);
|
|
1894
1930
|
}
|
|
1895
1931
|
if (proto.type) {
|
|
1896
|
-
m.type = enumStringToValue(
|
|
1897
|
-
}
|
|
1898
|
-
if (proto.supportedChannels) {
|
|
1899
|
-
m.supportedChannels = proto.supportedChannels.map((v) => enumStringToValue(GoalChannel, v));
|
|
1932
|
+
m.type = enumStringToValue(AssistantType, proto.type);
|
|
1900
1933
|
}
|
|
1901
1934
|
return m;
|
|
1902
1935
|
}
|
|
@@ -1914,18 +1947,15 @@ class ListGoalsRequestFilters {
|
|
|
1914
1947
|
if (typeof this.type !== 'undefined') {
|
|
1915
1948
|
toReturn['type'] = this.type;
|
|
1916
1949
|
}
|
|
1917
|
-
if (typeof this.supportedChannels !== 'undefined') {
|
|
1918
|
-
toReturn['supportedChannels'] = this.supportedChannels;
|
|
1919
|
-
}
|
|
1920
1950
|
return toReturn;
|
|
1921
1951
|
}
|
|
1922
1952
|
}
|
|
1923
|
-
class
|
|
1953
|
+
class ListFunctionRequestFilters {
|
|
1924
1954
|
static fromProto(proto) {
|
|
1925
|
-
let m = new
|
|
1955
|
+
let m = new ListFunctionRequestFilters();
|
|
1926
1956
|
m = Object.assign(m, proto);
|
|
1927
|
-
if (proto.
|
|
1928
|
-
m.
|
|
1957
|
+
if (proto.namespace) {
|
|
1958
|
+
m.namespace = Namespace.fromProto(proto.namespace);
|
|
1929
1959
|
}
|
|
1930
1960
|
return m;
|
|
1931
1961
|
}
|
|
@@ -1937,19 +1967,25 @@ class ListAllAssistantsAssociatedToConnectionRequestFilters {
|
|
|
1937
1967
|
}
|
|
1938
1968
|
toApiJson() {
|
|
1939
1969
|
const toReturn = {};
|
|
1940
|
-
if (typeof this.
|
|
1941
|
-
toReturn['
|
|
1970
|
+
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
1971
|
+
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
1942
1972
|
}
|
|
1943
1973
|
return toReturn;
|
|
1944
1974
|
}
|
|
1945
1975
|
}
|
|
1946
|
-
class
|
|
1976
|
+
class ListGoalsRequestFilters {
|
|
1947
1977
|
static fromProto(proto) {
|
|
1948
|
-
let m = new
|
|
1978
|
+
let m = new ListGoalsRequestFilters();
|
|
1949
1979
|
m = Object.assign(m, proto);
|
|
1950
1980
|
if (proto.namespace) {
|
|
1951
1981
|
m.namespace = Namespace.fromProto(proto.namespace);
|
|
1952
1982
|
}
|
|
1983
|
+
if (proto.type) {
|
|
1984
|
+
m.type = enumStringToValue(GoalType, proto.type);
|
|
1985
|
+
}
|
|
1986
|
+
if (proto.supportedChannels) {
|
|
1987
|
+
m.supportedChannels = proto.supportedChannels.map((v) => enumStringToValue(GoalChannel, v));
|
|
1988
|
+
}
|
|
1953
1989
|
return m;
|
|
1954
1990
|
}
|
|
1955
1991
|
constructor(kwargs) {
|
|
@@ -1963,6 +1999,12 @@ class ListFunctionRequestFilters {
|
|
|
1963
1999
|
if (typeof this.namespace !== 'undefined' && this.namespace !== null) {
|
|
1964
2000
|
toReturn['namespace'] = 'toApiJson' in this.namespace ? this.namespace.toApiJson() : this.namespace;
|
|
1965
2001
|
}
|
|
2002
|
+
if (typeof this.type !== 'undefined') {
|
|
2003
|
+
toReturn['type'] = this.type;
|
|
2004
|
+
}
|
|
2005
|
+
if (typeof this.supportedChannels !== 'undefined') {
|
|
2006
|
+
toReturn['supportedChannels'] = this.supportedChannels;
|
|
2007
|
+
}
|
|
1966
2008
|
return toReturn;
|
|
1967
2009
|
}
|
|
1968
2010
|
}
|
|
@@ -3388,9 +3430,9 @@ class ListPromptVersionsResponse {
|
|
|
3388
3430
|
return toReturn;
|
|
3389
3431
|
}
|
|
3390
3432
|
}
|
|
3391
|
-
class
|
|
3433
|
+
class CreatePromptModuleVersionRequestOptions {
|
|
3392
3434
|
static fromProto(proto) {
|
|
3393
|
-
let m = new
|
|
3435
|
+
let m = new CreatePromptModuleVersionRequestOptions();
|
|
3394
3436
|
m = Object.assign(m, proto);
|
|
3395
3437
|
return m;
|
|
3396
3438
|
}
|
|
@@ -3402,15 +3444,15 @@ class UpsertAssistantRequestOptions {
|
|
|
3402
3444
|
}
|
|
3403
3445
|
toApiJson() {
|
|
3404
3446
|
const toReturn = {};
|
|
3405
|
-
if (typeof this.
|
|
3406
|
-
toReturn['
|
|
3447
|
+
if (typeof this.shouldDeploy !== 'undefined') {
|
|
3448
|
+
toReturn['shouldDeploy'] = this.shouldDeploy;
|
|
3407
3449
|
}
|
|
3408
3450
|
return toReturn;
|
|
3409
3451
|
}
|
|
3410
3452
|
}
|
|
3411
|
-
class
|
|
3453
|
+
class UpsertAssistantRequestOptions {
|
|
3412
3454
|
static fromProto(proto) {
|
|
3413
|
-
let m = new
|
|
3455
|
+
let m = new UpsertAssistantRequestOptions();
|
|
3414
3456
|
m = Object.assign(m, proto);
|
|
3415
3457
|
return m;
|
|
3416
3458
|
}
|
|
@@ -3422,8 +3464,8 @@ class CreatePromptModuleVersionRequestOptions {
|
|
|
3422
3464
|
}
|
|
3423
3465
|
toApiJson() {
|
|
3424
3466
|
const toReturn = {};
|
|
3425
|
-
if (typeof this.
|
|
3426
|
-
toReturn['
|
|
3467
|
+
if (typeof this.applyDefaults !== 'undefined') {
|
|
3468
|
+
toReturn['applyDefaults'] = this.applyDefaults;
|
|
3427
3469
|
}
|
|
3428
3470
|
return toReturn;
|
|
3429
3471
|
}
|
|
@@ -3486,6 +3528,29 @@ class SetAssistantConnectionsRequest {
|
|
|
3486
3528
|
return toReturn;
|
|
3487
3529
|
}
|
|
3488
3530
|
}
|
|
3531
|
+
class UpdateGoalRequest {
|
|
3532
|
+
static fromProto(proto) {
|
|
3533
|
+
let m = new UpdateGoalRequest();
|
|
3534
|
+
m = Object.assign(m, proto);
|
|
3535
|
+
if (proto.goal) {
|
|
3536
|
+
m.goal = Goal.fromProto(proto.goal);
|
|
3537
|
+
}
|
|
3538
|
+
return m;
|
|
3539
|
+
}
|
|
3540
|
+
constructor(kwargs) {
|
|
3541
|
+
if (!kwargs) {
|
|
3542
|
+
return;
|
|
3543
|
+
}
|
|
3544
|
+
Object.assign(this, kwargs);
|
|
3545
|
+
}
|
|
3546
|
+
toApiJson() {
|
|
3547
|
+
const toReturn = {};
|
|
3548
|
+
if (typeof this.goal !== 'undefined' && this.goal !== null) {
|
|
3549
|
+
toReturn['goal'] = 'toApiJson' in this.goal ? this.goal.toApiJson() : this.goal;
|
|
3550
|
+
}
|
|
3551
|
+
return toReturn;
|
|
3552
|
+
}
|
|
3553
|
+
}
|
|
3489
3554
|
class UpdatePromptModuleRequest {
|
|
3490
3555
|
static fromProto(proto) {
|
|
3491
3556
|
let m = new UpdatePromptModuleRequest();
|
|
@@ -3865,6 +3930,15 @@ class GoalApiService {
|
|
|
3865
3930
|
const request = (r.toApiJson) ? r : new UpsertGoalRequest(r);
|
|
3866
3931
|
return this.http.post(this._host + "/ai_assistants.v1alpha1.GoalService/Upsert", request.toApiJson(), Object.assign(Object.assign({}, this.apiOptions()), { observe: 'response' }));
|
|
3867
3932
|
}
|
|
3933
|
+
create(r) {
|
|
3934
|
+
const request = (r.toApiJson) ? r : new CreateGoalRequest(r);
|
|
3935
|
+
return this.http.post(this._host + "/ai_assistants.v1alpha1.GoalService/Create", request.toApiJson(), this.apiOptions())
|
|
3936
|
+
.pipe(map(resp => CreateGoalResponse.fromProto(resp)));
|
|
3937
|
+
}
|
|
3938
|
+
update(r) {
|
|
3939
|
+
const request = (r.toApiJson) ? r : new UpdateGoalRequest(r);
|
|
3940
|
+
return this.http.post(this._host + "/ai_assistants.v1alpha1.GoalService/Update", request.toApiJson(), Object.assign(Object.assign({}, this.apiOptions()), { observe: 'response' }));
|
|
3941
|
+
}
|
|
3868
3942
|
get(r) {
|
|
3869
3943
|
const request = (r.toApiJson) ? r : new GetGoalRequest(r);
|
|
3870
3944
|
return this.http.post(this._host + "/ai_assistants.v1alpha1.GoalService/Get", request.toApiJson(), this.apiOptions())
|
|
@@ -3919,7 +3993,8 @@ class PromptModuleApiService {
|
|
|
3919
3993
|
}
|
|
3920
3994
|
create(r) {
|
|
3921
3995
|
const request = (r.toApiJson) ? r : new CreatePromptModuleRequest(r);
|
|
3922
|
-
return this.http.post(this._host + "/ai_assistants.v1alpha1.PromptModuleService/Create", request.toApiJson(),
|
|
3996
|
+
return this.http.post(this._host + "/ai_assistants.v1alpha1.PromptModuleService/Create", request.toApiJson(), this.apiOptions())
|
|
3997
|
+
.pipe(map(resp => CreatePromptModuleResponse.fromProto(resp)));
|
|
3923
3998
|
}
|
|
3924
3999
|
createVersion(r) {
|
|
3925
4000
|
const request = (r.toApiJson) ? r : new CreatePromptModuleVersionRequest(r);
|
|
@@ -4065,5 +4140,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImpo
|
|
|
4065
4140
|
* Generated bundle index. Do not edit.
|
|
4066
4141
|
*/
|
|
4067
4142
|
|
|
4068
|
-
export { Access, Assistant, AssistantApiService, AssistantKey, AssistantType,
|
|
4143
|
+
export { Access, Assistant, AssistantApiService, AssistantKey, AssistantType, BuildDefaultAssistantRequest, BuildDefaultAssistantResponse, ChatAnswerFunctionExecutionJob, ChatAnswerFunctionExecutionJobResult, ChatAnswerFunctionExecutionJobStatus, ChatChannel, ChatMessage, ChatMessageRole, ChatUserInfo, Config, ConfigInboxConfig, ConfigVoiceConfig, ConfigurableGoal, Connection, ConnectionApiService, ConnectionKey, CreateGoalRequest, CreateGoalResponse, CreatePromptModuleRequest, CreatePromptModuleResponse, CreatePromptModuleVersionRequest, CreatePromptModuleVersionRequestOptions, CreatePromptRequest, DeepgramConfig, DeleteAssistantRequest, DeleteConnectionRequest, DeleteFunctionRequest, DeleteGoalRequest, DeletePromptModuleRequest, DeletePromptRequest, DeployPromptModuleRequest, DeployPromptRequest, Function, FunctionApiService, FunctionHeader, FunctionKey, FunctionParameter, GenerateChatAnswerRequest, GenerateChatAnswerRequestOptions, GenerateChatAnswerResponse, GetAssistantRequest, 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, Goal, GoalApiService, GoalChannel, GoalKey, GoalType, GoalsDisabledForAccountGroupRequest, GoalsDisabledForAccountGroupResponse, HostService, KeyValuePair, ListAllAssistantsAssociatedToConnectionRequest, ListAllAssistantsAssociatedToConnectionRequestFilters, ListAllAssistantsAssociatedToConnectionResponse, ListAssistantRequest, ListAssistantRequestFilters, ListAssistantResponse, ListConnectionsRequest, ListConnectionsRequestFilters, ListConnectionsResponse, ListFunctionRequest, ListFunctionRequestFilters, ListFunctionResponse, ListGoalsRequest, ListGoalsRequestFilters, ListGoalsResponse, ListPromptModuleRequest, ListPromptModuleRequestFilters, ListPromptModuleResponse, ListPromptModuleVersionsRequest, ListPromptModuleVersionsResponse, ListPromptRequest, ListPromptResponse, ListPromptVersionsRequest, ListPromptVersionsResponse, ModelConfig, Namespace, NamespaceAccountGroupNamespace, NamespaceAccountGroupsForGroupNamespace, NamespaceAccountGroupsForPartnerNamespace, NamespaceGlobalNamespace, NamespacePartnerNamespace, NamespaceSystemNamespace, OpenAIRealtimeConfig, OpenAIRealtimeConfigTurnDetection, PagedRequestOptions, PagedResponseMetadata, Prompt, PromptApiService, PromptModule, PromptModuleApiService, PromptModuleKey, PromptModuleVersion, PromptVersion, SetAssistantConnectionsRequest, SetAssistantConnectionsRequestConnectionState, UpdateGoalRequest, UpdatePromptModuleRequest, UpdatePromptRequest, UpsertAssistantRequest, UpsertAssistantRequestOptions, UpsertAssistantResponse, UpsertConnectionRequest, UpsertFunctionRequest, UpsertGoalRequest, VendorModel };
|
|
4069
4144
|
//# sourceMappingURL=vendasta-ai-assistants.mjs.map
|