@d19n/youfibre-odin-sdk 2.0.233-beta.4 → 2.0.233-beta.5

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 CHANGED
@@ -1499,8 +1499,8 @@ This SDK includes **745** actions.
1499
1499
  | Action | Type | Event |
1500
1500
  |--------|------|-------|
1501
1501
  | `CreateModifyServiceRequest` | CREATE | k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Create.CreateModifyServiceRequest |
1502
- | `MoveMsrToComplete` | STAGE_TRANSITION | k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Transition.MoveMsrToComplete |
1503
- | `MoveMsrToFailed` | STAGE_TRANSITION | k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Transition.MoveMsrToFailed |
1502
+ | `MoveMsrToComplete` | STAGE_TRANSITION | k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest |
1503
+ | `MoveMsrToFailed` | STAGE_TRANSITION | k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest |
1504
1504
  | `MoveMsrToInProgress` | STAGE_TRANSITION | k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest |
1505
1505
  | `UpdateModifyServiceRequest` | UPDATE | k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest |
1506
1506
 
@@ -12,7 +12,101 @@
12
12
  * AUTO-GENERATED - DO NOT EDIT DIRECTLY
13
13
  */
14
14
  import { OdinRecord, OdinRecordUpdateDto, OdinRecordUpdatedEvent } from '@d19n/odin-types/dist/core';
15
- declare type StepClassMap = {};
15
+ /**
16
+ * Properties for UpdateModifyServiceRequest action
17
+ *
18
+ * @property Required fields: 0
19
+ * @property Optional fields: 7
20
+ */
21
+ export interface UpdateModifyServiceRequestProperties {
22
+ /**
23
+ * Service ID
24
+ *
25
+ * The ID of the service being modified
26
+ * @type {TEXT}
27
+ */
28
+ ServiceId?: string | null;
29
+ /**
30
+ * SKU Previous
31
+ *
32
+ * The previous SKU being modified from (Used for Line Profile mapping)
33
+ * @type {TEXT}
34
+ */
35
+ SkuPrevious?: string | null;
36
+ /**
37
+ * SKU Next
38
+ *
39
+ * The next SKU being modified to (Used for Line Profile mapping)
40
+ * @type {TEXT}
41
+ */
42
+ SkuNext?: string | null;
43
+ /**
44
+ * FNO Modify Status
45
+ *
46
+ * FNO Modify Status
47
+ * @type {ENUM}
48
+ */
49
+ FnoModifyStatus?: string | null;
50
+ /**
51
+ * FNO Comment
52
+ *
53
+ * FNO Comment
54
+ * @type {TEXT_LONG}
55
+ */
56
+ FnoComment?: string | null;
57
+ /**
58
+ * ISP Modify Status
59
+ *
60
+ * ISP Modify Status
61
+ * @type {ENUM}
62
+ */
63
+ IspModifyStatus?: string | null;
64
+ /**
65
+ * ISP Comment
66
+ *
67
+ * ISP Comment
68
+ * @type {TEXT_LONG}
69
+ */
70
+ IspComment?: string | null;
71
+ }
72
+ /**
73
+ * UpdateModifyServiceRequest
74
+ *
75
+ * @actionType UPDATE - Updates an existing ModifyServiceRequest record
76
+ * @module ServiceModule
77
+ * @entity ModifyServiceRequest
78
+ * @event k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest
79
+ * @permission schema.action.updatemodifyservicerequest.trigger
80
+ * @benchmark This action is tracked for performance benchmarks
81
+ */
82
+ export declare class UpdateModifyServiceRequestDto extends OdinRecordUpdateDto<UpdateModifyServiceRequestProperties> {
83
+ /** Used by SDK generators to identify action type */
84
+ static readonly ACTION_TYPE = "UPDATE";
85
+ static readonly ACTION_KEY = "UpdateModifyServiceRequest";
86
+ static readonly MODULE_NAME = "ServiceModule";
87
+ static readonly ENTITIES: string[];
88
+ static readonly EVENT_NAME = "k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest";
89
+ static readonly PERMISSION = "schema.action.updatemodifyservicerequest.trigger";
90
+ /** Step metadata - entity this action targets */
91
+ static readonly STEP_ENTITY = "ServiceModule:ModifyServiceRequest";
92
+ static readonly STEP_SCHEMA_ID = "c33f6215-f398-4d02-a35a-ebcde2ee2669";
93
+ static readonly STEP_SCHEMA_ACTION_ID = "f4fb3994-062a-46f6-ad1b-badfa0bf3afa";
94
+ static readonly AUTO_LINK_PARENT = false;
95
+ readonly actionName: string;
96
+ readonly schemaActionId: string;
97
+ readonly entity: string;
98
+ constructor(record: OdinRecord<any> | {
99
+ id: string;
100
+ entity: string;
101
+ type?: string;
102
+ }, properties: UpdateModifyServiceRequestProperties, options?: {
103
+ journeyId?: string;
104
+ stageKey?: string;
105
+ });
106
+ }
107
+ declare type StepClassMap = {
108
+ UpdateModifyServiceRequestDto: UpdateModifyServiceRequestDto;
109
+ };
16
110
  /**
17
111
  * Link definition for connecting steps in MoveMsrToComplete
18
112
  */
@@ -109,7 +203,7 @@ export declare class MoveMsrToCompleteDto extends OdinRecordUpdateDto<Record<str
109
203
  journeyId?: string;
110
204
  });
111
205
  /** Step classes that can be used with this action */
112
- static readonly stepClasses: readonly [];
206
+ static readonly stepClasses: readonly ["UpdateModifyServiceRequestDto"];
113
207
  steps: StepClassMap[(typeof MoveMsrToCompleteDto.stepClasses)[number]][];
114
208
  }
115
209
  export {};
@@ -13,8 +13,46 @@
13
13
  * AUTO-GENERATED - DO NOT EDIT DIRECTLY
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.MoveMsrToCompleteDto = exports.MoveMsrToCompleteSteps = void 0;
16
+ exports.MoveMsrToCompleteDto = exports.MoveMsrToCompleteSteps = exports.UpdateModifyServiceRequestDto = void 0;
17
17
  const core_1 = require("@d19n/odin-types/dist/core");
