@d19n/youfibre-odin-sdk 2.0.21 → 2.0.23-beta.0

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 (39) hide show
  1. package/README.md +4 -1
  2. package/dist/actions-v2/CreateAccountCreditDto.d.ts +22 -1
  3. package/dist/actions-v2/CreateInstallDto.d.ts +16 -15
  4. package/dist/actions-v2/CreateInstallDto.js +6 -4
  5. package/dist/actions-v2/CreateServiceDto.d.ts +14 -13
  6. package/dist/actions-v2/CreateServiceDto.js +3 -1
  7. package/dist/actions-v2/MoveOrderFromSupplyToActiveDto.d.ts +112 -0
  8. package/dist/actions-v2/MoveOrderFromSupplyToActiveDto.js +77 -0
  9. package/dist/actions-v2/PriceMatchDto.d.ts +12 -4
  10. package/dist/actions-v2/PriceMatchDto.js +1 -1
  11. package/dist/actions-v2/UpdateAccountCreditBalanceDto.d.ts +10 -0
  12. package/dist/api-sdk-v2/AccountCreditApi.d.ts +2 -0
  13. package/dist/api-sdk-v2/AccountCreditApi.js +6 -0
  14. package/dist/api-sdk-v2/CreditNoteApi.d.ts +2 -0
  15. package/dist/api-sdk-v2/CreditNoteApi.js +6 -0
  16. package/dist/db-sdk-v2/AccountCreditDb.d.ts +2 -0
  17. package/dist/db-sdk-v2/AccountCreditDb.js +6 -0
  18. package/dist/db-sdk-v2/CreditNoteDb.d.ts +2 -0
  19. package/dist/db-sdk-v2/CreditNoteDb.js +6 -0
  20. package/dist/entities-v2/AccountCredit.d.ts +7 -0
  21. package/dist/entities-v2/AccountCredit.js +5 -1
  22. package/dist/entities-v2/Config.d.ts +8 -8
  23. package/dist/entities-v2/Config.js +4 -4
  24. package/dist/entities-v2/CreditNote.d.ts +3 -0
  25. package/dist/entities-v2/Email.d.ts +0 -22
  26. package/dist/entities-v2/Email.js +0 -2
  27. package/dist/entities-v2/OrderItem.d.ts +44 -1
  28. package/dist/entities-v2/OrderItem.js +39 -1
  29. package/dist/entities-v2/PaymentMethodRefund.d.ts +29 -29
  30. package/dist/entities-v2/PaymentMethodRefund.js +8 -8
  31. package/dist/records-v2/AccountCreditRecord.d.ts +26 -7
  32. package/dist/records-v2/AccountCreditRecord.js +40 -15
  33. package/dist/records-v2/CreditNoteRecord.d.ts +20 -0
  34. package/dist/records-v2/CreditNoteRecord.js +33 -0
  35. package/dist/records-v2/OrderRecord.d.ts +25 -0
  36. package/dist/records-v2/OrderRecord.js +29 -0
  37. package/dist/records-v2/ServiceAppointmentConfigRecord.d.ts +1 -1
  38. package/dist/records-v2/ServiceAppointmentConfigRecord.js +2 -2
  39. package/package.json +1 -1
@@ -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_ACCOUNT_CREDIT_INVOICE_DELETED = exports.ROUTING_KEY_LINK_ACCOUNT_CREDIT_INVOICE_CREATED = exports.ROUTING_KEY_ACCOUNT_CREDIT_DEFAULT_DELETED = exports.ROUTING_KEY_ACCOUNT_CREDIT_DEFAULT_UPDATED = exports.ROUTING_KEY_ACCOUNT_CREDIT_DEFAULT_CREATED = exports.ROUTING_KEY_ACCOUNT_CREDIT_DELETED = exports.ROUTING_KEY_ACCOUNT_CREDIT_UPDATED = exports.ROUTING_KEY_ACCOUNT_CREDIT_CREATED = exports.AccountCredit = exports.AccountCreditPropertyKeys = exports.AccountCreditReason = exports.AccountCreditSource = exports.DefaultAccountCreditStageKeys = exports.DefaultAccountCreditStageNames = exports.AccountCreditEntityTypes = void 0;
15
+ exports.ROUTING_KEY_LINK_ACCOUNT_CREDIT_INVOICE_DELETED = exports.ROUTING_KEY_LINK_ACCOUNT_CREDIT_INVOICE_CREATED = exports.ROUTING_KEY_LINK_ACCOUNT_CREDIT_CREDIT_NOTE_DELETED = exports.ROUTING_KEY_LINK_ACCOUNT_CREDIT_CREDIT_NOTE_CREATED = exports.ROUTING_KEY_ACCOUNT_CREDIT_DEFAULT_DELETED = exports.ROUTING_KEY_ACCOUNT_CREDIT_DEFAULT_UPDATED = exports.ROUTING_KEY_ACCOUNT_CREDIT_DEFAULT_CREATED = exports.ROUTING_KEY_ACCOUNT_CREDIT_DELETED = exports.ROUTING_KEY_ACCOUNT_CREDIT_UPDATED = exports.ROUTING_KEY_ACCOUNT_CREDIT_CREATED = exports.AccountCredit = exports.AccountCreditPropertyKeys = exports.AccountCreditReason = exports.AccountCreditSource = exports.DefaultAccountCreditStageKeys = exports.DefaultAccountCreditStageNames = exports.AccountCreditEntityTypes = void 0;
16
16
  const core_1 = require("@d19n/odin-types/dist/core");
