@d19n/youfibre-odin-sdk 2.0.308 → 2.0.310

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.
Files changed (32) hide show
  1. package/README.md +4 -1
  2. package/dist/actions-v2/AssignEngineerDto.d.ts +1 -1
  3. package/dist/actions-v2/CreateContactSalesAppDto.d.ts +98 -0
  4. package/dist/actions-v2/CreateContactSalesAppDto.js +54 -0
  5. package/dist/actions-v2/CreateLeadFromAddressSalesAppDto.d.ts +58 -0
  6. package/dist/actions-v2/CreateLeadFromAddressSalesAppDto.js +54 -0
  7. package/dist/actions-v2/CreateLeadSalesAppDto.d.ts +92 -0
  8. package/dist/actions-v2/CreateLeadSalesAppDto.js +54 -0
  9. package/dist/api-sdk-v2/EmailApi.d.ts +2 -0
  10. package/dist/api-sdk-v2/EmailApi.js +6 -0
  11. package/dist/api-sdk-v2/OrderApi.d.ts +2 -0
  12. package/dist/api-sdk-v2/OrderApi.js +6 -0
  13. package/dist/db-sdk-v2/EmailDb.d.ts +2 -0
  14. package/dist/db-sdk-v2/EmailDb.js +6 -0
  15. package/dist/db-sdk-v2/OrderDb.d.ts +2 -0
  16. package/dist/db-sdk-v2/OrderDb.js +6 -0
  17. package/dist/entities-v2/AgentStatus.d.ts +33 -33
  18. package/dist/entities-v2/AgentStatus.js +21 -21
  19. package/dist/entities-v2/CustomerDeviceOnt.d.ts +8 -0
  20. package/dist/entities-v2/CustomerDeviceOnt.js +2 -0
  21. package/dist/entities-v2/Email.d.ts +3 -0
  22. package/dist/entities-v2/Order.d.ts +7 -0
  23. package/dist/entities-v2/Order.js +5 -1
  24. package/dist/records-v2/ContactRecord.d.ts +29 -0
  25. package/dist/records-v2/ContactRecord.js +36 -0
  26. package/dist/records-v2/EmailRecord.d.ts +20 -0
  27. package/dist/records-v2/EmailRecord.js +33 -0
  28. package/dist/records-v2/LeadRecord.d.ts +58 -0
  29. package/dist/records-v2/LeadRecord.js +72 -0
  30. package/dist/records-v2/OrderRecord.d.ts +20 -0
  31. package/dist/records-v2/OrderRecord.js +33 -0
  32. package/package.json +1 -1
@@ -19,6 +19,21 @@ export declare enum AgentStatusEntityTypes {
19
19
  /** This is the default record type */
20
20
  DEFAULT = "DEFAULT"
21
21
  }
22
+ /**
23
+ * Valid values for AgentStatus.Source
24
+ *
25
+ * What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change.
26
+ *
27
+ * @remarks Available options:
28
+ * - `Manual` - Manual agent selection
29
+ * - `System` - System-generated change
30
+ * - `Voice` - Voice or Twilio event
31
+ */
32
+ export declare enum AgentStatusSource {
33
+ MANUAL_AGENT_SELECTION = "Manual",
34
+ SYSTEM_GENERATED_CHANGE = "System",
35
+ VOICE_OR_TWILIO_EVENT = "Voice"
36
+ }
22
37
  /**
23
38
  * Valid values for AgentStatus.Status
24
39
  *
@@ -85,38 +100,23 @@ export declare enum AgentStatusPreviousStatus {
85
100
  UNAVAILABLE = "Unavailable",
86
101
  UNPLANNED_BREAK = "Unplanned Break"
87
102
  }
88
- /**
89
- * Valid values for AgentStatus.Source
90
- *
91
- * What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change.
92
- *
93
- * @remarks Available options:
94
- * - `Manual` - Manual agent selection
95
- * - `System` - System-generated change
96
- * - `Voice` - Voice or Twilio event
97
- */
98
- export declare enum AgentStatusSource {
99
- MANUAL_AGENT_SELECTION = "Manual",
100
- SYSTEM_GENERATED_CHANGE = "System",
101
- VOICE_OR_TWILIO_EVENT = "Voice"
102
- }
103
103
  /**
104
104
  * Property keys for AgentStatus
105
105
  * Use these constants instead of string literals for type safety
106
106
  */
107
107
  export declare enum AgentStatusPropertyKeys {
108
+ /** What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change. */
109
+ Source = "Source",
108
110
  /** The Odin user this status belongs to. One AgentStatus row per user (UNIQUE) — the natural key upsertOnCreate upserts against. */
109
111
  UserId = "UserId",
110
112
  /** Current channel-agnostic availability status. Values mirror TwilioActivity.Name. */
111
113
  Status = "Status",
112
- /** The status immediately before the current one. Null on a user’s first-ever status write. */
113
- PreviousStatus = "PreviousStatus",
114
114
  /** Whether this user’s Odin status should sync to their Twilio Worker. Phase 1: stored only, never read by any sync (no Twilio calls happen yet) — the field exists now so Phase 2 does not need a schema change to turn sync on. */
115
115
  VoiceEnabled = "VoiceEnabled",
116
+ /** The status immediately before the current one. Null on a user’s first-ever status write. */
117
+ PreviousStatus = "PreviousStatus",
116
118
  /** When the current Status began. Reset on every status change. */
117
- StatusStartedAt = "StatusStartedAt",
118
- /** What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change. */
119
- Source = "Source"
119
+ StatusStartedAt = "StatusStartedAt"
120
120
  }
