@ripwords/myinvois-client 0.2.5 → 0.2.7

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 (180) hide show
  1. package/dist/{1X-ClnJ79HH.d.cts → 1X-DYw2tURz.d.cts} +1 -1
  2. package/dist/{2X-CV9eYhog.d.cts → 2X-CXtqiwRg.d.cts} +1 -1
  3. package/dist/{3X--VWVsC84.d.cts → 3X-Bk_fUIAk.d.cts} +1 -1
  4. package/dist/{4X-By9PzHaY.d.cts → 4X-CK9rj5qd.d.cts} +1 -1
  5. package/dist/{5X-B5M0Cv_K.d.cts → 5X-CpAvNxvd.d.cts} +1 -1
  6. package/dist/{6X-C3elgd-n.d.cts → 6X-bXWr_7xY.d.cts} +1 -1
  7. package/dist/{7X-D3idQBl9.d.cts → 7X-BJBOlWhV.d.cts} +1 -1
  8. package/dist/{8X-C6UMFvQW.d.cts → 8X-dshwiOxU.d.cts} +1 -1
  9. package/dist/{9X-CJjPJgIG.d.cts → 9X-9j2Djy4W.d.cts} +1 -1
  10. package/dist/{AX-DrEd2Ov6.d.cts → AX-CWCopjCC.d.cts} +1 -1
  11. package/dist/{BX-C5jc6myN.d.cts → BX-Cq7WdhD3.d.cts} +1 -1
  12. package/dist/{CX-oSgvmn3h.d.cts → CX-DlcVZfxx.d.cts} +1 -1
  13. package/dist/{DX-ZIG0enmK.d.cts → DX-DLdv-Nxj.d.cts} +1 -1
  14. package/dist/{EX-BpWZ5ADq.d.cts → EX-CIJv8-Lw.d.cts} +1 -1
  15. package/dist/{FX-CvYBEc51.d.cts → FX-DlDM_Zea.d.cts} +1 -1
  16. package/dist/{GX-CU8PZy0G.d.cts → GX-BFGNX6Jy.d.cts} +1 -1
  17. package/dist/{HX-DoEErDeE.d.cts → HX-D7Y9qRSm.d.cts} +1 -1
  18. package/dist/{IX-jLAUHe8i.d.cts → IX-DPTrbhgX.d.cts} +1 -1
  19. package/dist/{JX-DX8BjYQC.d.cts → JX-D8JmtNpo.d.cts} +1 -1
  20. package/dist/{KX-fZb4_vhw.d.cts → KX-B46KJZrH.d.cts} +1 -1
  21. package/dist/{LX-D_mI1bk-.d.cts → LX-CfTKy8Sx.d.cts} +1 -1
  22. package/dist/{MX-DlYZhpkT.d.cts → MX-BKJ4gNvV.d.cts} +1 -1
  23. package/dist/{NX-DELEEbad.d.cts → NX-CSdLIFqU.d.cts} +1 -1
  24. package/dist/{OX-CKPyrIFf.d.cts → OX-BwqOsulT.d.cts} +1 -1
  25. package/dist/{PX-SP6NxBtG.d.cts → PX-BTx0TXsJ.d.cts} +1 -1
  26. package/dist/{QX-QZA7E2O-.d.cts → QX-BUXR8RJL.d.cts} +1 -1
  27. package/dist/{RX-DBcgbdeE.d.cts → RX-CZ8HiH37.d.cts} +1 -1
  28. package/dist/{SX-DmiJeCMN.d.cts → SX-CLxsqiQk.d.cts} +1 -1
  29. package/dist/{TX-C1SoDobK.d.cts → TX-DKc8hLc4.d.cts} +1 -1
  30. package/dist/{UX-DFVynFhQ.d.cts → UX-bc7xDnZI.d.cts} +1 -1
  31. package/dist/{VX-DsRum5k3.d.cts → VX-CIHTFyoC.d.cts} +1 -1
  32. package/dist/{WX-VReU5R5M.d.cts → WX-BHvlq7Jx.d.cts} +1 -1
  33. package/dist/{XX-ChAviUMj.d.cts → XX-DztQxYHJ.d.cts} +1 -1
  34. package/dist/{YX-QfzeMEKx.d.cts → YX-CkxLeFb4.d.cts} +1 -1
  35. package/dist/{ZX-Ca2E726a.d.cts → ZX-DVb_buNI.d.cts} +1 -1
  36. package/dist/api/documentManagement.d.ts +39 -39
  37. package/dist/api/documentSubmission.d.ts +40 -40
  38. package/dist/api/documentSubmission.js +2 -2
  39. package/dist/api/documentTypeManagement.d.ts +39 -39
  40. package/dist/api/notificationManagement.d.ts +39 -39
  41. package/dist/api/platformLogin.d.ts +39 -39
  42. package/dist/api/taxpayerValidation.d.ts +39 -39
  43. package/dist/{document-djvnrrZo.cjs → document-BgPF4b8T.cjs} +20 -3
  44. package/dist/document-BgPF4b8T.cjs.map +1 -0
  45. package/dist/{document-BvyYSCPx.js → document-CX2DalTX.js} +19 -2
  46. package/dist/{documentSubmission-695VhFA8.js → documentSubmission-BszHhgyA.js} +1 -1
  47. package/dist/{documentSubmission-CK1zOsSV.cjs → documentSubmission-DTnOLqdW.cjs} +2 -2
  48. package/dist/documentSubmission-DTnOLqdW.cjs.map +1 -0
  49. package/dist/{documents-BuH9ULyn.d.cts → documents-BXxJLeMe.d.cts} +223 -25
  50. package/dist/{documents-Br8I8SvT.d.ts → documents-BrbgAg2U.d.ts} +222 -24
  51. package/dist/index.cjs +2 -2
  52. package/dist/index.cjs.map +1 -1
  53. package/dist/index.d.ts +41 -41
  54. package/dist/index.js +2 -2
  55. package/dist/index10.cjs +187 -16
  56. package/dist/index10.cjs.map +1 -1
  57. package/dist/index12.cjs +16 -25
  58. package/dist/index12.cjs.map +1 -1
  59. package/dist/index13.cjs +0 -24
  60. package/dist/index15.cjs +29 -0
  61. package/dist/index15.cjs.map +1 -0
  62. package/dist/index16.cjs +25 -0
  63. package/dist/index16.cjs.map +1 -0
  64. package/dist/index17.cjs +0 -5
  65. package/dist/index18.cjs +33 -5
  66. package/dist/index18.cjs.map +1 -0
  67. package/dist/index19.cjs +23 -4
  68. package/dist/{index13.cjs.map → index19.cjs.map} +1 -1
  69. package/dist/index2.cjs +4 -61
  70. package/dist/index20.cjs +0 -3
  71. package/dist/index21.cjs +0 -3
  72. package/dist/index22.cjs +0 -5
  73. package/dist/index25.cjs +1 -1
  74. package/dist/index27.cjs +1 -1
  75. package/dist/index3.cjs +5 -531
  76. package/dist/index4.cjs +4 -195
  77. package/dist/index5.cjs +3 -0
  78. package/dist/index6.cjs +2 -24
  79. package/dist/index62.cts.map +1 -1
  80. package/dist/index67.cts.map +1 -1
  81. package/dist/index7.cjs +5 -0
  82. package/dist/index70.cts.map +1 -1
  83. package/dist/index8.cjs +62 -0
  84. package/dist/{index2.cjs.map → index8.cjs.map} +1 -1
  85. package/dist/index9.cjs +526 -23
  86. package/dist/index9.cjs.map +1 -1
  87. package/dist/{payment-modes-ghFEXnUl.d.cts → payment-modes-7c1lWlIr.d.cts} +1 -1
  88. package/dist/{taxpayer-5MlboTnW.d.ts → taxpayer-B5jvXdII.d.ts} +1 -1
  89. package/dist/{taxpayer-DVjaFzJw.d.cts → taxpayer-ONpnw0na.d.cts} +2 -2
  90. package/dist/types/documents.d.ts +38 -2
  91. package/dist/types/index.d.ts +40 -40
  92. package/dist/types/payment-modes.d.ts +1 -1
  93. package/dist/types/taxpayer.d.ts +38 -2
  94. package/dist/types/unit/1X.d.ts +1 -1
  95. package/dist/types/unit/2X.d.ts +1 -1
  96. package/dist/types/unit/3X.d.ts +1 -1
  97. package/dist/types/unit/4X.d.ts +1 -1
  98. package/dist/types/unit/5X.d.ts +1 -1
  99. package/dist/types/unit/6X.d.ts +1 -1
  100. package/dist/types/unit/7X.d.ts +1 -1
  101. package/dist/types/unit/8X.d.ts +1 -1
  102. package/dist/types/unit/9X.d.ts +1 -1
  103. package/dist/types/unit/AX.d.ts +1 -1
  104. package/dist/types/unit/BX.d.ts +1 -1
  105. package/dist/types/unit/CX.d.ts +1 -1
  106. package/dist/types/unit/DX.d.ts +1 -1
  107. package/dist/types/unit/EX.d.ts +1 -1
  108. package/dist/types/unit/FX.d.ts +1 -1
  109. package/dist/types/unit/GX.d.ts +1 -1
  110. package/dist/types/unit/HX.d.ts +1 -1
  111. package/dist/types/unit/IX.d.ts +1 -1
  112. package/dist/types/unit/JX.d.ts +1 -1
  113. package/dist/types/unit/KX.d.ts +1 -1
  114. package/dist/types/unit/LX.d.ts +1 -1
  115. package/dist/types/unit/MX.d.ts +1 -1
  116. package/dist/types/unit/NX.d.ts +1 -1
  117. package/dist/types/unit/OX.d.ts +1 -1
  118. package/dist/types/unit/PX.d.ts +1 -1
  119. package/dist/types/unit/QX.d.ts +1 -1
  120. package/dist/types/unit/RX.d.ts +1 -1
  121. package/dist/types/unit/SX.d.ts +1 -1
  122. package/dist/types/unit/TX.d.ts +1 -1
  123. package/dist/types/unit/UX.d.ts +1 -1
  124. package/dist/types/unit/VX.d.ts +1 -1
  125. package/dist/types/unit/WX.d.ts +1 -1
  126. package/dist/types/unit/XX.d.ts +1 -1
  127. package/dist/types/unit/YX.d.ts +1 -1
  128. package/dist/types/unit/ZX.d.ts +1 -1
  129. package/dist/types/unit-types.d.ts +36 -36
  130. package/dist/unit-types-BXdufGWm.d.cts +56 -0
  131. package/dist/unit-types-COhKgwRx.d.ts +55 -0
  132. package/dist/utils/document.d.ts +56 -56
  133. package/dist/utils/document.js +1 -1
  134. package/dist/utils/signature-diagnostics.d.ts +39 -39
  135. package/dist/utils/signature-diagnostics.js +1 -1
  136. package/dist/utils/validation.d.ts +39 -39
  137. package/package.json +1 -1
  138. package/dist/document-djvnrrZo.cjs.map +0 -1
  139. package/dist/documentSubmission-CK1zOsSV.cjs.map +0 -1
  140. package/dist/index3.cjs.map +0 -1
  141. package/dist/index4.cjs.map +0 -1
  142. package/dist/index6.cjs.map +0 -1
  143. package/dist/unit-types-CjWNk2wS.d.cts +0 -56
  144. package/dist/unit-types-VgYXIwTT.d.ts +0 -55
  145. /package/dist/{1X-C72Wa4pk.d.ts → 1X-DItnKpyI.d.ts} +0 -0
  146. /package/dist/{2X-CH89y3Af.d.ts → 2X-BRqwtcFk.d.ts} +0 -0
  147. /package/dist/{3X-DryrwYRf.d.ts → 3X-B9ib7hmz.d.ts} +0 -0
  148. /package/dist/{4X-BPMLRoDv.d.ts → 4X-DnvqoFRK.d.ts} +0 -0
  149. /package/dist/{5X-Bv7M6KyG.d.ts → 5X-B5VgbyuP.d.ts} +0 -0
  150. /package/dist/{6X-ZeZ8OB57.d.ts → 6X-DkXfHpvM.d.ts} +0 -0
  151. /package/dist/{7X-Dvw2Z2VN.d.ts → 7X-C5JVFy1t.d.ts} +0 -0
  152. /package/dist/{8X-BkgoX8dg.d.ts → 8X-B4ugLZwg.d.ts} +0 -0
  153. /package/dist/{9X-Du0e44cq.d.ts → 9X-CJNvMnQl.d.ts} +0 -0
  154. /package/dist/{AX-BSPLpkVT.d.ts → AX-DOUxT2rI.d.ts} +0 -0
  155. /package/dist/{BX-u4yMaIkz.d.ts → BX-oblwBfTI.d.ts} +0 -0
  156. /package/dist/{CX-BKZG0pVE.d.ts → CX-BSkJgKgO.d.ts} +0 -0
  157. /package/dist/{DX-CwA9WJAf.d.ts → DX-BnaWlGEa.d.ts} +0 -0
  158. /package/dist/{EX-BRNu1Ooi.d.ts → EX-DqMLkTD6.d.ts} +0 -0
  159. /package/dist/{FX-DBxjq6xY.d.ts → FX-WMYJJiXw.d.ts} +0 -0
  160. /package/dist/{GX-B3CvWNrP.d.ts → GX-Bq5dlHcB.d.ts} +0 -0
  161. /package/dist/{HX-D7FABgTv.d.ts → HX-rnN-1gc4.d.ts} +0 -0
  162. /package/dist/{IX-D3ZknsAB.d.ts → IX-DEhTE-sl.d.ts} +0 -0
  163. /package/dist/{JX-BRaZM3Gc.d.ts → JX-DDmdLUAf.d.ts} +0 -0
  164. /package/dist/{KX-B1K0OWoi.d.ts → KX-ahQ_YdHF.d.ts} +0 -0
  165. /package/dist/{LX-CKRefinL.d.ts → LX-C7pFhvwp.d.ts} +0 -0
  166. /package/dist/{MX-DKmaeO9r.d.ts → MX-BiGP-zfs.d.ts} +0 -0
  167. /package/dist/{NX-CJL2Gn1U.d.ts → NX-D9OweSyC.d.ts} +0 -0
  168. /package/dist/{OX-Do2ap5v_.d.ts → OX-DnnpAMzr.d.ts} +0 -0
  169. /package/dist/{PX-_DOr_rm9.d.ts → PX-Zg8k4vu2.d.ts} +0 -0
  170. /package/dist/{QX-HlXLkIki.d.ts → QX-DxR99yw8.d.ts} +0 -0
  171. /package/dist/{RX-DVPGOVES.d.ts → RX-DBVE-XJ8.d.ts} +0 -0
  172. /package/dist/{SX-OGT3qwlS.d.ts → SX-BPJh5Wy9.d.ts} +0 -0
  173. /package/dist/{TX-cPDINmZ5.d.ts → TX-BWd2tM68.d.ts} +0 -0
  174. /package/dist/{UX-Be3sqvPV.d.ts → UX-B8bqUo26.d.ts} +0 -0
  175. /package/dist/{VX-CoEuBNDK.d.ts → VX-C-mcQkWG.d.ts} +0 -0
  176. /package/dist/{WX-DMvw__jH.d.ts → WX-C-7bazUi.d.ts} +0 -0
  177. /package/dist/{XX-DOA-10JW.d.ts → XX-DhTx4dT8.d.ts} +0 -0
  178. /package/dist/{YX-F34sJ7Ik.d.ts → YX-CzIG0m1_.d.ts} +0 -0
  179. /package/dist/{ZX-CDQOfsHh.d.ts → ZX-BoEUGCYa.d.ts} +0 -0
  180. /package/dist/{payment-modes-NpE3OcCV.d.ts → payment-modes-tbWpu_Qh.d.ts} +0 -0