18
+ /**
19
+ * UpdateModifyServiceRequest
20
+ *
21
+ * @actionType UPDATE - Updates an existing ModifyServiceRequest record
22
+ * @module ServiceModule
23
+ * @entity ModifyServiceRequest
24
+ * @event k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest
25
+ * @permission schema.action.updatemodifyservicerequest.trigger
26
+ * @benchmark This action is tracked for performance benchmarks
27
+ */
28
+ class UpdateModifyServiceRequestDto extends core_1.OdinRecordUpdateDto {
29
+ constructor(record, properties, options) {
30
+ super({
31
+ id: record.id,
32
+ entity: record.entity,
33
+ type: record.type,
34
+ properties,
35
+ journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
36
+ stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
37
+ });
38
+ this.actionName = 'UpdateModifyServiceRequest';
39
+ this.schemaActionId = 'f4fb3994-062a-46f6-ad1b-badfa0bf3afa';
40
+ this.entity = 'ServiceModule:ModifyServiceRequest';
41
+ }
42
+ }
43
+ exports.UpdateModifyServiceRequestDto = UpdateModifyServiceRequestDto;
44
+ /** Used by SDK generators to identify action type */
45
+ UpdateModifyServiceRequestDto.ACTION_TYPE = 'UPDATE';
46
+ UpdateModifyServiceRequestDto.ACTION_KEY = 'UpdateModifyServiceRequest';
47
+ UpdateModifyServiceRequestDto.MODULE_NAME = 'ServiceModule';
48
+ UpdateModifyServiceRequestDto.ENTITIES = ['ModifyServiceRequest'];
49
+ UpdateModifyServiceRequestDto.EVENT_NAME = 'k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest';
50
+ UpdateModifyServiceRequestDto.PERMISSION = 'schema.action.updatemodifyservicerequest.trigger';
51
+ /** Step metadata - entity this action targets */
52
+ UpdateModifyServiceRequestDto.STEP_ENTITY = 'ServiceModule:ModifyServiceRequest';
53
+ UpdateModifyServiceRequestDto.STEP_SCHEMA_ID = 'c33f6215-f398-4d02-a35a-ebcde2ee2669';
54
+ UpdateModifyServiceRequestDto.STEP_SCHEMA_ACTION_ID = 'f4fb3994-062a-46f6-ad1b-badfa0bf3afa';
55
+ UpdateModifyServiceRequestDto.AUTO_LINK_PARENT = false;
18
56
  /**
19
57
  * Type-safe step keys for MoveMsrToComplete
20
58
  */
@@ -69,12 +107,12 @@ MoveMsrToCompleteDto.HAS_STEP_LINKS = false;
69
107
  MoveMsrToCompleteDto.stepDefinitions = [
70
108
  {
71
109
  stepKey: 'step_1',
72
- dtoClass: 'unknown',
73
- entity: 'unknown',
110
+ dtoClass: 'UpdateModifyServiceRequestDto',
111
+ entity: 'ServiceModule:ModifyServiceRequest',
74
112
  linksTo: null
75
113
  }
76
114
  ];
77
115
  /** Type-safe step key accessor */
78
116
  MoveMsrToCompleteDto.Steps = exports.MoveMsrToCompleteSteps;
79
117
  /** Step classes that can be used with this action */
80
- MoveMsrToCompleteDto.stepClasses = [];
118
+ MoveMsrToCompleteDto.stepClasses = ['UpdateModifyServiceRequestDto'];
@@ -12,7 +12,101 @@
12
12
  * AUTO-GENERATED - DO NOT EDIT DIRECTLY
13
13
  */
14
14
  import { OdinRecord, OdinRecordUpdateDto, OdinRecordUpdatedEvent } from '@d19n/odin-types/dist/core';
15
- declare type StepClassMap = {};
15
+ /**
16
+ * Properties for UpdateModifyServiceRequest action
17
+ *
18
+ * @property Required fields: 0
19
+ * @property Optional fields: 7
20
+ */
21
+ export interface UpdateModifyServiceRequestProperties {
22
+ /**
23
+ * Service ID
24
+ *
25
+ * The ID of the service being modified
26
+ * @type {TEXT}
27
+ */
28
+ ServiceId?: string | null;
29
+ /**
30
+ * SKU Previous
31
+ *
32
+ * The previous SKU being modified from (Used for Line Profile mapping)
33
+ * @type {TEXT}
34
+ */
35
+ SkuPrevious?: string | null;
36
+ /**
37
+ * SKU Next
38
+ *
39
+ * The next SKU being modified to (Used for Line Profile mapping)
40
+ * @type {TEXT}
41
+ */
42
+ SkuNext?: string | null;
43
+ /**
44
+ * FNO Modify Status
45
+ *
46
+ * FNO Modify Status
47
+ * @type {ENUM}
48
+ */
49
+ FnoModifyStatus?: string | null;
50
+ /**
51
+ * FNO Comment
52
+ *
53
+ * FNO Comment
54
+ * @type {TEXT_LONG}
55
+ */
56
+ FnoComment?: string | null;
57
+ /**
58
+ * ISP Modify Status
59
+ *
60
+ * ISP Modify Status
61
+ * @type {ENUM}
62
+ */
63
+ IspModifyStatus?: string | null;
64
+ /**
65
+ * ISP Comment
66
+ *
67
+ * ISP Comment
68
+ * @type {TEXT_LONG}
69
+ */
70
+ IspComment?: string | null;
71
+ }
72
+ /**
73
+ * UpdateModifyServiceRequest
74
+ *
75
+ * @actionType UPDATE - Updates an existing ModifyServiceRequest record
76
+ * @module ServiceModule
77
+ * @entity ModifyServiceRequest
78
+ * @event k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest
79
+ * @permission schema.action.updatemodifyservicerequest.trigger
80
+ * @benchmark This action is tracked for performance benchmarks
81
+ */
82
+ export declare class UpdateModifyServiceRequestDto extends OdinRecordUpdateDto<UpdateModifyServiceRequestProperties> {
83
+ /** Used by SDK generators to identify action type */
84
+ static readonly ACTION_TYPE = "UPDATE";
85
+ static readonly ACTION_KEY = "UpdateModifyServiceRequest";
86
+ static readonly MODULE_NAME = "ServiceModule";
87
+ static readonly ENTITIES: string[];
88
+ static readonly EVENT_NAME = "k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest";
89
+ static readonly PERMISSION = "schema.action.updatemodifyservicerequest.trigger";
90
+ /** Step metadata - entity this action targets */
91
+ static readonly STEP_ENTITY = "ServiceModule:ModifyServiceRequest";
92
+ static readonly STEP_SCHEMA_ID = "c33f6215-f398-4d02-a35a-ebcde2ee2669";
93
+ static readonly STEP_SCHEMA_ACTION_ID = "f4fb3994-062a-46f6-ad1b-badfa0bf3afa";
94
+ static readonly AUTO_LINK_PARENT = false;
95
+ readonly actionName: string;
96
+ readonly schemaActionId: string;
97
+ readonly entity: string;
98
+ constructor(record: OdinRecord<any> | {
99
+ id: string;
100
+ entity: string;
101
+ type?: string;
102
+ }, properties: UpdateModifyServiceRequestProperties, options?: {
103
+ journeyId?: string;
104
+ stageKey?: string;
105
+ });
106
+ }
107
+ declare type StepClassMap = {
108
+ UpdateModifyServiceRequestDto: UpdateModifyServiceRequestDto;
109
+ };
16
110
  /**
17
111
  * Link definition for connecting steps in MoveMsrToFailed
18
112
  */