121
121
  /**
122
122
  * Properties for AgentStatus records
@@ -124,6 +124,13 @@ export declare enum AgentStatusPropertyKeys {
124
124
  * @see SupportModule:AgentStatus
125
125
  */
126
126
  export interface AgentStatusProperties {
127
+ /** What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change.
128
+ *
129
+ * @type {ENUM}
130
+ * @default Manual
131
+ * @enum {AgentStatusSource}
132
+ */
133
+ Source: AgentStatusSource;
127
134
  /** The Odin user this status belongs to. One AgentStatus row per user (UNIQUE) — the natural key upsertOnCreate upserts against.
128
135
  *
129
136
  * @type {LOOKUP}
@@ -137,6 +144,12 @@ export interface AgentStatusProperties {
137
144
  * @enum {AgentStatusStatus}
138
145
  */
139
146
  Status: AgentStatusStatus;
147
+ /** Whether this user’s Odin status should sync to their Twilio Worker. Phase 1: stored only, never read by any sync (no Twilio calls happen yet) — the field exists now so Phase 2 does not need a schema change to turn sync on.
148
+ *
149
+ * @type {BOOLEAN}
150
+ * @default false
151
+ */
152
+ VoiceEnabled: boolean;
140
153
  /** The status immediately before the current one. Null on a user’s first-ever status write.
141
154
  *
142
155
  * @type {ENUM}
@@ -144,25 +157,12 @@ export interface AgentStatusProperties {
144
157
  * @enum {AgentStatusPreviousStatus}
145
158
  */
146
159
  PreviousStatus: AgentStatusPreviousStatus;
147
- /** Whether this user’s Odin status should sync to their Twilio Worker. Phase 1: stored only, never read by any sync (no Twilio calls happen yet) — the field exists now so Phase 2 does not need a schema change to turn sync on.
148
- *
149
- * @type {BOOLEAN}
150
- * @default false
151
- */
152
- VoiceEnabled: boolean;
153
160
  /** When the current Status began. Reset on every status change.
154
161
  *
155
162
  * @type {DATE_TIME}
156
163
  * @default
157
164
  */
158
165
  StatusStartedAt: string;
159
- /** What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change.
160
- *
161
- * @type {ENUM}
162
- * @default Manual
163
- * @enum {AgentStatusSource}
164
- */
165
- Source: AgentStatusSource;
166
166
  }
167
167
  /**
168
168
  * AgentStatus entity from SupportModule
@@ -12,7 +12,7 @@
12
12
  * Generated from Odin schema definition
13
13
  */
14
14
  Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.ROUTING_KEY_LINK_AGENT_STATUS_USER_DELETED = exports.ROUTING_KEY_LINK_AGENT_STATUS_USER_CREATED = exports.ROUTING_KEY_AGENT_STATUS_DEFAULT_DELETED = exports.ROUTING_KEY_AGENT_STATUS_DEFAULT_UPDATED = exports.ROUTING_KEY_AGENT_STATUS_DEFAULT_CREATED = exports.ROUTING_KEY_AGENT_STATUS_DELETED = exports.ROUTING_KEY_AGENT_STATUS_UPDATED = exports.ROUTING_KEY_AGENT_STATUS_CREATED = exports.AgentStatus = exports.AgentStatusPropertyKeys = exports.AgentStatusSource = exports.AgentStatusPreviousStatus = exports.AgentStatusStatus = exports.AgentStatusEntityTypes = void 0;
15
+ exports.ROUTING_KEY_LINK_AGENT_STATUS_USER_DELETED = exports.ROUTING_KEY_LINK_AGENT_STATUS_USER_CREATED = exports.ROUTING_KEY_AGENT_STATUS_DEFAULT_DELETED = exports.ROUTING_KEY_AGENT_STATUS_DEFAULT_UPDATED = exports.ROUTING_KEY_AGENT_STATUS_DEFAULT_CREATED = exports.ROUTING_KEY_AGENT_STATUS_DELETED = exports.ROUTING_KEY_AGENT_STATUS_UPDATED = exports.ROUTING_KEY_AGENT_STATUS_CREATED = exports.AgentStatus = exports.AgentStatusPropertyKeys = exports.AgentStatusPreviousStatus = exports.AgentStatusStatus = exports.AgentStatusSource = exports.AgentStatusEntityTypes = void 0;
16
16
  const core_1 = require("@d19n/odin-types/dist/core");
17
17
  /**
18
18
  * Available types for AgentStatus records
@@ -22,6 +22,22 @@ var AgentStatusEntityTypes;
22
22
  /** This is the default record type */
23
23
  AgentStatusEntityTypes["DEFAULT"] = "DEFAULT";
24
24
  })(AgentStatusEntityTypes = exports.AgentStatusEntityTypes || (exports.AgentStatusEntityTypes = {}));