17
17
  /**
18
18
  * Available types for AccountCredit records
@@ -172,6 +172,10 @@ exports.ROUTING_KEY_ACCOUNT_CREDIT_DEFAULT_CREATED = 'BillingModule.AccountCredi
172
172
  exports.ROUTING_KEY_ACCOUNT_CREDIT_DEFAULT_UPDATED = 'BillingModule.AccountCredit.DEFAULT.SubDbRecordUpdated';
173
173
  /** This is the default record type deleted */
174
174
  exports.ROUTING_KEY_ACCOUNT_CREDIT_DEFAULT_DELETED = 'BillingModule.AccountCredit.DEFAULT.SubDbRecordDeleted';
175
+ /** Event: AccountCredit__CreditNote link created */
176
+ exports.ROUTING_KEY_LINK_ACCOUNT_CREDIT_CREDIT_NOTE_CREATED = 'BillingModule.AccountCredit.CreditNote.SubDbRecordAssociationCreated';
177
+ /** Event: AccountCredit__CreditNote link deleted */
178
+ exports.ROUTING_KEY_LINK_ACCOUNT_CREDIT_CREDIT_NOTE_DELETED = 'BillingModule.AccountCredit.CreditNote.SubDbRecordAssociationDeleted';
175
179
  /** Event: AccountCredit__Invoice link created */
176
180
  exports.ROUTING_KEY_LINK_ACCOUNT_CREDIT_INVOICE_CREATED = 'BillingModule.AccountCredit.Invoice.SubDbRecordAssociationCreated';
177
181
  /** Event: AccountCredit__Invoice link deleted */