@@ -5,6 +5,7 @@ import { EInvoiceTypeCode } from "./e-invoice-BuwtFnlI.cjs";
5
5
  import { MSICCode } from "./msic-codes-CIKdPqag.cjs";
6
6
  import { TaxTypeCode } from "./tax-types-fu5Q6dic.cjs";
7
7
  import { StateCode } from "./state-codes-u3ppueWo.cjs";
8
+ import { UnitTypeCode } from "./unit-types-BXdufGWm.cjs";
8
9
 
9
10
  //#region src/types/documents.d.ts
10
11
  type RegistrationType = 'BRN' | 'NRIC' | 'PASSPORT' | 'ARMY';
@@ -158,7 +159,7 @@ interface InvoiceLineItem {
158
159
  * Required when using fixed rate taxation.
159
160
  * @example 'C62'
160
161
  */
161
- baseUnitMeasureCode?: string;
162
+ baseUnitMeasureCode?: UnitTypeCode;
162
163
  /**
163
164
  * Tax amount. Max 18 digits, 2 decimal places.
164
165
  * For percentage tax: calculated as taxableAmount * taxRate / 100
@@ -258,6 +259,210 @@ interface InvoiceV1_1 {
258
259
  /** Total tax amounts and subtotals. */
259
260
  taxTotal: TaxTotal;
260
261
  }
