@vendasta/conversation 0.91.1 → 0.93.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/esm2022/lib/_internal/conversation.api.service.mjs +7 -2
- package/esm2022/lib/_internal/interfaces/api.interface.mjs +1 -1
- package/esm2022/lib/_internal/interfaces/conversation.interface.mjs +1 -1
- package/esm2022/lib/_internal/interfaces/evaluation.interface.mjs +8 -0
- package/esm2022/lib/_internal/interfaces/index.mjs +1 -1
- package/esm2022/lib/_internal/objects/api.mjs +118 -1
- package/esm2022/lib/_internal/objects/conversation.mjs +8 -1
- package/esm2022/lib/_internal/objects/evaluation.mjs +51 -0
- package/esm2022/lib/_internal/objects/index.mjs +3 -2
- package/fesm2022/vendasta-conversation.mjs +203 -25
- package/fesm2022/vendasta-conversation.mjs.map +1 -1
- package/lib/_internal/conversation.api.service.d.ts +3 -2
- package/lib/_internal/interfaces/api.interface.d.ts +18 -0
- package/lib/_internal/interfaces/conversation.interface.d.ts +1 -0
- package/lib/_internal/interfaces/evaluation.interface.d.ts +8 -0
- package/lib/_internal/interfaces/index.d.ts +2 -1
- package/lib/_internal/objects/api.d.ts +27 -0
- package/lib/_internal/objects/conversation.d.ts +1 -0
- package/lib/_internal/objects/evaluation.d.ts +13 -0
- package/lib/_internal/objects/index.d.ts +2 -1
- package/package.json +1 -1
|
@@ -202,7 +202,7 @@ var Status;
|
|
|
202
202
|
// Enums Index.
|
|
203
203
|
// *********************************
|
|
204
204
|
|
|
205
|
-
function enumStringToValue$
|
|
205
|
+
function enumStringToValue$d(enumRef, value) {
|
|
206
206
|
if (typeof value === 'number') {
|
|
207
207
|
return value;
|
|
208
208
|
}
|
|
@@ -240,7 +240,7 @@ class NamespaceDetail {
|
|
|
240
240
|
let m = new NamespaceDetail();
|
|
241
241
|
m = Object.assign(m, proto);
|
|
242
242
|
if (proto.participantType) {
|
|
243
|
-
m.participantType = enumStringToValue$
|
|
243
|
+
m.participantType = enumStringToValue$d(GlobalParticipantType, proto.participantType);
|
|
244
244
|
}
|
|
245
245
|
return m;
|
|
246
246
|
}
|
|
@@ -268,7 +268,7 @@ class SubjectParticipant {
|
|
|
268
268
|
let m = new SubjectParticipant();
|
|
269
269
|
m = Object.assign(m, proto);
|
|
270
270
|
if (proto.participantType) {
|
|
271
|
-
m.participantType = enumStringToValue$
|
|
271
|
+
m.participantType = enumStringToValue$d(GlobalParticipantType, proto.participantType);
|
|
272
272
|
}
|
|
273
273
|
return m;
|
|
274
274
|
}
|
|
@@ -290,7 +290,7 @@ class SubjectParticipant {
|
|
|
290
290
|
}
|
|
291
291
|
}
|
|
292
292
|
|
|
293
|
-
function enumStringToValue$
|
|
293
|
+
function enumStringToValue$c(enumRef, value) {
|
|
294
294
|
if (typeof value === 'number') {
|
|
295
295
|
return value;
|
|
296
296
|
}
|
|
@@ -336,11 +336,12 @@ class Conversation {
|
|
|
336
336
|
aiConfiguration;
|
|
337
337
|
latestMsgSentTimeBySubjectParticipant;
|
|
338
338
|
subjectParticipantKey;
|
|
339
|
+
latestRelevantActivityTime;
|
|
339
340
|
static fromProto(proto) {
|
|
340
341
|
let m = new Conversation();
|
|
341
342
|
m = Object.assign(m, proto);
|
|
342
343
|
if (proto.channel) {
|
|
343
|
-
m.channel = enumStringToValue$
|
|
344
|
+
m.channel = enumStringToValue$c(ConversationChannel, proto.channel);
|
|
344
345
|
}
|
|
345
346
|
if (proto.created) {
|
|
346
347
|
m.created = new Date(proto.created);
|
|
@@ -355,7 +356,7 @@ class Conversation {
|
|
|
355
356
|
m.latestMsgSentTime = new Date(proto.latestMsgSentTime);
|
|
356
357
|
}
|
|
357
358
|
if (proto.originLocation) {
|
|
358
|
-
m.originLocation = enumStringToValue$
|
|
359
|
+
m.originLocation = enumStringToValue$c(PlatformLocation, proto.originLocation);
|
|
359
360
|
}
|
|
360
361
|
if (proto.lastSeenByParticipant) {
|
|
361
362
|
m.lastSeenByParticipant = proto.lastSeenByParticipant.map(LastSeenByParticipant.fromProto);
|
|
@@ -372,6 +373,9 @@ class Conversation {
|
|
|
372
373
|
if (proto.subjectParticipantKey) {
|
|
373
374
|
m.subjectParticipantKey = SubjectParticipantKey.fromProto(proto.subjectParticipantKey);
|
|
374
375
|
}
|
|
376
|
+
if (proto.latestRelevantActivityTime) {
|
|
377
|
+
m.latestRelevantActivityTime = new Date(proto.latestRelevantActivityTime);
|
|
378
|
+
}
|
|
375
379
|
return m;
|
|
376
380
|
}
|
|
377
381
|
constructor(kwargs) {
|
|
@@ -436,6 +440,9 @@ class Conversation {
|
|
|
436
440
|
if (typeof this.subjectParticipantKey !== 'undefined' && this.subjectParticipantKey !== null) {
|
|
437
441
|
toReturn['subjectParticipantKey'] = 'toApiJson' in this.subjectParticipantKey ? this.subjectParticipantKey.toApiJson() : this.subjectParticipantKey;
|
|
438
442
|
}
|
|
443
|
+
if (typeof this.latestRelevantActivityTime !== 'undefined' && this.latestRelevantActivityTime !== null) {
|
|
444
|
+
toReturn['latestRelevantActivityTime'] = 'toApiJson' in this.latestRelevantActivityTime ? this.latestRelevantActivityTime.toApiJson() : this.latestRelevantActivityTime;
|
|
445
|
+
}
|
|
439
446
|
return toReturn;
|
|
440
447
|
}
|
|
441
448
|
}
|
|
@@ -450,7 +457,7 @@ class ConversationKey {
|
|
|
450
457
|
m.subjectParticipants = proto.subjectParticipants.map(SubjectParticipant.fromProto);
|
|
451
458
|
}
|
|
452
459
|
if (proto.channel) {
|
|
453
|
-
m.channel = enumStringToValue$
|
|
460
|
+
m.channel = enumStringToValue$c(ConversationChannel, proto.channel);
|
|
454
461
|
}
|
|
455
462
|
return m;
|
|
456
463
|
}
|
|
@@ -562,7 +569,7 @@ class SubjectParticipantKey {
|
|
|
562
569
|
}
|
|
563
570
|
}
|
|
564
571
|
|
|
565
|
-
function enumStringToValue$
|
|
572
|
+
function enumStringToValue$b(enumRef, value) {
|
|
566
573
|
if (typeof value === 'number') {
|
|
567
574
|
return value;
|
|
568
575
|
}
|
|
@@ -588,7 +595,7 @@ class Message {
|
|
|
588
595
|
let m = new Message();
|
|
589
596
|
m = Object.assign(m, proto);
|
|
590
597
|
if (proto.type) {
|
|
591
|
-
m.type = enumStringToValue$
|
|
598
|
+
m.type = enumStringToValue$b(MessageType, proto.type);
|
|
592
599
|
}
|
|
593
600
|
if (proto.created) {
|
|
594
601
|
m.created = new Date(proto.created);
|
|
@@ -603,7 +610,7 @@ class Message {
|
|
|
603
610
|
m.sendStatus = SendStatus.fromProto(proto.sendStatus);
|
|
604
611
|
}
|
|
605
612
|
if (proto.channel) {
|
|
606
|
-
m.channel = enumStringToValue$
|
|
613
|
+
m.channel = enumStringToValue$b(ConversationChannel, proto.channel);
|
|
607
614
|
}
|
|
608
615
|
if (proto.metadata) {
|
|
609
616
|
m.metadata = proto.metadata.map(KeyValuePair.fromProto);
|
|
@@ -675,7 +682,7 @@ class ParticipantMessageStatus {
|
|
|
675
682
|
let m = new ParticipantMessageStatus();
|
|
676
683
|
m = Object.assign(m, proto);
|
|
677
684
|
if (proto.status) {
|
|
678
|
-
m.status = enumStringToValue$
|
|
685
|
+
m.status = enumStringToValue$b(MessageStatus, proto.status);
|
|
679
686
|
}
|
|
680
687
|
if (proto.updated) {
|
|
681
688
|
m.updated = new Date(proto.updated);
|
|
@@ -713,7 +720,7 @@ class SendStatus {
|
|
|
713
720
|
let m = new SendStatus();
|
|
714
721
|
m = Object.assign(m, proto);
|
|
715
722
|
if (proto.status) {
|
|
716
|
-
m.status = enumStringToValue$
|
|
723
|
+
m.status = enumStringToValue$b(MessageStatus, proto.status);
|
|
717
724
|
}
|
|
718
725
|
if (proto.created) {
|
|
719
726
|
m.created = new Date(proto.created);
|
|
@@ -741,7 +748,7 @@ class SendStatus {
|
|
|
741
748
|
}
|
|
742
749
|
}
|
|
743
750
|
|
|
744
|
-
function enumStringToValue$
|
|
751
|
+
function enumStringToValue$a(enumRef, value) {
|
|
745
752
|
if (typeof value === 'number') {
|
|
746
753
|
return value;
|
|
747
754
|
}
|
|
@@ -812,10 +819,10 @@ class Participant {
|
|
|
812
819
|
let m = new Participant();
|
|
813
820
|
m = Object.assign(m, proto);
|
|
814
821
|
if (proto.location) {
|
|
815
|
-
m.location = enumStringToValue$
|
|
822
|
+
m.location = enumStringToValue$a(PlatformLocation, proto.location);
|
|
816
823
|
}
|
|
817
824
|
if (proto.channel) {
|
|
818
|
-
m.channel = enumStringToValue$
|
|
825
|
+
m.channel = enumStringToValue$a(ConversationChannel, proto.channel);
|
|
819
826
|
}
|
|
820
827
|
if (proto.created) {
|
|
821
828
|
m.created = new Date(proto.created);
|
|
@@ -827,7 +834,7 @@ class Participant {
|
|
|
827
834
|
m.deleted = new Date(proto.deleted);
|
|
828
835
|
}
|
|
829
836
|
if (proto.participantType) {
|
|
830
|
-
m.participantType = enumStringToValue$
|
|
837
|
+
m.participantType = enumStringToValue$a(ParticipantType, proto.participantType);
|
|
831
838
|
}
|
|
832
839
|
if (proto.address) {
|
|
833
840
|
m.address = Address.fromProto(proto.address);
|
|
@@ -917,13 +924,13 @@ class ParticipantKey {
|
|
|
917
924
|
let m = new ParticipantKey();
|
|
918
925
|
m = Object.assign(m, proto);
|
|
919
926
|
if (proto.location) {
|
|
920
|
-
m.location = enumStringToValue$
|
|
927
|
+
m.location = enumStringToValue$a(PlatformLocation, proto.location);
|
|
921
928
|
}
|
|
922
929
|
if (proto.channels) {
|
|
923
|
-
m.channels = proto.channels.map((v) => enumStringToValue$
|
|
930
|
+
m.channels = proto.channels.map((v) => enumStringToValue$a(ConversationChannel, v));
|
|
924
931
|
}
|
|
925
932
|
if (proto.participantType) {
|
|
926
|
-
m.participantType = enumStringToValue$
|
|
933
|
+
m.participantType = enumStringToValue$a(GlobalParticipantType, proto.participantType);
|
|
927
934
|
}
|
|
928
935
|
if (proto.namespaceHierarchy) {
|
|
929
936
|
m.namespaceHierarchy = proto.namespaceHierarchy.map(NamespaceDetail.fromProto);
|
|
@@ -963,7 +970,7 @@ class ParticipantKey {
|
|
|
963
970
|
}
|
|
964
971
|
}
|
|
965
972
|
|
|
966
|
-
function enumStringToValue$
|
|
973
|
+
function enumStringToValue$9(enumRef, value) {
|
|
967
974
|
if (typeof value === 'number') {
|
|
968
975
|
return value;
|
|
969
976
|
}
|
|
@@ -995,7 +1002,7 @@ class Access {
|
|
|
995
1002
|
}
|
|
996
1003
|
}
|
|
997
1004
|
|
|
998
|
-
function enumStringToValue$
|
|
1005
|
+
function enumStringToValue$8(enumRef, value) {
|
|
999
1006
|
if (typeof value === 'number') {
|
|
1000
1007
|
return value;
|
|
1001
1008
|
}
|
|
@@ -1157,7 +1164,7 @@ class ProductFeature {
|
|
|
1157
1164
|
}
|
|
1158
1165
|
}
|
|
1159
1166
|
|
|
1160
|
-
function enumStringToValue$
|
|
1167
|
+
function enumStringToValue$7(enumRef, value) {
|
|
1161
1168
|
if (typeof value === 'number') {
|
|
1162
1169
|
return value;
|
|
1163
1170
|
}
|
|
@@ -1192,7 +1199,7 @@ class View {
|
|
|
1192
1199
|
}
|
|
1193
1200
|
}
|
|
1194
1201
|
|
|
1195
|
-
function enumStringToValue$
|
|
1202
|
+
function enumStringToValue$6(enumRef, value) {
|
|
1196
1203
|
if (typeof value === 'number') {
|
|
1197
1204
|
return value;
|
|
1198
1205
|
}
|
|
@@ -1249,7 +1256,7 @@ class Widget {
|
|
|
1249
1256
|
let m = new Widget();
|
|
1250
1257
|
m = Object.assign(m, proto);
|
|
1251
1258
|
if (proto.position) {
|
|
1252
|
-
m.position = enumStringToValue$
|
|
1259
|
+
m.position = enumStringToValue$6(WidgetPosition, proto.position);
|
|
1253
1260
|
}
|
|
1254
1261
|
if (proto.created) {
|
|
1255
1262
|
m.created = new Date(proto.created);
|
|
@@ -1334,6 +1341,56 @@ class Widget {
|
|
|
1334
1341
|
}
|
|
1335
1342
|
}
|
|
1336
1343
|
|
|
1344
|
+
function enumStringToValue$5(enumRef, value) {
|
|
1345
|
+
if (typeof value === 'number') {
|
|
1346
|
+
return value;
|
|
1347
|
+
}
|
|
1348
|
+
return enumRef[value];
|
|
1349
|
+
}
|
|
1350
|
+
class ResponseEvaluation {
|
|
1351
|
+
messageId;
|
|
1352
|
+
conversationId;
|
|
1353
|
+
sentiment;
|
|
1354
|
+
comment;
|
|
1355
|
+
createdAt;
|
|
1356
|
+
static fromProto(proto) {
|
|
1357
|
+
let m = new ResponseEvaluation();
|
|
1358
|
+
m = Object.assign(m, proto);
|
|
1359
|
+
if (proto.sentiment) {
|
|
1360
|
+
m.sentiment = enumStringToValue$5(EvaluationSentiment, proto.sentiment);
|
|
1361
|
+
}
|
|
1362
|
+
if (proto.createdAt) {
|
|
1363
|
+
m.createdAt = new Date(proto.createdAt);
|
|
1364
|
+
}
|
|
1365
|
+
return m;
|
|
1366
|
+
}
|
|
1367
|
+
constructor(kwargs) {
|
|
1368
|
+
if (!kwargs) {
|
|
1369
|
+
return;
|
|
1370
|
+
}
|
|
1371
|
+
Object.assign(this, kwargs);
|
|
1372
|
+
}
|
|
1373
|
+
toApiJson() {
|
|
1374
|
+
const toReturn = {};
|
|
1375
|
+
if (typeof this.messageId !== 'undefined') {
|
|
1376
|
+
toReturn['messageId'] = this.messageId;
|
|
1377
|
+
}
|
|
1378
|
+
if (typeof this.conversationId !== 'undefined') {
|
|
1379
|
+
toReturn['conversationId'] = this.conversationId;
|
|
1380
|
+
}
|
|
1381
|
+
if (typeof this.sentiment !== 'undefined') {
|
|
1382
|
+
toReturn['sentiment'] = this.sentiment;
|
|
1383
|
+
}
|
|
1384
|
+
if (typeof this.comment !== 'undefined') {
|
|
1385
|
+
toReturn['comment'] = this.comment;
|
|
1386
|
+
}
|
|
1387
|
+
if (typeof this.createdAt !== 'undefined' && this.createdAt !== null) {
|
|
1388
|
+
toReturn['createdAt'] = 'toApiJson' in this.createdAt ? this.createdAt.toApiJson() : this.createdAt;
|
|
1389
|
+
}
|
|
1390
|
+
return toReturn;
|
|
1391
|
+
}
|
|
1392
|
+
}
|
|
1393
|
+
|
|
1337
1394
|
function enumStringToValue$4(enumRef, value) {
|
|
1338
1395
|
if (typeof value === 'number') {
|
|
1339
1396
|
return value;
|
|
@@ -3415,6 +3472,7 @@ class GetWidgetConfigResponse {
|
|
|
3415
3472
|
hideMobileCta;
|
|
3416
3473
|
customGreetingMessage;
|
|
3417
3474
|
enableGreetingMessage;
|
|
3475
|
+
namespace;
|
|
3418
3476
|
static fromProto(proto) {
|
|
3419
3477
|
let m = new GetWidgetConfigResponse();
|
|
3420
3478
|
m = Object.assign(m, proto);
|
|
@@ -3479,6 +3537,9 @@ class GetWidgetConfigResponse {
|
|
|
3479
3537
|
if (typeof this.enableGreetingMessage !== 'undefined') {
|
|
3480
3538
|
toReturn['enableGreetingMessage'] = this.enableGreetingMessage;
|
|
3481
3539
|
}
|
|
3540
|
+
if (typeof this.namespace !== 'undefined') {
|
|
3541
|
+
toReturn['namespace'] = this.namespace;
|
|
3542
|
+
}
|
|
3482
3543
|
return toReturn;
|
|
3483
3544
|
}
|
|
3484
3545
|
}
|
|
@@ -3847,6 +3908,90 @@ class ListMessagesResponse {
|
|
|
3847
3908
|
return toReturn;
|
|
3848
3909
|
}
|
|
3849
3910
|
}
|
|
3911
|
+
class ListResponseEvaluationsRequest {
|
|
3912
|
+
summarize;
|
|
3913
|
+
subjectParticipant;
|
|
3914
|
+
pagingOptions;
|
|
3915
|
+
createdAfter;
|
|
3916
|
+
createdBefore;
|
|
3917
|
+
static fromProto(proto) {
|
|
3918
|
+
let m = new ListResponseEvaluationsRequest();
|
|
3919
|
+
m = Object.assign(m, proto);
|
|
3920
|
+
if (proto.subjectParticipant) {
|
|
3921
|
+
m.subjectParticipant = SubjectParticipant.fromProto(proto.subjectParticipant);
|
|
3922
|
+
}
|
|
3923
|
+
if (proto.pagingOptions) {
|
|
3924
|
+
m.pagingOptions = PagedRequestOptions.fromProto(proto.pagingOptions);
|
|
3925
|
+
}
|
|
3926
|
+
if (proto.createdAfter) {
|
|
3927
|
+
m.createdAfter = new Date(proto.createdAfter);
|
|
3928
|
+
}
|
|
3929
|
+
if (proto.createdBefore) {
|
|
3930
|
+
m.createdBefore = new Date(proto.createdBefore);
|
|
3931
|
+
}
|
|
3932
|
+
return m;
|
|
3933
|
+
}
|
|
3934
|
+
constructor(kwargs) {
|
|
3935
|
+
if (!kwargs) {
|
|
3936
|
+
return;
|
|
3937
|
+
}
|
|
3938
|
+
Object.assign(this, kwargs);
|
|
3939
|
+
}
|
|
3940
|
+
toApiJson() {
|
|
3941
|
+
const toReturn = {};
|
|
3942
|
+
if (typeof this.summarize !== 'undefined') {
|
|
3943
|
+
toReturn['summarize'] = this.summarize;
|
|
3944
|
+
}
|
|
3945
|
+
if (typeof this.subjectParticipant !== 'undefined' && this.subjectParticipant !== null) {
|
|
3946
|
+
toReturn['subjectParticipant'] = 'toApiJson' in this.subjectParticipant ? this.subjectParticipant.toApiJson() : this.subjectParticipant;
|
|
3947
|
+
}
|
|
3948
|
+
if (typeof this.pagingOptions !== 'undefined' && this.pagingOptions !== null) {
|
|
3949
|
+
toReturn['pagingOptions'] = 'toApiJson' in this.pagingOptions ? this.pagingOptions.toApiJson() : this.pagingOptions;
|
|
3950
|
+
}
|
|
3951
|
+
if (typeof this.createdAfter !== 'undefined' && this.createdAfter !== null) {
|
|
3952
|
+
toReturn['createdAfter'] = 'toApiJson' in this.createdAfter ? this.createdAfter.toApiJson() : this.createdAfter;
|
|
3953
|
+
}
|
|
3954
|
+
if (typeof this.createdBefore !== 'undefined' && this.createdBefore !== null) {
|
|
3955
|
+
toReturn['createdBefore'] = 'toApiJson' in this.createdBefore ? this.createdBefore.toApiJson() : this.createdBefore;
|
|
3956
|
+
}
|
|
3957
|
+
return toReturn;
|
|
3958
|
+
}
|
|
3959
|
+
}
|
|
3960
|
+
class ListResponseEvaluationsResponse {
|
|
3961
|
+
evaluations;
|
|
3962
|
+
summary;
|
|
3963
|
+
pagingMetadata;
|
|
3964
|
+
static fromProto(proto) {
|
|
3965
|
+
let m = new ListResponseEvaluationsResponse();
|
|
3966
|
+
m = Object.assign(m, proto);
|
|
3967
|
+
if (proto.evaluations) {
|
|
3968
|
+
m.evaluations = proto.evaluations.map(ResponseEvaluation.fromProto);
|
|
3969
|
+
}
|
|
3970
|
+
if (proto.pagingMetadata) {
|
|
3971
|
+
m.pagingMetadata = PagedResponseMetadata.fromProto(proto.pagingMetadata);
|
|
3972
|
+
}
|
|
3973
|
+
return m;
|
|
3974
|
+
}
|
|
3975
|
+
constructor(kwargs) {
|
|
3976
|
+
if (!kwargs) {
|
|
3977
|
+
return;
|
|
3978
|
+
}
|
|
3979
|
+
Object.assign(this, kwargs);
|
|
3980
|
+
}
|
|
3981
|
+
toApiJson() {
|
|
3982
|
+
const toReturn = {};
|
|
3983
|
+
if (typeof this.evaluations !== 'undefined' && this.evaluations !== null) {
|
|
3984
|
+
toReturn['evaluations'] = 'toApiJson' in this.evaluations ? this.evaluations.toApiJson() : this.evaluations;
|
|
3985
|
+
}
|
|
3986
|
+
if (typeof this.summary !== 'undefined') {
|
|
3987
|
+
toReturn['summary'] = this.summary;
|
|
3988
|
+
}
|
|
3989
|
+
if (typeof this.pagingMetadata !== 'undefined' && this.pagingMetadata !== null) {
|
|
3990
|
+
toReturn['pagingMetadata'] = 'toApiJson' in this.pagingMetadata ? this.pagingMetadata.toApiJson() : this.pagingMetadata;
|
|
3991
|
+
}
|
|
3992
|
+
return toReturn;
|
|
3993
|
+
}
|
|
3994
|
+
}
|
|
3850
3995
|
class ListWidgetsRequestListWidgetsFilters {
|
|
3851
3996
|
namespaces;
|
|
3852
3997
|
widgetTypes;
|
|
@@ -4495,6 +4640,27 @@ class SearchConversationsResponse {
|
|
|
4495
4640
|
return toReturn;
|
|
4496
4641
|
}
|
|
4497
4642
|
}
|
|
4643
|
+
class SendMessageOptions {
|
|
4644
|
+
runSync;
|
|
4645
|
+
static fromProto(proto) {
|
|
4646
|
+
let m = new SendMessageOptions();
|
|
4647
|
+
m = Object.assign(m, proto);
|
|
4648
|
+
return m;
|
|
4649
|
+
}
|
|
4650
|
+
constructor(kwargs) {
|
|
4651
|
+
if (!kwargs) {
|
|
4652
|
+
return;
|
|
4653
|
+
}
|
|
4654
|
+
Object.assign(this, kwargs);
|
|
4655
|
+
}
|
|
4656
|
+
toApiJson() {
|
|
4657
|
+
const toReturn = {};
|
|
4658
|
+
if (typeof this.runSync !== 'undefined') {
|
|
4659
|
+
toReturn['runSync'] = this.runSync;
|
|
4660
|
+
}
|
|
4661
|
+
return toReturn;
|
|
4662
|
+
}
|
|
4663
|
+
}
|
|
4498
4664
|
class SendMessageRequest {
|
|
4499
4665
|
sender;
|
|
4500
4666
|
recipient;
|
|
@@ -4505,6 +4671,7 @@ class SendMessageRequest {
|
|
|
4505
4671
|
originLocation;
|
|
4506
4672
|
media;
|
|
4507
4673
|
channel;
|
|
4674
|
+
options;
|
|
4508
4675
|
static fromProto(proto) {
|
|
4509
4676
|
let m = new SendMessageRequest();
|
|
4510
4677
|
m = Object.assign(m, proto);
|
|
@@ -4529,6 +4696,9 @@ class SendMessageRequest {
|
|
|
4529
4696
|
if (proto.channel) {
|
|
4530
4697
|
m.channel = enumStringToValue(ConversationChannel, proto.channel);
|
|
4531
4698
|
}
|
|
4699
|
+
if (proto.options) {
|
|
4700
|
+
m.options = SendMessageOptions.fromProto(proto.options);
|
|
4701
|
+
}
|
|
4532
4702
|
return m;
|
|
4533
4703
|
}
|
|
4534
4704
|
constructor(kwargs) {
|
|
@@ -4566,6 +4736,9 @@ class SendMessageRequest {
|
|
|
4566
4736
|
if (typeof this.channel !== 'undefined') {
|
|
4567
4737
|
toReturn['channel'] = this.channel;
|
|
4568
4738
|
}
|
|
4739
|
+
if (typeof this.options !== 'undefined' && this.options !== null) {
|
|
4740
|
+
toReturn['options'] = 'toApiJson' in this.options ? this.options.toApiJson() : this.options;
|
|
4741
|
+
}
|
|
4569
4742
|
return toReturn;
|
|
4570
4743
|
}
|
|
4571
4744
|
}
|
|
@@ -5319,6 +5492,11 @@ class ConversationApiService {
|
|
|
5319
5492
|
const request = (r.toApiJson) ? r : new EvaluateResponseRequest(r);
|
|
5320
5493
|
return this.http.post(this._host + "/conversation.v1.ConversationService/EvaluateResponse", request.toApiJson(), { ...this.apiOptions(), observe: 'response' });
|
|
5321
5494
|
}
|
|
5495
|
+
listResponseEvaluations(r) {
|
|
5496
|
+
const request = (r.toApiJson) ? r : new ListResponseEvaluationsRequest(r);
|
|
5497
|
+
return this.http.post(this._host + "/conversation.v1.ConversationService/ListResponseEvaluations", request.toApiJson(), this.apiOptions())
|
|
5498
|
+
.pipe(map(resp => ListResponseEvaluationsResponse.fromProto(resp)));
|
|
5499
|
+
}
|
|
5322
5500
|
createWidget(r) {
|
|
5323
5501
|
const request = (r.toApiJson) ? r : new CreateWidgetRequest(r);
|
|
5324
5502
|
return this.http.post(this._host + "/conversation.v1.ConversationService/CreateWidget", request.toApiJson(), this.apiOptions())
|
|
@@ -5492,5 +5670,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
|
|
|
5492
5670
|
* Generated bundle index. Do not edit.
|
|
5493
5671
|
*/
|
|
5494
5672
|
|
|
5495
|
-
export { AIConfiguration, AISystemMessage, AISystemMessageApiService, Access, AddConversationToConversationViewRequest, AddMultiParticipantsRequest, AddMultiParticipantsResponse, Address, CapturedLead, ChannelAvailability, ChannelStatus, Configuration, ConfigurationAIConfiguration, Conversation, ConversationApiService, ConversationChannel, ConversationKey, ConversationMessageCount, CreateConversationRequest, CreateConversationResponse, CreateMessageTemplateRequest, CreateMessageTemplateResponse, CreateMultiMessagesRequest, CreateWidgetConversationRequest, CreateWidgetConversationResponse, CreateWidgetRequest, CreateWidgetResponse, DataSources, DeleteConversationRequest, DeleteMessageRequest, DeleteMessageTemplateRequest, DeleteWidgetRequest, EmailApiService, EvaluateResponseRequest, EvaluationSentiment, Event, EventType, FieldMask, GetAISystemMessageRequest, GetAISystemMessageResponse, GetAvailableChannelsForConversationRequest, GetAvailableChannelsForConversationResponse, GetConfigurationRequest, GetConfigurationResponse, GetConversationByKeyRequest, GetConversationByKeyResponse, GetConversationSummaryRequest, GetConversationSummaryResponse, GetConversationViewsRequest, GetConversationViewsResponse, GetMessageOptions, GetMessageRequest, GetMessageTemplateRequest, GetMessageTemplateRequestHydrationOptions, GetMessageTemplateRequestHydrationOptionsHydrationEntity, GetMessageTemplateRequestHydrationOptionsHydrationEntityEntityType, GetMessageTemplateResponse, GetMessageTemplateResponseHydrationInformation, GetMultiConfigurationRequest, GetMultiConfigurationResponse, GetMultiConversationDetailsRequest, GetMultiConversationDetailsResponse, GetMultiConversationDetailsResponseDetailedConversation, GetMultiConversationMessageCountRequest, GetMultiConversationMessageCountResponse, GetMultiConversationMessageCountResponseCountsEntry, GetMultiEventsRequest, GetMultiEventsResponse, GetMultiMessagesRequest, GetMultiMessagesResponse, GetMultiParticipantsRequest, GetMultiParticipantsResponse, GetMultiWidgetMessagesRequest, GetMultiWidgetMessagesResponse, GetMultiWidgetRequest, GetMultiWidgetResponse, GetOwnerEmailRequest, GetOwnerEmailResponse, GetParticipantsByKeyRequest, GetParticipantsByKeyResponse, GetWidgetConfigRequest, GetWidgetConfigResponse, GetWidgetConversationResponse, GetWidgetRequest, GetWidgetResponse, GlobalParticipantType, InboxApiService, InjectMessageRequest, InjectMessageRequestMetadataEntry, KeyValuePair, LastSeenByParticipant, LatestMessageSentTimeBySubjectParticipant, ListAISystemMessagesRequest, ListAISystemMessagesResponse, ListMessageTemplateRequest, ListMessageTemplateResponse, ListMessagesRequest, ListMessagesRequestListMessagesFilters, ListMessagesResponse, ListWidgetsRequest, ListWidgetsRequestListWidgetsFilters, ListWidgetsResponse, LookupConversationsRequest, LookupConversationsRequestLookupConversationsFilters, LookupConversationsResponse, LookupConversationsResponseConversations, Media, Message, MessageStatus, MessageTemplate, MessageType, Metadata, MetadataDataEntry, MetadataIdentifier, NamespaceDetail, NewInboxLeadCapturedRequest, NewInboxLeadCapturedResponse, PagedRequestOptions, PagedResponseMetadata, Participant, ParticipantKey, ParticipantMessageStatus, ParticipantType, PlatformLocation, ProductFeature, ReceiveMessageRequest, ReceiveMessageRequestMetadataEntry, RemoveConversationFromConversationViewRequest, SearchConversationsRequest, SearchConversationsResponse, SearchConversationsResponseDetailedConversation, SendMessageRequest, SendMessageResponse, SendStatus, SendWidgetMessageRequest, SendWidgetMessageResponse, SetLastSeenRequest, SetLastSeenRequestStatus, SetLastSeenResponse, SortDirection, Status, SubjectParticipant, SubjectParticipantKey, UpdateConversationRequest, UpdateConversationResponse, UpdateMessageStatusRequest, UpdateMessageTemplateRequest, UpdateMessageTemplateResponse, UpdateWidgetRequest, UpdateWidgetResponse, UpsertAISystemMessageRequest, UpsertConfigurationRequest, UpsertConfigurationResponse, UpsertProductFeatureRequest, UpsertProductFeatureResponse, View, ViewType, Widget, WidgetPosition };
|
|
5673
|
+
export { AIConfiguration, AISystemMessage, AISystemMessageApiService, Access, AddConversationToConversationViewRequest, AddMultiParticipantsRequest, AddMultiParticipantsResponse, Address, CapturedLead, ChannelAvailability, ChannelStatus, Configuration, ConfigurationAIConfiguration, Conversation, ConversationApiService, ConversationChannel, ConversationKey, ConversationMessageCount, CreateConversationRequest, CreateConversationResponse, CreateMessageTemplateRequest, CreateMessageTemplateResponse, CreateMultiMessagesRequest, CreateWidgetConversationRequest, CreateWidgetConversationResponse, CreateWidgetRequest, CreateWidgetResponse, DataSources, DeleteConversationRequest, DeleteMessageRequest, DeleteMessageTemplateRequest, DeleteWidgetRequest, EmailApiService, EvaluateResponseRequest, EvaluationSentiment, Event, EventType, FieldMask, GetAISystemMessageRequest, GetAISystemMessageResponse, GetAvailableChannelsForConversationRequest, GetAvailableChannelsForConversationResponse, GetConfigurationRequest, GetConfigurationResponse, GetConversationByKeyRequest, GetConversationByKeyResponse, GetConversationSummaryRequest, GetConversationSummaryResponse, GetConversationViewsRequest, GetConversationViewsResponse, GetMessageOptions, GetMessageRequest, GetMessageTemplateRequest, GetMessageTemplateRequestHydrationOptions, GetMessageTemplateRequestHydrationOptionsHydrationEntity, GetMessageTemplateRequestHydrationOptionsHydrationEntityEntityType, GetMessageTemplateResponse, GetMessageTemplateResponseHydrationInformation, GetMultiConfigurationRequest, GetMultiConfigurationResponse, GetMultiConversationDetailsRequest, GetMultiConversationDetailsResponse, GetMultiConversationDetailsResponseDetailedConversation, GetMultiConversationMessageCountRequest, GetMultiConversationMessageCountResponse, GetMultiConversationMessageCountResponseCountsEntry, GetMultiEventsRequest, GetMultiEventsResponse, GetMultiMessagesRequest, GetMultiMessagesResponse, GetMultiParticipantsRequest, GetMultiParticipantsResponse, GetMultiWidgetMessagesRequest, GetMultiWidgetMessagesResponse, GetMultiWidgetRequest, GetMultiWidgetResponse, GetOwnerEmailRequest, GetOwnerEmailResponse, GetParticipantsByKeyRequest, GetParticipantsByKeyResponse, GetWidgetConfigRequest, GetWidgetConfigResponse, GetWidgetConversationResponse, GetWidgetRequest, GetWidgetResponse, GlobalParticipantType, InboxApiService, InjectMessageRequest, InjectMessageRequestMetadataEntry, KeyValuePair, LastSeenByParticipant, LatestMessageSentTimeBySubjectParticipant, ListAISystemMessagesRequest, ListAISystemMessagesResponse, ListMessageTemplateRequest, ListMessageTemplateResponse, ListMessagesRequest, ListMessagesRequestListMessagesFilters, ListMessagesResponse, ListResponseEvaluationsRequest, ListResponseEvaluationsResponse, ListWidgetsRequest, ListWidgetsRequestListWidgetsFilters, ListWidgetsResponse, LookupConversationsRequest, LookupConversationsRequestLookupConversationsFilters, LookupConversationsResponse, LookupConversationsResponseConversations, Media, Message, MessageStatus, MessageTemplate, MessageType, Metadata, MetadataDataEntry, MetadataIdentifier, NamespaceDetail, NewInboxLeadCapturedRequest, NewInboxLeadCapturedResponse, PagedRequestOptions, PagedResponseMetadata, Participant, ParticipantKey, ParticipantMessageStatus, ParticipantType, PlatformLocation, ProductFeature, ReceiveMessageRequest, ReceiveMessageRequestMetadataEntry, RemoveConversationFromConversationViewRequest, ResponseEvaluation, SearchConversationsRequest, SearchConversationsResponse, SearchConversationsResponseDetailedConversation, SendMessageOptions, SendMessageRequest, SendMessageResponse, SendStatus, SendWidgetMessageRequest, SendWidgetMessageResponse, SetLastSeenRequest, SetLastSeenRequestStatus, SetLastSeenResponse, SortDirection, Status, SubjectParticipant, SubjectParticipantKey, UpdateConversationRequest, UpdateConversationResponse, UpdateMessageStatusRequest, UpdateMessageTemplateRequest, UpdateMessageTemplateResponse, UpdateWidgetRequest, UpdateWidgetResponse, UpsertAISystemMessageRequest, UpsertConfigurationRequest, UpsertConfigurationResponse, UpsertProductFeatureRequest, UpsertProductFeatureResponse, View, ViewType, Widget, WidgetPosition };
|
|
5496
5674
|
//# sourceMappingURL=vendasta-conversation.mjs.map
|