@@ -23,12 +23,12 @@ export declare enum ConfigEntityTypes {
23
23
  * Use these constants instead of string literals for type safety
24
24
  */
25
25
  export declare enum ConfigPropertyKeys {
26
- /** Data field for Config records. Used by Platform team. */
27
- Test = "Test",
26
+ /** the name of the app this config relates to (Platform - Config) */
27
+ AppName = "AppName",
28
28
  /** object of { key: value } mappings (Platform - Config) */
29
29
  Mappings = "Mappings",
30
- /** the name of the app this config relates to (Platform - Config) */
31
- AppName = "AppName"
30
+ /** Data field for Config records. Used by Platform team. */
31
+ Test = "Test"
32
32
  }
33
33
  /**
34
34
  * Properties for Config records
@@ -36,21 +36,21 @@ export declare enum ConfigPropertyKeys {
36
36
  * @see SchemaModule:Config
37
37
  */
38
38
  export interface ConfigProperties {
39
- /** Data field for Config records. Used by Platform team.
39
+ /** the name of the app this config relates to (Platform - Config)
40
40
  *
41
41
  * @type {TEXT}
42
42
  */
43
- Test: string;
43
+ AppName: string;
44
44
  /** object of { key: value } mappings (Platform - Config)
45
45
  *
46
46
  * @type {JSON}
47
47
  */
48
48
  Mappings: string;
49
- /** the name of the app this config relates to (Platform - Config)
49
+ /** Data field for Config records. Used by Platform team.
50
50
  *
51
51
  * @type {TEXT}
52
52
  */
53
- AppName: string;
53
+ Test: string;
54
54
  }
55
55
  /**
56
56
  * Config entity from SchemaModule
@@ -28,12 +28,12 @@ var ConfigEntityTypes;
28
28
  */
29
29
  var ConfigPropertyKeys;
30
30
  (function (ConfigPropertyKeys) {
31
- /** Data field for Config records. Used by Platform team. */
32
- ConfigPropertyKeys["Test"] = "Test";
33
- /** object of { key: value } mappings (Platform - Config) */
34
- ConfigPropertyKeys["Mappings"] = "Mappings";
35
31
  /** the name of the app this config relates to (Platform - Config) */
36
32
  ConfigPropertyKeys["AppName"] = "AppName";
33
+ /** object of { key: value } mappings (Platform - Config) */
34
+ ConfigPropertyKeys["Mappings"] = "Mappings";
35
+ /** Data field for Config records. Used by Platform team. */
36
+ ConfigPropertyKeys["Test"] = "Test";
37
37
  })(ConfigPropertyKeys = exports.ConfigPropertyKeys || (exports.ConfigPropertyKeys = {}));
38
38
  /**
39
39
  * Config entity from SchemaModule
@@ -11,6 +11,7 @@
11
11
  * Generated from Odin schema definition
12
12
  */
13
13
  import { OdinRecord, OdinLink, LinkedOdinRecord } from '@d19n/odin-types/dist/core';
14
+ import { AccountCreditProperties } from './AccountCredit';
14
15
  import { TransactionProperties } from './Transaction';
15
16
  import { NoteProperties } from './Note';
16
17
  import { InvoiceProperties } from './Invoice';
@@ -142,6 +143,8 @@ export declare class CreditNote extends OdinRecord<CreditNoteProperties> {
142
143
  type: CreditNoteEntityTypes;
143
144
  schemaId: 'ee80aeca-5653-494a-80bf-1994b6df1cd0';
144
145
  properties: CreditNoteProperties;
146
+ /** Linked AccountCredit records (AccountCredit__CreditNote) */
147
+ AccountCredit: OdinLink<LinkedOdinRecord<AccountCreditProperties>>;
145
148
  /** Linked Transaction records (CreditNote__Transaction) */
146
149
  Transaction: OdinLink<LinkedOdinRecord<TransactionProperties>>;
147
150
  /** Linked Note records (CreditNote__Note) */
@@ -135,8 +135,6 @@ export declare enum EmailPropertyKeys {
135
135
  EmailingService = "EmailingService",
136
136
  /** The Email Sender related entity */
137
137
  EmailSenderId = "EmailSenderId",
138
- /** parsed headers */
139
- ParsedHeaders = "ParsedHeaders",
140
138
  /** WorkOrder */
141
139
  WorkOrder = "WorkOrder"
142
140
  }
@@ -276,11 +274,6 @@ export interface EmailProperties {
276
274
  * @type {LOOKUP}
277
275
  */
278
276
  EmailSenderId: string;
279
- /** parsed headers
280
- *
281
- * @type {JSON}
282
- */
283
- ParsedHeaders: string;
284
277
  /** WorkOrder
285
278
  *
286
279
  * @type {LOOKUP}
@@ -423,11 +416,6 @@ export interface ReferralEmailProperties {
423
416
  * @type {LOOKUP}
424
417
  */
425
418
  EmailSenderId: string;
426
- /** parsed headers
427
- *
428
- * @type {JSON}
429
- */
430
- ParsedHeaders: string;
431
419
  /** WorkOrder
432
420
  *
433
421
  * @type {LOOKUP}
@@ -570,11 +558,6 @@ export interface SupportEmailProperties {
570
558
  * @type {LOOKUP}
571
559
  */
572
560
  EmailSenderId: string;
573
- /** parsed headers
574
- *
575
- * @type {JSON}
576
- */
577
- ParsedHeaders: string;
578
561
  /** WorkOrder
579
562
  *
580
563
  * @type {LOOKUP}
@@ -717,11 +700,6 @@ export interface TransactionalEmailProperties {
717
700
  * @type {LOOKUP}
718
701
  */
719
702
  EmailSenderId: string;
720
- /** parsed headers
721
- *
722
- * @type {JSON}
723
- */
724
- ParsedHeaders: string;
725
703
  /** WorkOrder
726
704
  *
727
705
  * @type {LOOKUP}
@@ -136,8 +136,6 @@ var EmailPropertyKeys;
136
136
  EmailPropertyKeys["EmailingService"] = "EmailingService";
137
137
  /** The Email Sender related entity */
138
138
  EmailPropertyKeys["EmailSenderId"] = "EmailSenderId";
139
- /** parsed headers */
140
- EmailPropertyKeys["ParsedHeaders"] = "ParsedHeaders";
141
139
  /** WorkOrder */
142
140
  EmailPropertyKeys["WorkOrder"] = "WorkOrder";
143
141
  })(EmailPropertyKeys = exports.EmailPropertyKeys || (exports.EmailPropertyKeys = {}));
@@ -131,6 +131,41 @@ export declare enum OrderItemTaxable {
131
131
  NO = "NO",
132
132
  YES = "YES"
133
133
  }
134
+ /**
135
+ * Valid values for OrderItem.PriceMatchedTo
136
+ *
137
+ * PriceMatchedTo
138
+ *
139
+ * @remarks Available options:
140
+ * - `BRSK` - Brsk Reward
141
+ * - `BT`
142
+ * - `EE`
143
+ * - `GRAIN` - Grain
144
+ * - `LIGHTSPEED` - LightSpeed
145
+ * - `OTHER` - Other
146
+ * - `POP_TELECOM` - POP Telecom
147
+ * - `SKY` - Sky
148
+ * - `TALKTALK` - TalkTalk
149
+ * - `THREE` - Three
150
+ * - `UNKNOWN` - Unknown
151
+ * - `VIRGIN_MEDIA` - Virgin Media
152
+ * - `VODAFONE` - Vodafone
153
+ */
154
+ export declare enum OrderItemPriceMatchedTo {
155
+ BRSK_REWARD = "BRSK",
156
+ BT = "BT",
157
+ EE = "EE",
158
+ GRAIN = "GRAIN",
159
+ LIGHT_SPEED = "LIGHTSPEED",
160
+ OTHER = "OTHER",
161
+ POP_TELECOM = "POP_TELECOM",
162
+ SKY = "SKY",
163
+ TALK_TALK = "TALKTALK",
164
+ THREE = "THREE",
165
+ UNKNOWN = "UNKNOWN",
166
+ VIRGIN_MEDIA = "VIRGIN_MEDIA",
167
+ VODAFONE = "VODAFONE"
168
+ }
134
169
  /**
135
170
  * Property keys for OrderItem
136
171
  * Use these constants instead of string literals for type safety
@@ -209,7 +244,9 @@ export declare enum OrderItemPropertyKeys {
209
244
  /** is the item taxable (Sales - OrderItem) */
210
245
  Taxable = "Taxable",
211
246
  /** suggested retail price cost + markup (Sales - OrderItem) */
212
- UnitPrice = "UnitPrice"
247
+ UnitPrice = "UnitPrice",
248
+ /** PriceMatchedTo */
249
+ PriceMatchedTo = "PriceMatchedTo"
213
250
  }