25
+ /**
26
+ * Valid values for AgentStatus.Source
27
+ *
28
+ * What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change.
29
+ *
30
+ * @remarks Available options:
31
+ * - `Manual` - Manual agent selection
32
+ * - `System` - System-generated change
33
+ * - `Voice` - Voice or Twilio event
34
+ */
35
+ var AgentStatusSource;
36
+ (function (AgentStatusSource) {
37
+ AgentStatusSource["MANUAL_AGENT_SELECTION"] = "Manual";
38
+ AgentStatusSource["SYSTEM_GENERATED_CHANGE"] = "System";
39
+ AgentStatusSource["VOICE_OR_TWILIO_EVENT"] = "Voice";
40
+ })(AgentStatusSource = exports.AgentStatusSource || (exports.AgentStatusSource = {}));
25
41
  /**
26
42
  * Valid values for AgentStatus.Status
27
43
  *
@@ -90,40 +106,24 @@ var AgentStatusPreviousStatus;
90
106
  AgentStatusPreviousStatus["UNAVAILABLE"] = "Unavailable";
91
107
  AgentStatusPreviousStatus["UNPLANNED_BREAK"] = "Unplanned Break";
92
108
  })(AgentStatusPreviousStatus = exports.AgentStatusPreviousStatus || (exports.AgentStatusPreviousStatus = {}));
93
- /**
94
- * Valid values for AgentStatus.Source
95
- *
96
- * What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change.
97
- *
98
- * @remarks Available options:
99
- * - `Manual` - Manual agent selection
100
- * - `System` - System-generated change
101
- * - `Voice` - Voice or Twilio event
102
- */
103
- var AgentStatusSource;
104
- (function (AgentStatusSource) {
105
- AgentStatusSource["MANUAL_AGENT_SELECTION"] = "Manual";
106
- AgentStatusSource["SYSTEM_GENERATED_CHANGE"] = "System";
107
- AgentStatusSource["VOICE_OR_TWILIO_EVENT"] = "Voice";
108
- })(AgentStatusSource = exports.AgentStatusSource || (exports.AgentStatusSource = {}));
109
109
  /**
110
110
  * Property keys for AgentStatus
111
111
  * Use these constants instead of string literals for type safety
112
112
  */
113
113
  var AgentStatusPropertyKeys;
114
114
  (function (AgentStatusPropertyKeys) {
115
+ /** What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change. */
116
+ AgentStatusPropertyKeys["Source"] = "Source";
115
117
  /** The Odin user this status belongs to. One AgentStatus row per user (UNIQUE) — the natural key upsertOnCreate upserts against. */
116
118
  AgentStatusPropertyKeys["UserId"] = "UserId";
117
119
  /** Current channel-agnostic availability status. Values mirror TwilioActivity.Name. */
118
120
  AgentStatusPropertyKeys["Status"] = "Status";
119
- /** The status immediately before the current one. Null on a user’s first-ever status write. */
120
- AgentStatusPropertyKeys["PreviousStatus"] = "PreviousStatus";
121
121
  /** Whether this user’s Odin status should sync to their Twilio Worker. Phase 1: stored only, never read by any sync (no Twilio calls happen yet) — the field exists now so Phase 2 does not need a schema change to turn sync on. */
122
122
  AgentStatusPropertyKeys["VoiceEnabled"] = "VoiceEnabled";
123
+ /** The status immediately before the current one. Null on a user’s first-ever status write. */
124
+ AgentStatusPropertyKeys["PreviousStatus"] = "PreviousStatus";
123
125
  /** When the current Status began. Reset on every status change. */
124
126
  AgentStatusPropertyKeys["StatusStartedAt"] = "StatusStartedAt";
125
- /** What triggered the current Status: manual agent selection, a voice/Twilio event, or a system-generated change. */
126
- AgentStatusPropertyKeys["Source"] = "Source";
127
127
  })(AgentStatusPropertyKeys = exports.AgentStatusPropertyKeys || (exports.AgentStatusPropertyKeys = {}));
128
128
  /**
129
129
  * AgentStatus entity from SupportModule
@@ -158,6 +158,8 @@ export declare enum CustomerDeviceOntPropertyKeys {
158
158
  Uptime = "Uptime",
159
159
  /** StaticIpReboot (Network Operations - CustomerDeviceOnt) */
160
160
  StaticIpReboot = "StaticIpReboot",
161
+ /** the operational state of the ONT UNI port carrying the service, as reported by the last device or service check (Network Operations - CustomerDeviceOnt) */
162
+ UniState = "UniState",
161
163
  /** ServiceState */
162
164
  ServiceState = "ServiceState"
163
165
  }
@@ -310,6 +312,12 @@ export interface CustomerDeviceOntProperties {
310
312
  * @type {TEXT}
311
313
  */
312
314
  StaticIpReboot: string;
315
+ /** the operational state of the ONT UNI port carrying the service, as reported by the last device or service check (Network Operations - CustomerDeviceOnt)
316
+ *
317
+ * @type {TEXT}
318
+ * @default
319
+ */
320
+ UniState: string;
313
321
  /** ServiceState
314
322
  *
315
323
  * @type {TEXT}
@@ -156,6 +156,8 @@ var CustomerDeviceOntPropertyKeys;
156
156
  CustomerDeviceOntPropertyKeys["Uptime"] = "Uptime";
157
157
  /** StaticIpReboot (Network Operations - CustomerDeviceOnt) */
158
158
  CustomerDeviceOntPropertyKeys["StaticIpReboot"] = "StaticIpReboot";
159
+ /** the operational state of the ONT UNI port carrying the service, as reported by the last device or service check (Network Operations - CustomerDeviceOnt) */
160
+ CustomerDeviceOntPropertyKeys["UniState"] = "UniState";
159
161
  /** ServiceState */
160
162
  CustomerDeviceOntPropertyKeys["ServiceState"] = "ServiceState";
161
163
  })(CustomerDeviceOntPropertyKeys = exports.CustomerDeviceOntPropertyKeys || (exports.CustomerDeviceOntPropertyKeys = {}));
@@ -18,6 +18,7 @@ import { UserProperties } from './User';
18
18
  import { CaseProperties } from './Case';
19
19
  import { FileProperties } from './File';