@@ -109,7 +203,7 @@ export declare class MoveMsrToFailedDto extends OdinRecordUpdateDto<Record<strin
109
203
  journeyId?: string;
110
204
  });
111
205
  /** Step classes that can be used with this action */
112
- static readonly stepClasses: readonly [];
206
+ static readonly stepClasses: readonly ["UpdateModifyServiceRequestDto"];
113
207
  steps: StepClassMap[(typeof MoveMsrToFailedDto.stepClasses)[number]][];
114
208
  }
115
209
  export {};
@@ -13,8 +13,46 @@
13
13
  * AUTO-GENERATED - DO NOT EDIT DIRECTLY
14
14
  */
15
15
  Object.defineProperty(exports, "__esModule", { value: true });
16
- exports.MoveMsrToFailedDto = exports.MoveMsrToFailedSteps = void 0;
16
+ exports.MoveMsrToFailedDto = exports.MoveMsrToFailedSteps = exports.UpdateModifyServiceRequestDto = void 0;
17
17
  const core_1 = require("@d19n/odin-types/dist/core");
18
+ /**
19
+ * UpdateModifyServiceRequest
20
+ *
21
+ * @actionType UPDATE - Updates an existing ModifyServiceRequest record
22
+ * @module ServiceModule
23
+ * @entity ModifyServiceRequest
24
+ * @event k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest
25
+ * @permission schema.action.updatemodifyservicerequest.trigger
26
+ * @benchmark This action is tracked for performance benchmarks
27
+ */
28
+ class UpdateModifyServiceRequestDto extends core_1.OdinRecordUpdateDto {
29
+ constructor(record, properties, options) {
30
+ super({
31
+ id: record.id,
32
+ entity: record.entity,
33
+ type: record.type,
34
+ properties,
35
+ journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
36
+ stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
37
+ });
38
+ this.actionName = 'UpdateModifyServiceRequest';
39
+ this.schemaActionId = 'f4fb3994-062a-46f6-ad1b-badfa0bf3afa';
40
+ this.entity = 'ServiceModule:ModifyServiceRequest';
41
+ }
42
+ }
43
+ exports.UpdateModifyServiceRequestDto = UpdateModifyServiceRequestDto;
44
+ /** Used by SDK generators to identify action type */
45
+ UpdateModifyServiceRequestDto.ACTION_TYPE = 'UPDATE';
46
+ UpdateModifyServiceRequestDto.ACTION_KEY = 'UpdateModifyServiceRequest';
47
+ UpdateModifyServiceRequestDto.MODULE_NAME = 'ServiceModule';
48
+ UpdateModifyServiceRequestDto.ENTITIES = ['ModifyServiceRequest'];
49
+ UpdateModifyServiceRequestDto.EVENT_NAME = 'k1.t-hEOJjsDb.ServiceModule.ModifyServiceRequest.Update.UpdateModifyServiceRequest';
50
+ UpdateModifyServiceRequestDto.PERMISSION = 'schema.action.updatemodifyservicerequest.trigger';
51
+ /** Step metadata - entity this action targets */
52
+ UpdateModifyServiceRequestDto.STEP_ENTITY = 'ServiceModule:ModifyServiceRequest';
53
+ UpdateModifyServiceRequestDto.STEP_SCHEMA_ID = 'c33f6215-f398-4d02-a35a-ebcde2ee2669';
54
+ UpdateModifyServiceRequestDto.STEP_SCHEMA_ACTION_ID = 'f4fb3994-062a-46f6-ad1b-badfa0bf3afa';
55
+ UpdateModifyServiceRequestDto.AUTO_LINK_PARENT = false;
18
56
  /**
19
57
  * Type-safe step keys for MoveMsrToFailed
20
58
  */
@@ -69,12 +107,12 @@ MoveMsrToFailedDto.HAS_STEP_LINKS = false;
69
107
  MoveMsrToFailedDto.stepDefinitions = [
70
108
  {
71
109
  stepKey: 'step_1',
72
- dtoClass: 'unknown',
73
- entity: 'unknown',
110
+ dtoClass: 'UpdateModifyServiceRequestDto',
111
+ entity: 'ServiceModule:ModifyServiceRequest',
74
112
  linksTo: null
75
113
  }
76
114
  ];
77
115
  /** Type-safe step key accessor */
78
116
  MoveMsrToFailedDto.Steps = exports.MoveMsrToFailedSteps;
79
117
  /** Step classes that can be used with this action */