214
251
  /**
215
252
  * Properties for OrderItem records
@@ -463,6 +500,12 @@ export interface OrderItemProperties {
463
500
  * @hidden This field is hidden in the UI
464
501
  */
465
502
  UnitPrice: string;
503
+ /** PriceMatchedTo
504
+ *
505
+ * @type {ENUM}
506
+ * @enum {OrderItemPriceMatchedTo}
507
+ */
508
+ PriceMatchedTo: OrderItemPriceMatchedTo;
466
509
  }
467
510
  /**
468
511
  * OrderItem entity from OrderModule
@@ -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_ORDER_ITEM_OFFER_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_OFFER_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_FILE_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_FILE_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_PRODUCT_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_PRODUCT_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_PHONE_PORTING_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_PHONE_PORTING_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_ACTIVITY_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_ACTIVITY_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ONT_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ONT_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_NOTE_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_NOTE_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_VOICE_CONFIGURATION_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_VOICE_CONFIGURATION_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_ORDER_ITEM_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_ORDER_ITEM_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ATA_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ATA_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ROUTER_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ROUTER_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_BNG_PROVISION_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_BNG_PROVISION_CREATED = exports.ROUTING_KEY_ORDER_ITEM_DEFAULT_DELETED = exports.ROUTING_KEY_ORDER_ITEM_DEFAULT_UPDATED = exports.ROUTING_KEY_ORDER_ITEM_DEFAULT_CREATED = exports.ROUTING_KEY_ORDER_ITEM_DELETED = exports.ROUTING_KEY_ORDER_ITEM_UPDATED = exports.ROUTING_KEY_ORDER_ITEM_CREATED = exports.OrderItem = exports.OrderItemPropertyKeys = exports.OrderItemTaxable = exports.OrderItemActivationStatus = exports.OrderItemDiscount2Type = exports.OrderItemBillingPeriodType = exports.OrderItemTaxIncluded = exports.OrderItemAmendmentType = exports.OrderItemDiscountType = exports.OrderItemEntityTypes = void 0;
15
+ exports.ROUTING_KEY_LINK_ORDER_ITEM_OFFER_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_OFFER_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_FILE_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_FILE_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_PRODUCT_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_PRODUCT_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_PHONE_PORTING_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_PHONE_PORTING_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_ACTIVITY_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_ACTIVITY_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ONT_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ONT_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_NOTE_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_NOTE_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_VOICE_CONFIGURATION_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_VOICE_CONFIGURATION_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_ORDER_ITEM_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_ORDER_ITEM_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ATA_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ATA_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ROUTER_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_CUSTOMER_DEVICE_ROUTER_CREATED = exports.ROUTING_KEY_LINK_ORDER_ITEM_BNG_PROVISION_DELETED = exports.ROUTING_KEY_LINK_ORDER_ITEM_BNG_PROVISION_CREATED = exports.ROUTING_KEY_ORDER_ITEM_DEFAULT_DELETED = exports.ROUTING_KEY_ORDER_ITEM_DEFAULT_UPDATED = exports.ROUTING_KEY_ORDER_ITEM_DEFAULT_CREATED = exports.ROUTING_KEY_ORDER_ITEM_DELETED = exports.ROUTING_KEY_ORDER_ITEM_UPDATED = exports.ROUTING_KEY_ORDER_ITEM_CREATED = exports.OrderItem = exports.OrderItemPropertyKeys = exports.OrderItemPriceMatchedTo = exports.OrderItemTaxable = exports.OrderItemActivationStatus = exports.OrderItemDiscount2Type = exports.OrderItemBillingPeriodType = exports.OrderItemTaxIncluded = exports.OrderItemAmendmentType = exports.OrderItemDiscountType = exports.OrderItemEntityTypes = void 0;
16
16
  const core_1 = require("@d19n/odin-types/dist/core");
17
17
  /**
18
18
  * Available types for OrderItem records
@@ -126,6 +126,42 @@ var OrderItemTaxable;
126
126
  OrderItemTaxable["NO"] = "NO";
127
127
  OrderItemTaxable["YES"] = "YES";
128
128
  })(OrderItemTaxable = exports.OrderItemTaxable || (exports.OrderItemTaxable = {}));
129
+ /**
130
+ * Valid values for OrderItem.PriceMatchedTo
131
+ *
132
+ * PriceMatchedTo
133
+ *
134
+ * @remarks Available options:
135
+ * - `BRSK` - Brsk Reward
136
+ * - `BT`
137
+ * - `EE`
138
+ * - `GRAIN` - Grain
139
+ * - `LIGHTSPEED` - LightSpeed
140
+ * - `OTHER` - Other
141
+ * - `POP_TELECOM` - POP Telecom
142
+ * - `SKY` - Sky
143
+ * - `TALKTALK` - TalkTalk
144
+ * - `THREE` - Three
145
+ * - `UNKNOWN` - Unknown
146
+ * - `VIRGIN_MEDIA` - Virgin Media
147
+ * - `VODAFONE` - Vodafone
148
+ */
149
+ var OrderItemPriceMatchedTo;
150
+ (function (OrderItemPriceMatchedTo) {
151
+ OrderItemPriceMatchedTo["BRSK_REWARD"] = "BRSK";
152
+ OrderItemPriceMatchedTo["BT"] = "BT";
153
+ OrderItemPriceMatchedTo["EE"] = "EE";
154
+ OrderItemPriceMatchedTo["GRAIN"] = "GRAIN";
155
+ OrderItemPriceMatchedTo["LIGHT_SPEED"] = "LIGHTSPEED";
156
+ OrderItemPriceMatchedTo["OTHER"] = "OTHER";
157
+ OrderItemPriceMatchedTo["POP_TELECOM"] = "POP_TELECOM";
158
+ OrderItemPriceMatchedTo["SKY"] = "SKY";
159
+ OrderItemPriceMatchedTo["TALK_TALK"] = "TALKTALK";
160
+ OrderItemPriceMatchedTo["THREE"] = "THREE";
161
+ OrderItemPriceMatchedTo["UNKNOWN"] = "UNKNOWN";
162
+ OrderItemPriceMatchedTo["VIRGIN_MEDIA"] = "VIRGIN_MEDIA";
163
+ OrderItemPriceMatchedTo["VODAFONE"] = "VODAFONE";
164
+ })(OrderItemPriceMatchedTo = exports.OrderItemPriceMatchedTo || (exports.OrderItemPriceMatchedTo = {}));
129
165
  /**
130
166
  * Property keys for OrderItem
131
167
  * Use these constants instead of string literals for type safety
@@ -206,6 +242,8 @@ var OrderItemPropertyKeys;
206
242
  OrderItemPropertyKeys["Taxable"] = "Taxable";
207
243
  /** suggested retail price cost + markup (Sales - OrderItem) */
