@oystehr/sdk 4.3.11 → 4.3.12
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/dist/cjs/index.min.cjs +1 -1
- package/dist/cjs/index.min.cjs.map +1 -1
- package/dist/cjs/resources/classes/erx.cjs +8 -0
- package/dist/cjs/resources/classes/erx.cjs.map +1 -1
- package/dist/cjs/resources/classes/erx.d.ts +7 -1
- package/dist/cjs/resources/classes/fhir.cjs +31 -0
- package/dist/cjs/resources/classes/fhir.cjs.map +1 -1
- package/dist/cjs/resources/classes/fhir.d.ts +31 -0
- package/dist/cjs/resources/classes/rcm.cjs +9 -0
- package/dist/cjs/resources/classes/rcm.cjs.map +1 -1
- package/dist/cjs/resources/classes/rcm.d.ts +8 -1
- package/dist/cjs/resources/classes/terminology.cjs +9 -0
- package/dist/cjs/resources/classes/terminology.cjs.map +1 -1
- package/dist/cjs/resources/classes/terminology.d.ts +8 -1
- package/dist/cjs/resources/classes/z3.cjs +9 -0
- package/dist/cjs/resources/classes/z3.cjs.map +1 -1
- package/dist/cjs/resources/classes/z3.d.ts +8 -1
- package/dist/cjs/resources/types/ErxGetMedicationHistoryResponse.d.ts +1 -1
- package/dist/cjs/resources/types/ErxGetPharmacyParams.d.ts +3 -0
- package/dist/cjs/resources/types/ErxGetPharmacyResponse.d.ts +16 -0
- package/dist/cjs/resources/types/ErxSearchPharmaciesResponse.d.ts +2 -2
- package/dist/cjs/resources/types/LabOrderSubmitParams.d.ts +4 -0
- package/dist/cjs/resources/types/RcmProcessEraParams.d.ts +6 -0
- package/dist/cjs/resources/types/RcmProcessEraResponse.d.ts +5 -0
- package/dist/cjs/resources/types/TerminologySearchIcd10Params.d.ts +9 -0
- package/dist/cjs/resources/types/TerminologySearchIcd10Response.d.ts +27 -0
- package/dist/cjs/resources/types/Z3EmptyBucketParams.d.ts +3 -0
- package/dist/cjs/resources/types/Z3EmptyBucketResponse.d.ts +9 -0
- package/dist/cjs/resources/types/index.d.ts +8 -0
- package/dist/esm/index.min.js +1 -1
- package/dist/esm/index.min.js.map +1 -1
- package/dist/esm/resources/classes/erx.d.ts +7 -1
- package/dist/esm/resources/classes/erx.js +8 -0
- package/dist/esm/resources/classes/erx.js.map +1 -1
- package/dist/esm/resources/classes/fhir.d.ts +31 -0
- package/dist/esm/resources/classes/fhir.js +31 -0
- package/dist/esm/resources/classes/fhir.js.map +1 -1
- package/dist/esm/resources/classes/rcm.d.ts +8 -1
- package/dist/esm/resources/classes/rcm.js +9 -0
- package/dist/esm/resources/classes/rcm.js.map +1 -1
- package/dist/esm/resources/classes/terminology.d.ts +8 -1
- package/dist/esm/resources/classes/terminology.js +9 -0
- package/dist/esm/resources/classes/terminology.js.map +1 -1
- package/dist/esm/resources/classes/z3.d.ts +8 -1
- package/dist/esm/resources/classes/z3.js +9 -0
- package/dist/esm/resources/classes/z3.js.map +1 -1
- package/dist/esm/resources/types/ErxGetMedicationHistoryResponse.d.ts +1 -1
- package/dist/esm/resources/types/ErxGetPharmacyParams.d.ts +3 -0
- package/dist/esm/resources/types/ErxGetPharmacyResponse.d.ts +16 -0
- package/dist/esm/resources/types/ErxSearchPharmaciesResponse.d.ts +2 -2
- package/dist/esm/resources/types/LabOrderSubmitParams.d.ts +4 -0
- package/dist/esm/resources/types/RcmProcessEraParams.d.ts +6 -0
- package/dist/esm/resources/types/RcmProcessEraResponse.d.ts +5 -0
- package/dist/esm/resources/types/TerminologySearchIcd10Params.d.ts +9 -0
- package/dist/esm/resources/types/TerminologySearchIcd10Response.d.ts +27 -0
- package/dist/esm/resources/types/Z3EmptyBucketParams.d.ts +3 -0
- package/dist/esm/resources/types/Z3EmptyBucketResponse.d.ts +9 -0
- package/dist/esm/resources/types/index.d.ts +8 -0
- package/package.json +1 -1
- package/src/resources/classes/erx.ts +10 -0
- package/src/resources/classes/fhir.ts +31 -0
- package/src/resources/classes/rcm.ts +11 -0
- package/src/resources/classes/terminology.ts +14 -0
- package/src/resources/classes/z3.ts +11 -0
- package/src/resources/types/ErxGetMedicationHistoryResponse.ts +1 -1
- package/src/resources/types/ErxGetPharmacyParams.ts +5 -0
- package/src/resources/types/ErxGetPharmacyResponse.ts +18 -0
- package/src/resources/types/ErxSearchPharmaciesResponse.ts +2 -2
- package/src/resources/types/LabOrderSubmitParams.ts +4 -0
- package/src/resources/types/RcmProcessEraParams.ts +8 -0
- package/src/resources/types/RcmProcessEraResponse.ts +7 -0
- package/src/resources/types/TerminologySearchIcd10Params.ts +11 -0
- package/src/resources/types/TerminologySearchIcd10Response.ts +29 -0
- package/src/resources/types/Z3EmptyBucketParams.ts +5 -0
- package/src/resources/types/Z3EmptyBucketResponse.ts +11 -0
- package/src/resources/types/index.ts +8 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ErxAddPatientPharmacyParams, ErxCancelPrescriptionParams, ErxCheckAllergyInteractionsParams, ErxCheckAllergyInteractionsResponse, ErxCheckMedicationInteractionsParams, ErxCheckMedicationInteractionsResponse, ErxCheckPractitionerEnrollmentParams, ErxCheckPractitionerEnrollmentResponse, ErxCheckPrecheckInteractionsParams, ErxCheckPrecheckInteractionsResponse, ErxConnectPractitionerParams, ErxConnectPractitionerResponse, ErxEnrollPractitionerParams, ErxGetConfigurationResponse, ErxGetMedicationHistoryParams, ErxGetMedicationHistoryResponse, ErxGetMedicationParams, ErxGetMedicationResponse, ErxSearchAllergensParams, ErxSearchAllergensResponse, ErxSearchMedicationsParams, ErxSearchMedicationsResponse, ErxSearchPharmaciesParams, ErxSearchPharmaciesResponse, ErxSyncPatientParams, ErxUnenrollPractitionerParams, OystehrClientRequest } from '../..';
|
|
1
|
+
import { ErxAddPatientPharmacyParams, ErxCancelPrescriptionParams, ErxCheckAllergyInteractionsParams, ErxCheckAllergyInteractionsResponse, ErxCheckMedicationInteractionsParams, ErxCheckMedicationInteractionsResponse, ErxCheckPractitionerEnrollmentParams, ErxCheckPractitionerEnrollmentResponse, ErxCheckPrecheckInteractionsParams, ErxCheckPrecheckInteractionsResponse, ErxConnectPractitionerParams, ErxConnectPractitionerResponse, ErxEnrollPractitionerParams, ErxGetConfigurationResponse, ErxGetMedicationHistoryParams, ErxGetMedicationHistoryResponse, ErxGetMedicationParams, ErxGetMedicationResponse, ErxGetPharmacyParams, ErxGetPharmacyResponse, ErxSearchAllergensParams, ErxSearchAllergensResponse, ErxSearchMedicationsParams, ErxSearchMedicationsResponse, ErxSearchPharmaciesParams, ErxSearchPharmaciesResponse, ErxSyncPatientParams, ErxUnenrollPractitionerParams, OystehrClientRequest } from '../..';
|
|
2
2
|
import { SDKResource } from '../../client/client';
|
|
3
3
|
import { OystehrConfig } from '../../config';
|
|
4
4
|
export declare class Erx extends SDKResource {
|
|
@@ -88,6 +88,12 @@ export declare class Erx extends SDKResource {
|
|
|
88
88
|
* Access Policy Resource: `eRx:Pharmacy`
|
|
89
89
|
*/
|
|
90
90
|
searchPharmacies(request?: OystehrClientRequest): Promise<ErxSearchPharmaciesResponse>;
|
|
91
|
+
/**
|
|
92
|
+
* Get a pharmacy by its eRx pharmacy ID.
|
|
93
|
+
* Action: `eRx:GetPharmacy`
|
|
94
|
+
* Access Policy Resource: `eRx:Pharmacy`
|
|
95
|
+
*/
|
|
96
|
+
getPharmacy(params: ErxGetPharmacyParams, request?: OystehrClientRequest): Promise<ErxGetPharmacyResponse>;
|
|
91
97
|
/**
|
|
92
98
|
* Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.
|
|
93
99
|
* Action: `eRx:Connect`
|
|
@@ -104,6 +104,14 @@ class Erx extends SDKResource {
|
|
|
104
104
|
searchPharmacies(params, request) {
|
|
105
105
|
return this.request('/pharmacy', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
106
106
|
}
|
|
107
|
+
/**
|
|
108
|
+
* Get a pharmacy by its eRx pharmacy ID.
|
|
109
|
+
* Action: `eRx:GetPharmacy`
|
|
110
|
+
* Access Policy Resource: `eRx:Pharmacy`
|
|
111
|
+
*/
|
|
112
|
+
getPharmacy(params, request) {
|
|
113
|
+
return this.request('/pharmacy/{pharmacyId}', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
114
|
+
}
|
|
107
115
|
/**
|
|
108
116
|
* Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.
|
|
109
117
|
* Action: `eRx:Connect`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"erx.js","sources":["../../../../src/resources/classes/erx.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n ErxAddPatientPharmacyParams,\n ErxCancelPrescriptionParams,\n ErxCheckAllergyInteractionsParams,\n ErxCheckAllergyInteractionsResponse,\n ErxCheckMedicationInteractionsParams,\n ErxCheckMedicationInteractionsResponse,\n ErxCheckPractitionerEnrollmentParams,\n ErxCheckPractitionerEnrollmentResponse,\n ErxCheckPrecheckInteractionsParams,\n ErxCheckPrecheckInteractionsResponse,\n ErxConnectPractitionerParams,\n ErxConnectPractitionerResponse,\n ErxEnrollPractitionerParams,\n ErxGetConfigurationResponse,\n ErxGetMedicationHistoryParams,\n ErxGetMedicationHistoryResponse,\n ErxGetMedicationParams,\n ErxGetMedicationResponse,\n ErxSearchAllergensParams,\n ErxSearchAllergensResponse,\n ErxSearchMedicationsParams,\n ErxSearchMedicationsResponse,\n ErxSearchPharmaciesParams,\n ErxSearchPharmaciesResponse,\n ErxSyncPatientParams,\n ErxUnenrollPractitionerParams,\n OystehrClientRequest,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Erx extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['erxApiUrl'] ?? 'https://erx-api.zapehr.com/v3';\n }\n /**\n * Search for allergens.\n * Action: `eRx:SearchAllergen`\n * Access Policy Resource: `eRx:Allergen`\n */\n searchAllergens(\n params: ErxSearchAllergensParams,\n request?: OystehrClientRequest\n ): Promise<ErxSearchAllergensResponse> {\n return this.request('/allergen', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search for medications.\n * Action: `eRx:SearchMedication`\n * Access Policy Resource: `eRx:Medication`\n */\n searchMedications(\n params: ErxSearchMedicationsParams,\n request?: OystehrClientRequest\n ): Promise<ErxSearchMedicationsResponse> {\n return this.request('/medication', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get full medication details.\n * Action: `eRx:GetMedication`\n * Access Policy Resource: `eRx:Medication`\n */\n getMedication(params: ErxGetMedicationParams, request?: OystehrClientRequest): Promise<ErxGetMedicationResponse>;\n /**\n * Get full medication details.\n * Action: `eRx:GetMedication`\n * Access Policy Resource: `eRx:Medication`\n */\n getMedication(request?: OystehrClientRequest): Promise<ErxGetMedicationResponse>;\n /**\n * Get full medication details.\n * Action: `eRx:GetMedication`\n * Access Policy Resource: `eRx:Medication`\n */\n getMedication(\n params?: ErxGetMedicationParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<ErxGetMedicationResponse> {\n return this.request('/medication/details', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get eRx configuration for project.\n * Action: `eRx:GetConfiguration`\n * Access Policy Resource: `eRx:Configuration`\n */\n getConfiguration(request?: OystehrClientRequest): Promise<ErxGetConfigurationResponse> {\n return this.request('/config', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Check for drug-allergy interactions for a patient. This endpoint requires the patient's allergies to be synced with the upstream eRx provider.\n * Action: `eRx:Check`\n * Access Policy Resource: `eRx:Interaction`\n */\n checkAllergyInteractions(\n params: ErxCheckAllergyInteractionsParams,\n request?: OystehrClientRequest\n ): Promise<ErxCheckAllergyInteractionsResponse> {\n return this.request(\n '/patient/{patientId}/interactions/allergy',\n 'get',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Check for drug-drug interactions for a patient. This endpoint requires the patient's medications to be synced with the upstream eRx provider.\n * Action: `eRx:Check`\n * Access Policy Resource: `eRx:Interaction`\n */\n checkMedicationInteractions(\n params: ErxCheckMedicationInteractionsParams,\n request?: OystehrClientRequest\n ): Promise<ErxCheckMedicationInteractionsResponse> {\n return this.request(\n '/patient/{patientId}/interactions/medication',\n 'get',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Check for drug-allergy and drug-drug interactions with a specific drug for a patient. This endpoint requires the patient's allergies and medications to be synced with the upstream eRx provider.\n * Action: `eRx:Check`\n * Access Policy Resource: `eRx:Interaction`\n */\n checkPrecheckInteractions(\n params: ErxCheckPrecheckInteractionsParams,\n request?: OystehrClientRequest\n ): Promise<ErxCheckPrecheckInteractionsResponse> {\n return this.request(\n '/patient/{patientId}/interactions/precheck/{drugId}',\n 'get',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Retrieve claims-based medication history for a patient. This endpoint requires the patient to be synced with the upstream eRx provider.\n * Action: `eRx:GetMedicationHistory`\n * Access Policy Resource: `eRx:Patient`\n */\n getMedicationHistory(\n params: ErxGetMedicationHistoryParams,\n request?: OystehrClientRequest\n ): Promise<ErxGetMedicationHistoryResponse> {\n return this.request(\n '/patient/{patientId}/medication-history',\n 'get',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Adds pharmacy for a patient with the upstream eRx provider, setting it as primary if specified.\n * Action: `eRx:AddPatientPharmacy`\n * Access Policy Resource: `eRx:Patient`\n */\n addPatientPharmacy(params: ErxAddPatientPharmacyParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/patient/{patientId}/pharmacies', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Cancel prescription for patient.\n * Action: `eRx:CancelPrescription`\n * Access Policy Resource: `eRx:Prescription`\n */\n cancelPrescription(params: ErxCancelPrescriptionParams, request?: OystehrClientRequest): Promise<void> {\n return this.request(\n '/patient/{patientId}/prescriptions/{medicationRequestId}',\n 'delete',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Syncs demographic, allergy, and medication data for a patient with the upstream eRx provider.\n * Action: `eRx:SyncPatient`\n * Access Policy Resource: `eRx:Patient`\n */\n syncPatient(params: ErxSyncPatientParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/patient/{patientId}/sync', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search for pharmacies by a variety of criteria.\n * Action: `eRx:SearchPharmacy`\n * Access Policy Resource: `eRx:Pharmacy`\n */\n searchPharmacies(\n params: ErxSearchPharmaciesParams,\n request?: OystehrClientRequest\n ): Promise<ErxSearchPharmaciesResponse>;\n /**\n * Search for pharmacies by a variety of criteria.\n * Action: `eRx:SearchPharmacy`\n * Access Policy Resource: `eRx:Pharmacy`\n */\n searchPharmacies(request?: OystehrClientRequest): Promise<ErxSearchPharmaciesResponse>;\n /**\n * Search for pharmacies by a variety of criteria.\n * Action: `eRx:SearchPharmacy`\n * Access Policy Resource: `eRx:Pharmacy`\n */\n searchPharmacies(\n params?: ErxSearchPharmaciesParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<ErxSearchPharmaciesResponse> {\n return this.request('/pharmacy', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.\n * Action: `eRx:Connect`\n * Access Policy Resource: `eRx:SSO`\n */\n connectPractitioner(\n params: ErxConnectPractitionerParams,\n request?: OystehrClientRequest\n ): Promise<ErxConnectPractitionerResponse>;\n /**\n * Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.\n * Action: `eRx:Connect`\n * Access Policy Resource: `eRx:SSO`\n */\n connectPractitioner(request?: OystehrClientRequest): Promise<ErxConnectPractitionerResponse>;\n /**\n * Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.\n * Action: `eRx:Connect`\n * Access Policy Resource: `eRx:SSO`\n */\n connectPractitioner(\n params?: ErxConnectPractitionerParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<ErxConnectPractitionerResponse> {\n return this.request('/practitioner/connect', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Check eRx enrollment and notifications for a practitioner.\n * Action: `eRx:Read`\n * Access Policy Resource: `eRx:Enrollment`\n */\n checkPractitionerEnrollment(\n params: ErxCheckPractitionerEnrollmentParams,\n request?: OystehrClientRequest\n ): Promise<ErxCheckPractitionerEnrollmentResponse> {\n return this.request('/practitioner/{practitionerId}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Enroll a practitioner in the eRx service.\n * Action: `eRx:Create`\n * Access Policy Resource: `eRx:Enrollment`\n */\n enrollPractitioner(params: ErxEnrollPractitionerParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/practitioner/{practitionerId}', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Unenroll a practitioner from the eRx service.\n * Action: `eRx:Delete`\n * Access Policy Resource: `eRx:Enrollment`\n */\n unenrollPractitioner(params: ErxUnenrollPractitionerParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/practitioner/{practitionerId}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":";;AAAA;AAkCM,MAAO,GAAI,SAAQ,WAAW,CAAA;AAClC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,WAAW,CAAC,IAAI,+BAA+B;IAC/E;AACA;;;;AAIG;IACH,eAAe,CACb,MAAgC,EAChC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACzF;AACA;;;;AAIG;IACH,iBAAiB,CACf,MAAkC,EAClC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC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AIG;IACH,2BAA2B,CACzB,MAA4C,EAC5C,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC9G;AACA;;;;AAIG;IACH,kBAAkB,CAAC,MAAmC,EAAE,OAA8B,EAAA;QACpF,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC/G;AACA;;;;AAIG;IACH,oBAAoB,CAAC,MAAqC,EAAE,OAA8B,EAAA;QACxF,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACjH;AACD;;;;"}
|
|
1
|
+
{"version":3,"file":"erx.js","sources":["../../../../src/resources/classes/erx.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n ErxAddPatientPharmacyParams,\n ErxCancelPrescriptionParams,\n ErxCheckAllergyInteractionsParams,\n ErxCheckAllergyInteractionsResponse,\n ErxCheckMedicationInteractionsParams,\n ErxCheckMedicationInteractionsResponse,\n ErxCheckPractitionerEnrollmentParams,\n ErxCheckPractitionerEnrollmentResponse,\n ErxCheckPrecheckInteractionsParams,\n ErxCheckPrecheckInteractionsResponse,\n ErxConnectPractitionerParams,\n ErxConnectPractitionerResponse,\n ErxEnrollPractitionerParams,\n ErxGetConfigurationResponse,\n ErxGetMedicationHistoryParams,\n ErxGetMedicationHistoryResponse,\n ErxGetMedicationParams,\n ErxGetMedicationResponse,\n ErxGetPharmacyParams,\n ErxGetPharmacyResponse,\n ErxSearchAllergensParams,\n ErxSearchAllergensResponse,\n ErxSearchMedicationsParams,\n ErxSearchMedicationsResponse,\n ErxSearchPharmaciesParams,\n ErxSearchPharmaciesResponse,\n ErxSyncPatientParams,\n ErxUnenrollPractitionerParams,\n OystehrClientRequest,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Erx extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['erxApiUrl'] ?? 'https://erx-api.zapehr.com/v3';\n }\n /**\n * Search for allergens.\n * Action: `eRx:SearchAllergen`\n * Access Policy Resource: `eRx:Allergen`\n */\n searchAllergens(\n params: ErxSearchAllergensParams,\n request?: OystehrClientRequest\n ): Promise<ErxSearchAllergensResponse> {\n return this.request('/allergen', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search for medications.\n * Action: `eRx:SearchMedication`\n * Access Policy Resource: `eRx:Medication`\n */\n searchMedications(\n params: ErxSearchMedicationsParams,\n request?: OystehrClientRequest\n ): Promise<ErxSearchMedicationsResponse> {\n return this.request('/medication', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get full medication details.\n * Action: `eRx:GetMedication`\n * Access Policy Resource: `eRx:Medication`\n */\n getMedication(params: ErxGetMedicationParams, request?: OystehrClientRequest): Promise<ErxGetMedicationResponse>;\n /**\n * Get full medication details.\n * Action: `eRx:GetMedication`\n * Access Policy Resource: `eRx:Medication`\n */\n getMedication(request?: OystehrClientRequest): Promise<ErxGetMedicationResponse>;\n /**\n * Get full medication details.\n * Action: `eRx:GetMedication`\n * Access Policy Resource: `eRx:Medication`\n */\n getMedication(\n params?: ErxGetMedicationParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<ErxGetMedicationResponse> {\n return this.request('/medication/details', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get eRx configuration for project.\n * Action: `eRx:GetConfiguration`\n * Access Policy Resource: `eRx:Configuration`\n */\n getConfiguration(request?: OystehrClientRequest): Promise<ErxGetConfigurationResponse> {\n return this.request('/config', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Check for drug-allergy interactions for a patient. This endpoint requires the patient's allergies to be synced with the upstream eRx provider.\n * Action: `eRx:Check`\n * Access Policy Resource: `eRx:Interaction`\n */\n checkAllergyInteractions(\n params: ErxCheckAllergyInteractionsParams,\n request?: OystehrClientRequest\n ): Promise<ErxCheckAllergyInteractionsResponse> {\n return this.request(\n '/patient/{patientId}/interactions/allergy',\n 'get',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Check for drug-drug interactions for a patient. This endpoint requires the patient's medications to be synced with the upstream eRx provider.\n * Action: `eRx:Check`\n * Access Policy Resource: `eRx:Interaction`\n */\n checkMedicationInteractions(\n params: ErxCheckMedicationInteractionsParams,\n request?: OystehrClientRequest\n ): Promise<ErxCheckMedicationInteractionsResponse> {\n return this.request(\n '/patient/{patientId}/interactions/medication',\n 'get',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Check for drug-allergy and drug-drug interactions with a specific drug for a patient. This endpoint requires the patient's allergies and medications to be synced with the upstream eRx provider.\n * Action: `eRx:Check`\n * Access Policy Resource: `eRx:Interaction`\n */\n checkPrecheckInteractions(\n params: ErxCheckPrecheckInteractionsParams,\n request?: OystehrClientRequest\n ): Promise<ErxCheckPrecheckInteractionsResponse> {\n return this.request(\n '/patient/{patientId}/interactions/precheck/{drugId}',\n 'get',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Retrieve claims-based medication history for a patient. This endpoint requires the patient to be synced with the upstream eRx provider.\n * Action: `eRx:GetMedicationHistory`\n * Access Policy Resource: `eRx:Patient`\n */\n getMedicationHistory(\n params: ErxGetMedicationHistoryParams,\n request?: OystehrClientRequest\n ): Promise<ErxGetMedicationHistoryResponse> {\n return this.request(\n '/patient/{patientId}/medication-history',\n 'get',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Adds pharmacy for a patient with the upstream eRx provider, setting it as primary if specified.\n * Action: `eRx:AddPatientPharmacy`\n * Access Policy Resource: `eRx:Patient`\n */\n addPatientPharmacy(params: ErxAddPatientPharmacyParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/patient/{patientId}/pharmacies', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Cancel prescription for patient.\n * Action: `eRx:CancelPrescription`\n * Access Policy Resource: `eRx:Prescription`\n */\n cancelPrescription(params: ErxCancelPrescriptionParams, request?: OystehrClientRequest): Promise<void> {\n return this.request(\n '/patient/{patientId}/prescriptions/{medicationRequestId}',\n 'delete',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Syncs demographic, allergy, and medication data for a patient with the upstream eRx provider.\n * Action: `eRx:SyncPatient`\n * Access Policy Resource: `eRx:Patient`\n */\n syncPatient(params: ErxSyncPatientParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/patient/{patientId}/sync', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search for pharmacies by a variety of criteria.\n * Action: `eRx:SearchPharmacy`\n * Access Policy Resource: `eRx:Pharmacy`\n */\n searchPharmacies(\n params: ErxSearchPharmaciesParams,\n request?: OystehrClientRequest\n ): Promise<ErxSearchPharmaciesResponse>;\n /**\n * Search for pharmacies by a variety of criteria.\n * Action: `eRx:SearchPharmacy`\n * Access Policy Resource: `eRx:Pharmacy`\n */\n searchPharmacies(request?: OystehrClientRequest): Promise<ErxSearchPharmaciesResponse>;\n /**\n * Search for pharmacies by a variety of criteria.\n * Action: `eRx:SearchPharmacy`\n * Access Policy Resource: `eRx:Pharmacy`\n */\n searchPharmacies(\n params?: ErxSearchPharmaciesParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<ErxSearchPharmaciesResponse> {\n return this.request('/pharmacy', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get a pharmacy by its eRx pharmacy ID.\n * Action: `eRx:GetPharmacy`\n * Access Policy Resource: `eRx:Pharmacy`\n */\n getPharmacy(params: ErxGetPharmacyParams, request?: OystehrClientRequest): Promise<ErxGetPharmacyResponse> {\n return this.request('/pharmacy/{pharmacyId}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.\n * Action: `eRx:Connect`\n * Access Policy Resource: `eRx:SSO`\n */\n connectPractitioner(\n params: ErxConnectPractitionerParams,\n request?: OystehrClientRequest\n ): Promise<ErxConnectPractitionerResponse>;\n /**\n * Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.\n * Action: `eRx:Connect`\n * Access Policy Resource: `eRx:SSO`\n */\n connectPractitioner(request?: OystehrClientRequest): Promise<ErxConnectPractitionerResponse>;\n /**\n * Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.\n * Action: `eRx:Connect`\n * Access Policy Resource: `eRx:SSO`\n */\n connectPractitioner(\n params?: ErxConnectPractitionerParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<ErxConnectPractitionerResponse> {\n return this.request('/practitioner/connect', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Check eRx enrollment and notifications for a practitioner.\n * Action: `eRx:Read`\n * Access Policy Resource: `eRx:Enrollment`\n */\n checkPractitionerEnrollment(\n params: ErxCheckPractitionerEnrollmentParams,\n request?: OystehrClientRequest\n ): Promise<ErxCheckPractitionerEnrollmentResponse> {\n return this.request('/practitioner/{practitionerId}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Enroll a practitioner in the eRx service.\n * Action: `eRx:Create`\n * Access Policy Resource: `eRx:Enrollment`\n */\n enrollPractitioner(params: ErxEnrollPractitionerParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/practitioner/{practitionerId}', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Unenroll a practitioner from the eRx service.\n * Action: `eRx:Delete`\n * Access Policy Resource: `eRx:Enrollment`\n */\n unenrollPractitioner(params: ErxUnenrollPractitionerParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/practitioner/{practitionerId}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":";;AAAA;AAoCM,MAAO,GAAI,SAAQ,WAAW,CAAA;AAClC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,WAAW,CAAC,IAAI,+BAA+B;IAC/E;AACA;;;;AAIG;IACH,eAAe,CACb,MAAgC,EAChC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,WAAW,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACzF;AACA;;;;AAIG;IACH,iBAAiB,CACf,MAAkC,EAClC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3F;AAaA;;;;AAIG;IACH,aAAa,CACX,MAAsD,EACtD,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,qBAAqB,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACnG;AACA;;;;AAIG;AACH,IAAA,gBAAgB,CAAC,OAA8B,EAAA;QAC7C,OAAO,IAAI,CAAC,OAAO,CAAC,SAAS,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC;IAC/E;AACA;;;;AAIG;IACH,wBAAwB,C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,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC/G;AACA;;;;AAIG;IACH,oBAAoB,CAAC,MAAqC,EAAE,OAA8B,EAAA;QACxF,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACjH;AACD;;;;"}
|
|
@@ -25,9 +25,40 @@ export declare class Fhir extends SDKResource {
|
|
|
25
25
|
update: typeof ext.update;
|
|
26
26
|
patch: typeof ext.patch;
|
|
27
27
|
delete: typeof ext.delete;
|
|
28
|
+
/**
|
|
29
|
+
* Fetches the status of an async job. If the job is still in progress, returns an object with status 202. If the job is completed, returns the job result with status 200. If the job has failed, returns an object with status 500 and an OperationOutcome resource describing the failure. If the job has expired, returns an object with status 410.
|
|
30
|
+
* @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.getAsyncJob(jobId)`)
|
|
31
|
+
* @param jobId The ID of the async job to fetch
|
|
32
|
+
* @param request Optional OystehrClientRequest for authentication and headers
|
|
33
|
+
* @returns A Promise that resolves to the FhirAsyncJobStatus
|
|
34
|
+
*/
|
|
28
35
|
getAsyncJob: typeof ext.getAsyncJob;
|
|
36
|
+
/**
|
|
37
|
+
* Waits for an async job to complete by polling its status until it reaches a terminal state (success, failure, or expiration) or the specified timeout is reached. Returns the final job status. Throws if the job fails, expires, or does not complete within the timeout.
|
|
38
|
+
* @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncJob(jobId)`)
|
|
39
|
+
* @param jobId The ID of the async job to wait for
|
|
40
|
+
* @param options Optional FhirAsyncWaitOptions to configure polling behavior
|
|
41
|
+
* @param request Optional OystehrClientRequest for authentication and headers
|
|
42
|
+
* @returns A Promise that resolves to the final FhirAsyncJobStatus
|
|
43
|
+
*/
|
|
29
44
|
waitForAsyncJob: typeof ext.waitForAsyncJob;
|
|
45
|
+
/**
|
|
46
|
+
* Waits for an async job to complete and retrieves the bulk output manifest and files. Throws if the job fails, expires, or does not complete within the specified timeout.
|
|
47
|
+
* @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncBulkOutput(jobId)`)
|
|
48
|
+
* @param jobId The ID of the async job to wait for
|
|
49
|
+
* @param options Optional FhirAsyncWaitOptions to configure polling behavior
|
|
50
|
+
* @param request Optional OystehrClientRequest for authentication and headers
|
|
51
|
+
* @returns A Promise that resolves to a FhirAsyncBulkOutputResult containing the bulk output manifest and files
|
|
52
|
+
*/
|
|
30
53
|
waitForAsyncBulkOutput: typeof ext.waitForAsyncBulkOutput;
|
|
54
|
+
/**
|
|
55
|
+
* Wrapper around waitForAsyncBulkOutput that transforms the retrieved bulk output files into a single Bundle resource containing all the output resources as entries. This is a convenience method for use cases where you want to work with the bulk output as a Bundle, but it may not be efficient for large outputs due to the overhead of downloading and parsing all files and constructing the Bundle in memory.
|
|
56
|
+
* Can be slow due to downloading and parsing potentially large NDJSON files, so use only if you need the full output as a Bundle resource. For more efficient processing of large bulk outputs, use waitForAsyncBulkOutput directly.
|
|
57
|
+
* @param jobId the ID of the async job to wait for
|
|
58
|
+
* @param options optional FhirAsyncWaitOptions to configure polling behavior
|
|
59
|
+
* @param request optional OystehrClientRequest for authentication and headers
|
|
60
|
+
* @returns a Promise that resolves to a Bundle containing all resources from the bulk output
|
|
61
|
+
*/
|
|
31
62
|
waitForAsyncBulkBundle: typeof ext.waitForAsyncBulkBundle;
|
|
32
63
|
cancelAsyncJob: typeof ext.cancelAsyncJob;
|
|
33
64
|
history: typeof ext.history;
|
|
@@ -30,9 +30,40 @@ class Fhir extends SDKResource {
|
|
|
30
30
|
update = update;
|
|
31
31
|
patch = patch;
|
|
32
32
|
delete = del;
|
|
33
|
+
/**
|
|
34
|
+
* Fetches the status of an async job. If the job is still in progress, returns an object with status 202. If the job is completed, returns the job result with status 200. If the job has failed, returns an object with status 500 and an OperationOutcome resource describing the failure. If the job has expired, returns an object with status 410.
|
|
35
|
+
* @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.getAsyncJob(jobId)`)
|
|
36
|
+
* @param jobId The ID of the async job to fetch
|
|
37
|
+
* @param request Optional OystehrClientRequest for authentication and headers
|
|
38
|
+
* @returns A Promise that resolves to the FhirAsyncJobStatus
|
|
39
|
+
*/
|
|
33
40
|
getAsyncJob = getAsyncJob;
|
|
41
|
+
/**
|
|
42
|
+
* Waits for an async job to complete by polling its status until it reaches a terminal state (success, failure, or expiration) or the specified timeout is reached. Returns the final job status. Throws if the job fails, expires, or does not complete within the timeout.
|
|
43
|
+
* @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncJob(jobId)`)
|
|
44
|
+
* @param jobId The ID of the async job to wait for
|
|
45
|
+
* @param options Optional FhirAsyncWaitOptions to configure polling behavior
|
|
46
|
+
* @param request Optional OystehrClientRequest for authentication and headers
|
|
47
|
+
* @returns A Promise that resolves to the final FhirAsyncJobStatus
|
|
48
|
+
*/
|
|
34
49
|
waitForAsyncJob = waitForAsyncJob;
|
|
50
|
+
/**
|
|
51
|
+
* Waits for an async job to complete and retrieves the bulk output manifest and files. Throws if the job fails, expires, or does not complete within the specified timeout.
|
|
52
|
+
* @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncBulkOutput(jobId)`)
|
|
53
|
+
* @param jobId The ID of the async job to wait for
|
|
54
|
+
* @param options Optional FhirAsyncWaitOptions to configure polling behavior
|
|
55
|
+
* @param request Optional OystehrClientRequest for authentication and headers
|
|
56
|
+
* @returns A Promise that resolves to a FhirAsyncBulkOutputResult containing the bulk output manifest and files
|
|
57
|
+
*/
|
|
35
58
|
waitForAsyncBulkOutput = waitForAsyncBulkOutput;
|
|
59
|
+
/**
|
|
60
|
+
* Wrapper around waitForAsyncBulkOutput that transforms the retrieved bulk output files into a single Bundle resource containing all the output resources as entries. This is a convenience method for use cases where you want to work with the bulk output as a Bundle, but it may not be efficient for large outputs due to the overhead of downloading and parsing all files and constructing the Bundle in memory.
|
|
61
|
+
* Can be slow due to downloading and parsing potentially large NDJSON files, so use only if you need the full output as a Bundle resource. For more efficient processing of large bulk outputs, use waitForAsyncBulkOutput directly.
|
|
62
|
+
* @param jobId the ID of the async job to wait for
|
|
63
|
+
* @param options optional FhirAsyncWaitOptions to configure polling behavior
|
|
64
|
+
* @param request optional OystehrClientRequest for authentication and headers
|
|
65
|
+
* @returns a Promise that resolves to a Bundle containing all resources from the bulk output
|
|
66
|
+
*/
|
|
36
67
|
waitForAsyncBulkBundle = waitForAsyncBulkBundle;
|
|
37
68
|
cancelAsyncJob = cancelAsyncJob;
|
|
38
69
|
history = history;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fhir.js","sources":["../../../../src/resources/classes/fhir.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './fhir-ext';\n\nexport class Fhir extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['fhirApiUrl'] ?? 'https://fhir-api.zapehr.com';\n }\n /**\n * Performs a FHIR search and returns the results as a Bundle resource\n * @param options FHIR resource type and FHIR search parameters\n * @param request optional OystehrClientRequest object\n * @returns FHIR Bundle resource\n */\n search = ext.search;\n /**\n * Performs an iterative FHIR search over initial request and following \"next\" urls,\n * collecting all pages into a single Bundle.\n * @param params FHIR search parameters plus optional pageSize that will overwrite _count in params\n * @param request optional OystehrClientRequest object\n * @returns FHIR Bundle resource that contains all entries across all pages. Bundle-level metadata\n * (id, meta, total, etc.) is taken from the first page.\n */\n searchAndGetAllPages = ext.searchAndGetAllPages;\n create = ext.create;\n get = ext.get;\n update = ext.update;\n patch = ext.patch;\n delete = ext.delete;\n getAsyncJob = ext.getAsyncJob;\n waitForAsyncJob = ext.waitForAsyncJob;\n waitForAsyncBulkOutput = ext.waitForAsyncBulkOutput;\n waitForAsyncBulkBundle = ext.waitForAsyncBulkBundle;\n cancelAsyncJob = ext.cancelAsyncJob;\n history = ext.history;\n batch = ext.batch;\n transaction = ext.transaction;\n generateFriendlyPatientId = ext.generateFriendlyPatientId;\n formatAddress = ext.formatAddress;\n formatHumanName = ext.formatHumanName;\n}\n"],"names":["ext.search","ext.searchAndGetAllPages","ext.create","ext.get","ext.update","ext.patch","ext.delete","ext.getAsyncJob","ext.waitForAsyncJob","ext.waitForAsyncBulkOutput","ext.waitForAsyncBulkBundle","ext.cancelAsyncJob","ext.history","ext.batch","ext.transaction","ext.generateFriendlyPatientId","ext.formatAddress","ext.formatHumanName"],"mappings":";;;AAAA;AAMM,MAAO,IAAK,SAAQ,WAAW,CAAA;AACnC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,YAAY,CAAC,IAAI,6BAA6B;IAC9E;AACA;;;;;AAKG;AACH,IAAA,MAAM,GAAGA,MAAU;AACnB;;;;;;;AAOG;AACH,IAAA,oBAAoB,GAAGC,oBAAwB;AAC/C,IAAA,MAAM,GAAGC,MAAU;AACnB,IAAA,GAAG,GAAGC,GAAO;AACb,IAAA,MAAM,GAAGC,MAAU;AACnB,IAAA,KAAK,GAAGC,KAAS;AACjB,IAAA,MAAM,GAAGC,GAAU;AACnB,IAAA,WAAW,GAAGC,WAAe;AAC7B,IAAA,eAAe,GAAGC,eAAmB;AACrC,IAAA,sBAAsB,GAAGC,sBAA0B;AACnD,IAAA,sBAAsB,GAAGC,sBAA0B;AACnD,IAAA,cAAc,GAAGC,cAAkB;AACnC,IAAA,OAAO,GAAGC,OAAW;AACrB,IAAA,KAAK,GAAGC,KAAS;AACjB,IAAA,WAAW,GAAGC,WAAe;AAC7B,IAAA,yBAAyB,GAAGC,yBAA6B;AACzD,IAAA,aAAa,GAAGC,aAAiB;AACjC,IAAA,eAAe,GAAGC,eAAmB;AACtC;;;;"}
|
|
1
|
+
{"version":3,"file":"fhir.js","sources":["../../../../src/resources/classes/fhir.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './fhir-ext';\n\nexport class Fhir extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['fhirApiUrl'] ?? 'https://fhir-api.zapehr.com';\n }\n /**\n * Performs a FHIR search and returns the results as a Bundle resource\n * @param options FHIR resource type and FHIR search parameters\n * @param request optional OystehrClientRequest object\n * @returns FHIR Bundle resource\n */\n search = ext.search;\n /**\n * Performs an iterative FHIR search over initial request and following \"next\" urls,\n * collecting all pages into a single Bundle.\n * @param params FHIR search parameters plus optional pageSize that will overwrite _count in params\n * @param request optional OystehrClientRequest object\n * @returns FHIR Bundle resource that contains all entries across all pages. Bundle-level metadata\n * (id, meta, total, etc.) is taken from the first page.\n */\n searchAndGetAllPages = ext.searchAndGetAllPages;\n create = ext.create;\n get = ext.get;\n update = ext.update;\n patch = ext.patch;\n delete = ext.delete;\n /**\n * Fetches the status of an async job. If the job is still in progress, returns an object with status 202. If the job is completed, returns the job result with status 200. If the job has failed, returns an object with status 500 and an OperationOutcome resource describing the failure. If the job has expired, returns an object with status 410.\n * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.getAsyncJob(jobId)`)\n * @param jobId The ID of the async job to fetch\n * @param request Optional OystehrClientRequest for authentication and headers\n * @returns A Promise that resolves to the FhirAsyncJobStatus\n */\n getAsyncJob = ext.getAsyncJob;\n /**\n * Waits for an async job to complete by polling its status until it reaches a terminal state (success, failure, or expiration) or the specified timeout is reached. Returns the final job status. Throws if the job fails, expires, or does not complete within the timeout.\n * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncJob(jobId)`)\n * @param jobId The ID of the async job to wait for\n * @param options Optional FhirAsyncWaitOptions to configure polling behavior\n * @param request Optional OystehrClientRequest for authentication and headers\n * @returns A Promise that resolves to the final FhirAsyncJobStatus\n */\n waitForAsyncJob = ext.waitForAsyncJob;\n /**\n * Waits for an async job to complete and retrieves the bulk output manifest and files. Throws if the job fails, expires, or does not complete within the specified timeout.\n * @param this The SDKResource context (this is an extension method and should be called with the SDKResource instance as the context, e.g. `sdkResource.waitForAsyncBulkOutput(jobId)`)\n * @param jobId The ID of the async job to wait for\n * @param options Optional FhirAsyncWaitOptions to configure polling behavior\n * @param request Optional OystehrClientRequest for authentication and headers\n * @returns A Promise that resolves to a FhirAsyncBulkOutputResult containing the bulk output manifest and files\n */\n waitForAsyncBulkOutput = ext.waitForAsyncBulkOutput;\n /**\n * Wrapper around waitForAsyncBulkOutput that transforms the retrieved bulk output files into a single Bundle resource containing all the output resources as entries. This is a convenience method for use cases where you want to work with the bulk output as a Bundle, but it may not be efficient for large outputs due to the overhead of downloading and parsing all files and constructing the Bundle in memory.\n * Can be slow due to downloading and parsing potentially large NDJSON files, so use only if you need the full output as a Bundle resource. For more efficient processing of large bulk outputs, use waitForAsyncBulkOutput directly.\n * @param jobId the ID of the async job to wait for\n * @param options optional FhirAsyncWaitOptions to configure polling behavior\n * @param request optional OystehrClientRequest for authentication and headers\n * @returns a Promise that resolves to a Bundle containing all resources from the bulk output\n */\n waitForAsyncBulkBundle = ext.waitForAsyncBulkBundle;\n cancelAsyncJob = ext.cancelAsyncJob;\n history = ext.history;\n batch = ext.batch;\n transaction = ext.transaction;\n generateFriendlyPatientId = ext.generateFriendlyPatientId;\n formatAddress = ext.formatAddress;\n formatHumanName = ext.formatHumanName;\n}\n"],"names":["ext.search","ext.searchAndGetAllPages","ext.create","ext.get","ext.update","ext.patch","ext.delete","ext.getAsyncJob","ext.waitForAsyncJob","ext.waitForAsyncBulkOutput","ext.waitForAsyncBulkBundle","ext.cancelAsyncJob","ext.history","ext.batch","ext.transaction","ext.generateFriendlyPatientId","ext.formatAddress","ext.formatHumanName"],"mappings":";;;AAAA;AAMM,MAAO,IAAK,SAAQ,WAAW,CAAA;AACnC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,YAAY,CAAC,IAAI,6BAA6B;IAC9E;AACA;;;;;AAKG;AACH,IAAA,MAAM,GAAGA,MAAU;AACnB;;;;;;;AAOG;AACH,IAAA,oBAAoB,GAAGC,oBAAwB;AAC/C,IAAA,MAAM,GAAGC,MAAU;AACnB,IAAA,GAAG,GAAGC,GAAO;AACb,IAAA,MAAM,GAAGC,MAAU;AACnB,IAAA,KAAK,GAAGC,KAAS;AACjB,IAAA,MAAM,GAAGC,GAAU;AACnB;;;;;;AAMG;AACH,IAAA,WAAW,GAAGC,WAAe;AAC7B;;;;;;;AAOG;AACH,IAAA,eAAe,GAAGC,eAAmB;AACrC;;;;;;;AAOG;AACH,IAAA,sBAAsB,GAAGC,sBAA0B;AACnD;;;;;;;AAOG;AACH,IAAA,sBAAsB,GAAGC,sBAA0B;AACnD,IAAA,cAAc,GAAGC,cAAkB;AACnC,IAAA,OAAO,GAAGC,OAAW;AACrB,IAAA,KAAK,GAAGC,KAAS;AACjB,IAAA,WAAW,GAAGC,WAAe;AAC7B,IAAA,yBAAyB,GAAGC,yBAA6B;AACzD,IAAA,aAAa,GAAGC,aAAiB;AACjC,IAAA,eAAe,GAAGC,eAAmB;AACtC;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { OystehrClientRequest, RcmEligibilityCheckParams, RcmEligibilityCheckResponse, RcmGetPayerParams, RcmGetPayerResponse, RcmListPayersParams, RcmListPayersResponse, RcmSetClaimStatusParams, RcmSetClaimStatusResponse, RcmSubmitClaimParams, RcmSubmitClaimResponse } from '../..';
|
|
1
|
+
import { OystehrClientRequest, RcmEligibilityCheckParams, RcmEligibilityCheckResponse, RcmGetPayerParams, RcmGetPayerResponse, RcmListPayersParams, RcmListPayersResponse, RcmProcessEraParams, RcmProcessEraResponse, RcmSetClaimStatusParams, RcmSetClaimStatusResponse, RcmSubmitClaimParams, RcmSubmitClaimResponse } from '../..';
|
|
2
2
|
import { SDKResource } from '../../client/client';
|
|
3
3
|
import { OystehrConfig } from '../../config';
|
|
4
4
|
import * as ext from './rcm-ext';
|
|
@@ -58,4 +58,11 @@ export declare class Rcm extends SDKResource {
|
|
|
58
58
|
* Access Policy Resource: `RCM:Payer`
|
|
59
59
|
*/
|
|
60
60
|
getPayer(params: RcmGetPayerParams, request?: OystehrClientRequest): Promise<RcmGetPayerResponse>;
|
|
61
|
+
/**
|
|
62
|
+
* Allows to manually process EDI835.
|
|
63
|
+
*
|
|
64
|
+
* Access Policy Action: `RCM:ProcessEra`
|
|
65
|
+
* Access Policy Resource: `RCM:Era`
|
|
66
|
+
*/
|
|
67
|
+
processEra(params: RcmProcessEraParams, request?: OystehrClientRequest): Promise<RcmProcessEraResponse>;
|
|
61
68
|
}
|
|
@@ -65,6 +65,15 @@ class Rcm extends SDKResource {
|
|
|
65
65
|
getPayer(params, request) {
|
|
66
66
|
return this.request('/payer/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
67
67
|
}
|
|
68
|
+
/**
|
|
69
|
+
* Allows to manually process EDI835.
|
|
70
|
+
*
|
|
71
|
+
* Access Policy Action: `RCM:ProcessEra`
|
|
72
|
+
* Access Policy Resource: `RCM:Era`
|
|
73
|
+
*/
|
|
74
|
+
processEra(params, request) {
|
|
75
|
+
return this.request('/process-era', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
76
|
+
}
|
|
68
77
|
}
|
|
69
78
|
|
|
70
79
|
export { Rcm };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rcm.js","sources":["../../../../src/resources/classes/rcm.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n RcmEligibilityCheckParams,\n RcmEligibilityCheckResponse,\n RcmGetPayerParams,\n RcmGetPayerResponse,\n RcmListPayersParams,\n RcmListPayersResponse,\n RcmSetClaimStatusParams,\n RcmSetClaimStatusResponse,\n RcmSubmitClaimParams,\n RcmSubmitClaimResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './rcm-ext';\n\nexport class Rcm extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['rcmApiUrl'] ?? 'https://rcm-api.zapehr.com/v1';\n }\n constructPayerUrl = ext.constructPayerUrl;\n getPayerByUrl = ext.getPayerByUrl;\n /**\n * Check [Insurance Eligibility](https://docs.oystehr.com/oystehr/services/rcm/eligibility/).\n *\n * Access Policy Action: `RCM:CheckInsuranceEligibility`\n * Access Policy Resource: `RCM:InsuranceEligibility`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:CoverageEligibilityResponse`\n */\n eligibilityCheck(\n params: RcmEligibilityCheckParams,\n request?: OystehrClientRequest\n ): Promise<RcmEligibilityCheckResponse> {\n return this.request('/eligibility-check', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Submit a claim to a payer.\n *\n * Access Policy Action: `RCM:SubmitClaim`\n * Access Policy Resource: `RCM:Claim`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:ClaimResponse`\n */\n submitClaim(params: RcmSubmitClaimParams, request?: OystehrClientRequest): Promise<RcmSubmitClaimResponse> {\n return this.request('/claim/{claimId}/submit', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Emulate asynchronous claim responses by manually setting claim status.\n *\n * Access Policy Action: `RCM:SubmitClaim`\n * Access Policy Resource: `RCM:Claim`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:ClaimResponse`\n */\n setClaimStatus(params: RcmSetClaimStatusParams, request?: OystehrClientRequest): Promise<RcmSetClaimStatusResponse> {\n return this.request('/claim/{claimId}/status', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(params: RcmListPayersParams, request?: OystehrClientRequest): Promise<RcmListPayersResponse>;\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(request?: OystehrClientRequest): Promise<RcmListPayersResponse>;\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(\n params?: RcmListPayersParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<RcmListPayersResponse> {\n return this.request('/payer', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Retrieve a payer by its ID.\n *\n * Access Policy Action: `RCM:GetPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n getPayer(params: RcmGetPayerParams, request?: OystehrClientRequest): Promise<RcmGetPayerResponse> {\n return this.request('/payer/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":["ext.constructPayerUrl","ext.getPayerByUrl"],"mappings":";;;AAAA;
|
|
1
|
+
{"version":3,"file":"rcm.js","sources":["../../../../src/resources/classes/rcm.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n RcmEligibilityCheckParams,\n RcmEligibilityCheckResponse,\n RcmGetPayerParams,\n RcmGetPayerResponse,\n RcmListPayersParams,\n RcmListPayersResponse,\n RcmProcessEraParams,\n RcmProcessEraResponse,\n RcmSetClaimStatusParams,\n RcmSetClaimStatusResponse,\n RcmSubmitClaimParams,\n RcmSubmitClaimResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './rcm-ext';\n\nexport class Rcm extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['rcmApiUrl'] ?? 'https://rcm-api.zapehr.com/v1';\n }\n constructPayerUrl = ext.constructPayerUrl;\n getPayerByUrl = ext.getPayerByUrl;\n /**\n * Check [Insurance Eligibility](https://docs.oystehr.com/oystehr/services/rcm/eligibility/).\n *\n * Access Policy Action: `RCM:CheckInsuranceEligibility`\n * Access Policy Resource: `RCM:InsuranceEligibility`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:CoverageEligibilityResponse`\n */\n eligibilityCheck(\n params: RcmEligibilityCheckParams,\n request?: OystehrClientRequest\n ): Promise<RcmEligibilityCheckResponse> {\n return this.request('/eligibility-check', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Submit a claim to a payer.\n *\n * Access Policy Action: `RCM:SubmitClaim`\n * Access Policy Resource: `RCM:Claim`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:ClaimResponse`\n */\n submitClaim(params: RcmSubmitClaimParams, request?: OystehrClientRequest): Promise<RcmSubmitClaimResponse> {\n return this.request('/claim/{claimId}/submit', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Emulate asynchronous claim responses by manually setting claim status.\n *\n * Access Policy Action: `RCM:SubmitClaim`\n * Access Policy Resource: `RCM:Claim`\n *\n * Access Policy Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:ClaimResponse`\n */\n setClaimStatus(params: RcmSetClaimStatusParams, request?: OystehrClientRequest): Promise<RcmSetClaimStatusResponse> {\n return this.request('/claim/{claimId}/status', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(params: RcmListPayersParams, request?: OystehrClientRequest): Promise<RcmListPayersResponse>;\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(request?: OystehrClientRequest): Promise<RcmListPayersResponse>;\n /**\n * Search for payers by name or identifier.\n *\n * Access Policy Action: `RCM:SearchPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n listPayers(\n params?: RcmListPayersParams | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<RcmListPayersResponse> {\n return this.request('/payer', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Retrieve a payer by its ID.\n *\n * Access Policy Action: `RCM:GetPayer`\n * Access Policy Resource: `RCM:Payer`\n */\n getPayer(params: RcmGetPayerParams, request?: OystehrClientRequest): Promise<RcmGetPayerResponse> {\n return this.request('/payer/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Allows to manually process EDI835.\n *\n * Access Policy Action: `RCM:ProcessEra`\n * Access Policy Resource: `RCM:Era`\n */\n processEra(params: RcmProcessEraParams, request?: OystehrClientRequest): Promise<RcmProcessEraResponse> {\n return this.request('/process-era', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":["ext.constructPayerUrl","ext.getPayerByUrl"],"mappings":";;;AAAA;AAqBM,MAAO,GAAI,SAAQ,WAAW,CAAA;AAClC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,WAAW,CAAC,IAAI,+BAA+B;IAC/E;AACA,IAAA,iBAAiB,GAAGA,iBAAqB;AACzC,IAAA,aAAa,GAAGC,aAAiB;AACjC;;;;;;;;AAQG;IACH,gBAAgB,CACd,MAAiC,EACjC,OAA8B,EAAA;QAE9B,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 -1,4 +1,4 @@
|
|
|
1
|
-
import { OystehrClientRequest, TerminologySearchCptParams, TerminologySearchCptResponse, TerminologySearchHcpcsParams, TerminologySearchHcpcsResponse } from '../..';
|
|
1
|
+
import { OystehrClientRequest, TerminologySearchCptParams, TerminologySearchCptResponse, TerminologySearchHcpcsParams, TerminologySearchHcpcsResponse, TerminologySearchIcd10Params, TerminologySearchIcd10Response } from '../..';
|
|
2
2
|
import { SDKResource } from '../../client/client';
|
|
3
3
|
import { OystehrConfig } from '../../config';
|
|
4
4
|
export declare class Terminology extends SDKResource {
|
|
@@ -18,4 +18,11 @@ export declare class Terminology extends SDKResource {
|
|
|
18
18
|
* Access Policy Resource: `Terminology:Code:*`
|
|
19
19
|
*/
|
|
20
20
|
searchHcpcs(params: TerminologySearchHcpcsParams, request?: OystehrClientRequest): Promise<TerminologySearchHcpcsResponse>;
|
|
21
|
+
/**
|
|
22
|
+
* Search ICD-10-CM (International Classification of Diseases, 10th Revision, Clinical Modification) diagnosis codes by code or description. Only billable (leaf-node) codes are returned, including codes expanded with their required seventh character. Supports exact matches, prefix searches, and full-text search with BM25 ranking.
|
|
23
|
+
*
|
|
24
|
+
* Access Policy Action: `Terminology:SearchCodes`
|
|
25
|
+
* Access Policy Resource: `Terminology:Code:*`
|
|
26
|
+
*/
|
|
27
|
+
searchIcd10(params: TerminologySearchIcd10Params, request?: OystehrClientRequest): Promise<TerminologySearchIcd10Response>;
|
|
21
28
|
}
|
|
@@ -26,6 +26,15 @@ class Terminology extends SDKResource {
|
|
|
26
26
|
searchHcpcs(params, request) {
|
|
27
27
|
return this.request('/hcpcs/search', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
28
28
|
}
|
|
29
|
+
/**
|
|
30
|
+
* Search ICD-10-CM (International Classification of Diseases, 10th Revision, Clinical Modification) diagnosis codes by code or description. Only billable (leaf-node) codes are returned, including codes expanded with their required seventh character. Supports exact matches, prefix searches, and full-text search with BM25 ranking.
|
|
31
|
+
*
|
|
32
|
+
* Access Policy Action: `Terminology:SearchCodes`
|
|
33
|
+
* Access Policy Resource: `Terminology:Code:*`
|
|
34
|
+
*/
|
|
35
|
+
searchIcd10(params, request) {
|
|
36
|
+
return this.request('/icd10/search', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
37
|
+
}
|
|
29
38
|
}
|
|
30
39
|
|
|
31
40
|
export { Terminology };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"terminology.js","sources":["../../../../src/resources/classes/terminology.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n TerminologySearchCptParams,\n TerminologySearchCptResponse,\n TerminologySearchHcpcsParams,\n TerminologySearchHcpcsResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Terminology extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['terminologyApiUrl'] ?? 'https://terminology-api.zapehr.com/v1';\n }\n /**\n * Search CPT (Current Procedural Terminology) codes by code or description. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchCpt(params: TerminologySearchCptParams, request?: OystehrClientRequest): Promise<TerminologySearchCptResponse> {\n return this.request('/cpt/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search HCPCS (Healthcare Common Procedure Coding System) Level II codes by code or description. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchHcpcs(\n params: TerminologySearchHcpcsParams,\n request?: OystehrClientRequest\n ): Promise<TerminologySearchHcpcsResponse> {\n return this.request('/hcpcs/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":";;AAAA;
|
|
1
|
+
{"version":3,"file":"terminology.js","sources":["../../../../src/resources/classes/terminology.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n TerminologySearchCptParams,\n TerminologySearchCptResponse,\n TerminologySearchHcpcsParams,\n TerminologySearchHcpcsResponse,\n TerminologySearchIcd10Params,\n TerminologySearchIcd10Response,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Terminology extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['terminologyApiUrl'] ?? 'https://terminology-api.zapehr.com/v1';\n }\n /**\n * Search CPT (Current Procedural Terminology) codes by code or description. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchCpt(params: TerminologySearchCptParams, request?: OystehrClientRequest): Promise<TerminologySearchCptResponse> {\n return this.request('/cpt/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search HCPCS (Healthcare Common Procedure Coding System) Level II codes by code or description. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchHcpcs(\n params: TerminologySearchHcpcsParams,\n request?: OystehrClientRequest\n ): Promise<TerminologySearchHcpcsResponse> {\n return this.request('/hcpcs/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Search ICD-10-CM (International Classification of Diseases, 10th Revision, Clinical Modification) diagnosis codes by code or description. Only billable (leaf-node) codes are returned, including codes expanded with their required seventh character. Supports exact matches, prefix searches, and full-text search with BM25 ranking.\n *\n * Access Policy Action: `Terminology:SearchCodes`\n * Access Policy Resource: `Terminology:Code:*`\n */\n searchIcd10(\n params: TerminologySearchIcd10Params,\n request?: OystehrClientRequest\n ): Promise<TerminologySearchIcd10Response> {\n return this.request('/icd10/search', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":";;AAAA;AAcM,MAAO,WAAY,SAAQ,WAAW,CAAA;AAC1C,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,mBAAmB,CAAC,IAAI,uCAAuC;IAC/F;AACA;;;;;AAKG;IACH,SAAS,CAAC,MAAkC,EAAE,OAA8B,EAAA;QAC1E,OAAO,IAAI,CAAC,OAAO,CAAC,aAAa,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC3F;AACA;;;;;AAKG;IACH,WAAW,CACT,MAAoC,EACpC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,eAAe,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC7F;AACA;;;;;AAKG;IACH,WAAW,CACT,MAAoC,EACpC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,eAAe,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IAC7F;AACD;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { OystehrClientRequest, Z3CreateBucketParams, Z3CreateBucketResponse, Z3DeleteBucketParams, Z3DeleteObjectParams, Z3GetPresignedUrlParams, Z3GetPresignedUrlResponse, Z3ListBucketsResponse, Z3ListObjectsParams, Z3ListObjectsResponse } from '../..';
|
|
1
|
+
import { OystehrClientRequest, Z3CreateBucketParams, Z3CreateBucketResponse, Z3DeleteBucketParams, Z3DeleteObjectParams, Z3EmptyBucketParams, Z3EmptyBucketResponse, Z3GetPresignedUrlParams, Z3GetPresignedUrlResponse, Z3ListBucketsResponse, Z3ListObjectsParams, Z3ListObjectsResponse } from '../..';
|
|
2
2
|
import { SDKResource } from '../../client/client';
|
|
3
3
|
import { OystehrConfig } from '../../config';
|
|
4
4
|
import * as ext from './z3-ext';
|
|
@@ -43,6 +43,13 @@ export declare class Z3 extends SDKResource {
|
|
|
43
43
|
* Access Policy Resource: `Z3:BucketName`
|
|
44
44
|
*/
|
|
45
45
|
deleteBucket(params: Z3DeleteBucketParams, request?: OystehrClientRequest): Promise<void>;
|
|
46
|
+
/**
|
|
47
|
+
* Recursively delete all Z3 Objects in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.
|
|
48
|
+
*
|
|
49
|
+
* Access Policy Action: `Z3:EmptyBucket`
|
|
50
|
+
* Access Policy Resource: `Z3:BucketName`
|
|
51
|
+
*/
|
|
52
|
+
emptyBucket(params: Z3EmptyBucketParams, request?: OystehrClientRequest): Promise<Z3EmptyBucketResponse>;
|
|
46
53
|
/**
|
|
47
54
|
* List all Z3 Objects at the provided path in the Bucket with the provided name [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.
|
|
48
55
|
*
|
|
@@ -53,6 +53,15 @@ class Z3 extends SDKResource {
|
|
|
53
53
|
deleteBucket(params, request) {
|
|
54
54
|
return this.request('/z3/{bucketName}', 'delete', this.#baseUrlThunk.bind(this))(params, request);
|
|
55
55
|
}
|
|
56
|
+
/**
|
|
57
|
+
* Recursively delete all Z3 Objects in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.
|
|
58
|
+
*
|
|
59
|
+
* Access Policy Action: `Z3:EmptyBucket`
|
|
60
|
+
* Access Policy Resource: `Z3:BucketName`
|
|
61
|
+
*/
|
|
62
|
+
emptyBucket(params, request) {
|
|
63
|
+
return this.request('/z3/{bucketName}/objects', 'delete', this.#baseUrlThunk.bind(this))(params, request);
|
|
64
|
+
}
|
|
56
65
|
/**
|
|
57
66
|
* List all Z3 Objects at the provided path in the Bucket with the provided name [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.
|
|
58
67
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"z3.js","sources":["../../../../src/resources/classes/z3.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n Z3CreateBucketParams,\n Z3CreateBucketResponse,\n Z3DeleteBucketParams,\n Z3DeleteObjectParams,\n Z3GetPresignedUrlParams,\n Z3GetPresignedUrlResponse,\n Z3ListBucketsResponse,\n Z3ListObjectsParams,\n Z3ListObjectsResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './z3-ext';\n\nexport class Z3 extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Uploads a file to the bucket and key. Files should be Blobs.\n * @param params upload file params\n */\n uploadFile = ext.uploadFile;\n /**\n * Downloads an object matching the bucket and key. File content is returned as an ArrayBuffer.\n * @param params download file params\n */\n downloadFile = ext.downloadFile;\n /**\n * This helper performs a `getPresignedUrl` request for Z3 URLs of the forms\n * `https://projects-api.oystehr.com/v1/z3/<bucket>/<key>` or `z3://<bucket>/<key>`\n * instead of the standard SDK `Z3GetPresignedUrlParams`.\n * @param params url and action\n */\n getPresignedUrlForZ3Url = ext.getPresignedUrlForZ3Url;\n /**\n * List all Z3 Buckets. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:ListBuckets`\n * Access Policy Resource: `Z3:BucketName`\n */\n listBuckets(request?: OystehrClientRequest): Promise<Z3ListBucketsResponse> {\n return this.request('/z3', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Create a Z3 Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:CreateBucket`\n * Access Policy Resource: `Z3:*`\n */\n createBucket(params: Z3CreateBucketParams, request?: OystehrClientRequest): Promise<Z3CreateBucketResponse> {\n return this.request('/z3/{bucketName}', 'put', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Z3 Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:DeleteBucket`\n * Access Policy Resource: `Z3:BucketName`\n */\n deleteBucket(params: Z3DeleteBucketParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/z3/{bucketName}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * List all Z3 Objects at the provided path in the Bucket with the provided name [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:ListObjects`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n listObjects(params: Z3ListObjectsParams, request?: OystehrClientRequest): Promise<Z3ListObjectsResponse> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get a link for downloading or uploading a Z3 Object to the provided path in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:PutObject` or `Z3:GetObject`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n getPresignedUrl(params: Z3GetPresignedUrlParams, request?: OystehrClientRequest): Promise<Z3GetPresignedUrlResponse> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Z3 Object at the provided path in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:DeleteObject`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n deleteObject(params: Z3DeleteObjectParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":["ext.uploadFile","ext.downloadFile","ext.getPresignedUrlForZ3Url"],"mappings":";;;AAAA;
|
|
1
|
+
{"version":3,"file":"z3.js","sources":["../../../../src/resources/classes/z3.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n OystehrClientRequest,\n Z3CreateBucketParams,\n Z3CreateBucketResponse,\n Z3DeleteBucketParams,\n Z3DeleteObjectParams,\n Z3EmptyBucketParams,\n Z3EmptyBucketResponse,\n Z3GetPresignedUrlParams,\n Z3GetPresignedUrlResponse,\n Z3ListBucketsResponse,\n Z3ListObjectsParams,\n Z3ListObjectsResponse,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './z3-ext';\n\nexport class Z3 extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Uploads a file to the bucket and key. Files should be Blobs.\n * @param params upload file params\n */\n uploadFile = ext.uploadFile;\n /**\n * Downloads an object matching the bucket and key. File content is returned as an ArrayBuffer.\n * @param params download file params\n */\n downloadFile = ext.downloadFile;\n /**\n * This helper performs a `getPresignedUrl` request for Z3 URLs of the forms\n * `https://projects-api.oystehr.com/v1/z3/<bucket>/<key>` or `z3://<bucket>/<key>`\n * instead of the standard SDK `Z3GetPresignedUrlParams`.\n * @param params url and action\n */\n getPresignedUrlForZ3Url = ext.getPresignedUrlForZ3Url;\n /**\n * List all Z3 Buckets. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:ListBuckets`\n * Access Policy Resource: `Z3:BucketName`\n */\n listBuckets(request?: OystehrClientRequest): Promise<Z3ListBucketsResponse> {\n return this.request('/z3', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Create a Z3 Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:CreateBucket`\n * Access Policy Resource: `Z3:*`\n */\n createBucket(params: Z3CreateBucketParams, request?: OystehrClientRequest): Promise<Z3CreateBucketResponse> {\n return this.request('/z3/{bucketName}', 'put', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Z3 Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:DeleteBucket`\n * Access Policy Resource: `Z3:BucketName`\n */\n deleteBucket(params: Z3DeleteBucketParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/z3/{bucketName}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Recursively delete all Z3 Objects in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:EmptyBucket`\n * Access Policy Resource: `Z3:BucketName`\n */\n emptyBucket(params: Z3EmptyBucketParams, request?: OystehrClientRequest): Promise<Z3EmptyBucketResponse> {\n return this.request('/z3/{bucketName}/objects', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * List all Z3 Objects at the provided path in the Bucket with the provided name [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:ListObjects`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n listObjects(params: Z3ListObjectsParams, request?: OystehrClientRequest): Promise<Z3ListObjectsResponse> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get a link for downloading or uploading a Z3 Object to the provided path in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:PutObject` or `Z3:GetObject`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n getPresignedUrl(params: Z3GetPresignedUrlParams, request?: OystehrClientRequest): Promise<Z3GetPresignedUrlResponse> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Z3 Object at the provided path in the Bucket with the provided name. [Z3](https://docs.oystehr.com/oystehr/services/z3/) is Oystehr's built-in and fully integrated solution for file storage.\n *\n * Access Policy Action: `Z3:DeleteObject`\n * Access Policy Resource: `Z3:BucketName:ObjectPath`\n */\n deleteObject(params: Z3DeleteObjectParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/z3/{bucketName}/{objectPath+}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":["ext.uploadFile","ext.downloadFile","ext.getPresignedUrlForZ3Url"],"mappings":";;;AAAA;AAoBM,MAAO,EAAG,SAAQ,WAAW,CAAA;AACjC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC;IACf;IACA,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,eAAe,CAAC,IAAI,mCAAmC;IACvF;AACA;;;AAGG;AACH,IAAA,UAAU,GAAGA,UAAc;AAC3B;;;AAGG;AACH,IAAA,YAAY,GAAGC,YAAgB;AAC/B;;;;;AAKG;AACH,IAAA,uBAAuB,GAAGC,uBAA2B;AACrD;;;;;AAKG;AACH,IAAA,WAAW,CAAC,OAA8B,EAAA;QACxC,OAAO,IAAI,CAAC,OAAO,CA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QACvE,OAAO,IAAI,CAAC,OAAO,CAAC,gCAAgC,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC;IACjH;AACD;;;;"}
|
|
@@ -36,7 +36,7 @@ export type ErxGetMedicationHistoryResponse = {
|
|
|
36
36
|
schedule: number | null;
|
|
37
37
|
directions: string | null;
|
|
38
38
|
substitutionsAllowed: boolean;
|
|
39
|
-
writtenDate: string;
|
|
39
|
+
writtenDate: string | null;
|
|
40
40
|
effectiveDate: string | null;
|
|
41
41
|
lastFillDate: string | null;
|
|
42
42
|
expirationDate: string | null;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Success
|
|
3
|
+
*/
|
|
4
|
+
export interface ErxGetPharmacyResponse {
|
|
5
|
+
id: number;
|
|
6
|
+
name: string;
|
|
7
|
+
address1: string;
|
|
8
|
+
address2: string | null;
|
|
9
|
+
city: string;
|
|
10
|
+
state: string;
|
|
11
|
+
zipCode: string;
|
|
12
|
+
phone: string;
|
|
13
|
+
fax: string | null;
|
|
14
|
+
specialties: string[];
|
|
15
|
+
ncpdpId: string;
|
|
16
|
+
}
|
|
@@ -6,12 +6,12 @@ export interface ErxSearchPharmaciesResponse {
|
|
|
6
6
|
id: number;
|
|
7
7
|
name: string;
|
|
8
8
|
address1: string;
|
|
9
|
-
address2
|
|
9
|
+
address2: string | null;
|
|
10
10
|
city: string;
|
|
11
11
|
state: string;
|
|
12
12
|
zipCode: string;
|
|
13
13
|
phone: string;
|
|
14
|
-
fax
|
|
14
|
+
fax: string | null;
|
|
15
15
|
specialties: string[];
|
|
16
16
|
ncpdpId: string;
|
|
17
17
|
}[];
|
|
@@ -12,4 +12,8 @@ export interface LabOrderSubmitParams {
|
|
|
12
12
|
* A client-provided string used to identify all tests in an order. See [Submit Lab](https://docs.oystehr.com/oystehr/services/lab/submit-an-order/#client-provided-order-number/) for more details.
|
|
13
13
|
*/
|
|
14
14
|
orderNumber?: string;
|
|
15
|
+
/**
|
|
16
|
+
* Flag to indicate which patient ID to transmit on the lab order. Defaults to false, instead using the Patient resource's UUID. If set to true but no friendly ID is found, throws a 400 error. See [Friendly Patient ID](https://docs.oystehr.com/oystehr/services/fhir/friendly-patient-id/) for more information on the friendly ID. See [Submit Lab](https://docs.oystehr.com/oystehr/services/lab/submit-an-order/#friendly-patient-id-in-lab-orders/) for more information on submitting using the friendly ID.
|
|
17
|
+
*/
|
|
18
|
+
useFriendlyPatientId?: boolean;
|
|
15
19
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ICD-10-CM code search results
|
|
3
|
+
*/
|
|
4
|
+
export interface TerminologySearchIcd10Response {
|
|
5
|
+
/**
|
|
6
|
+
* Array of ICD-10-CM codes matching the search.
|
|
7
|
+
*/
|
|
8
|
+
codes: {
|
|
9
|
+
/**
|
|
10
|
+
* ICD-10-CM code.
|
|
11
|
+
*/
|
|
12
|
+
code: string;
|
|
13
|
+
/**
|
|
14
|
+
* Human-readable description of the ICD-10-CM code.
|
|
15
|
+
*/
|
|
16
|
+
display: string;
|
|
17
|
+
}[];
|
|
18
|
+
/**
|
|
19
|
+
* Pagination metadata.
|
|
20
|
+
*/
|
|
21
|
+
metadata: {
|
|
22
|
+
/**
|
|
23
|
+
* Cursor for the next page of results. Null if no more results.
|
|
24
|
+
*/
|
|
25
|
+
nextCursor: string | null;
|
|
26
|
+
};
|
|
27
|
+
}
|
|
@@ -121,6 +121,8 @@ export * from './Z3ListBucketsResponse';
|
|
|
121
121
|
export * from './Z3CreateBucketParams';
|
|
122
122
|
export * from './Z3CreateBucketResponse';
|
|
123
123
|
export * from './Z3DeleteBucketParams';
|
|
124
|
+
export * from './Z3EmptyBucketParams';
|
|
125
|
+
export * from './Z3EmptyBucketResponse';
|
|
124
126
|
export * from './Z3ListObjectsParams';
|
|
125
127
|
export * from './Z3ListObjectsResponse';
|
|
126
128
|
export * from './Z3GetPresignedUrlParams';
|
|
@@ -163,6 +165,8 @@ export * from './ErxCancelPrescriptionParams';
|
|
|
163
165
|
export * from './ErxSyncPatientParams';
|
|
164
166
|
export * from './ErxSearchPharmaciesParams';
|
|
165
167
|
export * from './ErxSearchPharmaciesResponse';
|
|
168
|
+
export * from './ErxGetPharmacyParams';
|
|
169
|
+
export * from './ErxGetPharmacyResponse';
|
|
166
170
|
export * from './ErxConnectPractitionerParams';
|
|
167
171
|
export * from './ErxConnectPractitionerResponse';
|
|
168
172
|
export * from './ErxCheckPractitionerEnrollmentParams';
|
|
@@ -173,6 +177,8 @@ export * from './TerminologySearchCptParams';
|
|
|
173
177
|
export * from './TerminologySearchCptResponse';
|
|
174
178
|
export * from './TerminologySearchHcpcsParams';
|
|
175
179
|
export * from './TerminologySearchHcpcsResponse';
|
|
180
|
+
export * from './TerminologySearchIcd10Params';
|
|
181
|
+
export * from './TerminologySearchIcd10Response';
|
|
176
182
|
export * from './ZambdaSchedule';
|
|
177
183
|
export * from './ZambdaFunction';
|
|
178
184
|
export * from './ZambdaExecuteResult';
|
|
@@ -208,3 +214,5 @@ export * from './RcmListPayersParams';
|
|
|
208
214
|
export * from './RcmListPayersResponse';
|
|
209
215
|
export * from './RcmGetPayerParams';
|
|
210
216
|
export * from './RcmGetPayerResponse';
|
|
217
|
+
export * from './RcmProcessEraParams';
|
|
218
|
+
export * from './RcmProcessEraResponse';
|
package/package.json
CHANGED
|
@@ -19,6 +19,8 @@ import {
|
|
|
19
19
|
ErxGetMedicationHistoryResponse,
|
|
20
20
|
ErxGetMedicationParams,
|
|
21
21
|
ErxGetMedicationResponse,
|
|
22
|
+
ErxGetPharmacyParams,
|
|
23
|
+
ErxGetPharmacyResponse,
|
|
22
24
|
ErxSearchAllergensParams,
|
|
23
25
|
ErxSearchAllergensResponse,
|
|
24
26
|
ErxSearchMedicationsParams,
|
|
@@ -206,6 +208,14 @@ export class Erx extends SDKResource {
|
|
|
206
208
|
): Promise<ErxSearchPharmaciesResponse> {
|
|
207
209
|
return this.request('/pharmacy', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
208
210
|
}
|
|
211
|
+
/**
|
|
212
|
+
* Get a pharmacy by its eRx pharmacy ID.
|
|
213
|
+
* Action: `eRx:GetPharmacy`
|
|
214
|
+
* Access Policy Resource: `eRx:Pharmacy`
|
|
215
|
+
*/
|
|
216
|
+
getPharmacy(params: ErxGetPharmacyParams, request?: OystehrClientRequest): Promise<ErxGetPharmacyResponse> {
|
|
217
|
+
return this.request('/pharmacy/{pharmacyId}', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
218
|
+
}
|
|
209
219
|
/**
|
|
210
220
|
* Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.
|
|
211
221
|
* Action: `eRx:Connect`
|