262
+ interface CreditNoteV1_1 {
263
+ /** Supplier information (AccountingSupplierParty). */
264
+ supplier: Supplier;
265
+ /** Buyer information (AccountingCustomerParty). */
266
+ buyer: Buyer;
267
+
268
+ /** e-Invoice version. Fixed value '1.1'. */
269
+ eInvoiceVersion: '1.1';
270
+ /** e-Invoice type code for Credit Note. Fixed value '02'. */
271
+ eInvoiceTypeCode: EInvoiceTypeCode;
272
+ /** Document reference number used by Supplier for internal tracking purpose. Max 50 chars. */
273
+ eInvoiceCodeOrNumber: string;
274
+ /** LHDNM Unique Identifier Number of the original invoice / document that is being adjusted. 26 chars. */
275
+ originalEInvoiceReferenceNumber: string;
276
+ /** Date of issuance (YYYY-MM-DD) in UTC. Must be the current date. */
277
+ eInvoiceDate: string;
278
+ /** Time of issuance (HH:mm:ssZ) in UTC. Must be the current time. */
279
+ eInvoiceTime: string;
280
+
281
+ /** Specific currency that is used to represent the monetary value stated in the e-Invoice. */
282
+ invoiceCurrencyCode: CurrencyCode;
283
+ /** Rate at which non-Malaysian currency will be converted into Malaysian Ringgit.
284
+ * Mandatory when invoiceCurrencyCode is not 'MYR'.
285
+ */
286
+ currencyExchangeRate?: number;
287
+
288
+ /** Credit note line items. */
289
+ creditNoteLineItems: InvoiceLineItem[];
290
+
291
+ /** Overall monetary totals for the credit note. */
292
+ legalMonetaryTotal: LegalMonetaryTotal;
293
+ /** Total tax amounts and subtotals. */
294
+ taxTotal: TaxTotal;
295
+ }
296
+ interface DebitNoteV1_1 {
297
+ /** Supplier information (AccountingSupplierParty). */
298
+ supplier: Supplier;
299
+ /** Buyer information (AccountingCustomerParty). */
300
+ buyer: Buyer;
301
+
302
+ /** e-Invoice version. Fixed value '1.1'. */
303
+ eInvoiceVersion: '1.1';
304
+ /** e-Invoice type code for Debit Note. Fixed value '03'. */
305
+ eInvoiceTypeCode: EInvoiceTypeCode;
306
+ /** Document reference number used by Supplier for internal tracking purpose. Max 50 chars. */
307
+ eInvoiceCodeOrNumber: string;
308
+ /** LHDNM Unique Identifier Number of the original invoice / document that is being adjusted. Mandatory where applicable (Debit/Credit/Refund notes). */
309
+ originalEInvoiceReferenceNumber: string;
310
+ /** Date of issuance (YYYY-MM-DD) in UTC. Must be the current date. */
311
+ eInvoiceDate: string;
312
+ /** Time of issuance (HH:mm:ssZ) in UTC. Must be the current time. */
313
+ eInvoiceTime: string;
314
+
315
+ /** Specific currency that is used to represent the monetary value stated in the e-Invoice. */
316
+ invoiceCurrencyCode: CurrencyCode;
317
+ /** Rate at which non-Malaysian currency will be converted into Malaysian Ringgit.
318
+ * Mandatory when invoiceCurrencyCode is not 'MYR'.
319
+ */
320
+ currencyExchangeRate?: number;
321
+
322
+ /** Debit note line items (InvoiceLine section with required fields). */
323
+ debitNoteLineItems: InvoiceLineItem[];
324
+
325
+ /** Overall monetary totals for the debit note. */
326
+ legalMonetaryTotal: LegalMonetaryTotal;
327
+ /** Total tax amounts and subtotals. */
328
+ taxTotal: TaxTotal;
329
+ }
330
+ interface RefundNoteV1_1 {
331
+ /** Supplier information (AccountingSupplierParty). */
332
+ supplier: Supplier;
333
+ /** Buyer information (AccountingCustomerParty). */
334
+ buyer: Buyer;
335
+
336
+ /** e-Invoice version. Fixed value '1.1'. */
337
+ eInvoiceVersion: '1.1';
338
+ /** e-Invoice type code for Refund Note. Fixed value '04'. */
339
+ eInvoiceTypeCode: EInvoiceTypeCode;
340
+ /** Document reference number used by Supplier for internal tracking purpose. Max 50 chars. */
341
+ eInvoiceCodeOrNumber: string;
342
+ /** LHDNM Unique Identifier Number of the original invoice / document that is being adjusted. Mandatory where applicable (Debit/Credit/Refund notes). */
343
+ originalEInvoiceReferenceNumber: string;
344
+ /** Date of issuance (YYYY-MM-DD) in UTC. Must be the current date. */
345
+ eInvoiceDate: string;
346
+ /** Time of issuance (HH:mm:ssZ) in UTC. Must be the current time. */
347
+ eInvoiceTime: string;
348
+
349
+ /** Specific currency that is used to represent the monetary value stated in the e-Invoice. */
350
+ invoiceCurrencyCode: CurrencyCode;
351
+ /** Rate at which non-Malaysian currency will be converted into Malaysian Ringgit.
352
+ * Mandatory when invoiceCurrencyCode is not 'MYR'.
353
+ */
354
+ currencyExchangeRate?: number;
355
+
356
+ /** Refund note line items. */
357
+ refundNoteLineItems: InvoiceLineItem[];
358
+
359
+ /** Overall monetary totals for the refund note. */
360
+ legalMonetaryTotal: LegalMonetaryTotal;
361
+ /** Total tax amounts and subtotals. */
362
+ taxTotal: TaxTotal;
363
+ }
364
+ interface SelfBilledInvoiceV1_1 {
365
+ /** Supplier information (AccountingSupplierParty). */
366
+ supplier: Supplier;
367
+ /** Buyer information (AccountingCustomerParty). */
368
+ buyer: Buyer;
369
+
370
+ /** e-Invoice version. Fixed value '1.1'. */
371
+ eInvoiceVersion: '1.1';
372
+ /** e-Invoice type code for Self-Billed Invoice. Fixed value '11'. */
373
+ eInvoiceTypeCode: EInvoiceTypeCode;
374
+ /** Document reference number used by Buyer (acting as issuer) for internal tracking purpose. Max 50 chars. */
375
+ eInvoiceCodeOrNumber: string;
376
+ /** Date of issuance (YYYY-MM-DD) in UTC. Must be the current date. */
377
+ eInvoiceDate: string;
378
+ /** Time of issuance (HH:mm:ssZ) in UTC. Must be the current time. */
379
+ eInvoiceTime: string;
380
+
381
+ /** Specific currency used to represent the monetary values stated in the e-Invoice. */
382
+ invoiceCurrencyCode: CurrencyCode;
383
+ /** Currency exchange rate to MYR when invoiceCurrencyCode is not 'MYR'. Mandatory where applicable. */
384
+ currencyExchangeRate?: number;
385
+
386
+ /** Frequency of billing (e.g., Daily, Monthly). Optional. */
387
+ frequencyOfBilling?: string;
388
+ /** Billing period start date (YYYY-MM-DD). Optional but allowed; include to match spec for optional elements. */
389
+ billingPeriodStartDate?: string;
390
+ /** Billing period end date (YYYY-MM-DD). Optional. */
391
+ billingPeriodEndDate?: string;
392
+
393
+ /** Invoice line items. */
394
+ invoiceLineItems: InvoiceLineItem[];
395
+
396
+ /** Overall monetary totals for the invoice. */
397
+ legalMonetaryTotal: LegalMonetaryTotal;
398
+ /** Total tax amounts and subtotals. */
399
+ taxTotal: TaxTotal;
400
+ }
401
+ interface SelfBilledCreditNoteV1_1 {
402
+ /** Supplier information. */
403
+ supplier: Supplier;
404
+ /** Buyer information. */
405
+ buyer: Buyer;
406
+
407
+ /** Fixed e-Invoice version '1.1'. */
408
+ eInvoiceVersion: '1.1';
409
+ /** e-Invoice type code for Self-Billed Credit Note (code '12'). */
410
+ eInvoiceTypeCode: EInvoiceTypeCode;
411
+ /** Internal document reference number issued by Buyer. Max 50 chars. */
412
+ eInvoiceCodeOrNumber: string;
413
+ /** LHDNM unique identifier of the original self-billed invoice being adjusted. */
414
+ originalEInvoiceReferenceNumber: string;
415
+ /** Date of issuance (YYYY-MM-DD, UTC). */
416
+ eInvoiceDate: string;
417
+ /** Time of issuance (HH:mm:ssZ, UTC). */
418
+ eInvoiceTime: string;
419
+
420
+ /** Currency code for monetary values. */
421
+ invoiceCurrencyCode: CurrencyCode;
422
+ /** Exchange rate to MYR – required when invoiceCurrencyCode ≠ 'MYR'. */
423
+ currencyExchangeRate?: number;
424
+
425
+ /** Line items for the credit note. */
426
+ selfBilledCreditNoteLineItems: InvoiceLineItem[];
427
+
428
+ /** Monetary totals. */
429
+ legalMonetaryTotal: LegalMonetaryTotal;
430
+ /** Tax totals. */
431
+ taxTotal: TaxTotal;
432
+ }
433
+ interface SelfBilledRefundNoteV1_1 {
434
+ /** Supplier information issued in the self-billed refund note. */
435
+ supplier: Supplier;
436
+ /** Buyer information (issuer of the self-billed document). */
437
+ buyer: Buyer;
438
+
439
+ /** Fixed e-Invoice version. */
440
+ eInvoiceVersion: '1.1';
441
+ /** e-Invoice type code for Self-Billed Refund Note (code '14'). */
442
+ eInvoiceTypeCode: EInvoiceTypeCode;
443
+ /** Internal tracking reference number. Max 50 chars. */
444
+ eInvoiceCodeOrNumber: string;
445
+ /** Original self-billed invoice UUID being adjusted (mandatory for refund/credit/debit). */
446
+ originalEInvoiceReferenceNumber: string;
447
+ /** Issue date (YYYY-MM-DD, UTC). */
448
+ eInvoiceDate: string;
449
+ /** Issue time (HH:mm:ssZ, UTC). */
450
+ eInvoiceTime: string;
451
+
452
+ /** Document currency code. */
453
+ invoiceCurrencyCode: CurrencyCode;
454
+ /** Exchange rate to MYR when currency ≠ 'MYR'. */
455
+ currencyExchangeRate?: number;
456
+
457
+ /** Line items contained in the refund note. */
458
+ selfBilledRefundNoteLineItems: InvoiceLineItem[];
459
+
460
+ /** Monetary totals for the document. */
461
+ legalMonetaryTotal: LegalMonetaryTotal;
462
+ /** Tax totals for the document. */
463
+ taxTotal: TaxTotal;
464
+ }
465
+ type AllDocumentsV1_1 = InvoiceV1_1 | CreditNoteV1_1 | DebitNoteV1_1 | RefundNoteV1_1 | SelfBilledInvoiceV1_1 | SelfBilledCreditNoteV1_1 | SelfBilledRefundNoteV1_1;
261
466
  type SubmissionStatus = 'InProgress' | 'Valid' | 'PartiallyValid' | 'Invalid';