20
20
  import { WorkOrderProperties } from './WorkOrder';
21
+ import { OrderProperties } from './Order';
21
22
  /**
22
23
  * Available types for Email records
23
24
  */
@@ -737,6 +738,8 @@ export declare class Email extends OdinRecord<EmailProperties> {
737
738
  File: OdinLink<LinkedOdinRecord<FileProperties>>;
738
739
  /** Linked WorkOrder records (WorkOrder__Email) */
739
740
  WorkOrder: OdinLink<LinkedOdinRecord<WorkOrderProperties>>;
741
+ /** Linked Order records (Order__Email) */
742
+ Order: OdinLink<LinkedOdinRecord<OrderProperties>>;
740
743
  }
741
744
  /**
742
745
  * RabbitMQ routing keys for Email events
@@ -50,6 +50,7 @@ import { ContactProperties } from './Contact';
50
50
  import { RecontractProperties } from './Recontract';
51
51
  import { DataIssueProperties } from './DataIssue';
52
52
  import { WorkOrderProperties } from './WorkOrder';
53
+ import { EmailProperties } from './Email';
53
54
  /**
54
55
  * Available types for Order records
55
56
  */
@@ -1324,6 +1325,8 @@ export declare class Order extends OdinRecord<OrderProperties> {
1324
1325
  DataIssue: OdinLink<LinkedOdinRecord<DataIssueProperties>>;
1325
1326
  /** Linked WorkOrder records (Order__WorkOrder) */
1326
1327
  WorkOrder: OdinLink<LinkedOdinRecord<WorkOrderProperties>>;
1328
+ /** Linked Email records (Order__Email) */
1329
+ Email: OdinLink<LinkedOdinRecord<EmailProperties>>;
1327
1330
  }
1328
1331
  /**
1329
1332
  * RabbitMQ routing keys for Order events
@@ -1441,3 +1444,7 @@ export declare const ROUTING_KEY_LINK_ORDER_CONTACT_DELETED = "OrderModule.Order
1441
1444
  export declare const ROUTING_KEY_LINK_ORDER_WORK_ORDER_CREATED = "OrderModule.Order.WorkOrder.SubDbRecordAssociationCreated";
1442
1445
  /** Event: Order__WorkOrder link deleted */
1443
1446
  export declare const ROUTING_KEY_LINK_ORDER_WORK_ORDER_DELETED = "OrderModule.Order.WorkOrder.SubDbRecordAssociationDeleted";
1447
+ /** Event: Order__Email link created */
1448
+ export declare const ROUTING_KEY_LINK_ORDER_EMAIL_CREATED = "OrderModule.Order.Email.SubDbRecordAssociationCreated";
1449
+ /** Event: Order__Email link deleted */
1450
+ export declare const ROUTING_KEY_LINK_ORDER_EMAIL_DELETED = "OrderModule.Order.Email.SubDbRecordAssociationDeleted";
@@ -13,7 +13,7 @@
13
13
  */
14
14
  Object.defineProperty(exports, "__esModule", { value: true });
15
15
  exports.ROUTING_KEY_LINK_ORDER_APPOINTMENT_DELETED = exports.ROUTING_KEY_LINK_ORDER_APPOINTMENT_CREATED = exports.ROUTING_KEY_LINK_ORDER_CUSTOMER_DEVICE_ROUTER_DELETED = exports.ROUTING_KEY_LINK_ORDER_CUSTOMER_DEVICE_ROUTER_CREATED = exports.ROUTING_KEY_LINK_ORDER_SMS_MESSAGE_DELETED = exports.ROUTING_KEY_LINK_ORDER_SMS_MESSAGE_CREATED = exports.ROUTING_KEY_LINK_ORDER_ORDER_DELETED = exports.ROUTING_KEY_LINK_ORDER_ORDER_CREATED = exports.ROUTING_KEY_LINK_ORDER_FILE_DELETED = exports.ROUTING_KEY_LINK_ORDER_FILE_CREATED = exports.ROUTING_KEY_LINK_ORDER_ORDER_ITEM_DELETED = exports.ROUTING_KEY_LINK_ORDER_ORDER_ITEM_CREATED = exports.ROUTING_KEY_LINK_ORDER_BILLING_ADJUSTMENT_DELETED = exports.ROUTING_KEY_LINK_ORDER_BILLING_ADJUSTMENT_CREATED = exports.ROUTING_KEY_LINK_ORDER_PUSH_NOTIFICATION_DELETED = exports.ROUTING_KEY_LINK_ORDER_PUSH_NOTIFICATION_CREATED = exports.ROUTING_KEY_LINK_ORDER_DISCOUNT_DELETED = exports.ROUTING_KEY_LINK_ORDER_DISCOUNT_CREATED = exports.ROUTING_KEY_LINK_ORDER_ADDRESS_DELETED = exports.ROUTING_KEY_LINK_ORDER_ADDRESS_CREATED = exports.ROUTING_KEY_LINK_ORDER_PHONE_NUMBER_DELETED = exports.ROUTING_KEY_LINK_ORDER_PHONE_NUMBER_CREATED = exports.ROUTING_KEY_LINK_ORDER_NOTE_DELETED = exports.ROUTING_KEY_LINK_ORDER_NOTE_CREATED = exports.ROUTING_KEY_ORDER_DEFAULT_DELETED = exports.ROUTING_KEY_ORDER_DEFAULT_UPDATED = exports.ROUTING_KEY_ORDER_DEFAULT_CREATED = exports.ROUTING_KEY_ORDER_DELETED = exports.ROUTING_KEY_ORDER_UPDATED = exports.ROUTING_KEY_ORDER_CREATED = exports.Order = exports.OrderPropertyKeys = exports.OrderActivationStatus = exports.OrderSupplierOrderType = exports.OrderOtsNotRequiredReason = exports.OrderBatteryPackRequired = exports.OrderMobileCoverage = exports.OrderAltContactMethod = exports.OrderProvider = exports.OrderBillingTerms = exports.OrderDeactivationReason = exports.OrderDiscountType = exports.OrderWithholdCommissionReason = exports.OrderDiscountUnit = exports.OrderTrialUnit = exports.OrderContractType = exports.OrderCurrencyCode = exports.DefaultOrderStageKeys = exports.DefaultOrderStageNames = exports.OrderEntityTypes = void 0;
