@d19n/youfibre-odin-sdk 2.0.227 → 2.0.228

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
@@ -354,7 +354,7 @@ This SDK includes **166** entities across **12** modules.
354
354
 
355
355
  ## Actions
356
356
 
357
- This SDK includes **713** actions.
357
+ This SDK includes **714** actions.
358
358
 
359
359
  ### Action Types
360
360
 
@@ -1323,6 +1323,7 @@ This SDK includes **713** actions.
1323
1323
  | `SendTlosNinjaCaseEmail` | CREATE | k1.t-hEOJjsDb.NotificationModule.Email.Create.SendTlosNinjaCaseEmail |
1324
1324
  | `UpdateEmail` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateEmail |
1325
1325
  | `UpdateSupportEmail` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateSupportEmail |
1326
+ | `UpdateTransactionalEmail` | UPDATE | k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateTransactionalEmail |
1326
1327
 
1327
1328
  #### OrderKci
1328
1329
 
@@ -0,0 +1,112 @@
1
+ /**
2
+ * UpdateTransactionalEmail Action DTO
3
+ *
4
+ * Update Transaction Email
5
+ *
6
+ * @module NotificationModule
7
+ * @entity Email
8
+ * @entityType TRANSACTIONAL
9
+ * @actionKey UpdateTransactionalEmail
10
+ * @event k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateTransactionalEmail
11
+ *
12
+ * AUTO-GENERATED - DO NOT EDIT DIRECTLY
13
+ */
14
+ import { OdinRecord, OdinRecordUpdateDto, OdinRecordUpdatedEvent } from '@d19n/odin-types/dist/core';
15
+ /**
16
+ * RabbitMQ message payload for UpdateTransactionalEmail updated events
17
+ *
18
+ * @event k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateTransactionalEmail
19
+ */
20
+ export interface UpdateTransactionalEmailMessage extends OdinRecordUpdatedEvent<UpdateTransactionalEmailDto, UpdateTransactionalEmailProperties> {
21
+ }
22
+ /**
23
+ * Properties for UpdateTransactionalEmail action
24
+ *
25
+ * @property Required fields: 0
26
+ * @property Optional fields: 6
27
+ */
28
+ export interface UpdateTransactionalEmailProperties {
29
+ /**
30
+ * Case
31
+ *
32
+ * Data field for Email records. Used by Communications team.
33
+ * @type {LOOKUP}
34
+ */
35
+ Case?: string | null;
36
+ /**
37
+ * ParentMessageId
38
+ *
39
+ * Parent Message id (Communications - Email)
40
+ * @type {LOOKUP}
41
+ */
42
+ ParentMessageId?: string | null;
43
+ /**
44
+ * ContactId
45
+ *
46
+ * The related Contact to send the email
47
+ * @type {LOOKUP}
48
+ */
49
+ ContactId?: string | null;
50
+ /**
51
+ * MessageId
52
+ *
53
+ * SMTP Message Id (Communications - Email)
54
+ * @type {TEXT}
55
+ */
56
+ MessageId?: string | null;
57
+ /**
58
+ * WorkOrder
59
+ *
60
+ * WorkOrder
61
+ * @type {LOOKUP}
62
+ */
63
+ WorkOrder?: string | null;
64
+ /**
65
+ * EmailSenderId
66
+ *
67
+ * The Email Sender related entity
68
+ * @type {LOOKUP}
69
+ */
70
+ EmailSenderId?: string | null;
71
+ }
72
+ /**
73
+ * UpdateTransactionalEmail
74
+ *
75
+ * Update Transaction Email
76
+ *
77
+ * @actionType UPDATE - Updates an existing Email record
78
+ * @module NotificationModule
79
+ * @entity Email
80
+ * @entityType TRANSACTIONAL (TRANSACTIONAL)
81
+ * @event k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateTransactionalEmail
82
+ * @permission schema.action.updatetransactionalemail.trigger
83
+ * @benchmark This action is tracked for performance benchmarks
84
+ */
85
+ export declare class UpdateTransactionalEmailDto extends OdinRecordUpdateDto<UpdateTransactionalEmailProperties> {
86
+ /** Used by SDK generators to identify action type */
87
+ static readonly ACTION_TYPE = "UPDATE";
88
+ static readonly ACTION_KEY = "UpdateTransactionalEmail";
89
+ static readonly MODULE_NAME = "NotificationModule";
90
+ static readonly ENTITIES: string[];
91
+ static readonly ENTITY_TYPE = "TRANSACTIONAL";
92
+ static readonly EVENT_NAME = "k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateTransactionalEmail";
93
+ static readonly PERMISSION = "schema.action.updatetransactionalemail.trigger";
94
+ /** Step metadata - entity this action targets */
95
+ static readonly STEP_ENTITY = "NotificationModule:Email";
96
+ static readonly STEP_SCHEMA_ID = "cb37958c-d72f-44aa-975a-a8fae42b1b72";
97
+ static readonly STEP_SCHEMA_ACTION_ID = "462fa8ca-d2e1-42eb-bb4a-8821174ffda7";
98
+ static readonly STEP_SCHEMA_TYPE_ID = "14042940-a388-44c7-87fe-3a4105d92e94";
99
+ static readonly STEP_TYPE = "TRANSACTIONAL";
100
+ static readonly AUTO_LINK_PARENT = false;
101
+ readonly actionName: string;
102
+ readonly schemaActionId: string;
103
+ readonly entity: string;
104
+ constructor(record: OdinRecord<any> | {
105
+ id: string;
106
+ entity: string;
107
+ type?: string;
108
+ }, properties: UpdateTransactionalEmailProperties, options?: {
109
+ journeyId?: string;
110
+ stageKey?: string;
111
+ });
112
+ }
@@ -0,0 +1,61 @@
1
+ "use strict";
2
+ /**
3
+ * UpdateTransactionalEmail Action DTO
4
+ *
5
+ * Update Transaction Email
6
+ *
7
+ * @module NotificationModule
8
+ * @entity Email
9
+ * @entityType TRANSACTIONAL
10
+ * @actionKey UpdateTransactionalEmail
11
+ * @event k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateTransactionalEmail
12
+ *
13
+ * AUTO-GENERATED - DO NOT EDIT DIRECTLY
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.UpdateTransactionalEmailDto = void 0;
17
+ const core_1 = require("@d19n/odin-types/dist/core");
18
+ /**
19
+ * UpdateTransactionalEmail
20
+ *
21
+ * Update Transaction Email
22
+ *
23
+ * @actionType UPDATE - Updates an existing Email record
24
+ * @module NotificationModule
25
+ * @entity Email
26
+ * @entityType TRANSACTIONAL (TRANSACTIONAL)
27
+ * @event k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateTransactionalEmail
28
+ * @permission schema.action.updatetransactionalemail.trigger
29
+ * @benchmark This action is tracked for performance benchmarks
30
+ */
31
+ class UpdateTransactionalEmailDto extends core_1.OdinRecordUpdateDto {
32
+ constructor(record, properties, options) {
33
+ super({
34
+ id: record.id,
35
+ entity: record.entity,
36
+ type: record.type,
37
+ properties,
38
+ journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
39
+ stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
40
+ });
41
+ this.actionName = 'UpdateTransactionalEmail';
42
+ this.schemaActionId = '462fa8ca-d2e1-42eb-bb4a-8821174ffda7';
43
+ this.entity = 'NotificationModule:Email';
44
+ }
45
+ }
46
+ exports.UpdateTransactionalEmailDto = UpdateTransactionalEmailDto;
47
+ /** Used by SDK generators to identify action type */
48
+ UpdateTransactionalEmailDto.ACTION_TYPE = 'UPDATE';
49
+ UpdateTransactionalEmailDto.ACTION_KEY = 'UpdateTransactionalEmail';
50
+ UpdateTransactionalEmailDto.MODULE_NAME = 'NotificationModule';
51
+ UpdateTransactionalEmailDto.ENTITIES = ['Email'];
52
+ UpdateTransactionalEmailDto.ENTITY_TYPE = 'TRANSACTIONAL';
53
+ UpdateTransactionalEmailDto.EVENT_NAME = 'k1.t-hEOJjsDb.NotificationModule.Email.Update.UpdateTransactionalEmail';
54
+ UpdateTransactionalEmailDto.PERMISSION = 'schema.action.updatetransactionalemail.trigger';
55
+ /** Step metadata - entity this action targets */
56
+ UpdateTransactionalEmailDto.STEP_ENTITY = 'NotificationModule:Email';
57
+ UpdateTransactionalEmailDto.STEP_SCHEMA_ID = 'cb37958c-d72f-44aa-975a-a8fae42b1b72';
58
+ UpdateTransactionalEmailDto.STEP_SCHEMA_ACTION_ID = '462fa8ca-d2e1-42eb-bb4a-8821174ffda7';
59
+ UpdateTransactionalEmailDto.STEP_SCHEMA_TYPE_ID = '14042940-a388-44c7-87fe-3a4105d92e94';
60
+ UpdateTransactionalEmailDto.STEP_TYPE = 'TRANSACTIONAL';
61
+ UpdateTransactionalEmailDto.AUTO_LINK_PARENT = false;
@@ -48,6 +48,7 @@ import { SendRefundTransactionEmailProperties } from '../actions-v2/SendRefundTr
48
48
  import { SendTlosNinjaCaseEmailProperties } from '../actions-v2/SendTlosNinjaCaseEmailDto';