262
467
  type DocumentStatus = 'Valid' | 'Invalid' | 'Cancelled' | 'Submitted';
263
468
  type StandardError = {
@@ -664,28 +869,7 @@ interface InvoiceSubmission {
664
869
  SignatureValue: {
665
870
  _: string;
666
871
  }[];
667
- SignedInfo: {
668
- CanonicalizationMethod: {
669
- _: string;
670
- Algorithm: string;
671
- }[];
672
- SignatureMethod: {
673
- _: string;
674
- Algorithm: string;
675
- }[];
676
- Reference: {
677
- Id: string;
678
- Type: string;
679
- URI: string;
680
- DigestMethod: {
681
- _: string;
682
- Algorithm: string;
683
- }[];
684
- DigestValue: {
685
- _: string;
686
- }[];
687
- }[];
688
- }[];
872
+ SignedInfo: SignedInfoObject[];
689
873
  }[];
690
874
  }[];
691
875
  }[];
@@ -702,6 +886,20 @@ interface InvoiceSubmission {
702
886
  _: string;
703
887
  }[];
704
888
  }[];
889
+
890
+ /** Billing reference linking to original invoice (used for credit/debit/refund). Optional. */
891
+ BillingReference?: {
892
+ InvoiceDocumentReference: {
893
+ /** LHDNM Unique Identifier Number */
894
+ UUID: {
895
+ _: string;
896
+ }[];
897
+ /** Internal ID (e-Invoice Code/Number) */
898
+ ID: {
899
+ _: string;
900
+ }[];
901
+ }[];
902
+ }[];
705
903
  }
