@icure/be-fhc-api 0.4.7 → 0.4.8
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/index.d.ts +2 -0
- package/index.js +2 -0
- package/package.json +1 -1
- package/x-api/message-x-api.d.ts +35 -0
- package/x-api/message-x-api.js +790 -0
- package/x-api/receipt-x-api.d.ts +10 -0
- package/x-api/receipt-x-api.js +42 -0
- package/x-api/utils/efact-parser.d.ts +234 -0
- package/x-api/utils/efact-parser.js +1121 -0
- package/x-api/utils/efact-util.d.ts +28 -0
- package/x-api/utils/efact-util.js +316 -0
- package/x-api/utils/fhc-invoice-sender-util.d.ts +3 -0
- package/x-api/utils/fhc-invoice-sender-util.js +31 -0
- package/x-api/utils/fhc-patient-util.d.ts +3 -0
- package/x-api/utils/fhc-patient-util.js +20 -0
- package/x-api/utils/formatting-util.d.ts +76 -0
- package/x-api/utils/formatting-util.js +218 -0
- package/x-api/utils/hcp-util.d.ts +16 -0
- package/x-api/utils/hcp-util.js +131 -0
- package/x-api/utils/insurability-util.d.ts +22 -0
- package/x-api/utils/insurability-util.js +56 -0
- package/x-api/utils/uuid-encoder.d.ts +44 -0
- package/x-api/utils/uuid-encoder.js +110 -0
package/index.d.ts
CHANGED
package/index.js
CHANGED
|
@@ -13,5 +13,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
13
13
|
exports.XHR = void 0;
|
|
14
14
|
__exportStar(require("./fhcApi"), exports);
|
|
15
15
|
__exportStar(require("./model/models"), exports);
|
|
16
|
+
__exportStar(require("./x-api/message-x-api"), exports);
|
|
17
|
+
__exportStar(require("./x-api/receipt-x-api"), exports);
|
|
16
18
|
var XHR_1 = require("./api/XHR");
|
|
17
19
|
Object.defineProperty(exports, "XHR", { enumerable: true, get: function () { return XHR_1.XHR; } });
|
package/package.json
CHANGED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { HealthcareParty, IccCryptoXApi, IccDocumentXApi, IccEntityrefApi, IccInsuranceApi, IccInvoiceXApi, IccMessageXApi, IccPatientXApi, Insurance, Invoice, Message, Receipt, User } from "@icure/api";
|
|
2
|
+
import { InvoiceWithPatient } from "./utils/efact-util";
|
|
3
|
+
import { DmgsList, EfactMessage, EfactSendResponse, ErrorDetail, GenAsyncResponse } from "../model/models";
|
|
4
|
+
import { fhcEfactApi } from "../api/fhcEfactApi";
|
|
5
|
+
import { ReceiptXApi } from "./receipt-x-api";
|
|
6
|
+
declare class EfactSendResponseWithError extends EfactSendResponse {
|
|
7
|
+
error: string | undefined;
|
|
8
|
+
constructor(json: JSON);
|
|
9
|
+
}
|
|
10
|
+
export declare class MessageXApi {
|
|
11
|
+
private api;
|
|
12
|
+
private crypto;
|
|
13
|
+
private insuranceApi;
|
|
14
|
+
private entityReferenceApi;
|
|
15
|
+
private receiptXApi;
|
|
16
|
+
private invoiceXApi;
|
|
17
|
+
private documentXApi;
|
|
18
|
+
private patientApi;
|
|
19
|
+
constructor(api: IccMessageXApi, crypto: IccCryptoXApi, documentXApi: IccDocumentXApi, insuranceApi: IccInsuranceApi, entityReferenceApi: IccEntityrefApi, fhcReceiptXApi: ReceiptXApi, invoiceXApi: IccInvoiceXApi, patientApi: IccPatientXApi);
|
|
20
|
+
saveDmgsListRequest(user: User, req: GenAsyncResponse, requestDate?: number): Promise<Message>;
|
|
21
|
+
processDmgMessagesList(user: User, hcp: HealthcareParty, list: DmgsList, docXApi: IccDocumentXApi): Promise<Array<Array<string>>>;
|
|
22
|
+
private makeHcp;
|
|
23
|
+
private saveMessageInDb;
|
|
24
|
+
saveDmgListRequestInDb(user: User, tack: string, resultMajor: string, appliesTo: string, hcp: HealthcareParty, date?: Date, inss?: string): Promise<Message>;
|
|
25
|
+
extractErrorMessage(error?: ErrorDetail): string | undefined;
|
|
26
|
+
extractErrors(parsedRecords: any): string[];
|
|
27
|
+
processTack(user: User, hcp: HealthcareParty, efactMessage: EfactMessage): Promise<Receipt>;
|
|
28
|
+
processEfactMessage(user: User, hcp: HealthcareParty, efactMessage: EfactMessage, invoicePrefix?: string, invoicePrefixer?: (invoice: Invoice, hcpId: string) => Promise<string>): Promise<{
|
|
29
|
+
message: Message;
|
|
30
|
+
invoices: Array<Invoice>;
|
|
31
|
+
}>;
|
|
32
|
+
sendBatch(user: User, hcp: HealthcareParty, invoices: Array<InvoiceWithPatient>, xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, efactApi: fhcEfactApi, fhcServer?: string | undefined, prefixer?: (fed: Insurance, hcpId: string) => Promise<string>, isConnectedAsPmg?: boolean, medicalLocationId?: string | null): Promise<Message>;
|
|
33
|
+
saveMessageAttachment(user: User, msg: Message, res: EfactSendResponseWithError): Promise<Receipt>;
|
|
34
|
+
}
|
|
35
|
+
export {};
|