16
- exports.ROUTING_KEY_LINK_ORDER_WORK_ORDER_DELETED = exports.ROUTING_KEY_LINK_ORDER_WORK_ORDER_CREATED = exports.ROUTING_KEY_LINK_ORDER_CONTACT_DELETED = exports.ROUTING_KEY_LINK_ORDER_CONTACT_CREATED = exports.ROUTING_KEY_LINK_ORDER_INVOICE_DELETED = exports.ROUTING_KEY_LINK_ORDER_INVOICE_CREATED = exports.ROUTING_KEY_LINK_ORDER_ACTIVITY_LOG_DELETED = exports.ROUTING_KEY_LINK_ORDER_ACTIVITY_LOG_CREATED = exports.ROUTING_KEY_LINK_ORDER_ACTIVITY_DELETED = exports.ROUTING_KEY_LINK_ORDER_ACTIVITY_CREATED = exports.ROUTING_KEY_LINK_ORDER_ORDER_CHECK_DELETED = exports.ROUTING_KEY_LINK_ORDER_ORDER_CHECK_CREATED = exports.ROUTING_KEY_LINK_ORDER_CUSTOMER_DEVICE_ONT_DELETED = exports.ROUTING_KEY_LINK_ORDER_CUSTOMER_DEVICE_ONT_CREATED = exports.ROUTING_KEY_LINK_ORDER_VISIT_DELETED = exports.ROUTING_KEY_LINK_ORDER_VISIT_CREATED = exports.ROUTING_KEY_LINK_ORDER_COMMISSION_DELETED = exports.ROUTING_KEY_LINK_ORDER_COMMISSION_CREATED = exports.ROUTING_KEY_LINK_ORDER_ORDER_KCI_DELETED = exports.ROUTING_KEY_LINK_ORDER_ORDER_KCI_CREATED = exports.ROUTING_KEY_LINK_ORDER_REFERRAL_DELETED = exports.ROUTING_KEY_LINK_ORDER_REFERRAL_CREATED = exports.ROUTING_KEY_LINK_ORDER_CONTRACT_BUY_OUT_DELETED = exports.ROUTING_KEY_LINK_ORDER_CONTRACT_BUY_OUT_CREATED = exports.ROUTING_KEY_LINK_ORDER_CONTACT_IDENTITY_DELETED = exports.ROUTING_KEY_LINK_ORDER_CONTACT_IDENTITY_CREATED = void 0;
16
+ exports.ROUTING_KEY_LINK_ORDER_EMAIL_DELETED = exports.ROUTING_KEY_LINK_ORDER_EMAIL_CREATED = exports.ROUTING_KEY_LINK_ORDER_WORK_ORDER_DELETED = exports.ROUTING_KEY_LINK_ORDER_WORK_ORDER_CREATED = exports.ROUTING_KEY_LINK_ORDER_CONTACT_DELETED = exports.ROUTING_KEY_LINK_ORDER_CONTACT_CREATED = exports.ROUTING_KEY_LINK_ORDER_INVOICE_DELETED = exports.ROUTING_KEY_LINK_ORDER_INVOICE_CREATED = exports.ROUTING_KEY_LINK_ORDER_ACTIVITY_LOG_DELETED = exports.ROUTING_KEY_LINK_ORDER_ACTIVITY_LOG_CREATED = exports.ROUTING_KEY_LINK_ORDER_ACTIVITY_DELETED = exports.ROUTING_KEY_LINK_ORDER_ACTIVITY_CREATED = exports.ROUTING_KEY_LINK_ORDER_ORDER_CHECK_DELETED = exports.ROUTING_KEY_LINK_ORDER_ORDER_CHECK_CREATED = exports.ROUTING_KEY_LINK_ORDER_CUSTOMER_DEVICE_ONT_DELETED = exports.ROUTING_KEY_LINK_ORDER_CUSTOMER_DEVICE_ONT_CREATED = exports.ROUTING_KEY_LINK_ORDER_VISIT_DELETED = exports.ROUTING_KEY_LINK_ORDER_VISIT_CREATED = exports.ROUTING_KEY_LINK_ORDER_COMMISSION_DELETED = exports.ROUTING_KEY_LINK_ORDER_COMMISSION_CREATED = exports.ROUTING_KEY_LINK_ORDER_ORDER_KCI_DELETED = exports.ROUTING_KEY_LINK_ORDER_ORDER_KCI_CREATED = exports.ROUTING_KEY_LINK_ORDER_REFERRAL_DELETED = exports.ROUTING_KEY_LINK_ORDER_REFERRAL_CREATED = exports.ROUTING_KEY_LINK_ORDER_CONTRACT_BUY_OUT_DELETED = exports.ROUTING_KEY_LINK_ORDER_CONTRACT_BUY_OUT_CREATED = exports.ROUTING_KEY_LINK_ORDER_CONTACT_IDENTITY_DELETED = exports.ROUTING_KEY_LINK_ORDER_CONTACT_IDENTITY_CREATED = void 0;
17
17
  const core_1 = require("@d19n/odin-types/dist/core");