706
904
 
707
905
  /** Represents the complete UBL document structure with namespace declarations */
@@ -925,5 +1123,5 @@ interface DocumentTypeVersionResponse {
925
1123
  activeTo: string;
926
1124
  }
927
1125
  //#endregion
928
- export { Address, Buyer, CompleteInvoice, DocumentStatus, DocumentSummary, DocumentTypeResponse, DocumentTypeVersion, DocumentTypeVersionResponse, DocumentTypesResponse, DocumentValidationResult, DocumentValidationStepResult, FinalDocumentData, GetSubmissionResponse, InvoiceLineItem, InvoiceSubmission, InvoiceV1_1, LegalMonetaryTotal, RegistrationType, ResponseDocument, SignedInfoObject, SignedInvoiceSubmission, SignedPropertiesData, SignedPropertiesObject, SigningCredentials, StandardError, SubmissionResponse, SubmissionStatus, Supplier, TaxCategory, TaxSubtotal, TaxTotal, UBLDocument, WorkflowParameter };
929
- //# sourceMappingURL=documents-BuH9ULyn.d.cts.map
1126
+ export { Address, AllDocumentsV1_1, Buyer, CompleteInvoice, CreditNoteV1_1, DebitNoteV1_1, DocumentStatus, DocumentSummary, DocumentTypeResponse, DocumentTypeVersion, DocumentTypeVersionResponse, DocumentTypesResponse, DocumentValidationResult, DocumentValidationStepResult, FinalDocumentData, GetSubmissionResponse, InvoiceLineItem, InvoiceSubmission, InvoiceV1_1, LegalMonetaryTotal, RefundNoteV1_1, RegistrationType, ResponseDocument, SelfBilledCreditNoteV1_1, SelfBilledInvoiceV1_1, SelfBilledRefundNoteV1_1, SignedInfoObject, SignedInvoiceSubmission, SignedPropertiesData, SignedPropertiesObject, SigningCredentials, StandardError, SubmissionResponse, SubmissionStatus, Supplier, TaxCategory, TaxSubtotal, TaxTotal, UBLDocument, WorkflowParameter };
1127
+ //# sourceMappingURL=documents-BXxJLeMe.d.cts.map
@@ -5,6 +5,7 @@ import { EInvoiceTypeCode } from "./e-invoice-BxNC6V_j.js";
5
5
  import { MSICCode } from "./msic-codes-CiPeemFK.js";
