@d19n/youfibre-odin-sdk 2.0.282 → 2.0.284

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
@@ -366,7 +366,7 @@ This SDK includes **178** entities across **12** modules.
366
366
 
367
367
  ## Actions
368
368
 
369
- This SDK includes **837** actions.
369
+ This SDK includes **839** actions.
370
370
 
371
371
  ### Action Types
372
372
 
@@ -1236,6 +1236,7 @@ This SDK includes **837** actions.
1236
1236
  |--------|------|-------|
1237
1237
  | `CloseConversation` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Conversation.Update.CloseConversation |
1238
1238
  | `CreateConversation` | CREATE | k1.t-hEOJjsDb.NotificationModule.Conversation.Create.CreateConversation |
1239
+ | `SyncConversationStateFromTwilio` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Conversation.Update.SyncConversationStateFromTwilio |
1239
1240
  | `UpdateConversation` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Conversation.Update.UpdateConversation |
1240
1241
  | `UpdateConversationSummary` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Conversation.Update.UpdateConversationSummary |
1241
1242
 
@@ -1503,6 +1504,7 @@ This SDK includes **837** actions.
1503
1504
  | `CreateEventMessage` | CREATE | k1.t-hEOJjsDb.NotificationModule.Message.Create.CreateEventMessage |
1504
1505
  | `CreateMessage` | CREATE | k1.t-hEOJjsDb.NotificationModule.Message.Create.CreateMessage |
1505
1506
  | `CreateNudgeMessage` | CREATE | k1.t-hEOJjsDb.NotificationModule.Message.Create.CreateNudgeMessage |
1507
+ | `SyncMessageStateFromTwilio` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Message.Update.SyncMessageStateFromTwilio |
1506
1508
 
1507
1509
  #### Config
1508
1510
 