18
18
  /**
19
19
  * Available types for Order records
@@ -695,3 +695,7 @@ exports.ROUTING_KEY_LINK_ORDER_CONTACT_DELETED = 'OrderModule.Order.Contact.SubD
695
695
  exports.ROUTING_KEY_LINK_ORDER_WORK_ORDER_CREATED = 'OrderModule.Order.WorkOrder.SubDbRecordAssociationCreated';
696
696
  /** Event: Order__WorkOrder link deleted */
697
697
  exports.ROUTING_KEY_LINK_ORDER_WORK_ORDER_DELETED = 'OrderModule.Order.WorkOrder.SubDbRecordAssociationDeleted';
698
+ /** Event: Order__Email link created */
699
+ exports.ROUTING_KEY_LINK_ORDER_EMAIL_CREATED = 'OrderModule.Order.Email.SubDbRecordAssociationCreated';
700
+ /** Event: Order__Email link deleted */
701
+ exports.ROUTING_KEY_LINK_ORDER_EMAIL_DELETED = 'OrderModule.Order.Email.SubDbRecordAssociationDeleted';
@@ -23,6 +23,7 @@ import { RecordLinkManager } from '@d19n/odin-sdk-generator/dist/record-link-man
23
23
  import { ContactProperties } from '../entities-v2/Contact';
24
24
  import { CreateCaseProperties } from '../actions-v2/CreateCaseFromContactDto';
25
25
  import { CreateContactProperties } from '../actions-v2/CreateContactDto';
26
+ import { CreateContactSalesAppProperties } from '../actions-v2/CreateContactSalesAppDto';
26
27
  import { UpdateAdditionalCareProperties } from '../actions-v2/UpdateAdditionalCareDto';
27
28
  import { UpdateContactProperties } from '../actions-v2/UpdateContactDto';
28
29
  import { UpdateReferralCodeProperties } from '../actions-v2/UpdateReferralCodeDto';
@@ -766,6 +767,34 @@ export declare class ContactRecord<TProps = ContactProperties> {
766
767
  journeyId?: string;
767
768
  stageKey?: string;
768
769
  }): ActionBuilder;
770
+ /**
771
+ * CreateContactSalesApp
772
+ *
773
+ * Creates a new Contact record with the specified properties.
774
+ * Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
775
+ *
776
+ * @param properties - The properties for the new record
777
+ * @param options - Optional settings
778
+ * @param options.type - Override the record type
779
+ * @param options.journeyId - Associate with a journey
780
+ * @param options.stageKey - Set initial pipeline stage
781
+ * @returns ActionBuilder - call .execute() to create or .dryRun() for payload
782
+ *
783
+ * @example
784
+ * ```typescript
785
+ * // Create with properties
786
+ * const record = odinClient.contacts.new();
787
+ * await record.createContactSalesApp({ ... }).execute();
788
+ *
789
+ * // Dry run (for debugging)
790
+ * const payload = record.createContactSalesApp({ ... }).dryRun();
791
+ * ```
792
+ */
793
+ createContactSalesApp(properties: CreateContactSalesAppProperties, options?: {
794
+ type?: string;
795
+ journeyId?: string;
796
+ stageKey?: string;
797
+ }): ActionBuilder;
769
798
  /**
770
799
  * CreateCaseFromContact
771
800
  *
@@ -1155,6 +1155,42 @@ class ContactRecord {
1155
1155
  };
1156
1156
  return new ActionBuilder(this._provider, 'CrmModule', 'Contact', payload, () => { this._pendingLinks = []; });
1157
1157
  }
1158
+ /**
1159
+ * CreateContactSalesApp
1160
+ *
1161
+ * Creates a new Contact record with the specified properties.
1162
+ * Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
1163
+ *
1164
+ * @param properties - The properties for the new record
1165
+ * @param options - Optional settings
1166
+ * @param options.type - Override the record type
1167
+ * @param options.journeyId - Associate with a journey
1168
+ * @param options.stageKey - Set initial pipeline stage
1169
+ * @returns ActionBuilder - call .execute() to create or .dryRun() for payload
1170
+ *
1171
+ * @example
1172
+ * ```typescript
1173
+ * // Create with properties
1174
+ * const record = odinClient.contacts.new();
1175
+ * await record.createContactSalesApp({ ... }).execute();
1176
+ *
1177
+ * // Dry run (for debugging)
1178
+ * const payload = record.createContactSalesApp({ ... }).dryRun();
1179
+ * ```
1180
+ */
1181
+ createContactSalesApp(properties, options) {
1182
+ var _a, _b;
1183
+ const payload = {
1184
+ entity: 'CrmModule:Contact',
1185
+ 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,
1186
+ actionName: 'CreateContactSalesApp',
1187
+ properties: properties || {},
1188
+ associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined,
1189
+ journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
1190
+ stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
1191
+ };
1192
+ return new ActionBuilder(this._provider, 'CrmModule', 'Contact', payload, () => { this._pendingLinks = []; });
1193
+ }
1158
1194
  // ============================================
1159
1195
  // UPDATE ACTIONS (require existing record)
1160
1196
  // ============================================
@@ -95,6 +95,7 @@ import { UserRecord } from './UserRecord';
95
95
  import { CaseRecord } from './CaseRecord';