6
6
  import { TaxTypeCode } from "./tax-types-BskcyNBv.js";
7
7
  import { StateCode } from "./state-codes-BaGjZcA8.js";
8
+ import { UnitTypeCode } from "./unit-types-COhKgwRx.js";
8
9
 
9
10
  //#region src/types/documents.d.ts
10
11
  type RegistrationType = 'BRN' | 'NRIC' | 'PASSPORT' | 'ARMY';
@@ -158,7 +159,7 @@ interface InvoiceLineItem {
158
159
  * Required when using fixed rate taxation.
159
160
  * @example 'C62'
160
161
  */
161
- baseUnitMeasureCode?: string;
162
+ baseUnitMeasureCode?: UnitTypeCode;
162
163
  /**
163
164
  * Tax amount. Max 18 digits, 2 decimal places.
164
165
  * For percentage tax: calculated as taxableAmount * taxRate / 100
@@ -258,6 +259,210 @@ interface InvoiceV1_1 {
258
259
  /** Total tax amounts and subtotals. */
259
260
  taxTotal: TaxTotal;
260
261
  }
262
+ interface CreditNoteV1_1 {
263
+ /** Supplier information (AccountingSupplierParty). */
264
+ supplier: Supplier;
265
+ /** Buyer information (AccountingCustomerParty). */
266
+ buyer: Buyer;
267
+
268
+ /** e-Invoice version. Fixed value '1.1'. */
269
+ eInvoiceVersion: '1.1';
270
+ /** e-Invoice type code for Credit Note. Fixed value '02'. */
271
+ eInvoiceTypeCode: EInvoiceTypeCode;
272
+ /** Document reference number used by Supplier for internal tracking purpose. Max 50 chars. */
273
+ eInvoiceCodeOrNumber: string;
274
+ /** LHDNM Unique Identifier Number of the original invoice / document that is being adjusted. 26 chars. */
275
+ originalEInvoiceReferenceNumber: string;
276
+ /** Date of issuance (YYYY-MM-DD) in UTC. Must be the current date. */
277
+ eInvoiceDate: string;
278
+ /** Time of issuance (HH:mm:ssZ) in UTC. Must be the current time. */
279
+ eInvoiceTime: string;
280
+
281
+ /** Specific currency that is used to represent the monetary value stated in the e-Invoice. */
282
+ invoiceCurrencyCode: CurrencyCode;
283
+ /** Rate at which non-Malaysian currency will be converted into Malaysian Ringgit.
284
+ * Mandatory when invoiceCurrencyCode is not 'MYR'.
285
+ */
286
+ currencyExchangeRate?: number;
287
+
288
+ /** Credit note line items. */
289
+ creditNoteLineItems: InvoiceLineItem[];
290
+
291
+ /** Overall monetary totals for the credit note. */
292
+ legalMonetaryTotal: LegalMonetaryTotal;
293
+ /** Total tax amounts and subtotals. */
294
+ taxTotal: TaxTotal;
295
+ }
296
+ interface DebitNoteV1_1 {
297
+ /** Supplier information (AccountingSupplierParty). */
298
+ supplier: Supplier;
299
+ /** Buyer information (AccountingCustomerParty). */
300
+ buyer: Buyer;
301
+
302
+ /** e-Invoice version. Fixed value '1.1'. */
303
+ eInvoiceVersion: '1.1';
304
+ /** e-Invoice type code for Debit Note. Fixed value '03'. */
305
+ eInvoiceTypeCode: EInvoiceTypeCode;
306
+ /** Document reference number used by Supplier for internal tracking purpose. Max 50 chars. */
307
+ eInvoiceCodeOrNumber: string;
308
+ /** LHDNM Unique Identifier Number of the original invoice / document that is being adjusted. Mandatory where applicable (Debit/Credit/Refund notes). */
309
+ originalEInvoiceReferenceNumber: string;
310
+ /** Date of issuance (YYYY-MM-DD) in UTC. Must be the current date. */
311
+ eInvoiceDate: string;
312
+ /** Time of issuance (HH:mm:ssZ) in UTC. Must be the current time. */
313
+ eInvoiceTime: string;
314
+
315
+ /** Specific currency that is used to represent the monetary value stated in the e-Invoice. */
316
+ invoiceCurrencyCode: CurrencyCode;
317
+ /** Rate at which non-Malaysian currency will be converted into Malaysian Ringgit.
318
+ * Mandatory when invoiceCurrencyCode is not 'MYR'.
319
+ */
320
+ currencyExchangeRate?: number;
321
+
322
+ /** Debit note line items (InvoiceLine section with required fields). */
323
+ debitNoteLineItems: InvoiceLineItem[];
324
+
325
+ /** Overall monetary totals for the debit note. */
326
+ legalMonetaryTotal: LegalMonetaryTotal;
327
+ /** Total tax amounts and subtotals. */
328
+ taxTotal: TaxTotal;
329
+ }
330
+ interface RefundNoteV1_1 {
331
+ /** Supplier information (AccountingSupplierParty). */
332
+ supplier: Supplier;
333
+ /** Buyer information (AccountingCustomerParty). */
334
+ buyer: Buyer;
335
+
336
+ /** e-Invoice version. Fixed value '1.1'. */
337
+ eInvoiceVersion: '1.1';
338
+ /** e-Invoice type code for Refund Note. Fixed value '04'. */
339
+ eInvoiceTypeCode: EInvoiceTypeCode;
340
+ /** Document reference number used by Supplier for internal tracking purpose. Max 50 chars. */
341
+ eInvoiceCodeOrNumber: string;
342
+ /** LHDNM Unique Identifier Number of the original invoice / document that is being adjusted. Mandatory where applicable (Debit/Credit/Refund notes). */
343
+ originalEInvoiceReferenceNumber: string;
344
+ /** Date of issuance (YYYY-MM-DD) in UTC. Must be the current date. */
345
+ eInvoiceDate: string;
346
+ /** Time of issuance (HH:mm:ssZ) in UTC. Must be the current time. */
347
+ eInvoiceTime: string;
348
+
349
+ /** Specific currency that is used to represent the monetary value stated in the e-Invoice. */
350
+ invoiceCurrencyCode: CurrencyCode;
351
+ /** Rate at which non-Malaysian currency will be converted into Malaysian Ringgit.
352
+ * Mandatory when invoiceCurrencyCode is not 'MYR'.
353
+ */
354
+ currencyExchangeRate?: number;
355
+
356
+ /** Refund note line items. */
357
+ refundNoteLineItems: InvoiceLineItem[];
358
+
359
+ /** Overall monetary totals for the refund note. */
360
+ legalMonetaryTotal: LegalMonetaryTotal;
361
+ /** Total tax amounts and subtotals. */
362
+ taxTotal: TaxTotal;
363
+ }
364
+ interface SelfBilledInvoiceV1_1 {
365
+ /** Supplier information (AccountingSupplierParty). */
366
+ supplier: Supplier;
367
+ /** Buyer information (AccountingCustomerParty). */
368
+ buyer: Buyer;
369
+
370
+ /** e-Invoice version. Fixed value '1.1'. */
371
+ eInvoiceVersion: '1.1';
372
+ /** e-Invoice type code for Self-Billed Invoice. Fixed value '11'. */
373
+ eInvoiceTypeCode: EInvoiceTypeCode;
374
+ /** Document reference number used by Buyer (acting as issuer) for internal tracking purpose. Max 50 chars. */
375
+ eInvoiceCodeOrNumber: string;
376
+ /** Date of issuance (YYYY-MM-DD) in UTC. Must be the current date. */
377
+ eInvoiceDate: string;
378
+ /** Time of issuance (HH:mm:ssZ) in UTC. Must be the current time. */
379
+ eInvoiceTime: string;
380
+
381
+ /** Specific currency used to represent the monetary values stated in the e-Invoice. */
382
+ invoiceCurrencyCode: CurrencyCode;
383
+ /** Currency exchange rate to MYR when invoiceCurrencyCode is not 'MYR'. Mandatory where applicable. */
384
+ currencyExchangeRate?: number;
385
+
386
+ /** Frequency of billing (e.g., Daily, Monthly). Optional. */
387
+ frequencyOfBilling?: string;
388
+ /** Billing period start date (YYYY-MM-DD). Optional but allowed; include to match spec for optional elements. */
389
+ billingPeriodStartDate?: string;
390
+ /** Billing period end date (YYYY-MM-DD). Optional. */
391
+ billingPeriodEndDate?: string;
392
+
393
+ /** Invoice line items. */
394
+ invoiceLineItems: InvoiceLineItem[];
395
+
396
+ /** Overall monetary totals for the invoice. */
397
+ legalMonetaryTotal: LegalMonetaryTotal;
398
+ /** Total tax amounts and subtotals. */
399
+ taxTotal: TaxTotal;
400
+ }
401
+ interface SelfBilledCreditNoteV1_1 {
402
+ /** Supplier information. */
403
+ supplier: Supplier;
404
+ /** Buyer information. */
405
+ buyer: Buyer;
406
+
407
+ /** Fixed e-Invoice version '1.1'. */
408
+ eInvoiceVersion: '1.1';
409
+ /** e-Invoice type code for Self-Billed Credit Note (code '12'). */
410
+ eInvoiceTypeCode: EInvoiceTypeCode;
411
+ /** Internal document reference number issued by Buyer. Max 50 chars. */
412
+ eInvoiceCodeOrNumber: string;
413
+ /** LHDNM unique identifier of the original self-billed invoice being adjusted. */
414
+ originalEInvoiceReferenceNumber: string;
415
+ /** Date of issuance (YYYY-MM-DD, UTC). */
416
+ eInvoiceDate: string;
417
+ /** Time of issuance (HH:mm:ssZ, UTC). */
418
+ eInvoiceTime: string;
419
+
420
+ /** Currency code for monetary values. */
421
+ invoiceCurrencyCode: CurrencyCode;
422
+ /** Exchange rate to MYR – required when invoiceCurrencyCode ≠ 'MYR'. */
423
+ currencyExchangeRate?: number;
424
+
425
+ /** Line items for the credit note. */
426
+ selfBilledCreditNoteLineItems: InvoiceLineItem[];
427
+
428
+ /** Monetary totals. */
429
+ legalMonetaryTotal: LegalMonetaryTotal;
430
+ /** Tax totals. */
431
+ taxTotal: TaxTotal;
432
+ }
433
+ interface SelfBilledRefundNoteV1_1 {
434
+ /** Supplier information issued in the self-billed refund note. */
435
+ supplier: Supplier;
436
+ /** Buyer information (issuer of the self-billed document). */
437
+ buyer: Buyer;
438
+
439
+ /** Fixed e-Invoice version. */
440
+ eInvoiceVersion: '1.1';
441
+ /** e-Invoice type code for Self-Billed Refund Note (code '14'). */
442
+ eInvoiceTypeCode: EInvoiceTypeCode;
443
+ /** Internal tracking reference number. Max 50 chars. */
444
+ eInvoiceCodeOrNumber: string;
445
+ /** Original self-billed invoice UUID being adjusted (mandatory for refund/credit/debit). */
446
+ originalEInvoiceReferenceNumber: string;
447
+ /** Issue date (YYYY-MM-DD, UTC). */
448
+ eInvoiceDate: string;
449
+ /** Issue time (HH:mm:ssZ, UTC). */
450
+ eInvoiceTime: string;
451
+
452
+ /** Document currency code. */
453
+ invoiceCurrencyCode: CurrencyCode;
454
+ /** Exchange rate to MYR when currency ≠ 'MYR'. */
455
+ currencyExchangeRate?: number;
456
+
457
+ /** Line items contained in the refund note. */
458
+ selfBilledRefundNoteLineItems: InvoiceLineItem[];
459
+
460
+ /** Monetary totals for the document. */
461
+ legalMonetaryTotal: LegalMonetaryTotal;
462
+ /** Tax totals for the document. */
463
+ taxTotal: TaxTotal;
464
+ }
465
+ type AllDocumentsV1_1 = InvoiceV1_1 | CreditNoteV1_1 | DebitNoteV1_1 | RefundNoteV1_1 | SelfBilledInvoiceV1_1 | SelfBilledCreditNoteV1_1 | SelfBilledRefundNoteV1_1;
261
466
  type SubmissionStatus = 'InProgress' | 'Valid' | 'PartiallyValid' | 'Invalid';