49
49
  import { UpdateEmailProperties } from '../actions-v2/UpdateEmailDto';
50
50
  import { UpdateSupportEmailProperties } from '../actions-v2/UpdateSupportEmailDto';
51
+ import { UpdateTransactionalEmailProperties } from '../actions-v2/UpdateTransactionalEmailDto';
51
52
  import { ReferralRecord } from './ReferralRecord';
52
53
  import { EmailSenderRecord } from './EmailSenderRecord';
53
54
  import { ContactRecord } from './ContactRecord';
@@ -1079,6 +1080,33 @@ export declare class EmailRecord<TProps = EmailProperties> {
1079
1080
  journeyId?: string;
1080
1081
  stageKey?: string;
1081
1082
  }): ActionBuilder;
1083
+ /**
1084
+ * UpdateTransactionalEmail
1085
+ *
1086
+ * Updates this Email record.
1087
+ * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
1088
+ *
1089
+ * @param propertiesOrOptions - Properties to update, or options object
1090
+ * @param options - Optional settings (journeyId, stageKey)
1091
+ * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
1092
+ * @throws Error if called on a new (unsaved) record
1093
+ *
1094
+ * @example
1095
+ * ```typescript
1096
+ * const record = await odinClient.emails.get(id);
1097
+ * await record.updateTransactionalEmail({ ... }).execute();
1098
+ *
1099
+ * // Dry run (for debugging)
1100
+ * const payload = record.updateTransactionalEmail({ ... }).dryRun();
1101
+ * ```
1102
+ */
1103
+ updateTransactionalEmail(propertiesOrOptions?: UpdateTransactionalEmailProperties | {
1104
+ journeyId?: string;
1105
+ stageKey?: string;
1106
+ }, options?: {
1107
+ journeyId?: string;
1108
+ stageKey?: string;
1109
+ }): ActionBuilder;
1082
1110
  }
