mindee 4.13.1 → 4.14.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 +18 -0
- package/README.md +9 -9
- package/package.json +2 -2
- package/src/cli.js +108 -48
- package/src/parsing/standard/companyRegistration.d.ts +3 -0
- package/src/parsing/standard/companyRegistration.js +15 -0
- package/src/product/barcodeReader/index.d.ts +1 -0
- package/src/product/barcodeReader/index.js +5 -0
- package/src/product/cropper/index.d.ts +1 -0
- package/src/product/cropper/index.js +5 -0
- package/src/product/eu/driverLicense/index.d.ts +1 -0
- package/src/product/eu/driverLicense/index.js +5 -0
- package/src/product/eu/driverLicense/internal.d.ts +1 -0
- package/src/product/eu/driverLicense/internal.js +3 -1
- package/src/product/eu/index.d.ts +1 -1
- package/src/product/eu/index.js +3 -3
- package/src/product/eu/internal.d.ts +1 -1
- package/src/product/eu/internal.js +2 -2
- package/src/product/eu/licensePlate/index.d.ts +1 -0
- package/src/product/eu/licensePlate/index.js +5 -0
- package/src/product/financialDocument/financialDocumentV1Document.d.ts +1 -1
- package/src/product/financialDocument/financialDocumentV1Document.js +3 -2
- package/src/product/financialDocument/financialDocumentV1LineItem.d.ts +2 -0
- package/src/product/financialDocument/financialDocumentV1LineItem.js +10 -0
- package/src/product/financialDocument/index.d.ts +1 -0
- package/src/product/financialDocument/index.js +5 -0
- package/src/product/fr/bankAccountDetails/index.d.ts +2 -0
- package/src/product/fr/bankAccountDetails/index.js +7 -0
- package/src/product/fr/bankAccountDetails/internal.d.ts +1 -1
- package/src/product/fr/bankAccountDetails/internal.js +3 -3
- package/src/product/fr/carteGrise/index.d.ts +1 -0
- package/src/product/fr/carteGrise/index.js +5 -0
- package/src/product/fr/carteVitale/index.d.ts +1 -0
- package/src/product/fr/carteVitale/index.js +5 -0
- package/src/product/fr/idCard/index.d.ts +2 -0
- package/src/product/fr/idCard/index.js +7 -0
- package/src/product/fr/idCard/internal.d.ts +3 -1
- package/src/product/fr/idCard/internal.js +7 -3
- package/src/product/fr/index.d.ts +3 -3
- package/src/product/fr/index.js +7 -7
- package/src/product/fr/internal.d.ts +1 -1
- package/src/product/fr/internal.js +2 -2
- package/src/product/index.d.ts +2 -2
- package/src/product/index.js +5 -5
- package/src/product/internal.d.ts +1 -1
- package/src/product/internal.js +2 -2
- package/src/product/internationalId/index.d.ts +1 -0
- package/src/product/internationalId/index.js +5 -0
- package/src/product/internationalId/internationalIdV2Document.d.ts +1 -1
- package/src/product/internationalId/internationalIdV2Document.js +1 -1
- package/src/product/invoice/index.d.ts +1 -0
- package/src/product/invoice/index.js +5 -0
- package/src/product/invoice/invoiceV4Document.d.ts +1 -1
- package/src/product/invoice/invoiceV4Document.js +3 -2
- package/src/product/invoice/invoiceV4LineItem.d.ts +2 -0
- package/src/product/invoice/invoiceV4LineItem.js +10 -0
- package/src/product/multiReceiptsDetector/index.d.ts +1 -0
- package/src/product/multiReceiptsDetector/index.js +5 -0
- package/src/product/multiReceiptsDetector/multiReceiptsDetectorV1Document.d.ts +1 -1
- package/src/product/multiReceiptsDetector/multiReceiptsDetectorV1Document.js +1 -1
- package/src/product/passport/index.d.ts +1 -0
- package/src/product/passport/index.js +5 -0
- package/src/product/proofOfAddress/index.d.ts +1 -0
- package/src/product/proofOfAddress/index.js +5 -0
- package/src/product/receipt/index.d.ts +1 -0
- package/src/product/receipt/index.js +5 -0
- package/src/product/receipt/receiptV5Document.d.ts +1 -1
- package/src/product/receipt/receiptV5Document.js +1 -1
- package/src/product/resume/index.d.ts +1 -0
- package/src/product/resume/index.js +5 -0
- package/src/product/resume/internal.d.ts +1 -1
- package/src/product/resume/internal.js +3 -3
- package/src/product/us/bankCheck/index.d.ts +1 -0
- package/src/product/us/bankCheck/index.js +5 -0
- package/src/product/us/driverLicense/index.d.ts +1 -0
- package/src/product/us/driverLicense/index.js +5 -0
- package/src/product/us/healthcareCard/healthcareCardV1.d.ts +16 -0
- package/src/product/us/healthcareCard/healthcareCardV1.js +27 -0
- package/src/product/us/healthcareCard/healthcareCardV1Copay.d.ts +30 -0
- package/src/product/us/healthcareCard/healthcareCardV1Copay.js +66 -0
- package/src/product/us/healthcareCard/healthcareCardV1Document.d.ts +37 -0
- package/src/product/us/healthcareCard/healthcareCardV1Document.js +96 -0
- package/src/product/us/healthcareCard/index.d.ts +3 -0
- package/src/product/us/healthcareCard/index.js +9 -0
- package/src/product/us/healthcareCard/internal.d.ts +3 -0
- package/src/product/us/healthcareCard/internal.js +9 -0
- package/src/product/us/index.d.ts +2 -1
- package/src/product/us/index.js +5 -3
- package/src/product/us/internal.d.ts +1 -0
- package/src/product/us/internal.js +2 -1
- package/src/product/us/w9/index.d.ts +1 -0
- package/src/product/us/w9/index.js +5 -0
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.HealthcareCardV1Document = void 0;
|
|
4
|
+
const common_1 = require("../../../parsing/common");
|
|
5
|
+
const healthcareCardV1Copay_1 = require("./healthcareCardV1Copay");
|
|
6
|
+
const standard_1 = require("../../../parsing/standard");
|
|
7
|
+
/**
|
|
8
|
+
* Healthcare Card API version 1.0 document data.
|
|
9
|
+
*/
|
|
10
|
+
class HealthcareCardV1Document {
|
|
11
|
+
constructor(rawPrediction, pageId) {
|
|
12
|
+
/** Is a fixed amount for a covered service. */
|
|
13
|
+
this.copays = [];
|
|
14
|
+
/** The list of dependents covered by the healthcare plan. */
|
|
15
|
+
this.dependents = [];
|
|
16
|
+
this.companyName = new standard_1.StringField({
|
|
17
|
+
prediction: rawPrediction["company_name"],
|
|
18
|
+
pageId: pageId,
|
|
19
|
+
});
|
|
20
|
+
rawPrediction["copays"] &&
|
|
21
|
+
rawPrediction["copays"].map((itemPrediction) => this.copays.push(new healthcareCardV1Copay_1.HealthcareCardV1Copay({
|
|
22
|
+
prediction: itemPrediction,
|
|
23
|
+
pageId: pageId,
|
|
24
|
+
})));
|
|
25
|
+
rawPrediction["dependents"] &&
|
|
26
|
+
rawPrediction["dependents"].map((itemPrediction) => this.dependents.push(new standard_1.StringField({
|
|
27
|
+
prediction: itemPrediction,
|
|
28
|
+
pageId: pageId,
|
|
29
|
+
})));
|
|
30
|
+
this.enrollmentDate = new standard_1.DateField({
|
|
31
|
+
prediction: rawPrediction["enrollment_date"],
|
|
32
|
+
pageId: pageId,
|
|
33
|
+
});
|
|
34
|
+
this.groupNumber = new standard_1.StringField({
|
|
35
|
+
prediction: rawPrediction["group_number"],
|
|
36
|
+
pageId: pageId,
|
|
37
|
+
});
|
|
38
|
+
this.issuer80840 = new standard_1.StringField({
|
|
39
|
+
prediction: rawPrediction["issuer_80840"],
|
|
40
|
+
pageId: pageId,
|
|
41
|
+
});
|
|
42
|
+
this.memberId = new standard_1.StringField({
|
|
43
|
+
prediction: rawPrediction["member_id"],
|
|
44
|
+
pageId: pageId,
|
|
45
|
+
});
|
|
46
|
+
this.memberName = new standard_1.StringField({
|
|
47
|
+
prediction: rawPrediction["member_name"],
|
|
48
|
+
pageId: pageId,
|
|
49
|
+
});
|
|
50
|
+
this.payerId = new standard_1.StringField({
|
|
51
|
+
prediction: rawPrediction["payer_id"],
|
|
52
|
+
pageId: pageId,
|
|
53
|
+
});
|
|
54
|
+
this.rxBin = new standard_1.StringField({
|
|
55
|
+
prediction: rawPrediction["rx_bin"],
|
|
56
|
+
pageId: pageId,
|
|
57
|
+
});
|
|
58
|
+
this.rxGrp = new standard_1.StringField({
|
|
59
|
+
prediction: rawPrediction["rx_grp"],
|
|
60
|
+
pageId: pageId,
|
|
61
|
+
});
|
|
62
|
+
this.rxPcn = new standard_1.StringField({
|
|
63
|
+
prediction: rawPrediction["rx_pcn"],
|
|
64
|
+
pageId: pageId,
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Default string representation.
|
|
69
|
+
*/
|
|
70
|
+
toString() {
|
|
71
|
+
const dependents = this.dependents.join("\n ");
|
|
72
|
+
let copaysSummary = "";
|
|
73
|
+
if (this.copays && this.copays.length > 0) {
|
|
74
|
+
const copaysColSizes = [14, 14];
|
|
75
|
+
copaysSummary += "\n" + (0, common_1.lineSeparator)(copaysColSizes, "-") + "\n ";
|
|
76
|
+
copaysSummary += "| Service Fees ";
|
|
77
|
+
copaysSummary += "| Service Name ";
|
|
78
|
+
copaysSummary += "|\n" + (0, common_1.lineSeparator)(copaysColSizes, "=");
|
|
79
|
+
copaysSummary += this.copays.map((item) => "\n " + item.toTableLine() + "\n" + (0, common_1.lineSeparator)(copaysColSizes, "-")).join("");
|
|
80
|
+
}
|
|
81
|
+
const outStr = `:Company Name: ${this.companyName}
|
|
82
|
+
:Member Name: ${this.memberName}
|
|
83
|
+
:Member ID: ${this.memberId}
|
|
84
|
+
:Issuer 80840: ${this.issuer80840}
|
|
85
|
+
:Dependents: ${dependents}
|
|
86
|
+
:Group Number: ${this.groupNumber}
|
|
87
|
+
:Payer ID: ${this.payerId}
|
|
88
|
+
:RX BIN: ${this.rxBin}
|
|
89
|
+
:RX GRP: ${this.rxGrp}
|
|
90
|
+
:RX PCN: ${this.rxPcn}
|
|
91
|
+
:copays: ${copaysSummary}
|
|
92
|
+
:Enrollment Date: ${this.enrollmentDate}`.trimEnd();
|
|
93
|
+
return (0, common_1.cleanOutString)(outStr);
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
exports.HealthcareCardV1Document = HealthcareCardV1Document;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.HealthcareCardV1Document = exports.HealthcareCardV1Copay = exports.HealthcareCardV1 = void 0;
|
|
4
|
+
var healthcareCardV1_1 = require("./healthcareCardV1");
|
|
5
|
+
Object.defineProperty(exports, "HealthcareCardV1", { enumerable: true, get: function () { return healthcareCardV1_1.HealthcareCardV1; } });
|
|
6
|
+
var healthcareCardV1Copay_1 = require("./healthcareCardV1Copay");
|
|
7
|
+
Object.defineProperty(exports, "HealthcareCardV1Copay", { enumerable: true, get: function () { return healthcareCardV1Copay_1.HealthcareCardV1Copay; } });
|
|
8
|
+
var healthcareCardV1Document_1 = require("./healthcareCardV1Document");
|
|
9
|
+
Object.defineProperty(exports, "HealthcareCardV1Document", { enumerable: true, get: function () { return healthcareCardV1Document_1.HealthcareCardV1Document; } });
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.HealthcareCardV1Document = exports.HealthcareCardV1Copay = exports.HealthcareCardV1 = void 0;
|
|
4
|
+
var healthcareCardV1_1 = require("./healthcareCardV1");
|
|
5
|
+
Object.defineProperty(exports, "HealthcareCardV1", { enumerable: true, get: function () { return healthcareCardV1_1.HealthcareCardV1; } });
|
|
6
|
+
var healthcareCardV1Copay_1 = require("./healthcareCardV1Copay");
|
|
7
|
+
Object.defineProperty(exports, "HealthcareCardV1Copay", { enumerable: true, get: function () { return healthcareCardV1Copay_1.HealthcareCardV1Copay; } });
|
|
8
|
+
var healthcareCardV1Document_1 = require("./healthcareCardV1Document");
|
|
9
|
+
Object.defineProperty(exports, "HealthcareCardV1Document", { enumerable: true, get: function () { return healthcareCardV1Document_1.HealthcareCardV1Document; } });
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export { BankCheckV1 } from "./bankCheck/bankCheckV1";
|
|
2
2
|
export { DriverLicenseV1 } from "./driverLicense/driverLicenseV1";
|
|
3
|
-
export {
|
|
3
|
+
export { HealthcareCardV1 } from "./healthcareCard/healthcareCardV1";
|
|
4
4
|
export { UsMailV2 } from "./usMail/usMailV2";
|
|
5
|
+
export { W9V1 } from "./w9/w9V1";
|
package/src/product/us/index.js
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UsMailV2 = exports.
|
|
3
|
+
exports.W9V1 = exports.UsMailV2 = exports.HealthcareCardV1 = exports.DriverLicenseV1 = exports.BankCheckV1 = void 0;
|
|
4
4
|
var bankCheckV1_1 = require("./bankCheck/bankCheckV1");
|
|
5
5
|
Object.defineProperty(exports, "BankCheckV1", { enumerable: true, get: function () { return bankCheckV1_1.BankCheckV1; } });
|
|
6
6
|
var driverLicenseV1_1 = require("./driverLicense/driverLicenseV1");
|
|
7
7
|
Object.defineProperty(exports, "DriverLicenseV1", { enumerable: true, get: function () { return driverLicenseV1_1.DriverLicenseV1; } });
|
|
8
|
-
var
|
|
9
|
-
Object.defineProperty(exports, "
|
|
8
|
+
var healthcareCardV1_1 = require("./healthcareCard/healthcareCardV1");
|
|
9
|
+
Object.defineProperty(exports, "HealthcareCardV1", { enumerable: true, get: function () { return healthcareCardV1_1.HealthcareCardV1; } });
|
|
10
10
|
var usMailV2_1 = require("./usMail/usMailV2");
|
|
11
11
|
Object.defineProperty(exports, "UsMailV2", { enumerable: true, get: function () { return usMailV2_1.UsMailV2; } });
|
|
12
|
+
var w9V1_1 = require("./w9/w9V1");
|
|
13
|
+
Object.defineProperty(exports, "W9V1", { enumerable: true, get: function () { return w9V1_1.W9V1; } });
|
|
@@ -23,8 +23,9 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.w9 = exports.usMail = exports.driverLicense = exports.bankCheck = void 0;
|
|
26
|
+
exports.w9 = exports.usMail = exports.us = exports.driverLicense = exports.bankCheck = void 0;
|
|
27
27
|
exports.bankCheck = __importStar(require("./bankCheck/internal"));
|
|
28
28
|
exports.driverLicense = __importStar(require("./driverLicense/internal"));
|
|
29
|
+
exports.us = __importStar(require("./healthcareCard/internal"));
|
|
29
30
|
exports.usMail = __importStar(require("./usMail/internal"));
|
|
30
31
|
exports.w9 = __importStar(require("./w9/internal"));
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { W9V1 } from "./w9V1";
|