262
467
  type DocumentStatus = 'Valid' | 'Invalid' | 'Cancelled' | 'Submitted';
263
468
  type StandardError = {
@@ -664,28 +869,7 @@ interface InvoiceSubmission {
664
869
  SignatureValue: {
665
870
  _: string;
666
871
  }[];
667
- SignedInfo: {
668
- CanonicalizationMethod: {
669
- _: string;
670
- Algorithm: string;
671
- }[];
672
- SignatureMethod: {
673
- _: string;
674
- Algorithm: string;
675
- }[];
676
- Reference: {
677
- Id: string;
678
- Type: string;
679
- URI: string;
680
- DigestMethod: {
681
- _: string;
682
- Algorithm: string;
683
- }[];
684
- DigestValue: {
685
- _: string;
686
- }[];
687
- }[];
688
- }[];
872
+ SignedInfo: SignedInfoObject[];
689
873
  }[];
690
874
  }[];
691
875
  }[];
@@ -702,6 +886,20 @@ interface InvoiceSubmission {
702
886
  _: string;
703
887
  }[];
704
888
  }[];
889
+
890
+ /** Billing reference linking to original invoice (used for credit/debit/refund). Optional. */
891
+ BillingReference?: {
892
+ InvoiceDocumentReference: {
893
+ /** LHDNM Unique Identifier Number */
894
+ UUID: {
895
+ _: string;
896
+ }[];
897
+ /** Internal ID (e-Invoice Code/Number) */
898
+ ID: {
899
+ _: string;
900
+ }[];
901
+ }[];
902
+ }[];
705
903
  }
