@getpeppr/cli 0.12.0 → 0.12.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -1
- package/dist/index.js +14 -14
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,7 +4,16 @@ All notable changes to `@getpeppr/cli` are documented here.
|
|
|
4
4
|
|
|
5
5
|
The CLI bundles `@getpeppr/sdk` into its published artifact (tsup `noExternal`), so `validate`, `convert` and `init` run the SDK's validators, country rules and UBL builder locally — an SDK release only reaches CLI users once the CLI is rebundled. Rebundle-only releases are listed with the SDK version they ship.
|
|
6
6
|
|
|
7
|
-
## [0.12.
|
|
7
|
+
## [0.12.1] — 2026-09-06
|
|
8
|
+
|
|
9
|
+
Rebundles `@getpeppr/sdk` 5.3.0 (GPR-1280).
|
|
10
|
+
|
|
11
|
+
- 0.12.0 was published with a stale SDK 5.2.0 bundle: its `validate` did not
|
|
12
|
+
enforce the billing-profile rules and its `structure` rule IDs predated
|
|
13
|
+
GPR-1267. Version 0.12.0 is deprecated on the registry; 0.12.1 carries the
|
|
14
|
+
intended bundle and the changes below as originally described.
|
|
15
|
+
|
|
16
|
+
## [0.12.0] — 2026-09-06 (deprecated — stale SDK bundle, superseded by 0.12.1)
|
|
8
17
|
|
|
9
18
|
Rebundles `@getpeppr/sdk` 5.3.0 (GPR-1280).
|
|
10
19
|
|
package/dist/index.js
CHANGED
|
@@ -130,7 +130,7 @@ Validating: ${pc.bold(filename)}
|
|
|
130
130
|
return lines.join("\n");
|
|
131
131
|
}
|
|
132
132
|
|
|
133
|
-
//
|
|
133
|
+
// ../sdk/dist/core/canonical-schemes.js
|
|
134
134
|
var ALIAS_TO_EAS = /* @__PURE__ */ new Map([
|
|
135
135
|
["AD:VAT", "9922"],
|
|
136
136
|
["AE:TIN", "0235"],
|
|
@@ -356,7 +356,7 @@ function countryForScheme(scheme) {
|
|
|
356
356
|
var CANONICAL_SCHEME_COUNT = ALIAS_TO_EAS.size;
|
|
357
357
|
var SCHEME_COUNTRY_COUNT = EAS_TO_COUNTRY.size;
|
|
358
358
|
|
|
359
|
-
//
|
|
359
|
+
// ../sdk/dist/core/peppol-id.js
|
|
360
360
|
function isWellFormedPeppolId(peppolId) {
|
|
361
361
|
if (!peppolId.includes(":"))
|
|
362
362
|
return false;
|
|
@@ -382,7 +382,7 @@ function parsePeppolId(peppolId) {
|
|
|
382
382
|
};
|
|
383
383
|
}
|
|
384
384
|
|
|
385
|
-
//
|
|
385
|
+
// ../sdk/dist/core/iso6523-icd-codes.js
|
|
386
386
|
var ICD_CODES = /* @__PURE__ */ new Set([
|
|
387
387
|
"0002",
|
|
388
388
|
"0003",
|
|
@@ -645,7 +645,7 @@ function canCarryPartyIdentification(scheme, context) {
|
|
|
645
645
|
return scheme === "SEPA" && context !== "AccountingCustomerParty";
|
|
646
646
|
}
|
|
647
647
|
|
|
648
|
-
//
|
|
648
|
+
// ../sdk/dist/core/ubl-builder.js
|
|
649
649
|
var UBL_NS = "urn:oasis:names:specification:ubl:schema:xsd:Invoice-2";
|
|
650
650
|
var CAC_NS = "urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2";
|
|
651
651
|
var CBC_NS = "urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2";
|
|
@@ -1296,7 +1296,7 @@ function buildCreditNoteXml(input) {
|
|
|
1296
1296
|
</CreditNote>`;
|
|
1297
1297
|
}
|
|
1298
1298
|
|
|
1299
|
-
//
|
|
1299
|
+
// ../sdk/dist/core/checksums/luhn.js
|
|
1300
1300
|
function isValidLuhn(input) {
|
|
1301
1301
|
if (typeof input !== "string")
|
|
1302
1302
|
return false;
|
|
@@ -1337,7 +1337,7 @@ function isValidLuhnSiret(input) {
|
|
|
1337
1337
|
return false;
|
|
1338
1338
|
}
|
|
1339
1339
|
|
|
1340
|
-
//
|
|
1340
|
+
// ../sdk/dist/core/country-rules.js
|
|
1341
1341
|
function warn(field, message, ruleId) {
|
|
1342
1342
|
return { field, message, ruleId };
|
|
1343
1343
|
}
|
|
@@ -1478,7 +1478,7 @@ function validateCountryRules(input) {
|
|
|
1478
1478
|
return { errors, warnings };
|
|
1479
1479
|
}
|
|
1480
1480
|
|
|
1481
|
-
//
|
|
1481
|
+
// ../sdk/dist/core/code-lists.js
|
|
1482
1482
|
var CURRENCIES = /* @__PURE__ */ new Map([
|
|
1483
1483
|
["EUR", { code: "EUR", name: "Euro", minorUnits: 2 }],
|
|
1484
1484
|
["USD", { code: "USD", name: "US Dollar", minorUnits: 2 }],
|
|
@@ -1681,7 +1681,7 @@ function getCreditNoteTypeCodes() {
|
|
|
1681
1681
|
return [...CREDIT_NOTE_TYPE_CODES];
|
|
1682
1682
|
}
|
|
1683
1683
|
|
|
1684
|
-
//
|
|
1684
|
+
// ../sdk/dist/core/validator.js
|
|
1685
1685
|
function error(field, message, ruleId, suggestion) {
|
|
1686
1686
|
return { field, message, ruleId, suggestion };
|
|
1687
1687
|
}
|
|
@@ -2001,7 +2001,7 @@ function validateInvoice(input) {
|
|
|
2001
2001
|
};
|
|
2002
2002
|
}
|
|
2003
2003
|
|
|
2004
|
-
//
|
|
2004
|
+
// ../sdk/dist/core/schematron.js
|
|
2005
2005
|
function violation(ruleId, severity, message, field) {
|
|
2006
2006
|
return { ruleId, severity, message, field };
|
|
2007
2007
|
}
|
|
@@ -2616,7 +2616,7 @@ var SDK_SCHEMATRON_RULE_IDS = [
|
|
|
2616
2616
|
"GETPEPPR-UNIT-CODE-RECOGNISED"
|
|
2617
2617
|
];
|
|
2618
2618
|
|
|
2619
|
-
//
|
|
2619
|
+
// ../sdk/dist/core/status-precedence.js
|
|
2620
2620
|
var STATUS_PRECEDENCE = [
|
|
2621
2621
|
{ status: "failed", family: "terminal-failure" },
|
|
2622
2622
|
{ status: "rejected", family: "terminal-failure" },
|
|
@@ -2640,10 +2640,10 @@ function statusFamily(status) {
|
|
|
2640
2640
|
}
|
|
2641
2641
|
var TERMINAL_FAILURE_STATUSES = STATUS_PRECEDENCE.filter((e) => e.family === "terminal-failure").map((e) => e.status);
|
|
2642
2642
|
|
|
2643
|
-
//
|
|
2644
|
-
var SDK_VERSION = "5.
|
|
2643
|
+
// ../sdk/dist/version.js
|
|
2644
|
+
var SDK_VERSION = "5.3.0";
|
|
2645
2645
|
|
|
2646
|
-
//
|
|
2646
|
+
// ../sdk/dist/core/api-result.js
|
|
2647
2647
|
var API_RESULT_HEADER_NAMES = {
|
|
2648
2648
|
requestId: "Getpeppr-Request-Id",
|
|
2649
2649
|
resultCode: "Getpeppr-Result-Code",
|
|
@@ -2760,7 +2760,7 @@ function parseApiResultHeaders(headers) {
|
|
|
2760
2760
|
return Object.keys(result).length === 0 ? void 0 : result;
|
|
2761
2761
|
}
|
|
2762
2762
|
|
|
2763
|
-
//
|
|
2763
|
+
// ../sdk/dist/core/client.js
|
|
2764
2764
|
function normalizeHeaderValue(value) {
|
|
2765
2765
|
return value.replace(/^[\t\n\r ]+|[\t\n\r ]+$/g, "");
|
|
2766
2766
|
}
|