@@ -0,0 +1,80 @@
1
+ /**
2
+ * SyncConversationStateFromTwilio Action DTO
3
+ *
4
+ * Applies the conversation state from a Twilio onConversationStateUpdated webhook (active -> CREATED, inactive -> INACTIVE, anything else -> CLOSED). Fired by youfibre-api-chat twilio.webhook.service.ts, never by a user.
5
+ *
6
+ * @module NotificationModule
7
+ * @entity Conversation
8
+ * @actionKey SyncConversationStateFromTwilio
9
+ * @event k1.t-hEOJjsDb.NotificationModule.Conversation.Update.SyncConversationStateFromTwilio
10
+ *
11
+ * AUTO-GENERATED - DO NOT EDIT DIRECTLY
12
+ */
13
+ import { OdinRecord, OdinRecordUpdateDto, OdinRecordUpdatedEvent } from '@d19n/odin-types/dist/core';
14
+ /**
15
+ * RabbitMQ message payload for SyncConversationStateFromTwilio updated events
16
+ *
17
+ * @event k1.t-hEOJjsDb.NotificationModule.Conversation.Update.SyncConversationStateFromTwilio
18
+ */
19
+ export interface SyncConversationStateFromTwilioMessage extends OdinRecordUpdatedEvent<SyncConversationStateFromTwilioDto, SyncConversationStateFromTwilioProperties> {
20
+ }
21
+ /**
22
+ * Properties for SyncConversationStateFromTwilio action
23
+ *
24
+ * @property Required fields: 1
25
+ * @property Optional fields: 1
26
+ */
27
+ export interface SyncConversationStateFromTwilioProperties {
28
+ /**
29
+ * Status
30
+ *
31
+ * the status of the conversation (Communications - Conversation)
32
+ * @type {ENUM}
33
+ * @required
34
+ */
35
+ Status: string;
36
+ /**
37
+ * Twilio conversation SID
38
+ *
39
+ * Unique External ID (Conversation SID / Conversation ID) (Communications - Conversation)
40
+ * @type {TEXT}
41
+ */
42
+ ExternalId?: string | null;
43
+ }
44
+ /**
45
+ * Mirror the conversation state Twilio reported
46
+ *
47
+ * Applies the conversation state from a Twilio onConversationStateUpdated webhook (active -> CREATED, inactive -> INACTIVE, anything else -> CLOSED). Fired by youfibre-api-chat twilio.webhook.service.ts, never by a user.
48
+ *
49
+ * @actionType UPDATE - Updates an existing Conversation record
50
+ * @module NotificationModule
51
+ * @entity Conversation
52
+ * @event k1.t-hEOJjsDb.NotificationModule.Conversation.Update.SyncConversationStateFromTwilio
53
+ * @permission schema.action.syncconversationstatefromtwilio.trigger
54
+ * @benchmark This action is tracked for performance benchmarks
55
+ */
56
+ export declare class SyncConversationStateFromTwilioDto extends OdinRecordUpdateDto<SyncConversationStateFromTwilioProperties> {
57
+ /** Used by SDK generators to identify action type */
58
+ static readonly ACTION_TYPE = "UPDATE";
59
+ static readonly ACTION_KEY = "SyncConversationStateFromTwilio";
60
+ static readonly MODULE_NAME = "NotificationModule";
61
+ static readonly ENTITIES: string[];
62
+ static readonly EVENT_NAME = "k1.t-hEOJjsDb.NotificationModule.Conversation.Update.SyncConversationStateFromTwilio";
63
+ static readonly PERMISSION = "schema.action.syncconversationstatefromtwilio.trigger";
64
+ /** Step metadata - entity this action targets */
65
+ static readonly STEP_ENTITY = "NotificationModule:Conversation";
66
+ static readonly STEP_SCHEMA_ID = "9efdee13-fefe-4131-b66e-60798c084c6d";
67
+ static readonly STEP_SCHEMA_ACTION_ID = "c8abcd96-6b18-4dee-94c6-b84016cafc61";
68
+ static readonly AUTO_LINK_PARENT = false;
69
+ readonly actionName: string;
70
+ readonly schemaActionId: string;
71
+ readonly entity: string;
72
+ constructor(record: OdinRecord<any> | {
73
+ id: string;
74
+ entity: string;
75
+ type?: string;
76
+ }, properties: SyncConversationStateFromTwilioProperties, options?: {
77
+ journeyId?: string;
78
+ stageKey?: string;
79
+ });
80
+ }
@@ -0,0 +1,56 @@
1
+ "use strict";
2
+ /**
3
+ * SyncConversationStateFromTwilio Action DTO
4
+ *
5
+ * Applies the conversation state from a Twilio onConversationStateUpdated webhook (active -> CREATED, inactive -> INACTIVE, anything else -> CLOSED). Fired by youfibre-api-chat twilio.webhook.service.ts, never by a user.
6
+ *
7
+ * @module NotificationModule
8
+ * @entity Conversation
9
+ * @actionKey SyncConversationStateFromTwilio
10
+ * @event k1.t-hEOJjsDb.NotificationModule.Conversation.Update.SyncConversationStateFromTwilio
11
+ *
12
+ * AUTO-GENERATED - DO NOT EDIT DIRECTLY
13
+ */
14
+ Object.defineProperty(exports, "__esModule", { value: true });
15
+ exports.SyncConversationStateFromTwilioDto = void 0;
16
+ const core_1 = require("@d19n/odin-types/dist/core");
17
+ /**
18
+ * Mirror the conversation state Twilio reported
19
+ *
20
+ * Applies the conversation state from a Twilio onConversationStateUpdated webhook (active -> CREATED, inactive -> INACTIVE, anything else -> CLOSED). Fired by youfibre-api-chat twilio.webhook.service.ts, never by a user.
21
+ *
22
+ * @actionType UPDATE - Updates an existing Conversation record
23
+ * @module NotificationModule
24
+ * @entity Conversation
25
+ * @event k1.t-hEOJjsDb.NotificationModule.Conversation.Update.SyncConversationStateFromTwilio
26
+ * @permission schema.action.syncconversationstatefromtwilio.trigger
27
+ * @benchmark This action is tracked for performance benchmarks
28
+ */
29
+ class SyncConversationStateFromTwilioDto extends core_1.OdinRecordUpdateDto {
30
+ constructor(record, properties, options) {
31
+ super({
32
+ id: record.id,
33
+ entity: record.entity,
34
+ type: record.type,
35
+ properties,
36
+ journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
37
+ stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
38
+ });
39
+ this.actionName = 'SyncConversationStateFromTwilio';
40
+ this.schemaActionId = 'c8abcd96-6b18-4dee-94c6-b84016cafc61';
41
+ this.entity = 'NotificationModule:Conversation';
42
+ }
43
+ }
44
+ exports.SyncConversationStateFromTwilioDto = SyncConversationStateFromTwilioDto;
45
+ /** Used by SDK generators to identify action type */
46
+ SyncConversationStateFromTwilioDto.ACTION_TYPE = 'UPDATE';
47
+ SyncConversationStateFromTwilioDto.ACTION_KEY = 'SyncConversationStateFromTwilio';
48
+ SyncConversationStateFromTwilioDto.MODULE_NAME = 'NotificationModule';
49
+ SyncConversationStateFromTwilioDto.ENTITIES = ['Conversation'];
50
+ SyncConversationStateFromTwilioDto.EVENT_NAME = 'k1.t-hEOJjsDb.NotificationModule.Conversation.Update.SyncConversationStateFromTwilio';
51
+ SyncConversationStateFromTwilioDto.PERMISSION = 'schema.action.syncconversationstatefromtwilio.trigger';
52
+ /** Step metadata - entity this action targets */
53
+ SyncConversationStateFromTwilioDto.STEP_ENTITY = 'NotificationModule:Conversation';
54
+ SyncConversationStateFromTwilioDto.STEP_SCHEMA_ID = '9efdee13-fefe-4131-b66e-60798c084c6d';
55
+ SyncConversationStateFromTwilioDto.STEP_SCHEMA_ACTION_ID = 'c8abcd96-6b18-4dee-94c6-b84016cafc61';
56
+ SyncConversationStateFromTwilioDto.AUTO_LINK_PARENT = false;
@@ -0,0 +1,80 @@
1
+ /**
2
+ * SyncMessageStateFromTwilio Action DTO
3
+ *
4
+ * Stamps the delivery state from a Twilio onMessageAdded webhook. Fired by youfibre-api-chat twilio.webhook.service.ts, never by a user.
5
+ *
6
+ * @module NotificationModule
7
+ * @entity Message
8
+ * @actionKey SyncMessageStateFromTwilio
9
+ * @event k1.t-hEOJjsDb.NotificationModule.Message.Update.SyncMessageStateFromTwilio
10
+ *
11
+ * AUTO-GENERATED - DO NOT EDIT DIRECTLY
12
+ */
13
+ import { OdinRecord, OdinRecordUpdateDto, OdinRecordUpdatedEvent } from '@d19n/odin-types/dist/core';
14
+ /**
15
+ * RabbitMQ message payload for SyncMessageStateFromTwilio updated events
16
+ *
17
+ * @event k1.t-hEOJjsDb.NotificationModule.Message.Update.SyncMessageStateFromTwilio
18
+ */
19
+ export interface SyncMessageStateFromTwilioMessage extends OdinRecordUpdatedEvent<SyncMessageStateFromTwilioDto, SyncMessageStateFromTwilioProperties> {
20
+ }
21
+ /**
22
+ * Properties for SyncMessageStateFromTwilio action
23
+ *
24
+ * @property Required fields: 1
25
+ * @property Optional fields: 1
26
+ */
27
+ export interface SyncMessageStateFromTwilioProperties {
28
+ /**
29
+ * Status
30
+ *
31
+ * Status of the message (CREATED,DELETED) (Communications - Message)
32
+ * @type {TEXT}
33
+ * @required
34
+ */
35
+ Status: string;
36
+ /**
37
+ * Twilio message SID
38
+ *
39
+ * External ID of the message (Communications - Message)
40
+ * @type {TEXT}
41
+ */
42
+ ExternalId?: string | null;
43
+ }
44
+ /**
45
+ * Mirror the message state Twilio reported
46
+ *
47
+ * Stamps the delivery state from a Twilio onMessageAdded webhook. Fired by youfibre-api-chat twilio.webhook.service.ts, never by a user.
48
+ *
49
+ * @actionType UPDATE - Updates an existing Message record
50
+ * @module NotificationModule
51
+ * @entity Message
52
+ * @event k1.t-hEOJjsDb.NotificationModule.Message.Update.SyncMessageStateFromTwilio
53
+ * @permission schema.action.syncmessagestatefromtwilio.trigger
54
+ * @benchmark This action is tracked for performance benchmarks
55
+ */
56
+ export declare class SyncMessageStateFromTwilioDto extends OdinRecordUpdateDto<SyncMessageStateFromTwilioProperties> {
57
+ /** Used by SDK generators to identify action type */
58
+ static readonly ACTION_TYPE = "UPDATE";
59
+ static readonly ACTION_KEY = "SyncMessageStateFromTwilio";
60
+ static readonly MODULE_NAME = "NotificationModule";
61
+ static readonly ENTITIES: string[];
62
+ static readonly EVENT_NAME = "k1.t-hEOJjsDb.NotificationModule.Message.Update.SyncMessageStateFromTwilio";
63
+ static readonly PERMISSION = "schema.action.syncmessagestatefromtwilio.trigger";
64
+ /** Step metadata - entity this action targets */
65
+ static readonly STEP_ENTITY = "NotificationModule:Message";
66
+ static readonly STEP_SCHEMA_ID = "f1c6db7a-eda8-405b-9d9e-536047a61b57";
67
+ static readonly STEP_SCHEMA_ACTION_ID = "b4cbab9e-776d-4869-97b2-7902ff8aebbc";
68
+ static readonly AUTO_LINK_PARENT = false;
69
+ readonly actionName: string;
70
+ readonly schemaActionId: string;
71
+ readonly entity: string;
72
+ constructor(record: OdinRecord<any> | {
73
+ id: string;
74
+ entity: string;
75
+ type?: string;
76
+ }, properties: SyncMessageStateFromTwilioProperties, options?: {
77
+ journeyId?: string;
78
+ stageKey?: string;
79
+ });
80
+ }
@@ -0,0 +1,56 @@
1
+ "use strict";
2
+ /**
3
+ * SyncMessageStateFromTwilio Action DTO
4
+ *
5
+ * Stamps the delivery state from a Twilio onMessageAdded webhook. Fired by youfibre-api-chat twilio.webhook.service.ts, never by a user.
6
+ *
7
+ * @module NotificationModule
8
+ * @entity Message
9
+ * @actionKey SyncMessageStateFromTwilio
10
+ * @event k1.t-hEOJjsDb.NotificationModule.Message.Update.SyncMessageStateFromTwilio
11
+ *
12
+ * AUTO-GENERATED - DO NOT EDIT DIRECTLY
13
+ */
14
+ Object.defineProperty(exports, "__esModule", { value: true });
15
+ exports.SyncMessageStateFromTwilioDto = void 0;
16
+ const core_1 = require("@d19n/odin-types/dist/core");
17
+ /**
18
+ * Mirror the message state Twilio reported
19
+ *
20
+ * Stamps the delivery state from a Twilio onMessageAdded webhook. Fired by youfibre-api-chat twilio.webhook.service.ts, never by a user.
21
+ *
22
+ * @actionType UPDATE - Updates an existing Message record
23
+ * @module NotificationModule
24
+ * @entity Message
25
+ * @event k1.t-hEOJjsDb.NotificationModule.Message.Update.SyncMessageStateFromTwilio
26
+ * @permission schema.action.syncmessagestatefromtwilio.trigger
27
+ * @benchmark This action is tracked for performance benchmarks
28
+ */
29
+ class SyncMessageStateFromTwilioDto extends core_1.OdinRecordUpdateDto {
30
+ constructor(record, properties, options) {
31
+ super({
32
+ id: record.id,
33
+ entity: record.entity,
34
+ type: record.type,
35
+ properties,
36
+ journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
37
+ stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
38
+ });
39
+ this.actionName = 'SyncMessageStateFromTwilio';
40
+ this.schemaActionId = 'b4cbab9e-776d-4869-97b2-7902ff8aebbc';
41
+ this.entity = 'NotificationModule:Message';
42
+ }
43
+ }
44
+ exports.SyncMessageStateFromTwilioDto = SyncMessageStateFromTwilioDto;
45
+ /** Used by SDK generators to identify action type */
46
+ SyncMessageStateFromTwilioDto.ACTION_TYPE = 'UPDATE';
47
+ SyncMessageStateFromTwilioDto.ACTION_KEY = 'SyncMessageStateFromTwilio';
48
+ SyncMessageStateFromTwilioDto.MODULE_NAME = 'NotificationModule';
49
+ SyncMessageStateFromTwilioDto.ENTITIES = ['Message'];
50
+ SyncMessageStateFromTwilioDto.EVENT_NAME = 'k1.t-hEOJjsDb.NotificationModule.Message.Update.SyncMessageStateFromTwilio';
51
+ SyncMessageStateFromTwilioDto.PERMISSION = 'schema.action.syncmessagestatefromtwilio.trigger';
52
+ /** Step metadata - entity this action targets */
53
+ SyncMessageStateFromTwilioDto.STEP_ENTITY = 'NotificationModule:Message';
54
+ SyncMessageStateFromTwilioDto.STEP_SCHEMA_ID = 'f1c6db7a-eda8-405b-9d9e-536047a61b57';
55
+ SyncMessageStateFromTwilioDto.STEP_SCHEMA_ACTION_ID = 'b4cbab9e-776d-4869-97b2-7902ff8aebbc';
56
+ SyncMessageStateFromTwilioDto.AUTO_LINK_PARENT = false;
@@ -26,10 +26,12 @@ export declare enum RecontractEntityTypes {
26
26
  *
27
27
  * @remarks Available options:
28
28
  * - `AGENT` - Agent
29
+ * - `CUSTOMER_APP` - Customer App
29
30
  * - `WEB_RECONTRACT` - Website
30
31
  */
31
32
  export declare enum RecontractSource {
32
33
  AGENT = "AGENT",
34
+ CUSTOMER_APP = "CUSTOMER_APP",
33
35
  WEBSITE = "WEB_RECONTRACT"
34
36
  }
35
37
  /**
@@ -51,6 +53,8 @@ export declare enum RecontractPropertyKeys {
51
53
  NextContractType = "NextContractType",
52
54
  /** DORMANT — written by nothing today. Added to make an ActiveDate 1:1 write safe, but that write was then deliberately dropped: amending in place, the order IS the one that went live on its original ActiveDate, so it is left untouched and needs no snapshot (RecontractWrittenProperties.spec.ts asserts it is never written). Retained because the column already exists in sandbox + prod and schema removals are not free; declared here so the spec still matches reality. Populate it only if Order.ActiveDate ever becomes something a recontract overwrites. */
53
55
  PreviousActiveDate = "PreviousActiveDate",
56
+ /** The amount of days left on the contract at point of recontract */
57
+ PreviousContractRemaining = "PreviousContractRemaining",
54
58
  /** Recontract title (e.g. "OR1654429 recontract 2026-07-24"). */
55
59
  Name = "Name",
56
60
  /** Snapshot of the order items BEFORE the recontract (rollback source). */
@@ -116,6 +120,11 @@ export interface RecontractProperties {
116
120
  * @default
117
121
  */
118
122
  PreviousActiveDate: string;
123
+ /** The amount of days left on the contract at point of recontract
124
+ *
125
+ * @type {NUMBER}
126
+ */
127
+ PreviousContractRemaining: number;
119
128
  /** Recontract title (e.g. "OR1654429 recontract 2026-07-24").
120
129
  *
121
130
  * @type {TEXT}
@@ -29,11 +29,13 @@ var RecontractEntityTypes;
29
29
  *
30
30
  * @remarks Available options:
31
31
  * - `AGENT` - Agent
32
+ * - `CUSTOMER_APP` - Customer App
32
33
  * - `WEB_RECONTRACT` - Website
33
34
  */
34
35
  var RecontractSource;
35
36
  (function (RecontractSource) {
36
37
  RecontractSource["AGENT"] = "AGENT";
38
+ RecontractSource["CUSTOMER_APP"] = "CUSTOMER_APP";
37
39
  RecontractSource["WEBSITE"] = "WEB_RECONTRACT";
38
40
  })(RecontractSource = exports.RecontractSource || (exports.RecontractSource = {}));
39
41
  /**
@@ -56,6 +58,8 @@ var RecontractPropertyKeys;
56
58
  RecontractPropertyKeys["NextContractType"] = "NextContractType";
57
59
  /** DORMANT — written by nothing today. Added to make an ActiveDate 1:1 write safe, but that write was then deliberately dropped: amending in place, the order IS the one that went live on its original ActiveDate, so it is left untouched and needs no snapshot (RecontractWrittenProperties.spec.ts asserts it is never written). Retained because the column already exists in sandbox + prod and schema removals are not free; declared here so the spec still matches reality. Populate it only if Order.ActiveDate ever becomes something a recontract overwrites. */
58
60
  RecontractPropertyKeys["PreviousActiveDate"] = "PreviousActiveDate";
61
+ /** The amount of days left on the contract at point of recontract */
62
+ RecontractPropertyKeys["PreviousContractRemaining"] = "PreviousContractRemaining";
59
63
  /** Recontract title (e.g. "OR1654429 recontract 2026-07-24"). */
60
64
  RecontractPropertyKeys["Name"] = "Name";
61
65
  /** Snapshot of the order items BEFORE the recontract (rollback source). */
@@ -25,6 +25,7 @@ import { RecordLinkManager } from '@d19n/odin-sdk-generator/dist/record-link-man
25
25
  import { ConversationProperties } from '../entities-v2/Conversation';
26
26
  import { CloseConversationProperties } from '../actions-v2/CloseConversationDto';
27
27
  import { CreateConversationProperties } from '../actions-v2/CreateConversationDto';
28
+ import { SyncConversationStateFromTwilioProperties } from '../actions-v2/SyncConversationStateFromTwilioDto';
28
29
  import { UpdateConversationProperties } from '../actions-v2/UpdateConversationDto';
29
30
  import { UpdateConversationSummaryProperties } from '../actions-v2/UpdateConversationSummaryDto';
30
31
  import { MessageRecord } from './MessageRecord';
@@ -288,6 +289,32 @@ export declare class ConversationRecord<TProps = ConversationProperties> {
288
289
  journeyId?: string;
289
290
  stageKey?: string;
290
291
  }): ActionBuilder;
292
+ /**
293
+ * SyncConversationStateFromTwilio
294
+ *
295
+ * Updates this Conversation record with the specified properties.
296
+ * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
297
+ *
298
+ * @param properties - Required properties for this action
299
+ * @param options - Optional settings
300
+ * @param options.journeyId - Associate with a journey
301
+ * @param options.stageKey - Transition to pipeline stage
302
+ * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
303
+ * @throws Error if called on a new (unsaved) record
304
+ *
305
+ * @example
306
+ * ```typescript
307
+ * const record = await odinClient.conversations.get(id);
308
+ * await record.syncConversationStateFromTwilio({ ... }).execute();
309
+ *
310
+ * // Dry run (for debugging)
311
+ * const payload = record.syncConversationStateFromTwilio({ ... }).dryRun();
312
+ * ```
313
+ */
314
+ syncConversationStateFromTwilio(properties: SyncConversationStateFromTwilioProperties, options?: {
315
+ journeyId?: string;
316
+ stageKey?: string;
317
+ }): ActionBuilder;
291
318
  /**
292
319
  * UpdateConversation
293
320
  *
@@ -391,6 +391,35 @@ class ConversationRecord {
391
391
  const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'CloseConversation', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, options);
392
392
  return new ActionBuilder(this._provider, 'NotificationModule', 'Conversation', payload, () => { this._pendingLinks = []; });
393
393
  }
394
+ /**
395
+ * SyncConversationStateFromTwilio
396
+ *
397
+ * Updates this Conversation record with the specified properties.
398
+ * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
399
+ *
400
+ * @param properties - Required properties for this action
401
+ * @param options - Optional settings
402
+ * @param options.journeyId - Associate with a journey
403
+ * @param options.stageKey - Transition to pipeline stage
404
+ * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
405
+ * @throws Error if called on a new (unsaved) record
406
+ *
407
+ * @example
408
+ * ```typescript
409
+ * const record = await odinClient.conversations.get(id);
410
+ * await record.syncConversationStateFromTwilio({ ... }).execute();
411
+ *
412
+ * // Dry run (for debugging)
413
+ * const payload = record.syncConversationStateFromTwilio({ ... }).dryRun();
414
+ * ```
415
+ */
416
+ syncConversationStateFromTwilio(properties, options) {
417
+ var _a;
418
+ if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
419
+ throw new Error('syncConversationStateFromTwilio requires an existing record. Use accessor.get() first.');
420
+ const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'SyncConversationStateFromTwilio', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, options);
421
+ return new ActionBuilder(this._provider, 'NotificationModule', 'Conversation', payload, () => { this._pendingLinks = []; });
422
+ }
394
423
  /**
395
424
  * UpdateConversation
396
425
  *
@@ -27,6 +27,7 @@ import { CreateCloseMessageProperties } from '../actions-v2/CreateCloseMessageDt
27
27
  import { CreateEventMessageProperties } from '../actions-v2/CreateEventMessageDto';
28
28
  import { CreateMessageProperties } from '../actions-v2/CreateMessageDto';
29
29
  import { CreateNudgeMessageProperties } from '../actions-v2/CreateNudgeMessageDto';
30
+ import { SyncMessageStateFromTwilioProperties } from '../actions-v2/SyncMessageStateFromTwilioDto';
30
31
  import { ConversationRecord } from './ConversationRecord';
31
32
  import { PushNotificationRecord } from './PushNotificationRecord';
32
33
  import { FileRecord } from './FileRecord';
@@ -374,6 +375,32 @@ export declare class MessageRecord<TProps = MessageProperties> {
374
375
  journeyId?: string;
375
376
  stageKey?: string;
376
377
  }): ActionBuilder;
378
+ /**
379
+ * SyncMessageStateFromTwilio
380
+ *
381
+ * Updates this Message record with the specified properties.
382
+ * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
383
+ *
384
+ * @param properties - Required properties for this action
385
+ * @param options - Optional settings
386
+ * @param options.journeyId - Associate with a journey
387
+ * @param options.stageKey - Transition to pipeline stage
388
+ * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
389
+ * @throws Error if called on a new (unsaved) record
390
+ *
391
+ * @example
392
+ * ```typescript
393
+ * const record = await odinClient.messages.get(id);
394
+ * await record.syncMessageStateFromTwilio({ ... }).execute();
395
+ *
396
+ * // Dry run (for debugging)
397
+ * const payload = record.syncMessageStateFromTwilio({ ... }).dryRun();
398
+ * ```
399
+ */
400
+ syncMessageStateFromTwilio(properties: SyncMessageStateFromTwilioProperties, options?: {
401
+ journeyId?: string;
402
+ stageKey?: string;
403
+ }): ActionBuilder;
377
404
  }