208
244
  OrderItemPropertyKeys["UnitPrice"] = "UnitPrice";
245
+ /** PriceMatchedTo */
246
+ OrderItemPropertyKeys["PriceMatchedTo"] = "PriceMatchedTo";
209
247
  })(OrderItemPropertyKeys = exports.OrderItemPropertyKeys || (exports.OrderItemPropertyKeys = {}));
210
248
  /**
211
249
  * OrderItem entity from OrderModule
@@ -74,26 +74,26 @@ export declare enum PaymentMethodRefundOutcome {
74
74
  * Use these constants instead of string literals for type safety
75
75
  */
76
76
  export declare enum PaymentMethodRefundPropertyKeys {
77
- /** Monetary value field for PaymentMethodRefund. Used by Finance team for financial tracking. */
78
- Amount = "Amount",
79
- /** Authorized By (Finance - PaymentMethodRefund) */
80
- AuthorizedBy = "AuthorizedBy",
81
77
  /** Reference identifier for PaymentMethodRefund relationships. Used for data integrity. */
82
78
  ContactId = "ContactId",
79
+ /** Work Order Ref (Finance - PaymentMethodRefund) */
80
+ WorkOrderRef = "WorkOrderRef",
83
81
  /** Description (Finance - PaymentMethodRefund) */
84
82
  Description = "Description",
83
+ /** Status indicator for PaymentMethodRefund records. Tracks lifecycle state. Used by Finance team. */
84
+ Status = "Status",
85
85
  /** Reference identifier for PaymentMethodRefund relationships. Used for data integrity. */
86
86
  InvoiceRef = "InvoiceRef",
87
+ /** Monetary value field for PaymentMethodRefund. Used by Finance team for financial tracking. */
88
+ Amount = "Amount",
87
89
  /** Reference identifier for PaymentMethodRefund relationships. Used for data integrity. */
88
90
  OrderRef = "OrderRef",
89
91
  /** Data field for PaymentMethodRefund records. Used by Finance team. */
90
92
  Outcome = "Outcome",
93
+ /** Authorized By (Finance - PaymentMethodRefund) */
94
+ AuthorizedBy = "AuthorizedBy",
91
95
  /** Reward for which the payment was triggered */
92
- RewardRef = "RewardRef",
93
- /** Status indicator for PaymentMethodRefund records. Tracks lifecycle state. Used by Finance team. */
94
- Status = "Status",
95
- /** Work Order Ref (Finance - PaymentMethodRefund) */
96
- WorkOrderRef = "WorkOrderRef"
96
+ RewardRef = "RewardRef"
97
97
  }
98
98
  /**
99
99
  * Properties for PaymentMethodRefund records
@@ -101,32 +101,38 @@ export declare enum PaymentMethodRefundPropertyKeys {
101
101
  * @see BillingModule:PaymentMethodRefund
102
102
  */