706
904
 
707
905
  /** Represents the complete UBL document structure with namespace declarations */
@@ -925,4 +1123,4 @@ interface DocumentTypeVersionResponse {
925
1123
  activeTo: string;
926
1124
  }
927
1125
  //#endregion
928
- export { Address, Buyer, CompleteInvoice, DocumentStatus, DocumentSummary, DocumentTypeResponse, DocumentTypeVersion, DocumentTypeVersionResponse, DocumentTypesResponse, DocumentValidationResult, DocumentValidationStepResult, FinalDocumentData, GetSubmissionResponse, InvoiceLineItem, InvoiceSubmission, InvoiceV1_1, LegalMonetaryTotal, RegistrationType, ResponseDocument, SignedInfoObject, SignedInvoiceSubmission, SignedPropertiesData, SignedPropertiesObject, SigningCredentials, StandardError, SubmissionResponse, SubmissionStatus, Supplier, TaxCategory, TaxSubtotal, TaxTotal, UBLDocument, WorkflowParameter };
1126
+ export { Address, AllDocumentsV1_1, Buyer, CompleteInvoice, CreditNoteV1_1, DebitNoteV1_1, DocumentStatus, DocumentSummary, DocumentTypeResponse, DocumentTypeVersion, DocumentTypeVersionResponse, DocumentTypesResponse, DocumentValidationResult, DocumentValidationStepResult, FinalDocumentData, GetSubmissionResponse, InvoiceLineItem, InvoiceSubmission, InvoiceV1_1, LegalMonetaryTotal, RefundNoteV1_1, RegistrationType, ResponseDocument, SelfBilledCreditNoteV1_1, SelfBilledInvoiceV1_1, SelfBilledRefundNoteV1_1, SignedInfoObject, SignedInvoiceSubmission, SignedPropertiesData, SignedPropertiesObject, SigningCredentials, StandardError, SubmissionResponse, SubmissionStatus, Supplier, TaxCategory, TaxSubtotal, TaxTotal, UBLDocument, WorkflowParameter };
package/dist/index.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  const require_documentManagement = require('./documentManagement-DQ7JEcBq.cjs');
2
- require('./document-djvnrrZo.cjs');
3
- const require_documentSubmission = require('./documentSubmission-CK1zOsSV.cjs');
2
+ require('./document-BgPF4b8T.cjs');
3
+ const require_documentSubmission = require('./documentSubmission-DTnOLqdW.cjs');
4
4
  const require_documentTypeManagement = require('./documentTypeManagement-DXRLfTsW.cjs');
5
5
  const require_notificationManagement = require('./notificationManagement-C_qrFwWL.cjs');
6
6
  const require_platformLogin = require('./platformLogin-CPiPiVUh.cjs');