378
405
  /** Type guard to check if an object is a MessageRecord */
379
406
  export declare function isMessageRecord(obj: any): obj is MessageRecord;
@@ -484,6 +484,38 @@ class MessageRecord {
484
484
  };
485
485
  return new ActionBuilder(this._provider, 'NotificationModule', 'Message', payload, () => { this._pendingLinks = []; });
486
486
  }
487
+ // ============================================
488
+ // UPDATE ACTIONS (require existing record)
489
+ // ============================================
490
+ /**
491
+ * SyncMessageStateFromTwilio
492
+ *
493
+ * Updates this Message record with the specified properties.
494
+ * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
495
+ *
496
+ * @param properties - Required properties for this action
497
+ * @param options - Optional settings
498
+ * @param options.journeyId - Associate with a journey
499
+ * @param options.stageKey - Transition to pipeline stage
500
+ * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
501
+ * @throws Error if called on a new (unsaved) record
502
+ *
503
+ * @example
504
+ * ```typescript
505
+ * const record = await odinClient.messages.get(id);
506
+ * await record.syncMessageStateFromTwilio({ ... }).execute();
507
+ *
508
+ * // Dry run (for debugging)
509
+ * const payload = record.syncMessageStateFromTwilio({ ... }).dryRun();
510
+ * ```
511
+ */
512
+ syncMessageStateFromTwilio(properties, options) {
513
+ var _a;
514
+ if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
515
+ throw new Error('syncMessageStateFromTwilio requires an existing record. Use accessor.get() first.');
516
+ const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'SyncMessageStateFromTwilio', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, options);
517
+ return new ActionBuilder(this._provider, 'NotificationModule', 'Message', payload, () => { this._pendingLinks = []; });
518
+ }
487
519
  }
488
520
  exports.MessageRecord = MessageRecord;
489
521
  // ============================================
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@d19n/youfibre-odin-sdk",
3
- "version": "2.0.282",
3
+ "version": "2.0.284",
4
4
  "description": "",
5
5
  "author": "@d19n",
6
6
  "license": "UNLICENSED",