103
103
  export interface PaymentMethodRefundProperties {
104
- /** Monetary value field for PaymentMethodRefund. Used by Finance team for financial tracking.
105
- *
106
- * @type {CURRENCY}
107
- */
108
- Amount: string;
109
- /** Authorized By (Finance - PaymentMethodRefund)
110
- *
111
- * @type {TEXT}
112
- */
113
- AuthorizedBy: string;
114
104
  /** Reference identifier for PaymentMethodRefund relationships. Used for data integrity.
115
105
  *
116
106
  * @type {LOOKUP}
117
107
  * @hidden This field is hidden in the UI
118
108
  */
119
109
  ContactId: string;
110
+ /** Work Order Ref (Finance - PaymentMethodRefund)
111
+ *
112
+ * @type {LOOKUP}
113
+ */
114
+ WorkOrderRef: string;
120
115
  /** Description (Finance - PaymentMethodRefund)
121
116
  *
122
117
  * @type {TEXT}
123
118
  */
124
119
  Description: string;
120
+ /** Status indicator for PaymentMethodRefund records. Tracks lifecycle state. Used by Finance team.
121
+ *
122
+ * @type {TEXT}
123
+ * @hidden This field is hidden in the UI
124
+ */
125
+ Status: string;
125
126
  /** Reference identifier for PaymentMethodRefund relationships. Used for data integrity.
126
127
  *
127
128
  * @type {LOOKUP}
128
129
  */
129
130
  InvoiceRef: string;
131
+ /** Monetary value field for PaymentMethodRefund. Used by Finance team for financial tracking.
132
+ *
133
+ * @type {CURRENCY}
134
+ */
135
+ Amount: string;
130
136
  /** Reference identifier for PaymentMethodRefund relationships. Used for data integrity.
131
137
  *
132
138
  * @type {LOOKUP}
@@ -138,22 +144,16 @@ export interface PaymentMethodRefundProperties {
138
144
  * @enum {PaymentMethodRefundOutcome}
139
145
  */
140
146
  Outcome: PaymentMethodRefundOutcome;
141
- /** Reward for which the payment was triggered
142
- *
143
- * @type {LOOKUP}
144
- */
145
- RewardRef: string;
146
- /** Status indicator for PaymentMethodRefund records. Tracks lifecycle state. Used by Finance team.
147
+ /** Authorized By (Finance - PaymentMethodRefund)
147
148
  *
148
149
  * @type {TEXT}
149
- * @hidden This field is hidden in the UI
150
150
  */
151
- Status: string;
152
- /** Work Order Ref (Finance - PaymentMethodRefund)
151
+ AuthorizedBy: string;
152
+ /** Reward for which the payment was triggered
153
153
  *
154
154
  * @type {LOOKUP}
155
155
  */
156
- WorkOrderRef: string;
156
+ RewardRef: string;
157
157
  }
158
158
  /**
159
159
  * PaymentMethodRefund entity from BillingModule
@@ -73,26 +73,26 @@ var PaymentMethodRefundOutcome;
73
73
  */
74
74
  var PaymentMethodRefundPropertyKeys;
75
75
  (function (PaymentMethodRefundPropertyKeys) {
76
- /** Monetary value field for PaymentMethodRefund. Used by Finance team for financial tracking. */
77
- PaymentMethodRefundPropertyKeys["Amount"] = "Amount";
78
- /** Authorized By (Finance - PaymentMethodRefund) */
79
- PaymentMethodRefundPropertyKeys["AuthorizedBy"] = "AuthorizedBy";
80
76
  /** Reference identifier for PaymentMethodRefund relationships. Used for data integrity. */
81
77
  PaymentMethodRefundPropertyKeys["ContactId"] = "ContactId";
78
+ /** Work Order Ref (Finance - PaymentMethodRefund) */
79
+ PaymentMethodRefundPropertyKeys["WorkOrderRef"] = "WorkOrderRef";
82
80
  /** Description (Finance - PaymentMethodRefund) */
83
81
  PaymentMethodRefundPropertyKeys["Description"] = "Description";
82
+ /** Status indicator for PaymentMethodRefund records. Tracks lifecycle state. Used by Finance team. */
83
+ PaymentMethodRefundPropertyKeys["Status"] = "Status";
84
84
  /** Reference identifier for PaymentMethodRefund relationships. Used for data integrity. */
85
85
  PaymentMethodRefundPropertyKeys["InvoiceRef"] = "InvoiceRef";
86
+ /** Monetary value field for PaymentMethodRefund. Used by Finance team for financial tracking. */
87
+ PaymentMethodRefundPropertyKeys["Amount"] = "Amount";
86
88
  /** Reference identifier for PaymentMethodRefund relationships. Used for data integrity. */
87
89
  PaymentMethodRefundPropertyKeys["OrderRef"] = "OrderRef";
88
90
  /** Data field for PaymentMethodRefund records. Used by Finance team. */
89
91
  PaymentMethodRefundPropertyKeys["Outcome"] = "Outcome";
92
+ /** Authorized By (Finance - PaymentMethodRefund) */
93
+ PaymentMethodRefundPropertyKeys["AuthorizedBy"] = "AuthorizedBy";
90
94
  /** Reward for which the payment was triggered */
91
95
  PaymentMethodRefundPropertyKeys["RewardRef"] = "RewardRef";
92
- /** Status indicator for PaymentMethodRefund records. Tracks lifecycle state. Used by Finance team. */
93
- PaymentMethodRefundPropertyKeys["Status"] = "Status";
94
- /** Work Order Ref (Finance - PaymentMethodRefund) */
95
- PaymentMethodRefundPropertyKeys["WorkOrderRef"] = "WorkOrderRef";
96
96
  })(PaymentMethodRefundPropertyKeys = exports.PaymentMethodRefundPropertyKeys || (exports.PaymentMethodRefundPropertyKeys = {}));
97
97
  /**
98
98
  * PaymentMethodRefund entity from BillingModule
@@ -25,6 +25,7 @@ import { RecordLinkManager } from '@d19n/odin-sdk-generator/dist/record-link-man
25
25
  import { AccountCreditProperties } from '../entities-v2/AccountCredit';
26
26
  import { CreateAccountCreditProperties } from '../actions-v2/CreateAccountCreditDto';
27
27
  import { UpdateAccountCreditBalanceProperties } from '../actions-v2/UpdateAccountCreditBalanceDto';
28
+ import { CreditNoteRecord } from './CreditNoteRecord';
28
29
  import { ContactRecord } from './ContactRecord';
29
30
  import { InvoiceRecord } from './InvoiceRecord';
30
31
  /** Valid entity types for AccountCredit */
