@d19n/youfibre-odin-sdk 2.0.141 → 2.0.143
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/README.md +2 -1
- package/dist/actions-v2/UpdateCallOnInboundCallAnsweredDto.d.ts +10 -20
- package/dist/actions-v2/UpdateCallOnTaskCanceledDto.d.ts +66 -0
- package/dist/actions-v2/UpdateCallOnTaskCanceledDto.js +52 -0
- package/dist/records-v2/CallRecord.d.ts +35 -7
- package/dist/records-v2/CallRecord.js +43 -15
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -353,7 +353,7 @@ This SDK includes **165** entities across **12** modules.
|
|
|
353
353
|
|
|
354
354
|
## Actions
|
|
355
355
|
|
|
356
|
-
This SDK includes **
|
|
356
|
+
This SDK includes **685** actions.
|
|
357
357
|
|
|
358
358
|
### Action Types
|
|
359
359
|
|
|
@@ -1289,6 +1289,7 @@ This SDK includes **684** actions.
|
|
|
1289
1289
|
| `UpdateCallOnOutboundCallFailed` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Call.Update.UpdateCallOnOutboundCallFailed |
|
|
1290
1290
|
| `UpdateCallOnOutboundCallNoAnswer` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Call.Update.UpdateCallOnOutboundCallNoAnswer |
|
|
1291
1291
|
| `UpdateCallOnOutboundDialAction` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Call.Update.UpdateCallOnOutboundDialAction |
|
|
1292
|
+
| `UpdateCallOnTaskCanceled` | CREATE | k1.t-hEOJjsDb.NotificationModule.Call.Create.UpdateCallOnTaskCanceled |
|
|
1292
1293
|
| `UpdateCallOnTaskRouterAssign` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Call.Update.UpdateCallOnTaskRouterAssign |
|
|
1293
1294
|
| `UpdateCallTranscriptionUrl` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Call.Update.UpdateCallTranscriptionUrl |
|
|
1294
1295
|
|
|
@@ -21,52 +21,42 @@ export interface UpdateCallOnInboundCallAnsweredMessage extends OdinRecordUpdate
|
|
|
21
21
|
/**
|
|
22
22
|
* Properties for UpdateCallOnInboundCallAnswered action
|
|
23
23
|
*
|
|
24
|
-
* @property Required fields:
|
|
25
|
-
* @property Optional fields:
|
|
24
|
+
* @property Required fields: 4
|
|
25
|
+
* @property Optional fields: 0
|
|
26
26
|
*/
|
|
27
27
|
export interface UpdateCallOnInboundCallAnsweredProperties {
|
|
28
|
-
/**
|
|
29
|
-
* CurrentAgentEmail
|
|
30
|
-
*
|
|
31
|
-
* Email of currently assigned agent (Communications - Call)
|
|
32
|
-
* @type {TEXT}
|
|
33
|
-
*/
|
|
34
|
-
CurrentAgentEmail?: string | null;
|
|
35
|
-
/**
|
|
36
|
-
* user Id
|
|
37
|
-
*
|
|
38
|
-
* The Odin user that handled the call (Communications - Call)
|
|
39
|
-
* @type {UUID}
|
|
40
|
-
*/
|
|
41
|
-
UserId?: string | null;
|
|
42
28
|
/**
|
|
43
29
|
* Call stage
|
|
44
30
|
*
|
|
45
31
|
* The granular stage of a call, more extensive than CallStatus (Communications - Call)
|
|
46
32
|
* @type {ENUM}
|
|
33
|
+
* @required
|
|
47
34
|
*/
|
|
48
|
-
CallStage
|
|
35
|
+
CallStage: string;
|
|
49
36
|
/**
|
|
50
37
|
* call status
|
|
51
38
|
*
|
|
52
39
|
* the status of the call (Communications - Call)
|
|
53
40
|
* @type {TEXT}
|
|
41
|
+
* @required
|
|
54
42
|
*/
|
|
55
|
-
CallStatus
|
|
43
|
+
CallStatus: string;
|
|
56
44
|
/**
|
|
57
45
|
* AnswerTime
|
|
58
46
|
*
|
|
59
47
|
* When customer call was answered (Communications - Call)
|
|
60
48
|
* @type {DATE_TIME}
|
|
49
|
+
* @required
|
|
61
50
|
*/
|
|
62
|
-
AnswerTime
|
|
51
|
+
AnswerTime: string;
|
|
63
52
|
/**
|
|
64
53
|
* QueueTime
|
|
65
54
|
*
|
|
66
55
|
* Seconds spent in queue (Communications - Call)
|
|
67
56
|
* @type {NUMBER}
|
|
57
|
+
* @required
|
|
68
58
|
*/
|
|
69
|
-
QueueTime
|
|
59
|
+
QueueTime: number;
|
|
70
60
|
}
|
|
71
61
|
/**
|
|
72
62
|
* UpdateCallOnInboundCallAnswered
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* UpdateCallOnTaskCanceled Action DTO
|
|
3
|
+
*
|
|
4
|
+
* UpdateCallOnTaskCanceled
|
|
5
|
+
*
|
|
6
|
+
* @module NotificationModule
|
|
7
|
+
* @entity Call
|
|
8
|
+
* @actionKey UpdateCallOnTaskCanceled
|
|
9
|
+
* @event k1.t-hEOJjsDb.NotificationModule.Call.Create.UpdateCallOnTaskCanceled
|
|
10
|
+
*
|
|
11
|
+
* AUTO-GENERATED - DO NOT EDIT DIRECTLY
|
|
12
|
+
*/
|
|
13
|
+
import { OdinRecordCreateDto, OdinRecordCreatedEvent } from '@d19n/odin-types/dist/core';
|
|
14
|
+
/**
|
|
15
|
+
* RabbitMQ message payload for UpdateCallOnTaskCanceled created events
|
|
16
|
+
*
|
|
17
|
+
* @event k1.t-hEOJjsDb.NotificationModule.Call.Create.UpdateCallOnTaskCanceled
|
|
18
|
+
*/
|
|
19
|
+
export interface UpdateCallOnTaskCanceledMessage extends OdinRecordCreatedEvent<UpdateCallOnTaskCanceledDto, UpdateCallOnTaskCanceledProperties> {
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Properties for UpdateCallOnTaskCanceled action
|
|
23
|
+
*
|
|
24
|
+
* @property Required fields: 1
|
|
25
|
+
* @property Optional fields: 0
|
|
26
|
+
*/
|
|
27
|
+
export interface UpdateCallOnTaskCanceledProperties {
|
|
28
|
+
/**
|
|
29
|
+
* missed call reason
|
|
30
|
+
*
|
|
31
|
+
* reason for the call being missed (Communications - Call)
|
|
32
|
+
* @type {TEXT}
|
|
33
|
+
* @required
|
|
34
|
+
*/
|
|
35
|
+
MissedCallReason: string;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* UpdateCallOnTaskCanceled
|
|
39
|
+
*
|
|
40
|
+
* @actionType CREATE - Creates a new Call record
|
|
41
|
+
* @module NotificationModule
|
|
42
|
+
* @entity Call
|
|
43
|
+
* @event k1.t-hEOJjsDb.NotificationModule.Call.Create.UpdateCallOnTaskCanceled
|
|
44
|
+
* @permission schema.action.updatecallontaskcanceled.trigger
|
|
45
|
+
* @benchmark This action is tracked for performance benchmarks
|
|
46
|
+
*/
|
|
47
|
+
export declare class UpdateCallOnTaskCanceledDto extends OdinRecordCreateDto<UpdateCallOnTaskCanceledProperties> {
|
|
48
|
+
/** Used by SDK generators to identify action type */
|
|
49
|
+
static readonly ACTION_TYPE = "CREATE";
|
|
50
|
+
static readonly ACTION_KEY = "UpdateCallOnTaskCanceled";
|
|
51
|
+
static readonly MODULE_NAME = "NotificationModule";
|
|
52
|
+
static readonly ENTITIES: string[];
|
|
53
|
+
static readonly EVENT_NAME = "k1.t-hEOJjsDb.NotificationModule.Call.Create.UpdateCallOnTaskCanceled";
|
|
54
|
+
static readonly PERMISSION = "schema.action.updatecallontaskcanceled.trigger";
|
|
55
|
+
/** Step metadata - entity this action targets */
|
|
56
|
+
static readonly STEP_ENTITY = "NotificationModule:Call";
|
|
57
|
+
static readonly STEP_SCHEMA_ID = "e157f15c-6846-4bfb-bc92-aed4c4084e9f";
|
|
58
|
+
static readonly STEP_SCHEMA_ACTION_ID = "7f8ddb83-6251-49d0-9c10-80a07d1a94e6";
|
|
59
|
+
static readonly AUTO_LINK_PARENT = true;
|
|
60
|
+
readonly actionName: string;
|
|
61
|
+
readonly schemaActionId: string;
|
|
62
|
+
readonly entity: string;
|
|
63
|
+
constructor(properties: UpdateCallOnTaskCanceledProperties, options?: {
|
|
64
|
+
journeyId?: string;
|
|
65
|
+
});
|
|
66
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* UpdateCallOnTaskCanceled Action DTO
|
|
4
|
+
*
|
|
5
|
+
* UpdateCallOnTaskCanceled
|
|
6
|
+
*
|
|
7
|
+
* @module NotificationModule
|
|
8
|
+
* @entity Call
|
|
9
|
+
* @actionKey UpdateCallOnTaskCanceled
|
|
10
|
+
* @event k1.t-hEOJjsDb.NotificationModule.Call.Create.UpdateCallOnTaskCanceled
|
|
11
|
+
*
|
|
12
|
+
* AUTO-GENERATED - DO NOT EDIT DIRECTLY
|
|
13
|
+
*/
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
exports.UpdateCallOnTaskCanceledDto = void 0;
|
|
16
|
+
const core_1 = require("@d19n/odin-types/dist/core");
|
|
17
|
+
/**
|
|
18
|
+
* UpdateCallOnTaskCanceled
|
|
19
|
+
*
|
|
20
|
+
* @actionType CREATE - Creates a new Call record
|
|
21
|
+
* @module NotificationModule
|
|
22
|
+
* @entity Call
|
|
23
|
+
* @event k1.t-hEOJjsDb.NotificationModule.Call.Create.UpdateCallOnTaskCanceled
|
|
24
|
+
* @permission schema.action.updatecallontaskcanceled.trigger
|
|
25
|
+
* @benchmark This action is tracked for performance benchmarks
|
|
26
|
+
*/
|
|
27
|
+
class UpdateCallOnTaskCanceledDto extends core_1.OdinRecordCreateDto {
|
|
28
|
+
constructor(properties, options) {
|
|
29
|
+
super({
|
|
30
|
+
entity: 'NotificationModule:Call',
|
|
31
|
+
type: undefined,
|
|
32
|
+
properties,
|
|
33
|
+
journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
|
|
34
|
+
});
|
|
35
|
+
this.actionName = 'UpdateCallOnTaskCanceled';
|
|
36
|
+
this.schemaActionId = '7f8ddb83-6251-49d0-9c10-80a07d1a94e6';
|
|
37
|
+
this.entity = 'NotificationModule:Call';
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
exports.UpdateCallOnTaskCanceledDto = UpdateCallOnTaskCanceledDto;
|
|
41
|
+
/** Used by SDK generators to identify action type */
|
|
42
|
+
UpdateCallOnTaskCanceledDto.ACTION_TYPE = 'CREATE';
|
|
43
|
+
UpdateCallOnTaskCanceledDto.ACTION_KEY = 'UpdateCallOnTaskCanceled';
|
|
44
|
+
UpdateCallOnTaskCanceledDto.MODULE_NAME = 'NotificationModule';
|
|
45
|
+
UpdateCallOnTaskCanceledDto.ENTITIES = ['Call'];
|
|
46
|
+
UpdateCallOnTaskCanceledDto.EVENT_NAME = 'k1.t-hEOJjsDb.NotificationModule.Call.Create.UpdateCallOnTaskCanceled';
|
|
47
|
+
UpdateCallOnTaskCanceledDto.PERMISSION = 'schema.action.updatecallontaskcanceled.trigger';
|
|
48
|
+
/** Step metadata - entity this action targets */
|
|
49
|
+
UpdateCallOnTaskCanceledDto.STEP_ENTITY = 'NotificationModule:Call';
|
|
50
|
+
UpdateCallOnTaskCanceledDto.STEP_SCHEMA_ID = 'e157f15c-6846-4bfb-bc92-aed4c4084e9f';
|
|
51
|
+
UpdateCallOnTaskCanceledDto.STEP_SCHEMA_ACTION_ID = '7f8ddb83-6251-49d0-9c10-80a07d1a94e6';
|
|
52
|
+
UpdateCallOnTaskCanceledDto.AUTO_LINK_PARENT = true;
|
|
@@ -44,6 +44,7 @@ import { UpdateCallOnOutboundCallCompletedProperties } from '../actions-v2/Updat
|
|
|
44
44
|
import { UpdateCallOnOutboundCallFailedProperties } from '../actions-v2/UpdateCallOnOutboundCallFailedDto';
|
|
45
45
|
import { UpdateCallOnOutboundCallNoAnswerProperties } from '../actions-v2/UpdateCallOnOutboundCallNoAnswerDto';
|
|
46
46
|
import { UpdateCallOnOutboundDialActionProperties } from '../actions-v2/UpdateCallOnOutboundDialActionDto';
|
|
47
|
+
import { UpdateCallOnTaskCanceledProperties } from '../actions-v2/UpdateCallOnTaskCanceledDto';
|
|
47
48
|
import { UpdateCallOnTaskRouterAssignProperties } from '../actions-v2/UpdateCallOnTaskRouterAssignDto';
|
|
48
49
|
import { UpdateCallTranscriptionUrlProperties } from '../actions-v2/UpdateCallTranscriptionUrlDto';
|
|
49
50
|
import { LeadRecord } from './LeadRecord';
|
|
@@ -456,6 +457,34 @@ export declare class CallRecord<TProps = CallProperties> {
|
|
|
456
457
|
journeyId?: string;
|
|
457
458
|
stageKey?: string;
|
|
458
459
|
}): ActionBuilder;
|
|
460
|
+
/**
|
|
461
|
+
* UpdateCallOnTaskCanceled
|
|
462
|
+
*
|
|
463
|
+
* Creates a new Call record with the specified properties.
|
|
464
|
+
* Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
|
|
465
|
+
*
|
|
466
|
+
* @param properties - The properties for the new record
|
|
467
|
+
* @param options - Optional settings
|
|
468
|
+
* @param options.type - Override the record type
|
|
469
|
+
* @param options.journeyId - Associate with a journey
|
|
470
|
+
* @param options.stageKey - Set initial pipeline stage
|
|
471
|
+
* @returns ActionBuilder - call .execute() to create or .dryRun() for payload
|
|
472
|
+
*
|
|
473
|
+
* @example
|
|
474
|
+
* ```typescript
|
|
475
|
+
* // Create with properties
|
|
476
|
+
* const record = odinClient.calls.new();
|
|
477
|
+
* await record.updateCallOnTaskCanceled({ ... }).execute();
|
|
478
|
+
*
|
|
479
|
+
* // Dry run (for debugging)
|
|
480
|
+
* const payload = record.updateCallOnTaskCanceled({ ... }).dryRun();
|
|
481
|
+
* ```
|
|
482
|
+
*/
|
|
483
|
+
updateCallOnTaskCanceled(properties: UpdateCallOnTaskCanceledProperties, options?: {
|
|
484
|
+
type?: string;
|
|
485
|
+
journeyId?: string;
|
|
486
|
+
stageKey?: string;
|
|
487
|
+
}): ActionBuilder;
|
|
459
488
|
/**
|
|
460
489
|
* UpdateCallAnalytics
|
|
461
490
|
*
|
|
@@ -485,11 +514,13 @@ export declare class CallRecord<TProps = CallProperties> {
|
|
|
485
514
|
/**
|
|
486
515
|
* UpdateCallOnInboundCallAnswered
|
|
487
516
|
*
|
|
488
|
-
* Updates this Call record.
|
|
517
|
+
* Updates this Call record with the specified properties.
|
|
489
518
|
* Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
|
|
490
519
|
*
|
|
491
|
-
* @param
|
|
492
|
-
* @param options - Optional settings
|
|
520
|
+
* @param properties - Required properties for this action
|
|
521
|
+
* @param options - Optional settings
|
|
522
|
+
* @param options.journeyId - Associate with a journey
|
|
523
|
+
* @param options.stageKey - Transition to pipeline stage
|
|
493
524
|
* @returns ActionBuilder - call .execute() to update or .dryRun() for payload
|
|
494
525
|
* @throws Error if called on a new (unsaved) record
|
|
495
526
|
*
|
|
@@ -502,10 +533,7 @@ export declare class CallRecord<TProps = CallProperties> {
|
|
|
502
533
|
* const payload = record.updateCallOnInboundCallAnswered({ ... }).dryRun();
|
|
503
534
|
* ```
|
|
504
535
|
*/
|
|
505
|
-
updateCallOnInboundCallAnswered(
|
|
506
|
-
journeyId?: string;
|
|
507
|
-
stageKey?: string;
|
|
508
|
-
}, options?: {
|
|
536
|
+
updateCallOnInboundCallAnswered(properties: UpdateCallOnInboundCallAnsweredProperties, options?: {
|
|
509
537
|
journeyId?: string;
|
|
510
538
|
stageKey?: string;
|
|
511
539
|
}): ActionBuilder;
|
|
@@ -589,6 +589,42 @@ class CallRecord {
|
|
|
589
589
|
};
|
|
590
590
|
return new ActionBuilder(this._provider, 'NotificationModule', 'Call', payload, () => { this._pendingLinks = []; });
|
|
591
591
|
}
|
|
592
|
+
/**
|
|
593
|
+
* UpdateCallOnTaskCanceled
|
|
594
|
+
*
|
|
595
|
+
* Creates a new Call record with the specified properties.
|
|
596
|
+
* Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
|
|
597
|
+
*
|
|
598
|
+
* @param properties - The properties for the new record
|
|
599
|
+
* @param options - Optional settings
|
|
600
|
+
* @param options.type - Override the record type
|
|
601
|
+
* @param options.journeyId - Associate with a journey
|
|
602
|
+
* @param options.stageKey - Set initial pipeline stage
|
|
603
|
+
* @returns ActionBuilder - call .execute() to create or .dryRun() for payload
|
|
604
|
+
*
|
|
605
|
+
* @example
|
|
606
|
+
* ```typescript
|
|
607
|
+
* // Create with properties
|
|
608
|
+
* const record = odinClient.calls.new();
|
|
609
|
+
* await record.updateCallOnTaskCanceled({ ... }).execute();
|
|
610
|
+
*
|
|
611
|
+
* // Dry run (for debugging)
|
|
612
|
+
* const payload = record.updateCallOnTaskCanceled({ ... }).dryRun();
|
|
613
|
+
* ```
|
|
614
|
+
*/
|
|
615
|
+
updateCallOnTaskCanceled(properties, options) {
|
|
616
|
+
var _a, _b;
|
|
617
|
+
const payload = {
|
|
618
|
+
entity: 'NotificationModule:Call',
|
|
619
|
+
type: (_a = options === null || options === void 0 ? void 0 : options.type) !== null && _a !== void 0 ? _a : (_b = this._record) === null || _b === void 0 ? void 0 : _b.type,
|
|
620
|
+
actionName: 'UpdateCallOnTaskCanceled',
|
|
621
|
+
properties: properties || {},
|
|
622
|
+
associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined,
|
|
623
|
+
journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
|
|
624
|
+
stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
|
|
625
|
+
};
|
|
626
|
+
return new ActionBuilder(this._provider, 'NotificationModule', 'Call', payload, () => { this._pendingLinks = []; });
|
|
627
|
+
}
|
|
592
628
|
// ============================================
|
|
593
629
|
// UPDATE ACTIONS (require existing record)
|
|
594
630
|
// ============================================
|
|
@@ -624,11 +660,13 @@ class CallRecord {
|
|
|
624
660
|
/**
|
|
625
661
|
* UpdateCallOnInboundCallAnswered
|
|
626
662
|
*
|
|
627
|
-
* Updates this Call record.
|
|
663
|
+
* Updates this Call record with the specified properties.
|
|
628
664
|
* Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
|
|
629
665
|
*
|
|
630
|
-
* @param
|
|
631
|
-
* @param options - Optional settings
|
|
666
|
+
* @param properties - Required properties for this action
|
|
667
|
+
* @param options - Optional settings
|
|
668
|
+
* @param options.journeyId - Associate with a journey
|
|
669
|
+
* @param options.stageKey - Transition to pipeline stage
|
|
632
670
|
* @returns ActionBuilder - call .execute() to update or .dryRun() for payload
|
|
633
671
|
* @throws Error if called on a new (unsaved) record
|
|
634
672
|
*
|
|
@@ -641,21 +679,11 @@ class CallRecord {
|
|
|
641
679
|
* const payload = record.updateCallOnInboundCallAnswered({ ... }).dryRun();
|
|
642
680
|
* ```
|
|
643
681
|
*/
|
|
644
|
-
updateCallOnInboundCallAnswered(
|
|
682
|
+
updateCallOnInboundCallAnswered(properties, options) {
|
|
645
683
|
var _a;
|
|
646
684
|
if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
|
|
647
685
|
throw new Error('updateCallOnInboundCallAnswered requires an existing record. Use accessor.get() first.');
|
|
648
|
-
|
|
649
|
-
let opts = options;
|
|
650
|
-
if (propertiesOrOptions) {
|
|
651
|
-
if ('journeyId' in propertiesOrOptions || 'stageKey' in propertiesOrOptions) {
|
|
652
|
-
opts = propertiesOrOptions;
|
|
653
|
-
}
|
|
654
|
-
else {
|
|
655
|
-
properties = propertiesOrOptions;
|
|
656
|
-
}
|
|
657
|
-
}
|
|
658
|
-
const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'UpdateCallOnInboundCallAnswered', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, opts);
|
|
686
|
+
const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'UpdateCallOnInboundCallAnswered', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, options);
|
|
659
687
|
return new ActionBuilder(this._provider, 'NotificationModule', 'Call', payload, () => { this._pendingLinks = []; });
|
|
660
688
|
}
|
|
661
689
|
/**
|