1083
1111
  /** Type guard to check if an object is a EmailRecord */
1084
1112
  export declare function isEmailRecord(obj: any): obj is EmailRecord;
@@ -1391,6 +1391,43 @@ class EmailRecord {
1391
1391
  const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'UpdateSupportEmail', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, options);
1392
1392
  return new ActionBuilder(this._provider, 'NotificationModule', 'Email', payload, () => { this._pendingLinks = []; });
1393
1393
  }
1394
+ /**
1395
+ * UpdateTransactionalEmail
1396
+ *
1397
+ * Updates this Email record.
1398
+ * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
1399
+ *
1400
+ * @param propertiesOrOptions - Properties to update, or options object
1401
+ * @param options - Optional settings (journeyId, stageKey)
1402
+ * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
1403
+ * @throws Error if called on a new (unsaved) record
1404
+ *
1405
+ * @example
1406
+ * ```typescript
1407
+ * const record = await odinClient.emails.get(id);
1408
+ * await record.updateTransactionalEmail({ ... }).execute();
1409
+ *
1410
+ * // Dry run (for debugging)
1411
+ * const payload = record.updateTransactionalEmail({ ... }).dryRun();
1412
+ * ```
1413
+ */
1414
+ updateTransactionalEmail(propertiesOrOptions, options) {
1415
+ var _a;
1416
+ if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
1417
+ throw new Error('updateTransactionalEmail requires an existing record. Use accessor.get() first.');
1418
+ let properties = {};
1419
+ let opts = options;
1420
+ if (propertiesOrOptions) {
1421
+ if ('journeyId' in propertiesOrOptions || 'stageKey' in propertiesOrOptions) {
1422
+ opts = propertiesOrOptions;
1423
+ }
1424
+ else {
1425
+ properties = propertiesOrOptions;
1426
+ }
1427
+ }
1428
+ const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'UpdateTransactionalEmail', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, opts);
1429
+ return new ActionBuilder(this._provider, 'NotificationModule', 'Email', payload, () => { this._pendingLinks = []; });
1430
+ }
1394
1431
  }
1395
1432
  exports.EmailRecord = EmailRecord;
1396
1433
  // ============================================
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@d19n/youfibre-odin-sdk",
3
- "version": "2.0.227",
3
+ "version": "2.0.228",
4
4
  "description": "",
5
5
  "author": "@d19n",
6
6
  "license": "UNLICENSED",