@@ -92,6 +93,7 @@ export declare class AccountCreditRecord<TProps = AccountCreditProperties> {
92
93
  private _provider;
93
94
  private _pendingLinks;
94
95
  private _preGeneratedId;
96
+ private _creditNotes?;
95
97
  private _contacts?;
96
98
  private _invoices?;
97
99
  /**
@@ -135,6 +137,24 @@ export declare class AccountCreditRecord<TProps = AccountCreditProperties> {
135
137
  * @remarks This is the default record type
136
138
  */
137
139
  isDefault(): this is AccountCreditRecord<AccountCreditProperties>;
140
+ /** Valid labels for CreditNote associations */
141
+ static readonly creditNotesLabels: readonly ["AccountCredit__CreditNote"];
142
+ /**
143
+ * Access linked CreditNote records
144
+ * @remarks Available labels: AccountCredit__CreditNote
145
+ * @throws Error if called on a new (unsaved) record
146
+ *
147
+ * @example
148
+ * ```typescript
149
+ * // Get all linked CreditNote records
150
+ * const items = await record.creditNotes.list();
151
+ * const first = await record.creditNotes.first();
152
+ *
153
+ * // Filter by label
154
+ * const specific = await record.creditNotes.first({ label: 'AccountCredit__CreditNote' });
155
+ * ```
156
+ */
157
+ get creditNotes(): RecordLinkManager<CreditNoteRecord, typeof AccountCreditRecord['creditNotesLabels'][number]>;
138
158
  /** Valid labels for Contact associations */
139
159
  static readonly contactsLabels: readonly ["Contact__AccountCredit"];
140
160
  /**
@@ -223,11 +243,13 @@ export declare class AccountCreditRecord<TProps = AccountCreditProperties> {
223
243
  /**
224
244
  * UpdateAccountCreditBalance
225
245
  *
226
- * Updates this AccountCredit record.
246
+ * Updates this AccountCredit record with the specified properties.
227
247
  * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
228
248
  *
229
- * @param propertiesOrOptions - Properties to update, or options object
230
- * @param options - Optional settings (journeyId, stageKey)
249
+ * @param properties - Required properties for this action
250
+ * @param options - Optional settings
251
+ * @param options.journeyId - Associate with a journey
252
+ * @param options.stageKey - Transition to pipeline stage
231
253
  * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
232
254
  * @throws Error if called on a new (unsaved) record
233
255
  *
@@ -240,10 +262,7 @@ export declare class AccountCreditRecord<TProps = AccountCreditProperties> {
240
262
  * const payload = record.updateAccountCreditBalance({ ... }).dryRun();
241
263
  * ```
242
264
  */
243
- updateAccountCreditBalance(propertiesOrOptions?: UpdateAccountCreditBalanceProperties | {
244
- journeyId?: string;
245
- stageKey?: string;
246
- }, options?: {
265
+ updateAccountCreditBalance(properties: UpdateAccountCreditBalanceProperties, options?: {
247
266
  journeyId?: string;
248
267
  stageKey?: string;
249
268
  }): ActionBuilder;
@@ -32,6 +32,7 @@ exports.isAccountCreditRecord = exports.AccountCreditRecord = 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");
35
+ const CreditNoteRecord_1 = require("./CreditNoteRecord");
35
36
  const ContactRecord_1 = require("./ContactRecord");
36
37
  const InvoiceRecord_1 = require("./InvoiceRecord");
37
38
  /**
@@ -163,6 +164,36 @@ class AccountCreditRecord {
163
164
  * @remarks This is the default record type
164
165
  */
165
166
  isDefault() { var _a; return ((_a = this._record) === null || _a === void 0 ? void 0 : _a.type) === 'DEFAULT'; }
167
+ /**
168
+ * Access linked CreditNote records
169
+ * @remarks Available labels: AccountCredit__CreditNote
170
+ * @throws Error if called on a new (unsaved) record
171
+ *
172
+ * @example
173
+ * ```typescript
174
+ * // Get all linked CreditNote records
175
+ * const items = await record.creditNotes.list();
176
+ * const first = await record.creditNotes.first();
177
+ *
178
+ * // Filter by label
179
+ * const specific = await record.creditNotes.first({ label: 'AccountCredit__CreditNote' });
180
+ * ```
181
+ */
182
+ get creditNotes() {
183
+ var _a;
184
+ if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
185
+ throw new Error('Cannot access links on a new (unsaved) record');
186
+ if (!this._creditNotes) {
187
+ this._creditNotes = new record_link_manager_1.RecordLinkManager(this._provider, this._record, {
188
+ sourceEntity: 'BillingModule:AccountCredit',
189
+ targetEntity: 'BillingModule:CreditNote',
190
+ targetModuleName: 'BillingModule',
191
+ targetEntityName: 'CreditNote',
192
+ labels: ['AccountCredit__CreditNote'],
193
+ }, CreditNoteRecord_1.CreditNoteRecord);
194
+ }
195
+ return this._creditNotes;
196
+ }
166
197
  /**
167
198
  * Access linked Contact records
168
199
  * @remarks Available labels: Contact__AccountCredit
@@ -303,11 +334,13 @@ class AccountCreditRecord {
303
334
  /**
304
335
  * UpdateAccountCreditBalance
305
336
  *
306
- * Updates this AccountCredit record.
337
+ * Updates this AccountCredit record with the specified properties.
307
338
  * Returns an ActionBuilder - call .execute() to update or .dryRun() for debugging.
308
339
  *
309
- * @param propertiesOrOptions - Properties to update, or options object
310
- * @param options - Optional settings (journeyId, stageKey)
340
+ * @param properties - Required properties for this action
341
+ * @param options - Optional settings
342
+ * @param options.journeyId - Associate with a journey
343
+ * @param options.stageKey - Transition to pipeline stage
311
344
  * @returns ActionBuilder - call .execute() to update or .dryRun() for payload
312
345
  * @throws Error if called on a new (unsaved) record
313
346
  *
@@ -320,21 +353,11 @@ class AccountCreditRecord {
320
353
  * const payload = record.updateAccountCreditBalance({ ... }).dryRun();
321
354
  * ```
322
355
  */
323
- updateAccountCreditBalance(propertiesOrOptions, options) {
356
+ updateAccountCreditBalance(properties, options) {
324
357
  var _a;
325
358
  if (!((_a = this._record) === null || _a === void 0 ? void 0 : _a.id))
326
359
  throw new Error('updateAccountCreditBalance requires an existing record. Use accessor.get() first.');
327
- let properties = {};
328
- let opts = options;
329
- if (propertiesOrOptions) {
330
- if ('journeyId' in propertiesOrOptions || 'stageKey' in propertiesOrOptions) {
331
- opts = propertiesOrOptions;
332
- }
333
- else {
334
- properties = propertiesOrOptions;
335
- }
336
- }
337
- const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'UpdateAccountCreditBalance', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, opts);
360
+ const payload = Object.assign({ id: this._record.id, entity: this._record.entity, type: this._record.type, actionName: 'UpdateAccountCreditBalance', properties, associations: this._pendingLinks.length > 0 ? this._pendingLinks : undefined }, options);
338
361
  return new ActionBuilder(this._provider, 'BillingModule', 'AccountCredit', payload, () => { this._pendingLinks = []; });
339
362
  }
340
363
  }
@@ -342,6 +365,8 @@ exports.AccountCreditRecord = AccountCreditRecord;
342
365
  // ============================================
343
366
  // TYPED LINK ACCESSORS
344
367
  // ============================================
368
+ /** Valid labels for CreditNote associations */
369
+ AccountCreditRecord.creditNotesLabels = ['AccountCredit__CreditNote'];
345
370
  /** Valid labels for Contact associations */
346
371
  AccountCreditRecord.contactsLabels = ['Contact__AccountCredit'];
347
372
  /** Valid labels for Invoice associations */
@@ -23,6 +23,7 @@ import { RecordLinkManager } from '@d19n/odin-sdk-generator/dist/record-link-man
23
23
  import { CreditNoteProperties } from '../entities-v2/CreditNote';
24
24
  import { CreditNoteCreateProperties } from '../actions-v2/CreditNoteCreateDto';
25
25
  import { CreditNoteUpdateProperties } from '../actions-v2/CreditNoteUpdateDto';
26
+ import { AccountCreditRecord } from './AccountCreditRecord';
26
27
  import { TransactionRecord } from './TransactionRecord';
27
28
  import { NoteRecord } from './NoteRecord';
28
29
  import { InvoiceRecord } from './InvoiceRecord';
@@ -90,6 +91,7 @@ export declare class CreditNoteRecord<TProps = CreditNoteProperties> {
90
91
  private _provider;
91
92
  private _pendingLinks;
92
93
  private _preGeneratedId;
94
+ private _accountCredits?;
93
95
  private _transactions?;
94
96
  private _notes?;
95
97
  private _invoices?;
@@ -119,6 +121,24 @@ export declare class CreditNoteRecord<TProps = CreditNoteProperties> {
119
121
  get groups(): string[];
120
122
  /** Access the underlying OdinRecord (null for new records) */
121
123
  get record(): OdinRecord<TProps> | null;
124
+ /** Valid labels for AccountCredit associations */
125
+ static readonly accountCreditsLabels: readonly ["AccountCredit__CreditNote"];
126
+ /**
127
+ * Access linked AccountCredit records
128
+ * @remarks Available labels: AccountCredit__CreditNote
129
+ * @throws Error if called on a new (unsaved) record
130
+ *
131
+ * @example
132
+ * ```typescript
133
+ * // Get all linked AccountCredit records
134
+ * const items = await record.accountCredits.list();
135
+ * const first = await record.accountCredits.first();
136
+ *
137
+ * // Filter by label
138
+ * const specific = await record.accountCredits.first({ label: 'AccountCredit__CreditNote' });
139
+ * ```
140
+ */
141
+ get accountCredits(): RecordLinkManager<AccountCreditRecord, typeof CreditNoteRecord['accountCreditsLabels'][number]>;
122
142
  /** Valid labels for Transaction associations */
123
143
  static readonly transactionsLabels: readonly ["CreditNote__Transaction"];
124
144
  /**