96
96
  import { FileRecord } from './FileRecord';
97
97
  import { WorkOrderRecord } from './WorkOrderRecord';
98
+ import { OrderRecord } from './OrderRecord';
98
99
  /** Valid entity types for Email */
99
100
  export declare type EmailType = 'DEFAULT' | 'REFERRAL' | 'SUPPORT' | 'TRANSACTIONAL';
100
101
  /**
@@ -168,6 +169,7 @@ export declare class EmailRecord<TProps = EmailProperties> {
168
169
  private _cases?;
169
170
  private _files?;
170
171
  private _workOrders?;
172
+ private _orders?;
171
173
  /**
172
174
  * Create a record wrapper.
173
175
  * @param record - The underlying record, or null for create operations
@@ -403,6 +405,24 @@ export declare class EmailRecord<TProps = EmailProperties> {
403
405
  * ```
404
406
  */
405
407
  get workOrders(): RecordLinkManager<WorkOrderRecord, typeof EmailRecord['workOrdersLabels'][number]>;
408
+ /** Valid labels for Order associations */
409
+ static readonly ordersLabels: readonly ["Order__Email"];
410
+ /**
411
+ * Access linked Order records
412
+ * @remarks Available labels: Order__Email
413
+ * @throws Error if called on a new (unsaved) record
414
+ *
415
+ * @example
416
+ * ```typescript
417
+ * // Get all linked Order records
418
+ * const items = await record.orders.list();
419
+ * const first = await record.orders.first();
420
+ *
421
+ * // Filter by label
422
+ * const specific = await record.orders.first({ label: 'Order__Email' });
423
+ * ```
424
+ */
425
+ get orders(): RecordLinkManager<OrderRecord, typeof EmailRecord['ordersLabels'][number]>;
406
426
  /**
407
427
  * Queue a link to be created with the next action.
408
428
  * Works for both create and update actions.
@@ -39,6 +39,7 @@ const UserRecord_1 = require("./UserRecord");
39
39
  const CaseRecord_1 = require("./CaseRecord");
40
40
  const FileRecord_1 = require("./FileRecord");
41
41
  const WorkOrderRecord_1 = require("./WorkOrderRecord");
42
+ const OrderRecord_1 = require("./OrderRecord");
42
43
  /**
43
44
  * Builder for action execution with dryRun support
44
45
  *
@@ -458,6 +459,36 @@ class EmailRecord {
458
459
  }
459
460
  return this._workOrders;
460
461
  }
462
+ /**
463
+ * Access linked Order records
464
+ * @remarks Available labels: Order__Email
465
+ * @throws Error if called on a new (unsaved) record
466
+ *
467
+ * @example
468
+ * ```typescript
469
+ * // Get all linked Order records
470
+ * const items = await record.orders.list();
471
+ * const first = await record.orders.first();
472
+ *
473
+ * // Filter by label
474
+ * const specific = await record.orders.first({ label: 'Order__Email' });
475
+ * ```
476
+ */
477
+ get orders() {
478
+ var _a;
479
+ if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
480
+ throw new Error('Cannot access links on a new (unsaved) record');
481
+ if (!this._orders) {
482
+ this._orders = new record_link_manager_1.RecordLinkManager(this._provider, this._record, {
483
+ sourceEntity: 'NotificationModule:Email',
484
+ targetEntity: 'OrderModule:Order',
485
+ targetModuleName: 'OrderModule',
486
+ targetEntityName: 'Order',
487
+ labels: ['Order__Email'],
488
+ }, OrderRecord_1.OrderRecord);
489
+ }
490
+ return this._orders;
491
+ }
461
492
  // ============================================
462
493
  // LINK MANAGEMENT
463
494
  // ============================================
@@ -2858,6 +2889,8 @@ EmailRecord.casesLabels = ['Case__Email'];
2858
2889
  EmailRecord.filesLabels = ['Attachments'];
2859
2890
  /** Valid labels for WorkOrder associations */
2860
2891
  EmailRecord.workOrdersLabels = ['WorkOrder__Email'];
2892
+ /** Valid labels for Order associations */
2893
+ EmailRecord.ordersLabels = ['Order__Email'];
2861
2894
  /** Type guard to check if an object is a EmailRecord */
2862
2895
  function isEmailRecord(obj) {
2863
2896
  return obj instanceof EmailRecord;
@@ -22,6 +22,8 @@ import { IOdinProvider } from '@d19n/odin-sdk-generator/dist/odin-sdk-types';
22
22
  import { RecordLinkManager } from '@d19n/odin-sdk-generator/dist/record-link-manager';
23
23
  import { LeadProperties } from '../entities-v2/Lead';
24
24
  import { CreateLeadProperties } from '../actions-v2/CreateLeadDto';
25
+ import { CreateLeadFromAddressSalesAppProperties } from '../actions-v2/CreateLeadFromAddressSalesAppDto';
26
+ import { CreateLeadSalesAppProperties } from '../actions-v2/CreateLeadSalesAppDto';
25
27
  import { UpdateLeadProperties } from '../actions-v2/UpdateLeadDto';
26
28
  import { NoteRecord } from './NoteRecord';
27
29
  import { DiscountRecord } from './DiscountRecord';
@@ -422,6 +424,62 @@ export declare class LeadRecord<TProps = LeadProperties> {
422
424
  journeyId?: string;
423
425
  stageKey?: string;
424
426
  }): ActionBuilder;