80
- MoveMsrToFailedDto.stepClasses = [];
118
+ MoveMsrToFailedDto.stepClasses = ['UpdateModifyServiceRequestDto'];
@@ -161,12 +161,12 @@ export declare enum CallPropertyKeys {
161
161
  UserId = "UserId",
162
162
  /** Reference identifier for Call relationships. Used for data integrity. */
163
163
  CaseId = "CaseId",
164
- /** the external id from the call management system (Communications - Call) */
165
- ExternalId = "ExternalId",
166
164
  /** Direction of call (Communications - Call) */
167
165
  Direction = "Direction",
168
166
  /** The granular stage of a call, more extensive than CallStatus (Communications - Call) */
169
167
  CallStage = "CallStage",
168
+ /** the external id from the call management system (Communications - Call) */
169
+ ExternalId = "ExternalId",
170
170
  /** Seconds spent in queue (Communications - Call) */
171
171
  QueueTime = "QueueTime",
172
172
  /** WorkOrderId (Communications - Call) */
@@ -183,8 +183,6 @@ export declare enum CallPropertyKeys {
183
183
  Duration = "Duration",
184
184
  /** Number of times this call was transferred (Communications - Call) */
185
185
  TransferCount = "TransferCount",
186
- /** Total call duration in seconds from customer perspective (Communications - Call) */
187
- TotalDuration = "TotalDuration",
188
186
  /** TimeInQueued (Communications - Call) */
189
187
  TimeInQueued = "TimeInQueued",
190
188
  /** TimeInProgress (Communications - Call) */
@@ -205,6 +203,8 @@ export declare enum CallPropertyKeys {
205
203
  AmdResult = "AmdResult",
206
204
  /** CustomerConnection */
207
205
  CustomerConnection = "CustomerConnection",
206
+ /** Total call duration in seconds from customer perspective (Communications - Call) */
207
+ TotalDuration = "TotalDuration",
208
208
  /** RecordingDuration (Communications - Call) */
209
209
  RecordingDuration = "RecordingDuration",
210
210
  /** Data field for Call records. Used by Communications team. */
@@ -318,12 +318,6 @@ export interface CallProperties {
318
318
  * @type {LOOKUP}
319
319
  */
320
320
  CaseId: string;
321
- /** the external id from the call management system (Communications - Call)
322
- *
323
- * @type {TEXT}
324
- * @hidden This field is hidden in the UI
325
- */
326
- ExternalId: string;
327
321
  /** Direction of call (Communications - Call)
328
322
  *
329
323
  * @type {ENUM}
@@ -336,6 +330,12 @@ export interface CallProperties {
336
330
  * @enum {CallCallStage}
337
331
  */
338
332
  CallStage: CallCallStage;
333
+ /** the external id from the call management system (Communications - Call)
334
+ *
335
+ * @type {TEXT}
336
+ * @hidden This field is hidden in the UI
337
+ */
338
+ ExternalId: string;
339
339
  /** Seconds spent in queue (Communications - Call)
340
340
  *
341
341
  * @type {NUMBER}
@@ -377,11 +377,6 @@ export interface CallProperties {
377
377
  * @type {NUMBER}
378
378
  */
379
379
  TransferCount: number;
380
- /** Total call duration in seconds from customer perspective (Communications - Call)
381
- *
382
- * @type {NUMBER}
383
- */
384
- TotalDuration: number;
385
380
  /** TimeInQueued (Communications - Call)
386
381
  *
387
382
  * @type {TEXT}
@@ -434,6 +429,11 @@ export interface CallProperties {
434
429
  * @type {TEXT}
435
430
  */
436
431
  CustomerConnection: string;
432
+ /** Total call duration in seconds from customer perspective (Communications - Call)
433
+ *
434
+ * @type {NUMBER}
435
+ */
436
+ TotalDuration: number;
437
437
  /** RecordingDuration (Communications - Call)
438
438
  *
439
439
  * @type {TEXT}
@@ -160,12 +160,12 @@ var CallPropertyKeys;
160
160
  CallPropertyKeys["UserId"] = "UserId";
161
161
  /** Reference identifier for Call relationships. Used for data integrity. */
162
162
  CallPropertyKeys["CaseId"] = "CaseId";
163
- /** the external id from the call management system (Communications - Call) */
164
- CallPropertyKeys["ExternalId"] = "ExternalId";
165
163
  /** Direction of call (Communications - Call) */
166
164
  CallPropertyKeys["Direction"] = "Direction";
167
165
  /** The granular stage of a call, more extensive than CallStatus (Communications - Call) */
168
166
  CallPropertyKeys["CallStage"] = "CallStage";
167
+ /** the external id from the call management system (Communications - Call) */
168
+ CallPropertyKeys["ExternalId"] = "ExternalId";
169
169
  /** Seconds spent in queue (Communications - Call) */
170
170
  CallPropertyKeys["QueueTime"] = "QueueTime";
171
171
  /** WorkOrderId (Communications - Call) */
@@ -182,8 +182,6 @@ var CallPropertyKeys;
182
182
  CallPropertyKeys["Duration"] = "Duration";
183
183
  /** Number of times this call was transferred (Communications - Call) */
184
184
  CallPropertyKeys["TransferCount"] = "TransferCount";
185
- /** Total call duration in seconds from customer perspective (Communications - Call) */
186
- CallPropertyKeys["TotalDuration"] = "TotalDuration";
187
185
  /** TimeInQueued (Communications - Call) */
188
186
  CallPropertyKeys["TimeInQueued"] = "TimeInQueued";
189
187
  /** TimeInProgress (Communications - Call) */
@@ -204,6 +202,8 @@ var CallPropertyKeys;
204
202
  CallPropertyKeys["AmdResult"] = "AmdResult";
205
203
  /** CustomerConnection */
206
204
  CallPropertyKeys["CustomerConnection"] = "CustomerConnection";
205
+ /** Total call duration in seconds from customer perspective (Communications - Call) */
206
+ CallPropertyKeys["TotalDuration"] = "TotalDuration";
207
207
  /** RecordingDuration (Communications - Call) */
208
208
  CallPropertyKeys["RecordingDuration"] = "RecordingDuration";
209
209
  /** Data field for Call records. Used by Communications team. */
@@ -24,7 +24,7 @@ import { IOdinProvider } from '@d19n/odin-sdk-generator/dist/odin-sdk-types';
24
24
  import { RecordLinkManager } from '@d19n/odin-sdk-generator/dist/record-link-manager';
25
25
  import { ModifyServiceRequestProperties } from '../entities-v2/ModifyServiceRequest';
26
26
  import { CreateModifyServiceRequestProperties } from '../actions-v2/CreateModifyServiceRequestDto';
27
- import { UpdateModifyServiceRequestProperties } from '../actions-v2/MoveMsrToInProgressDto';
27
+ import { UpdateModifyServiceRequestProperties } from '../actions-v2/MoveMsrToCompleteDto';
28
28
  import { OrderRecord } from './OrderRecord';
29
29
  import { OrderKciRecord } from './OrderKciRecord';
30
30
  /** Valid entity types for ModifyServiceRequest */
@@ -88,6 +88,130 @@ declare class ActionBuilder<T = IDbRecordCreateUpdateRes[]> {
88
88
  then(): never;
89
89
  }
90
90
  /** Options for a flow step */
91
+ export interface MoveMsrToCompleteFlowBuilderStepOptions {
92
+ /** Associations to create with this step */
93
+ associations?: Array<{
94
+ recordId?: string;
95
+ entity?: string;
96
+ }>;
97
+ /** Groups for this step */
98
+ groups?: string[];
99
+ }
100
+ /**
101
+ * FlowBuilder for MoveMsrToComplete multi-step action
102
+ *
103
+ * Use method chaining to add steps, then call execute() to run the flow.
104
+ * Transitions to stage: ModifyServiceRequestStateStageCompleted
105
+ */
106
+ export declare class MoveMsrToCompleteFlowBuilder {
107
+ private _record;
108
+ private _provider;
109
+ private _pendingLinks;
110
+ private _options?;
111
+ private _groups;
112
+ private _steps;
113
+ constructor(record: ModifyServiceRequestRecord<any>, provider: IOdinProvider, pendingLinks: OdinRecordLinkDto[], options?: {
114
+ journeyId?: string;
115
+ });
116
+ /**
117
+ * Add a group to the main action
118
+ * @param group - Group name to add
119
+ * @returns this (for method chaining)
120
+ */
121
+ addGroup(group: string): this;
122
+ /**
123
+ * Add UpdateModifyServiceRequest step to the flow
124
+ * @param id - ID of the record to update
125
+ * @param properties - Properties for this step
126
+ * @param options - Optional step settings
127
+ * @returns this (for method chaining)
128
+ */
129
+ updateModifyServiceRequest(id: string, properties: UpdateModifyServiceRequestProperties, options?: MoveMsrToCompleteFlowBuilderStepOptions): this;
130
+ /**
131
+ * Execute the flow
132
+ * @returns The result from the API
133
+ */
134
+ execute(): Promise<IDbRecordCreateUpdateRes[]>;
135
+ /**
136
+ * Returns the request payload without executing (for debugging)
137
+ * @returns The request payload that would be sent to the API
138
+ */
139
+ dryRun(): Record<string, any>;
140
+ /**
141
+ * Prevents accidental `await flowBuilder` without .execute()
142
+ * Forces developers to explicitly call .execute()
143
+ * @throws Error always - use .execute() or .dryRun() instead
144
+ */
145
+ then(): never;
146
+ /**
147
+ * Build the request payload for the action
148
+ * @private
149
+ */
150
+ private _buildRequestPayload;
151
+ }
152
+ /** Options for a flow step */
153
+ export interface MoveMsrToFailedFlowBuilderStepOptions {
154
+ /** Associations to create with this step */
155
+ associations?: Array<{
156
+ recordId?: string;
157
+ entity?: string;
158
+ }>;
159
+ /** Groups for this step */
160
+ groups?: string[];
161
+ }
162
+ /**
163
+ * FlowBuilder for MoveMsrToFailed multi-step action
164
+ *
165
+ * Use method chaining to add steps, then call execute() to run the flow.
166
+ * Transitions to stage: ModifyServiceRequestStateStageFailed
167
+ */
168
+ export declare class MoveMsrToFailedFlowBuilder {
169
+ private _record;
170
+ private _provider;
171
+ private _pendingLinks;
172
+ private _options?;
173
+ private _groups;
174
+ private _steps;
175
+ constructor(record: ModifyServiceRequestRecord<any>, provider: IOdinProvider, pendingLinks: OdinRecordLinkDto[], options?: {
176
+ journeyId?: string;
177
+ });
178
+ /**
179
+ * Add a group to the main action
180
+ * @param group - Group name to add
181
+ * @returns this (for method chaining)
182
+ */
183
+ addGroup(group: string): this;
184
+ /**
185
+ * Add UpdateModifyServiceRequest step to the flow
186
+ * @param id - ID of the record to update
187
+ * @param properties - Properties for this step
188
+ * @param options - Optional step settings
189
+ * @returns this (for method chaining)
190
+ */
191
+ updateModifyServiceRequest(id: string, properties: UpdateModifyServiceRequestProperties, options?: MoveMsrToFailedFlowBuilderStepOptions): this;
192
+ /**
193
+ * Execute the flow
194
+ * @returns The result from the API
195
+ */
196
+ execute(): Promise<IDbRecordCreateUpdateRes[]>;
197
+ /**
198
+ * Returns the request payload without executing (for debugging)
199
+ * @returns The request payload that would be sent to the API
200
+ */
201
+ dryRun(): Record<string, any>;
202
+ /**
203
+ * Prevents accidental `await flowBuilder` without .execute()
204
+ * Forces developers to explicitly call .execute()
205
+ * @throws Error always - use .execute() or .dryRun() instead
206
+ */
207
+ then(): never;
208
+ /**
209
+ * Build the request payload for the action
210
+ * @private
211
+ */
212
+ private _buildRequestPayload;
213
+ }
214
+ /** Options for a flow step */
91
215
  export interface MoveMsrToInProgressFlowBuilderStepOptions {
92
216
  /** Associations to create with this step */
93
217
  associations?: Array<{
@@ -283,82 +407,80 @@ export declare class ModifyServiceRequestRecord<TProps = ModifyServiceRequestPro
283
407
  stageKey?: string;
284
408
  }): ActionBuilder;
285
409
  /**
286
- * MoveMsrToComplete
287
- *
288
- * Transitions this ModifyServiceRequest record to a new pipeline stage.
289
- * Returns an ActionBuilder - call .execute() to transition or .dryRun() for debugging.
410
+ * UpdateModifyServiceRequest
290
411
  *
291
- * @remarks Transitions to stage: ModifyServiceRequestStateStageCompleted
412
+ * Updates this ModifyServiceRequest record.
413
+ * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
292
414
  *
293
- * @param options - Optional settings
294
- * @param options.journeyId - Associate with a journey
295
- * @returns ActionBuilder - call .execute() to transition or .dryRun() for payload
415
+ * @param propertiesOrOptions - Properties to update, or options object
416
+ * @param options - Optional settings (journeyId, stageKey)
417
+ * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
296
418
  * @throws Error if called on a new (unsaved) record
297
419
  *
298
420
  * @example
299
421
  * ```typescript
300
422
  * const record = await odinClient.modifyServiceRequests.get(id);
301
- * await record.moveMsrToComplete().execute();
423
+ * await record.updateModifyServiceRequest({ ... }).execute();
302
424
  *
303
425
  * // Dry run (for debugging)
304
- * const payload = record.moveMsrToComplete().dryRun();
426
+ * const payload = record.updateModifyServiceRequest({ ... }).dryRun();
305
427
  * ```
306
428
  */
307
- moveMsrToComplete(options?: {
429
+ updateModifyServiceRequest(propertiesOrOptions?: UpdateModifyServiceRequestProperties | {
308
430
  journeyId?: string;
431
+ stageKey?: string;
432
+ }, options?: {
433
+ journeyId?: string;
434
+ stageKey?: string;
309
435
  }): ActionBuilder;
310
436
  /**
311
- * MoveMsrToFailed
437
+ * MoveMsrToComplete
312
438
  *
313
- * Transitions this ModifyServiceRequest record to a new pipeline stage.
314
- * Returns an ActionBuilder - call .execute() to transition or .dryRun() for debugging.
439
+ * Starts a stage transition flow on this ModifyServiceRequest record.
440
+ * Chain step methods and call .execute() to run the flow.
315
441
  *
316
- * @remarks Transitions to stage: ModifyServiceRequestStateStageFailed
442
+ * @remarks Transitions to stage: ModifyServiceRequestStateStageCompleted
317
443
  *
318
444
  * @param options - Optional settings
319
445
  * @param options.journeyId - Associate with a journey
320
- * @returns ActionBuilder - call .execute() to transition or .dryRun() for payload
446
+ * @returns FlowBuilder for chaining step methods
321
447
  * @throws Error if called on a new (unsaved) record
322
448
  *
323
449
  * @example
324
450
  * ```typescript
325
451
  * const record = await odinClient.modifyServiceRequests.get(id);
326
- * await record.moveMsrToFailed().execute();
327
- *
328
- * // Dry run (for debugging)
329
- * const payload = record.moveMsrToFailed().dryRun();
452
+ * await record.moveMsrToComplete()
453
+ * .updateModifyServiceRequest(recordId, { ... })
454
+ * .execute();
330
455
  * ```
331
456
  */
332
- moveMsrToFailed(options?: {
457
+ moveMsrToComplete(options?: {
333
458
  journeyId?: string;
334
- }): ActionBuilder;
459
+ }): MoveMsrToCompleteFlowBuilder;
335
460
  /**
336
- * UpdateModifyServiceRequest
461
+ * MoveMsrToFailed
337
462
  *
338
- * Updates this ModifyServiceRequest record.
339
- * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
463
+ * Starts a stage transition flow on this ModifyServiceRequest record.
464
+ * Chain step methods and call .execute() to run the flow.
340
465
  *
341
- * @param propertiesOrOptions - Properties to update, or options object
342
- * @param options - Optional settings (journeyId, stageKey)
343
- * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
466
+ * @remarks Transitions to stage: ModifyServiceRequestStateStageFailed
467
+ *
468
+ * @param options - Optional settings
469
+ * @param options.journeyId - Associate with a journey
470
+ * @returns FlowBuilder for chaining step methods
344
471
  * @throws Error if called on a new (unsaved) record
345
472
  *
346
473
  * @example
347
474
  * ```typescript
348
475
  * const record = await odinClient.modifyServiceRequests.get(id);
349
- * await record.updateModifyServiceRequest({ ... }).execute();
350
- *
351
- * // Dry run (for debugging)
352
- * const payload = record.updateModifyServiceRequest({ ... }).dryRun();
476
+ * await record.moveMsrToFailed()
477
+ * .updateModifyServiceRequest(recordId, { ... })
478
+ * .execute();
353
479
  * ```
354
480
  */
355
- updateModifyServiceRequest(propertiesOrOptions?: UpdateModifyServiceRequestProperties | {
356
- journeyId?: string;
357
- stageKey?: string;
358
- }, options?: {
481
+ moveMsrToFailed(options?: {
359
482
  journeyId?: string;
360
- stageKey?: string;
361
- }): ActionBuilder;
483
+ }): MoveMsrToFailedFlowBuilder;
362
484
  /**
363
485
  * MoveMsrToInProgress
364
486
  *
@@ -28,7 +28,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
28
28
  });
29
29
  };
30
30
  Object.defineProperty(exports, "__esModule", { value: true });
31
- exports.isModifyServiceRequestRecord = exports.ModifyServiceRequestRecord = exports.MoveMsrToInProgressFlowBuilder = void 0;
31
+ exports.isModifyServiceRequestRecord = exports.ModifyServiceRequestRecord = exports.MoveMsrToInProgressFlowBuilder = exports.MoveMsrToFailedFlowBuilder = exports.MoveMsrToCompleteFlowBuilder = void 0;
32
32
  const uuid_1 = require("uuid");
33
33
  const core_1 = require("@d19n/odin-types/dist/core");
34
34
  const record_link_manager_1 = require("@d19n/odin-sdk-generator/dist/record-link-manager");
@@ -110,6 +110,220 @@ class ActionBuilder {
110
110
  throw new Error('ActionBuilder cannot be awaited directly. Call .execute() to run the action or .dryRun() to get the payload.');
111
111
  }
112
112
  }
113
+ /**
114
+ * FlowBuilder for MoveMsrToComplete multi-step action
115
+ *
116
+ * Use method chaining to add steps, then call execute() to run the flow.
117
+ * Transitions to stage: ModifyServiceRequestStateStageCompleted
118
+ */
119
+ class MoveMsrToCompleteFlowBuilder {
120
+ constructor(record, provider, pendingLinks, options) {
121
+ this._groups = [];
122
+ this._steps = [];
123
+ this._record = record;
124
+ this._provider = provider;
125
+ this._pendingLinks = pendingLinks;
126
+ this._options = options;
127
+ }
128
+ /**
129
+ * Add a group to the main action
130
+ * @param group - Group name to add
131
+ * @returns this (for method chaining)
132
+ */
133
+ addGroup(group) {
134
+ this._groups.push(group);
135
+ return this;
136
+ }
137
+ /**
138
+ * Add UpdateModifyServiceRequest step to the flow
139
+ * @param id - ID of the record to update
140
+ * @param properties - Properties for this step
141
+ * @param options - Optional step settings
142
+ * @returns this (for method chaining)
143
+ */
144
+ updateModifyServiceRequest(id, properties, options) {
145
+ var _a;
146
+ this._steps.push({
147
+ actionName: 'UpdateModifyServiceRequest',
148
+ properties,
149
+ id,
150
+ entity: 'ServiceModule:ModifyServiceRequest',
151
+ autoLinkParent: false,
152
+ associations: (_a = options === null || options === void 0 ? void 0 : options.associations) === null || _a === void 0 ? void 0 : _a.map(a => (Object.assign(Object.assign({}, a), { linkType: null, relationType: undefined }))),
153
+ groups: options === null || options === void 0 ? void 0 : options.groups,
154
+ });
155
+ return this;
156
+ }
157
+ /**
158
+ * Execute the flow
159
+ * @returns The result from the API
160
+ */
161
+ execute() {
162
+ return __awaiter(this, void 0, void 0, function* () {
163
+ const payload = this._buildRequestPayload();
164
+ const result = yield this._provider._applyAction('ServiceModule', 'ModifyServiceRequest', payload);
165
+ // Clear pending links on the record after execution
166
+ this._record.clearPendingLinks();
167
+ return result;
168
+ });
169
+ }
170
+ /**
171
+ * Returns the request payload without executing (for debugging)
172
+ * @returns The request payload that would be sent to the API
173
+ */
174
+ dryRun() {
175
+ return this._buildRequestPayload();
176
+ }
177
+ /**
178
+ * Prevents accidental `await flowBuilder` without .execute()
179
+ * Forces developers to explicitly call .execute()
180
+ * @throws Error always - use .execute() or .dryRun() instead
181
+ */
182
+ then() {
183
+ throw new Error('FlowBuilder cannot be awaited directly. Call .execute() to run the flow or .dryRun() to get the payload.');
184
+ }
185
+ /**
186
+ * Build the request payload for the action
187
+ * @private
188
+ */
189
+ _buildRequestPayload() {
190
+ const record = this._record.record;
191
+ if (!(record === null || record === void 0 ? void 0 : record.id))
192
+ throw new Error('Cannot execute flow on unsaved record');
193
+ // Build steps with parent associations
194
+ const stepsWithAssociations = this._steps.map(step => {
195
+ const stepAssociations = [...(step.associations || [])];
196
+ // Auto-add parent association if step requires it
197
+ if (step.autoLinkParent) {
198
+ stepAssociations.push({
199
+ entity: record.entity,
200
+ recordId: record.id,
201
+ linkType: null,
202
+ relationType: 'PARENT',
203
+ });
204
+ }
205
+ return {
206
+ entity: step.entity,
207
+ type: step.type,
208
+ actionName: step.actionName,
209
+ properties: step.properties,
210
+ title: step.title,
211
+ id: step.id,
212
+ associations: stepAssociations.length > 0 ? stepAssociations : undefined,
213
+ groups: step.groups,
214
+ };
215
+ });
216
+ return Object.assign({ id: record.id, entity: record.entity, type: record.type, actionName: 'MoveMsrToComplete', steps: stepsWithAssociations, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined, groups: this._groups.length > 0 ? this._groups : undefined, stageKey: 'ModifyServiceRequestStateStageCompleted' }, this._options);
217
+ }
218
+ }
219
+ exports.MoveMsrToCompleteFlowBuilder = MoveMsrToCompleteFlowBuilder;
220
+ /**
221
+ * FlowBuilder for MoveMsrToFailed multi-step action
222
+ *
223
+ * Use method chaining to add steps, then call execute() to run the flow.
224
+ * Transitions to stage: ModifyServiceRequestStateStageFailed
225
+ */
226
+ class MoveMsrToFailedFlowBuilder {
227
+ constructor(record, provider, pendingLinks, options) {
228
+ this._groups = [];
229
+ this._steps = [];
230
+ this._record = record;
231
+ this._provider = provider;
232
+ this._pendingLinks = pendingLinks;
233
+ this._options = options;
234
+ }
235
+ /**
236
+ * Add a group to the main action
237
+ * @param group - Group name to add
238
+ * @returns this (for method chaining)
239
+ */
240
+ addGroup(group) {
241
+ this._groups.push(group);
242
+ return this;
243
+ }
244
+ /**
245
+ * Add UpdateModifyServiceRequest step to the flow
246
+ * @param id - ID of the record to update
247
+ * @param properties - Properties for this step
248
+ * @param options - Optional step settings
249
+ * @returns this (for method chaining)
250
+ */
251
+ updateModifyServiceRequest(id, properties, options) {
252
+ var _a;
253
+ this._steps.push({
254
+ actionName: 'UpdateModifyServiceRequest',
255
+ properties,
256
+ id,
257
+ entity: 'ServiceModule:ModifyServiceRequest',
258
+ autoLinkParent: false,
259
+ associations: (_a = options === null || options === void 0 ? void 0 : options.associations) === null || _a === void 0 ? void 0 : _a.map(a => (Object.assign(Object.assign({}, a), { linkType: null, relationType: undefined }))),
260
+ groups: options === null || options === void 0 ? void 0 : options.groups,
261
+ });
262
+ return this;
263
+ }
264
+ /**
265
+ * Execute the flow
266
+ * @returns The result from the API
267
+ */
268
+ execute() {
269
+ return __awaiter(this, void 0, void 0, function* () {
270
+ const payload = this._buildRequestPayload();
271
+ const result = yield this._provider._applyAction('ServiceModule', 'ModifyServiceRequest', payload);
272
+ // Clear pending links on the record after execution
273
+ this._record.clearPendingLinks();
274
+ return result;
275
+ });
276
+ }
277
+ /**
278
+ * Returns the request payload without executing (for debugging)
279
+ * @returns The request payload that would be sent to the API
280
+ */
281
+ dryRun() {
282
+ return this._buildRequestPayload();
283
+ }
284
+ /**
285
+ * Prevents accidental `await flowBuilder` without .execute()
286
+ * Forces developers to explicitly call .execute()
287
+ * @throws Error always - use .execute() or .dryRun() instead
288
+ */
289
+ then() {
290
+ throw new Error('FlowBuilder cannot be awaited directly. Call .execute() to run the flow or .dryRun() to get the payload.');
291
+ }
292
+ /**
293
+ * Build the request payload for the action
294
+ * @private
295
+ */
296
+ _buildRequestPayload() {
297
+ const record = this._record.record;
298
+ if (!(record === null || record === void 0 ? void 0 : record.id))
299
+ throw new Error('Cannot execute flow on unsaved record');
300
+ // Build steps with parent associations
301
+ const stepsWithAssociations = this._steps.map(step => {
302
+ const stepAssociations = [...(step.associations || [])];
303
+ // Auto-add parent association if step requires it
304
+ if (step.autoLinkParent) {
305
+ stepAssociations.push({
306
+ entity: record.entity,
307
+ recordId: record.id,
308
+ linkType: null,
309
+ relationType: 'PARENT',
310
+ });
311
+ }
312
+ return {
313
+ entity: step.entity,
314
+ type: step.type,
315
+ actionName: step.actionName,
316
+ properties: step.properties,
317
+ title: step.title,
318
+ id: step.id,
319
+ associations: stepAssociations.length > 0 ? stepAssociations : undefined,
320
+ groups: step.groups,
321
+ };
322
+ });
323
+ return Object.assign({ id: record.id, entity: record.entity, type: record.type, actionName: 'MoveMsrToFailed', steps: stepsWithAssociations, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined, groups: this._groups.length > 0 ? this._groups : undefined, stageKey: 'ModifyServiceRequestStateStageFailed' }, this._options);
324
+ }
325
+ }
326
+ exports.MoveMsrToFailedFlowBuilder = MoveMsrToFailedFlowBuilder;
113
327
  /**
114
328
  * FlowBuilder for MoveMsrToInProgress multi-step action
115
329
  *
@@ -408,99 +622,95 @@ class ModifyServiceRequestRecord {
408
622
  // UPDATE ACTIONS (require existing record)
409
623
  // ============================================
410
624
  /**
411
- * MoveMsrToComplete
412
- *
413
- * Transitions this ModifyServiceRequest record to a new pipeline stage.
414
- * Returns an ActionBuilder - call .execute() to transition or .dryRun() for debugging.
625
+ * UpdateModifyServiceRequest
415
626
  *
416
- * @remarks Transitions to stage: ModifyServiceRequestStateStageCompleted
627
+ * Updates this ModifyServiceRequest record.
628
+ * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
417
629
  *
418
- * @param options - Optional settings
419
- * @param options.journeyId - Associate with a journey
420
- * @returns ActionBuilder - call .execute() to transition or .dryRun() for payload
630
+ * @param propertiesOrOptions - Properties to update, or options object
631
+ * @param options - Optional settings (journeyId, stageKey)
632
+ * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
421
633
  * @throws Error if called on a new (unsaved) record
422
634
  *
423
635
  * @example
424
636
  * ```typescript
425
637
  * const record = await odinClient.modifyServiceRequests.get(id);
426
- * await record.moveMsrToComplete().execute();
638
+ * await record.updateModifyServiceRequest({ ... }).execute();
427
639
  *
428
640
  * // Dry run (for debugging)
429
- * const payload = record.moveMsrToComplete().dryRun();
641
+ * const payload = record.updateModifyServiceRequest({ ... }).dryRun();
430
642
  * ```
431
643
  */
432
- moveMsrToComplete(options) {
644
+ updateModifyServiceRequest(propertiesOrOptions, options) {
433
645
  var _a;
434
646
  if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
435
- throw new Error('moveMsrToComplete requires an existing record. Use accessor.get() first.');
436
- const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'MoveMsrToComplete', associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined, stageKey: 'ModifyServiceRequestStateStageCompleted' }, options);
647
+ throw new Error('updateModifyServiceRequest requires an existing record. Use accessor.get() first.');
648
+ let properties = {};
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: 'UpdateModifyServiceRequest', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, opts);
437
659
  return new ActionBuilder(this._provider, 'ServiceModule', 'ModifyServiceRequest', payload, () => { this._pendingLinks = []; });
438
660
  }
439
661
  /**
440
- * MoveMsrToFailed
662
+ * MoveMsrToComplete
441
663
  *
442
- * Transitions this ModifyServiceRequest record to a new pipeline stage.
443
- * Returns an ActionBuilder - call .execute() to transition or .dryRun() for debugging.
664
+ * Starts a stage transition flow on this ModifyServiceRequest record.
665
+ * Chain step methods and call .execute() to run the flow.
444
666
  *
445
- * @remarks Transitions to stage: ModifyServiceRequestStateStageFailed
667
+ * @remarks Transitions to stage: ModifyServiceRequestStateStageCompleted
446
668
  *
447
669
  * @param options - Optional settings
448
670
  * @param options.journeyId - Associate with a journey
449
- * @returns ActionBuilder - call .execute() to transition or .dryRun() for payload
671
+ * @returns FlowBuilder for chaining step methods
450
672
  * @throws Error if called on a new (unsaved) record
451
673
  *
452
674
  * @example
453
675
  * ```typescript
454
676
  * const record = await odinClient.modifyServiceRequests.get(id);
455
- * await record.moveMsrToFailed().execute();
456
- *
457
- * // Dry run (for debugging)
458
- * const payload = record.moveMsrToFailed().dryRun();
677
+ * await record.moveMsrToComplete()
678
+ * .updateModifyServiceRequest(recordId, { ... })
679
+ * .execute();
459
680
  * ```
460
681
  */
461
- moveMsrToFailed(options) {
682
+ moveMsrToComplete(options) {
462
683
  var _a;
463
684
  if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
464
- throw new Error('moveMsrToFailed requires an existing record. Use accessor.get() first.');
465
- const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'MoveMsrToFailed', associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined, stageKey: 'ModifyServiceRequestStateStageFailed' }, options);
466
- return new ActionBuilder(this._provider, 'ServiceModule', 'ModifyServiceRequest', payload, () => { this._pendingLinks = []; });
685
+ throw new Error('moveMsrToComplete requires an existing record. Use accessor.get() first.');
686
+ return new MoveMsrToCompleteFlowBuilder(this, this._provider, this._pendingLinks, options);
467
687
  }
468
688
  /**
469
- * UpdateModifyServiceRequest
689
+ * MoveMsrToFailed
470
690
  *
471
- * Updates this ModifyServiceRequest record.
472
- * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
691
+ * Starts a stage transition flow on this ModifyServiceRequest record.
692
+ * Chain step methods and call .execute() to run the flow.
473
693
  *
474
- * @param propertiesOrOptions - Properties to update, or options object
475
- * @param options - Optional settings (journeyId, stageKey)
476
- * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
694
+ * @remarks Transitions to stage: ModifyServiceRequestStateStageFailed
695
+ *
696
+ * @param options - Optional settings
697
+ * @param options.journeyId - Associate with a journey
698
+ * @returns FlowBuilder for chaining step methods
477
699
  * @throws Error if called on a new (unsaved) record
478
700
  *
479
701
  * @example
480
702
  * ```typescript
481
703
  * const record = await odinClient.modifyServiceRequests.get(id);
482
- * await record.updateModifyServiceRequest({ ... }).execute();
483
- *
484
- * // Dry run (for debugging)
485
- * const payload = record.updateModifyServiceRequest({ ... }).dryRun();
704
+ * await record.moveMsrToFailed()
705
+ * .updateModifyServiceRequest(recordId, { ... })
706
+ * .execute();
486
707
  * ```
487
708
  */
488
- updateModifyServiceRequest(propertiesOrOptions, options) {
709
+ moveMsrToFailed(options) {
489
710
  var _a;
490
711
  if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
491
- throw new Error('updateModifyServiceRequest requires an existing record. Use accessor.get() first.');
492
- let properties = {};
493
- let opts = options;
494
- if (propertiesOrOptions) {
495
- if ('journeyId' in propertiesOrOptions || 'stageKey' in propertiesOrOptions) {
496
- opts = propertiesOrOptions;
497
- }
498
- else {
499
- properties = propertiesOrOptions;
500
- }
501
- }
502
- const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'UpdateModifyServiceRequest', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, opts);
503
- return new ActionBuilder(this._provider, 'ServiceModule', 'ModifyServiceRequest', payload, () => { this._pendingLinks = []; });
712
+ throw new Error('moveMsrToFailed requires an existing record. Use accessor.get() first.');
713
+ return new MoveMsrToFailedFlowBuilder(this, this._provider, this._pendingLinks, options);
504
714
  }
505
715
  /**
506
716
  * MoveMsrToInProgress
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@d19n/youfibre-odin-sdk",
3
- "version": "2.0.233-beta.4",
3
+ "version": "2.0.233-beta.5",
4
4
  "description": "",
5
5
  "author": "@d19n",
6
6
  "license": "UNLICENSED",