Comparing version 1.0.26 to 1.0.27
@@ -32,9 +32,9 @@ /** | ||
handleError(e: XHR.Data): void; | ||
confirmAcksUsingPOST(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, dmgTacks: Array<models.DmgAcknowledge>): Promise<boolean | any>; | ||
confirmDmgMessagesUsingPOST(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, dmgMessages: Array<models.DmgMessage>): Promise<boolean | any>; | ||
confirmAcksUsingPOST(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, dmgAcksHashes: Array<string>): Promise<boolean | any>; | ||
confirmDmgMessagesUsingPOST(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, dmgMessagesHashes: Array<string>): Promise<boolean | any>; | ||
consultDmgUsingGET(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, patientSsin?: string, patientGender?: string, oa?: string, regNrWithMut?: string, requestDate?: number): Promise<models.DmgConsultation | any>; | ||
getDmgMessagesUsingPOST(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, oa: string, messageNames: Array<string>): Promise<models.DmgsList | any>; | ||
notifyDmgUsingPOST(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, nomenclature: string, patientSsin?: string, oa?: string, regNrWithMut?: string, patientFirstName?: string, patientLastName?: string, patientGender?: string, requestDate?: number): Promise<models.DmgNotification | any>; | ||
notifyDmgUsingPOST(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, nomenclature: string, patientSsin?: string, oa?: string, regNrWithMut?: string, patientFirstName?: string, patientLastName?: string, patientGender?: string, requestDate?: number, traineeSupervisorSsin?: string, traineeSupervisorNihii?: string, traineeSupervisorFirstName?: string, traineeSupervisorLastName?: string): Promise<models.DmgNotification | any>; | ||
postDmgsListRequestUsingPOST(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, oa?: string, requestDate?: number): Promise<boolean | any>; | ||
registerDoctorUsingPOST(xFHCKeystoreId: string, xFHCTokenId: string, xFHCPassPhrase: string, hcpNihii: string, hcpSsin: string, hcpFirstName: string, hcpLastName: string, oa: string, bic: string, iban: string): Promise<models.DmgRegistration | any>; | ||
} |
@@ -40,5 +40,5 @@ /** | ||
} | ||
confirmAcksUsingPOST(xFHCKeystoreId, xFHCTokenId, xFHCPassPhrase, hcpNihii, hcpSsin, hcpFirstName, hcpLastName, dmgTacks) { | ||
confirmAcksUsingPOST(xFHCKeystoreId, xFHCTokenId, xFHCPassPhrase, hcpNihii, hcpSsin, hcpFirstName, hcpLastName, dmgAcksHashes) { | ||
let _body = null; | ||
_body = dmgTacks; | ||
_body = dmgAcksHashes; | ||
const _url = this.host + | ||
@@ -63,5 +63,5 @@ "/gmd/confirm/acks" + | ||
} | ||
confirmDmgMessagesUsingPOST(xFHCKeystoreId, xFHCTokenId, xFHCPassPhrase, hcpNihii, hcpSsin, hcpFirstName, hcpLastName, dmgMessages) { | ||
confirmDmgMessagesUsingPOST(xFHCKeystoreId, xFHCTokenId, xFHCPassPhrase, hcpNihii, hcpSsin, hcpFirstName, hcpLastName, dmgMessagesHashes) { | ||
let _body = null; | ||
_body = dmgMessages; | ||
_body = dmgMessagesHashes; | ||
const _url = this.host + | ||
@@ -135,3 +135,3 @@ "/gmd/confirm/messages" + | ||
} | ||
notifyDmgUsingPOST(xFHCKeystoreId, xFHCTokenId, xFHCPassPhrase, hcpNihii, hcpSsin, hcpFirstName, hcpLastName, nomenclature, patientSsin, oa, regNrWithMut, patientFirstName, patientLastName, patientGender, requestDate) { | ||
notifyDmgUsingPOST(xFHCKeystoreId, xFHCTokenId, xFHCPassPhrase, hcpNihii, hcpSsin, hcpFirstName, hcpLastName, nomenclature, patientSsin, oa, regNrWithMut, patientFirstName, patientLastName, patientGender, requestDate, traineeSupervisorSsin, traineeSupervisorNihii, traineeSupervisorFirstName, traineeSupervisorLastName) { | ||
let _body = null; | ||
@@ -152,3 +152,9 @@ const _url = this.host + | ||
(patientGender ? "&patientGender=" + patientGender : "") + | ||
(requestDate ? "&requestDate=" + requestDate : ""); | ||
(requestDate ? "&requestDate=" + requestDate : "") + | ||
(traineeSupervisorSsin ? "&traineeSupervisorSsin=" + traineeSupervisorSsin : "") + | ||
(traineeSupervisorNihii ? "&traineeSupervisorNihii=" + traineeSupervisorNihii : "") + | ||
(traineeSupervisorFirstName | ||
? "&traineeSupervisorFirstName=" + traineeSupervisorFirstName | ||
: "") + | ||
(traineeSupervisorLastName ? "&traineeSupervisorLastName=" + traineeSupervisorLastName : ""); | ||
let headers = this.headers; | ||
@@ -155,0 +161,0 @@ headers = headers |
@@ -13,3 +13,9 @@ export declare namespace XHR { | ||
} | ||
class XHRError extends Error { | ||
status: number; | ||
code: number; | ||
headers: Headers; | ||
constructor(message: string, status: number, code: number, headers: Headers); | ||
} | ||
function sendCommand(method: string, url: string, headers: Array<Header> | null, data?: string | any): Promise<Data>; | ||
} |
@@ -18,2 +18,11 @@ export var XHR; | ||
XHR.Data = Data; | ||
class XHRError extends Error { | ||
constructor(message, status, code, headers) { | ||
super(message); | ||
this.status = status; | ||
this.code = code; | ||
this.headers = headers; | ||
} | ||
} | ||
XHR.XHRError = XHRError; | ||
function sendCommand(method, url, headers, data = "") { | ||
@@ -40,2 +49,5 @@ const contentType = headers && | ||
: {})).then(function (response) { | ||
if (response.status >= 400) { | ||
throw new XHRError(response.statusText, response.status, response.status, response.headers); | ||
} | ||
const ct = response.headers.get("content-type") || "text/plain"; | ||
@@ -42,0 +54,0 @@ return (ct.startsWith("application/octet-stream") |
@@ -36,3 +36,2 @@ export * from "./AcknowledgeType"; | ||
export * from "./DmgInscription"; | ||
export * from "./DmgMessage"; | ||
export * from "./DmgNotification"; | ||
@@ -39,0 +38,0 @@ export * from "./DmgRegistration"; |
@@ -36,3 +36,2 @@ export * from "./AcknowledgeType"; | ||
export * from "./DmgInscription"; | ||
export * from "./DmgMessage"; | ||
export * from "./DmgNotification"; | ||
@@ -39,0 +38,0 @@ export * from "./DmgRegistration"; |
{ | ||
"name": "fhc-api", | ||
"version": "1.0.26", | ||
"version": "1.0.27", | ||
"description": "Typescript version of Freehealth Connector standalone API client", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
AI-detected possible typosquat
Supply chain riskAI has identified this package as a potential typosquat of a more popular package. This suggests that the package may be intentionally mimicking another package's name, description, or other metadata.
Found 1 instance in 1 package
445578
11788
1