427
+ /**
428
+ * CreateLeadFromAddressSalesApp
429
+ *
430
+ * Creates a new Lead record with the specified properties.
431
+ * Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
432
+ *
433
+ * @param properties - The properties for the new record
434
+ * @param options - Optional settings
435
+ * @param options.type - Override the record type
436
+ * @param options.journeyId - Associate with a journey
437
+ * @param options.stageKey - Set initial pipeline stage
438
+ * @returns ActionBuilder - call .execute() to create or .dryRun() for payload
439
+ *
440
+ * @example
441
+ * ```typescript
442
+ * // Create with properties
443
+ * const record = odinClient.leads.new();
444
+ * await record.createLeadFromAddressSalesApp({ ... }).execute();
445
+ *
446
+ * // Dry run (for debugging)
447
+ * const payload = record.createLeadFromAddressSalesApp({ ... }).dryRun();
448
+ * ```
449
+ */
450
+ createLeadFromAddressSalesApp(properties?: CreateLeadFromAddressSalesAppProperties, options?: {
451
+ type?: string;
452
+ journeyId?: string;
453
+ stageKey?: string;
454
+ }): ActionBuilder;
455
+ /**
456
+ * CreateLeadSalesApp
457
+ *
458
+ * Creates a new Lead record with the specified properties.
459
+ * Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
460
+ *
461
+ * @param properties - The properties for the new record
462
+ * @param options - Optional settings
463
+ * @param options.type - Override the record type
464
+ * @param options.journeyId - Associate with a journey
465
+ * @param options.stageKey - Set initial pipeline stage
466
+ * @returns ActionBuilder - call .execute() to create or .dryRun() for payload
467
+ *
468
+ * @example
469
+ * ```typescript
470
+ * // Create with properties
471
+ * const record = odinClient.leads.new();
472
+ * await record.createLeadSalesApp({ ... }).execute();
473
+ *
474
+ * // Dry run (for debugging)
475
+ * const payload = record.createLeadSalesApp({ ... }).dryRun();
476
+ * ```
477
+ */
478
+ createLeadSalesApp(properties: CreateLeadSalesAppProperties, options?: {
479
+ type?: string;
480
+ journeyId?: string;
481
+ stageKey?: string;
482
+ }): ActionBuilder;
425
483
  /**
426
484
  * MoveLeadToContacted
427
485
  *
@@ -619,6 +619,78 @@ class LeadRecord {
619
619
  };
620
620
  return new ActionBuilder(this._provider, 'CrmModule', 'Lead', payload, () => { this._pendingLinks = []; });
621
621
  }
622
+ /**
623
+ * CreateLeadFromAddressSalesApp
624
+ *
625
+ * Creates a new Lead record with the specified properties.
626
+ * Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
627
+ *
628
+ * @param properties - The properties for the new record
629
+ * @param options - Optional settings
630
+ * @param options.type - Override the record type
631
+ * @param options.journeyId - Associate with a journey
632
+ * @param options.stageKey - Set initial pipeline stage
633
+ * @returns ActionBuilder - call .execute() to create or .dryRun() for payload
634
+ *
635
+ * @example
636
+ * ```typescript
637
+ * // Create with properties
638
+ * const record = odinClient.leads.new();
639
+ * await record.createLeadFromAddressSalesApp({ ... }).execute();
640
+ *
641
+ * // Dry run (for debugging)
642
+ * const payload = record.createLeadFromAddressSalesApp({ ... }).dryRun();
643
+ * ```
644
+ */
645
+ createLeadFromAddressSalesApp(properties, options) {
646
+ var _a, _b;
647
+ const payload = {
648
+ entity: 'CrmModule:Lead',
649
+ 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,
650
+ actionName: 'CreateLeadFromAddressSalesApp',
651
+ properties: properties || {},
652
+ associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined,
653
+ journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
654
+ stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
655
+ };
656
+ return new ActionBuilder(this._provider, 'CrmModule', 'Lead', payload, () => { this._pendingLinks = []; });
657
+ }
658
+ /**
659
+ * CreateLeadSalesApp
660
+ *
661
+ * Creates a new Lead record with the specified properties.
662
+ * Returns an ActionBuilder - call .execute() to create or .dryRun() for debugging.
663
+ *
664
+ * @param properties - The properties for the new record
665
+ * @param options - Optional settings
666
+ * @param options.type - Override the record type
667
+ * @param options.journeyId - Associate with a journey
668
+ * @param options.stageKey - Set initial pipeline stage
669
+ * @returns ActionBuilder - call .execute() to create or .dryRun() for payload
670
+ *
671
+ * @example
672
+ * ```typescript
673
+ * // Create with properties
674
+ * const record = odinClient.leads.new();
675
+ * await record.createLeadSalesApp({ ... }).execute();
676
+ *
677
+ * // Dry run (for debugging)
678
+ * const payload = record.createLeadSalesApp({ ... }).dryRun();
679
+ * ```
680
+ */
681
+ createLeadSalesApp(properties, options) {
682
+ var _a, _b;
683
+ const payload = {
684
+ entity: 'CrmModule:Lead',
685
+ 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,
686
+ actionName: 'CreateLeadSalesApp',
687
+ properties: properties || {},
688
+ associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined,
689
+ journeyId: options === null || options === void 0 ? void 0 : options.journeyId,
690
+ stageKey: options === null || options === void 0 ? void 0 : options.stageKey,
691
+ };
692
+ return new ActionBuilder(this._provider, 'CrmModule', 'Lead', payload, () => { this._pendingLinks = []; });
693
+ }
622
694
  // ============================================
623
695
  // UPDATE ACTIONS (require existing record)
624
696
  // ============================================