@healthcloudai/hc-sdk 2.12.0 → 2.15.0
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/index.cjs +1020 -77
- package/dist/index.d.cts +14115 -6021
- package/dist/index.d.ts +14115 -6021
- package/dist/index.js +1020 -77
- package/docs/clients/AthenaHealthClient.md +3 -3
- package/docs/clients/HealthieClient.md +1 -1
- package/docs/clients/PatientClient.md +3 -0
- package/docs/docs-manifest.json +19 -7
- package/docs/examples/index.md +7 -4
- package/docs/index.md +7 -4
- package/docs/models/AddInsuranceRequest.md +0 -1
- package/docs/models/AddInsuranceResponse.md +4 -0
- package/docs/models/Allergy.md +2 -2
- package/docs/models/AnalyzeIdentityDocumentResponse.md +4 -1
- package/docs/models/Appointment.md +2 -0
- package/docs/models/AthenaAddPreferredPharmacyRequest.md +2 -1
- package/docs/models/AthenaCreatePatientRequest.md +2 -0
- package/docs/models/AthenaDeletePreferredPharmacyRequest.md +2 -1
- package/docs/models/AthenaGetInsurancePackagesRequest.md +3 -2
- package/docs/models/AthenaUpdateDriversLicenseRequest.md +1 -0
- package/docs/models/AthenaVitalsMirrorResult.md +20 -0
- package/docs/models/BookAppointmentRequest.md +2 -0
- package/docs/models/CancelAppointmentRequest.md +21 -0
- package/docs/models/DriversLicense.md +30 -0
- package/docs/models/DriversLicenseSubmission.md +21 -0
- package/docs/models/FamilyHistoryEntry.md +1 -1
- package/docs/models/GetEncounterResponse.md +4 -0
- package/docs/models/GetHealthRecordResponse.md +1 -1
- package/docs/models/GetPatientResponse.md +5 -0
- package/docs/models/HealthieAcceptInsurancePlansRequest.md +1 -0
- package/docs/models/HealthieAddDiagnosisRequest.md +1 -0
- package/docs/models/HealthieAddPharmacyRequest.md +1 -0
- package/docs/models/HealthieBulkApplyTagsRequest.md +1 -0
- package/docs/models/HealthieBulkUpdateClientsRequest.md +1 -0
- package/docs/models/HealthieBulkUpdateDiagnosesRequest.md +1 -0
- package/docs/models/HealthieCloseConversationRequest.md +1 -0
- package/docs/models/HealthieCompleteCcdaReconciliationRequest.md +1 -0
- package/docs/models/HealthieCompleteCheckoutRequest.md +1 -0
- package/docs/models/HealthieCopyFormRequest.md +1 -0
- package/docs/models/HealthieCopyOfferingRequest.md +1 -0
- package/docs/models/HealthieCreateApiKeyRequest.md +1 -0
- package/docs/models/HealthieCreateAppointmentRequest.md +1 -0
- package/docs/models/HealthieCreateAppointmentSettingRequest.md +1 -0
- package/docs/models/HealthieCreateAppointmentTypeRequest.md +1 -0
- package/docs/models/HealthieCreateAvailabilitiesBulkRequest.md +1 -0
- package/docs/models/HealthieCreateAvailabilityRequest.md +1 -0
- package/docs/models/HealthieCreateBillingItemRequest.md +1 -0
- package/docs/models/HealthieCreateCarePlanRequest.md +1 -0
- package/docs/models/HealthieCreateCms1500Request.md +1 -0
- package/docs/models/HealthieCreateCompletedOnboardingItemRequest.md +1 -0
- package/docs/models/HealthieCreateConversationRequest.md +1 -0
- package/docs/models/HealthieCreateEntryRequest.md +1 -0
- package/docs/models/HealthieCreateEpisodeOfCareRequest.md +1 -0
- package/docs/models/HealthieCreateFamilyHistoryRequest.md +1 -0
- package/docs/models/HealthieCreateFormAnswerGroupRequest.md +1 -0
- package/docs/models/HealthieCreateFormCompletionRequestRequest.md +1 -0
- package/docs/models/HealthieCreateFormRequest.md +1 -0
- package/docs/models/HealthieCreateGoalRequest.md +1 -0
- package/docs/models/HealthieCreateImmunizationRequest.md +1 -0
- package/docs/models/HealthieCreateInsurancePaymentRequest.md +1 -0
- package/docs/models/HealthieCreateInvoiceRequest.md +1 -0
- package/docs/models/HealthieCreateLabOrderRequest.md +1 -0
- package/docs/models/HealthieCreateLocationRequest.md +1 -0
- package/docs/models/HealthieCreateMedicationRequest.md +1 -0
- package/docs/models/HealthieCreateMetricEntryRequest.md +1 -0
- package/docs/models/HealthieCreateNoteRequest.md +1 -0
- package/docs/models/HealthieCreateOfferingRequest.md +1 -0
- package/docs/models/HealthieCreateOnboardingFlowRequest.md +1 -0
- package/docs/models/HealthieCreateOnboardingItemRequest.md +1 -0
- package/docs/models/HealthieCreateOpenLoopFormRequest.md +1 -0
- package/docs/models/HealthieCreateOrganizationMembershipRequest.md +1 -0
- package/docs/models/HealthieCreatePatientRequest.md +1 -0
- package/docs/models/HealthieCreatePersonalizationQuestionnaireRequest.md +1 -0
- package/docs/models/HealthieCreateProgramRequest.md +1 -0
- package/docs/models/HealthieCreateRupaOrderRequest.md +1 -0
- package/docs/models/HealthieCreateSuperBillRequest.md +1 -0
- package/docs/models/HealthieCreateTagRequest.md +1 -0
- package/docs/models/HealthieCreateTaskRequest.md +1 -0
- package/docs/models/HealthieCreateUserGroupRequest.md +1 -0
- package/docs/models/HealthieDeleteApiKeyRequest.md +1 -0
- package/docs/models/HealthieDeleteAppointmentRequest.md +1 -0
- package/docs/models/HealthieDeleteAppointmentTypeRequest.md +1 -0
- package/docs/models/HealthieDeleteAvailabilityRequest.md +1 -0
- package/docs/models/HealthieDeleteBillingItemRequest.md +1 -0
- package/docs/models/HealthieDeleteCarePlanRequest.md +1 -0
- package/docs/models/HealthieDeleteCms1500Request.md +1 -0
- package/docs/models/HealthieDeleteDocumentRequest.md +1 -0
- package/docs/models/HealthieDeleteEntryRequest.md +1 -0
- package/docs/models/HealthieDeleteEpisodeOfCareRequest.md +1 -0
- package/docs/models/HealthieDeleteFamilyHistoryRequest.md +1 -0
- package/docs/models/HealthieDeleteFormCompletionRequestRequest.md +1 -0
- package/docs/models/HealthieDeleteFormRequest.md +1 -0
- package/docs/models/HealthieDeleteGoalRequest.md +1 -0
- package/docs/models/HealthieDeleteInvoiceRequest.md +1 -0
- package/docs/models/HealthieDeleteManualInsurancePaymentRequest.md +1 -0
- package/docs/models/HealthieDeleteMedicationRequest.md +1 -0
- package/docs/models/HealthieDeleteOfferingRequest.md +1 -0
- package/docs/models/HealthieDeleteOnboardingFlowRequest.md +1 -0
- package/docs/models/HealthieDeleteOnboardingItemRequest.md +1 -0
- package/docs/models/HealthieDeleteOrganizationMembershipRequest.md +1 -0
- package/docs/models/HealthieDeleteProgramRequest.md +1 -0
- package/docs/models/HealthieDeleteSuperBillRequest.md +1 -0
- package/docs/models/HealthieDeleteTagRequest.md +1 -0
- package/docs/models/HealthieDeleteTaskRequest.md +1 -0
- package/docs/models/HealthieDeleteUserGroupRequest.md +1 -0
- package/docs/models/HealthieEditAvailabilityRequest.md +1 -0
- package/docs/models/HealthieFillLabResultReviewFormRequest.md +1 -0
- package/docs/models/HealthieFindAndBookFirstAvailableSlotRequest.md +1 -0
- package/docs/models/HealthieGetApiKeysRequest.md +1 -0
- package/docs/models/HealthieGetAppointmentBookingWarningsRequest.md +1 -0
- package/docs/models/HealthieGetAppointmentRequest.md +1 -0
- package/docs/models/HealthieGetAppointmentSettingRequest.md +1 -0
- package/docs/models/HealthieGetAppointmentTypeRequest.md +1 -0
- package/docs/models/HealthieGetAppointmentTypesRequest.md +1 -0
- package/docs/models/HealthieGetAppointmentsRequest.md +1 -0
- package/docs/models/HealthieGetAvailabilitiesRequest.md +1 -0
- package/docs/models/HealthieGetAvailabilityRequest.md +1 -0
- package/docs/models/HealthieGetAvailableItemTypesRequest.md +1 -0
- package/docs/models/HealthieGetAvailableSlotsForRangeRequest.md +1 -0
- package/docs/models/HealthieGetBillingItemRequest.md +1 -0
- package/docs/models/HealthieGetBillingItemsRequest.md +1 -0
- package/docs/models/HealthieGetCarePlanRequest.md +1 -0
- package/docs/models/HealthieGetCarePlansRequest.md +1 -0
- package/docs/models/HealthieGetCms1500Request.md +1 -0
- package/docs/models/HealthieGetCms1500sRequest.md +1 -0
- package/docs/models/HealthieGetConversationMembershipsRequest.md +1 -0
- package/docs/models/HealthieGetConversationRequest.md +1 -0
- package/docs/models/HealthieGetCurrentUserIdRequest.md +1 -0
- package/docs/models/HealthieGetCurrentUserRequest.md +1 -0
- package/docs/models/HealthieGetDaysAvailableForRangeRequest.md +1 -0
- package/docs/models/HealthieGetDietitianIdRequest.md +1 -0
- package/docs/models/HealthieGetDocumentRequest.md +1 -0
- package/docs/models/HealthieGetDocumentsRequest.md +1 -0
- package/docs/models/HealthieGetEntriesRequest.md +1 -0
- package/docs/models/HealthieGetEntryRequest.md +1 -0
- package/docs/models/HealthieGetEpisodesOfCareRequest.md +1 -0
- package/docs/models/HealthieGetFormAnswerGroupsRequest.md +1 -0
- package/docs/models/HealthieGetFormCompletionRequestsRequest.md +1 -0
- package/docs/models/HealthieGetFormRequest.md +1 -0
- package/docs/models/HealthieGetFormsRequest.md +1 -0
- package/docs/models/HealthieGetGoalHistoriesRequest.md +1 -0
- package/docs/models/HealthieGetGoalRequest.md +1 -0
- package/docs/models/HealthieGetGoalsRequest.md +1 -0
- package/docs/models/HealthieGetInsurancePaymentsRequest.md +1 -0
- package/docs/models/HealthieGetInsurancePlansRequest.md +1 -0
- package/docs/models/HealthieGetInvoiceRequest.md +1 -0
- package/docs/models/HealthieGetInvoicesRequest.md +1 -0
- package/docs/models/HealthieGetLabOrderRequest.md +1 -0
- package/docs/models/HealthieGetLabOrdersRequest.md +1 -0
- package/docs/models/HealthieGetLabResultRequest.md +1 -0
- package/docs/models/HealthieGetMedicationsRequest.md +1 -0
- package/docs/models/HealthieGetMetricEntriesRequest.md +1 -0
- package/docs/models/HealthieGetOfferingRequest.md +1 -0
- package/docs/models/HealthieGetOfferingsRequest.md +1 -0
- package/docs/models/HealthieGetOnboardingFlowRequest.md +1 -0
- package/docs/models/HealthieGetOnboardingFlowsRequest.md +1 -0
- package/docs/models/HealthieGetOnboardingItemRequest.md +1 -0
- package/docs/models/HealthieGetOrganizationDetailedRequest.md +1 -0
- package/docs/models/HealthieGetOrganizationMembersRequest.md +1 -0
- package/docs/models/HealthieGetOrganizationRequest.md +1 -0
- package/docs/models/HealthieGetPatientDefaultPharmacyRequest.md +1 -0
- package/docs/models/HealthieGetPatientDiagnosesRequest.md +1 -0
- package/docs/models/HealthieGetPatientDocumentsRequest.md +1 -0
- package/docs/models/HealthieGetPatientEncounterRequest.md +1 -0
- package/docs/models/HealthieGetPatientImmunizationsRequest.md +1 -0
- package/docs/models/HealthieGetPatientJsonRequest.md +1 -0
- package/docs/models/HealthieGetPatientNotesRequest.md +1 -0
- package/docs/models/HealthieGetPatientProblemsRequest.md +1 -0
- package/docs/models/HealthieGetPatientRequest.md +1 -0
- package/docs/models/HealthieGetPharmacyRequest.md +1 -0
- package/docs/models/HealthieGetProgramRequest.md +1 -0
- package/docs/models/HealthieGetProgramsRequest.md +1 -0
- package/docs/models/HealthieGetProviderRequest.md +1 -0
- package/docs/models/HealthieGetReceivedFaxRequest.md +1 -0
- package/docs/models/HealthieGetReceivedFaxesRequest.md +1 -0
- package/docs/models/HealthieGetSentFaxRequest.md +1 -0
- package/docs/models/HealthieGetSentFaxesRequest.md +1 -0
- package/docs/models/HealthieGetSuperBillRequest.md +1 -0
- package/docs/models/HealthieGetSuperBillsRequest.md +1 -0
- package/docs/models/HealthieGetTagsRequest.md +1 -0
- package/docs/models/HealthieGetTaskRequest.md +1 -0
- package/docs/models/HealthieGetTasksRequest.md +1 -0
- package/docs/models/HealthieGetUnassociatedCompletedOnboardingItemsRequest.md +1 -0
- package/docs/models/HealthieGetUserGroupRequest.md +1 -0
- package/docs/models/HealthieGetUserGroupsRequest.md +1 -0
- package/docs/models/HealthieLinkEncountersToEpisodeRequest.md +1 -0
- package/docs/models/HealthieListOrganizationMembersRequest.md +1 -0
- package/docs/models/HealthieListPatientsRequest.md +1 -0
- package/docs/models/HealthieMarkTasksAsSeenRequest.md +1 -0
- package/docs/models/HealthieParseCcdaDocumentRequest.md +1 -0
- package/docs/models/HealthieRemoveAcceptedInsurancePlanRequest.md +1 -0
- package/docs/models/HealthieRemoveAppliedTagRequest.md +1 -0
- package/docs/models/HealthieRemoveDiagnosisRequest.md +1 -0
- package/docs/models/HealthieSearchPatientsRequest.md +1 -0
- package/docs/models/HealthieSearchPharmaciesRequest.md +1 -0
- package/docs/models/HealthieSendChatMessageRequest.md +1 -0
- package/docs/models/HealthieSendFaxRequest.md +1 -0
- package/docs/models/HealthieShareFormRequest.md +1 -0
- package/docs/models/HealthieSignUpPatientRequest.md +1 -0
- package/docs/models/HealthieStorePaymentCardRequest.md +1 -0
- package/docs/models/HealthieUnlinkEncountersFromEpisodeRequest.md +1 -0
- package/docs/models/HealthieUpdateAppointmentRequest.md +1 -0
- package/docs/models/HealthieUpdateAppointmentSettingRequest.md +1 -0
- package/docs/models/HealthieUpdateAppointmentTypeRequest.md +1 -0
- package/docs/models/HealthieUpdateBillingItemRequest.md +1 -0
- package/docs/models/HealthieUpdateCarePlanRequest.md +1 -0
- package/docs/models/HealthieUpdateCms1500Request.md +1 -0
- package/docs/models/HealthieUpdateConversationRequest.md +1 -0
- package/docs/models/HealthieUpdateDiagnosisRequest.md +1 -0
- package/docs/models/HealthieUpdateDocumentRequest.md +1 -0
- package/docs/models/HealthieUpdateEntryRequest.md +1 -0
- package/docs/models/HealthieUpdateEpisodeOfCareRequest.md +1 -0
- package/docs/models/HealthieUpdateFamilyHistoryRequest.md +1 -0
- package/docs/models/HealthieUpdateFormRequest.md +1 -0
- package/docs/models/HealthieUpdateGoalRequest.md +1 -0
- package/docs/models/HealthieUpdateImmunizationRequest.md +1 -0
- package/docs/models/HealthieUpdateInsurancePaymentDepositStatusRequest.md +1 -0
- package/docs/models/HealthieUpdateInvoiceRequest.md +1 -0
- package/docs/models/HealthieUpdateLabOrderRequest.md +1 -0
- package/docs/models/HealthieUpdateLocationRequest.md +1 -0
- package/docs/models/HealthieUpdateManualInsurancePaymentRequest.md +1 -0
- package/docs/models/HealthieUpdateMedicationRequest.md +1 -0
- package/docs/models/HealthieUpdateOfferingRequest.md +1 -0
- package/docs/models/HealthieUpdateOnboardingFlowRequest.md +1 -0
- package/docs/models/HealthieUpdateOnboardingItemRequest.md +1 -0
- package/docs/models/HealthieUpdateOrganizationMembershipRequest.md +1 -0
- package/docs/models/HealthieUpdatePatientInsuranceBillingRequest.md +2 -1
- package/docs/models/HealthieUpdatePatientRequest.md +1 -0
- package/docs/models/HealthieUpdateProgramRequest.md +1 -0
- package/docs/models/HealthieUpdateSuperBillRequest.md +1 -0
- package/docs/models/HealthieUpdateTagRequest.md +1 -0
- package/docs/models/HealthieUpdateTaskRequest.md +1 -0
- package/docs/models/HealthieUpdateUserGroupRequest.md +1 -0
- package/docs/models/HealthieUpdateUserRequest.md +1 -0
- package/docs/models/ImportVitalsResponse.md +3 -0
- package/docs/models/OpenLoopVitalsMirrorResult.md +21 -0
- package/docs/models/PatientDemographics.md +5 -0
- package/docs/models/PatientIntakeRequest.md +26 -0
- package/docs/models/PatientIntakeResponse.md +20 -0
- package/docs/models/RecordVitalsResponse.md +1 -0
- package/docs/models/RescheduleAppointmentRequest.md +10 -1
- package/docs/models/SetPreferredPharmacyRequest.md +2 -0
- package/docs/models/SetPreferredPharmacyResponse.md +7 -3
- package/docs/models/Slot.md +2 -0
- package/docs/models/SteadyMDVitalsMirrorResult.md +21 -0
- package/docs/models/UpdateDriversLicenseRequest.md +20 -0
- package/docs/models/UpdateDriversLicenseResponse.md +20 -0
- package/docs/models/{AllergyReaction.md → ehr.AllergyReaction.md} +2 -2
- package/docs/models/{CodedConcept.md → ehr.CodedConcept.md} +1 -1
- package/docs/models/{FamilyCondition.md → ehr.FamilyCondition.md} +2 -1
- package/docs/models/fieldagent.Encounter.md +4 -0
- package/docs/models/index.md +13 -4
- package/docs/models/patient.Encounter.md +4 -0
- package/docs/models/patient.LoginResponse.md +2 -0
- package/docs/models/patient.RegisterRequest.md +1 -0
- package/docs/models/patient.RegisterResponse.md +4 -0
- package/docs/models/patient.UploadPhotoResponse.md +3 -0
- package/docs/operations/appointments.book.md +9 -3
- package/docs/operations/appointments.cancel.md +49 -5
- package/docs/operations/appointments.createSlot.md +3 -1
- package/docs/operations/appointments.listPatientAppointments.md +2 -0
- package/docs/operations/appointments.listSlots.md +3 -1
- package/docs/operations/appointments.reschedule.md +41 -6
- package/docs/operations/connectors.athenaAddPreferredPharmacy.md +2 -2
- package/docs/operations/connectors.athenaGetInsurancePackages.md +2 -6
- package/docs/operations/connectors.athenaListMedications.md +1 -0
- package/docs/operations/connectors.athenaUpdateDriversLicense.md +11 -12
- package/docs/operations/connectors.athenaUploadPatientPhoto.md +2 -2
- package/docs/operations/connectors.healthieAcceptInsurancePlans.md +3 -1
- package/docs/operations/connectors.healthieAddDiagnosis.md +3 -1
- package/docs/operations/connectors.healthieAddPharmacy.md +3 -1
- package/docs/operations/connectors.healthieBulkApplyTags.md +3 -1
- package/docs/operations/connectors.healthieBulkUpdateClients.md +3 -1
- package/docs/operations/connectors.healthieBulkUpdateDiagnoses.md +3 -1
- package/docs/operations/connectors.healthieCloseConversation.md +3 -1
- package/docs/operations/connectors.healthieCompleteCcdaReconciliation.md +3 -1
- package/docs/operations/connectors.healthieCompleteCheckout.md +3 -1
- package/docs/operations/connectors.healthieCopyForm.md +3 -3
- package/docs/operations/connectors.healthieCopyOffering.md +3 -1
- package/docs/operations/connectors.healthieCreateApiKey.md +3 -7
- package/docs/operations/connectors.healthieCreateAppointment.md +3 -1
- package/docs/operations/connectors.healthieCreateAppointmentSetting.md +3 -1
- package/docs/operations/connectors.healthieCreateAppointmentType.md +3 -1
- package/docs/operations/connectors.healthieCreateAvailabilitiesBulk.md +3 -1
- package/docs/operations/connectors.healthieCreateAvailability.md +3 -1
- package/docs/operations/connectors.healthieCreateBillingItem.md +3 -1
- package/docs/operations/connectors.healthieCreateCarePlan.md +3 -1
- package/docs/operations/connectors.healthieCreateCms1500.md +3 -1
- package/docs/operations/connectors.healthieCreateCompletedOnboardingItem.md +3 -7
- package/docs/operations/connectors.healthieCreateConversation.md +3 -1
- package/docs/operations/connectors.healthieCreateEntry.md +3 -1
- package/docs/operations/connectors.healthieCreateEpisodeOfCare.md +3 -1
- package/docs/operations/connectors.healthieCreateFamilyHistory.md +3 -1
- package/docs/operations/connectors.healthieCreateForm.md +5 -5
- package/docs/operations/connectors.healthieCreateFormAnswerGroup.md +3 -1
- package/docs/operations/connectors.healthieCreateFormCompletionRequest.md +3 -3
- package/docs/operations/connectors.healthieCreateGoal.md +3 -1
- package/docs/operations/connectors.healthieCreateImmunization.md +3 -1
- package/docs/operations/connectors.healthieCreateInsurancePayment.md +3 -1
- package/docs/operations/connectors.healthieCreateInvoice.md +3 -1
- package/docs/operations/connectors.healthieCreateLabOrder.md +3 -1
- package/docs/operations/connectors.healthieCreateLocation.md +3 -1
- package/docs/operations/connectors.healthieCreateMedication.md +3 -1
- package/docs/operations/connectors.healthieCreateMetricEntry.md +3 -7
- package/docs/operations/connectors.healthieCreateNote.md +3 -1
- package/docs/operations/connectors.healthieCreateOffering.md +3 -1
- package/docs/operations/connectors.healthieCreateOnboardingFlow.md +3 -7
- package/docs/operations/connectors.healthieCreateOnboardingItem.md +3 -1
- package/docs/operations/connectors.healthieCreateOpenLoopForm.md +3 -1
- package/docs/operations/connectors.healthieCreateOrganizationMembership.md +3 -1
- package/docs/operations/connectors.healthieCreatePatient.md +3 -1
- package/docs/operations/connectors.healthieCreatePersonalizationQuestionnaire.md +3 -1
- package/docs/operations/connectors.healthieCreateProgram.md +3 -1
- package/docs/operations/connectors.healthieCreateRupaOrder.md +3 -1
- package/docs/operations/connectors.healthieCreateSuperBill.md +3 -1
- package/docs/operations/connectors.healthieCreateTag.md +3 -7
- package/docs/operations/connectors.healthieCreateTask.md +3 -1
- package/docs/operations/connectors.healthieCreateUserGroup.md +3 -1
- package/docs/operations/connectors.healthieDeleteApiKey.md +3 -1
- package/docs/operations/connectors.healthieDeleteAppointment.md +3 -7
- package/docs/operations/connectors.healthieDeleteAppointmentType.md +3 -1
- package/docs/operations/connectors.healthieDeleteAvailability.md +3 -1
- package/docs/operations/connectors.healthieDeleteBillingItem.md +3 -1
- package/docs/operations/connectors.healthieDeleteCarePlan.md +3 -1
- package/docs/operations/connectors.healthieDeleteCms1500.md +3 -1
- package/docs/operations/connectors.healthieDeleteDocument.md +3 -1
- package/docs/operations/connectors.healthieDeleteEntry.md +3 -1
- package/docs/operations/connectors.healthieDeleteEpisodeOfCare.md +3 -1
- package/docs/operations/connectors.healthieDeleteFamilyHistory.md +3 -1
- package/docs/operations/connectors.healthieDeleteForm.md +3 -1
- package/docs/operations/connectors.healthieDeleteFormCompletionRequest.md +3 -7
- package/docs/operations/connectors.healthieDeleteGoal.md +3 -1
- package/docs/operations/connectors.healthieDeleteInvoice.md +3 -1
- package/docs/operations/connectors.healthieDeleteManualInsurancePayment.md +3 -1
- package/docs/operations/connectors.healthieDeleteMedication.md +3 -1
- package/docs/operations/connectors.healthieDeleteOffering.md +3 -1
- package/docs/operations/connectors.healthieDeleteOnboardingFlow.md +3 -7
- package/docs/operations/connectors.healthieDeleteOnboardingItem.md +3 -1
- package/docs/operations/connectors.healthieDeleteOrganizationMembership.md +3 -1
- package/docs/operations/connectors.healthieDeleteProgram.md +3 -1
- package/docs/operations/connectors.healthieDeleteSuperBill.md +3 -1
- package/docs/operations/connectors.healthieDeleteTag.md +3 -1
- package/docs/operations/connectors.healthieDeleteTask.md +3 -1
- package/docs/operations/connectors.healthieDeleteUserGroup.md +3 -7
- package/docs/operations/connectors.healthieEditAvailability.md +3 -1
- package/docs/operations/connectors.healthieFillLabResultReviewForm.md +3 -1
- package/docs/operations/connectors.healthieFindAndBookFirstAvailableSlot.md +4 -4
- package/docs/operations/connectors.healthieGetApiKeys.md +3 -1
- package/docs/operations/connectors.healthieGetAppointment.md +3 -7
- package/docs/operations/connectors.healthieGetAppointmentBookingWarnings.md +3 -3
- package/docs/operations/connectors.healthieGetAppointmentSetting.md +3 -3
- package/docs/operations/connectors.healthieGetAppointmentType.md +3 -1
- package/docs/operations/connectors.healthieGetAppointmentTypes.md +3 -3
- package/docs/operations/connectors.healthieGetAppointments.md +3 -3
- package/docs/operations/connectors.healthieGetAvailabilities.md +3 -3
- package/docs/operations/connectors.healthieGetAvailability.md +3 -1
- package/docs/operations/connectors.healthieGetAvailableItemTypes.md +3 -7
- package/docs/operations/connectors.healthieGetAvailableSlotsForRange.md +4 -4
- package/docs/operations/connectors.healthieGetBillingItem.md +3 -1
- package/docs/operations/connectors.healthieGetBillingItems.md +3 -1
- package/docs/operations/connectors.healthieGetCarePlan.md +3 -1
- package/docs/operations/connectors.healthieGetCarePlans.md +3 -3
- package/docs/operations/connectors.healthieGetCms1500.md +3 -1
- package/docs/operations/connectors.healthieGetCms1500s.md +5 -5
- package/docs/operations/connectors.healthieGetConversation.md +3 -1
- package/docs/operations/connectors.healthieGetConversationMemberships.md +3 -1
- package/docs/operations/connectors.healthieGetCurrentUser.md +3 -1
- package/docs/operations/connectors.healthieGetCurrentUserId.md +3 -1
- package/docs/operations/connectors.healthieGetDaysAvailableForRange.md +5 -5
- package/docs/operations/connectors.healthieGetDietitianId.md +3 -1
- package/docs/operations/connectors.healthieGetDocument.md +3 -3
- package/docs/operations/connectors.healthieGetDocuments.md +3 -1
- package/docs/operations/connectors.healthieGetEntries.md +3 -1
- package/docs/operations/connectors.healthieGetEntry.md +5 -5
- package/docs/operations/connectors.healthieGetEpisodesOfCare.md +3 -3
- package/docs/operations/connectors.healthieGetForm.md +3 -1
- package/docs/operations/connectors.healthieGetFormAnswerGroups.md +3 -3
- package/docs/operations/connectors.healthieGetFormCompletionRequests.md +3 -1
- package/docs/operations/connectors.healthieGetForms.md +3 -1
- package/docs/operations/connectors.healthieGetGoal.md +3 -3
- package/docs/operations/connectors.healthieGetGoalHistories.md +3 -3
- package/docs/operations/connectors.healthieGetGoals.md +3 -3
- package/docs/operations/connectors.healthieGetInsurancePayments.md +3 -3
- package/docs/operations/connectors.healthieGetInsurancePlans.md +3 -1
- package/docs/operations/connectors.healthieGetInvoice.md +3 -3
- package/docs/operations/connectors.healthieGetInvoices.md +3 -1
- package/docs/operations/connectors.healthieGetLabOrder.md +3 -1
- package/docs/operations/connectors.healthieGetLabOrders.md +3 -3
- package/docs/operations/connectors.healthieGetLabResult.md +3 -1
- package/docs/operations/connectors.healthieGetMedications.md +3 -3
- package/docs/operations/connectors.healthieGetMetricEntries.md +3 -3
- package/docs/operations/connectors.healthieGetOffering.md +3 -1
- package/docs/operations/connectors.healthieGetOfferings.md +5 -5
- package/docs/operations/connectors.healthieGetOnboardingFlow.md +5 -5
- package/docs/operations/connectors.healthieGetOnboardingFlows.md +5 -5
- package/docs/operations/connectors.healthieGetOnboardingItem.md +3 -1
- package/docs/operations/connectors.healthieGetOrganization.md +3 -1
- package/docs/operations/connectors.healthieGetOrganizationDetailed.md +3 -7
- package/docs/operations/connectors.healthieGetOrganizationMembers.md +3 -1
- package/docs/operations/connectors.healthieGetPatient.md +3 -1
- package/docs/operations/connectors.healthieGetPatientDefaultPharmacy.md +3 -1
- package/docs/operations/connectors.healthieGetPatientDiagnoses.md +3 -1
- package/docs/operations/connectors.healthieGetPatientDocuments.md +3 -7
- package/docs/operations/connectors.healthieGetPatientEncounter.md +3 -3
- package/docs/operations/connectors.healthieGetPatientImmunizations.md +3 -1
- package/docs/operations/connectors.healthieGetPatientJson.md +3 -1
- package/docs/operations/connectors.healthieGetPatientNotes.md +3 -1
- package/docs/operations/connectors.healthieGetPatientProblems.md +3 -1
- package/docs/operations/connectors.healthieGetPharmacy.md +3 -1
- package/docs/operations/connectors.healthieGetProgram.md +3 -1
- package/docs/operations/connectors.healthieGetPrograms.md +3 -3
- package/docs/operations/connectors.healthieGetProvider.md +3 -1
- package/docs/operations/connectors.healthieGetReceivedFax.md +3 -1
- package/docs/operations/connectors.healthieGetReceivedFaxes.md +3 -1
- package/docs/operations/connectors.healthieGetSentFax.md +3 -1
- package/docs/operations/connectors.healthieGetSentFaxes.md +3 -3
- package/docs/operations/connectors.healthieGetSuperBill.md +3 -1
- package/docs/operations/connectors.healthieGetSuperBills.md +5 -5
- package/docs/operations/connectors.healthieGetTags.md +3 -1
- package/docs/operations/connectors.healthieGetTask.md +3 -1
- package/docs/operations/connectors.healthieGetTasks.md +5 -5
- package/docs/operations/connectors.healthieGetUnassociatedCompletedOnboardingItems.md +3 -7
- package/docs/operations/connectors.healthieGetUserGroup.md +3 -1
- package/docs/operations/connectors.healthieGetUserGroups.md +5 -5
- package/docs/operations/connectors.healthieLinkEncountersToEpisode.md +3 -1
- package/docs/operations/connectors.healthieListOrganizationMembers.md +5 -5
- package/docs/operations/connectors.healthieListPatients.md +5 -5
- package/docs/operations/connectors.healthieMarkTasksAsSeen.md +3 -7
- package/docs/operations/connectors.healthieParseCcdaDocument.md +3 -1
- package/docs/operations/connectors.healthieRemoveAcceptedInsurancePlan.md +3 -1
- package/docs/operations/connectors.healthieRemoveAppliedTag.md +3 -1
- package/docs/operations/connectors.healthieRemoveDiagnosis.md +3 -1
- package/docs/operations/connectors.healthieSearchPatients.md +3 -1
- package/docs/operations/connectors.healthieSearchPharmacies.md +3 -3
- package/docs/operations/connectors.healthieSendChatMessage.md +3 -1
- package/docs/operations/connectors.healthieSendFax.md +3 -3
- package/docs/operations/connectors.healthieShareForm.md +3 -1
- package/docs/operations/connectors.healthieSignUpPatient.md +3 -1
- package/docs/operations/connectors.healthieStorePaymentCard.md +3 -1
- package/docs/operations/connectors.healthieUnlinkEncountersFromEpisode.md +3 -1
- package/docs/operations/connectors.healthieUpdateAppointment.md +3 -1
- package/docs/operations/connectors.healthieUpdateAppointmentSetting.md +3 -1
- package/docs/operations/connectors.healthieUpdateAppointmentType.md +3 -1
- package/docs/operations/connectors.healthieUpdateBillingItem.md +3 -1
- package/docs/operations/connectors.healthieUpdateCarePlan.md +3 -1
- package/docs/operations/connectors.healthieUpdateCms1500.md +3 -1
- package/docs/operations/connectors.healthieUpdateConversation.md +3 -1
- package/docs/operations/connectors.healthieUpdateDiagnosis.md +3 -1
- package/docs/operations/connectors.healthieUpdateDocument.md +3 -1
- package/docs/operations/connectors.healthieUpdateEntry.md +3 -1
- package/docs/operations/connectors.healthieUpdateEpisodeOfCare.md +3 -1
- package/docs/operations/connectors.healthieUpdateFamilyHistory.md +3 -1
- package/docs/operations/connectors.healthieUpdateForm.md +3 -3
- package/docs/operations/connectors.healthieUpdateGoal.md +3 -1
- package/docs/operations/connectors.healthieUpdateImmunization.md +3 -1
- package/docs/operations/connectors.healthieUpdateInsurancePaymentDepositStatus.md +3 -1
- package/docs/operations/connectors.healthieUpdateInvoice.md +3 -1
- package/docs/operations/connectors.healthieUpdateLabOrder.md +3 -1
- package/docs/operations/connectors.healthieUpdateLocation.md +3 -1
- package/docs/operations/connectors.healthieUpdateManualInsurancePayment.md +3 -1
- package/docs/operations/connectors.healthieUpdateMedication.md +3 -1
- package/docs/operations/connectors.healthieUpdateOffering.md +3 -1
- package/docs/operations/connectors.healthieUpdateOnboardingFlow.md +3 -3
- package/docs/operations/connectors.healthieUpdateOnboardingItem.md +3 -3
- package/docs/operations/connectors.healthieUpdateOrganizationMembership.md +3 -1
- package/docs/operations/connectors.healthieUpdatePatient.md +3 -1
- package/docs/operations/connectors.healthieUpdatePatientInsuranceBilling.md +7 -5
- package/docs/operations/connectors.healthieUpdateProgram.md +3 -1
- package/docs/operations/connectors.healthieUpdateSuperBill.md +3 -1
- package/docs/operations/connectors.healthieUpdateTag.md +3 -1
- package/docs/operations/connectors.healthieUpdateTask.md +3 -1
- package/docs/operations/connectors.healthieUpdateUser.md +3 -1
- package/docs/operations/connectors.healthieUpdateUserGroup.md +3 -1
- package/docs/operations/ehr.listFamilyHistory.md +18 -17
- package/docs/operations/fieldagent.listEncounters.md +4 -0
- package/docs/operations/fieldagent.listPatients.md +10 -1
- package/docs/operations/patient.addInsurance.md +11 -9
- package/docs/operations/patient.analyzeIdentityDocument.md +1 -1
- package/docs/operations/patient.checkInEncounter.md +1 -1
- package/docs/operations/patient.createEncounter.md +4 -0
- package/docs/operations/patient.getCheckinCheckin.md +4 -0
- package/docs/operations/patient.getCurrentCareSessionCareSessionsCurrent.md +4 -0
- package/docs/operations/patient.getEncounter.md +4 -0
- package/docs/operations/patient.getLatestEncounter.md +4 -0
- package/docs/operations/patient.getPatient.md +9 -0
- package/docs/operations/patient.getPatientIntake.md +137 -0
- package/docs/operations/patient.getPatientSidebarPatientSidebar.md +14 -1
- package/docs/operations/patient.importVitals.md +21 -1
- package/docs/operations/patient.listEncounters.md +4 -0
- package/docs/operations/patient.login.md +2 -0
- package/docs/operations/patient.register.md +52 -44
- package/docs/operations/patient.setPreferredPharmacy.md +14 -9
- package/docs/operations/patient.submitPatientIntake.md +703 -0
- package/docs/operations/patient.updateDriversLicense.md +127 -0
- package/docs/operations/patient.uploadPhoto.md +5 -2
- package/docs/operations/vitals.recordVitals.md +9 -3
- package/package.json +1 -1
- package/docs/models/AthenaUpdateDriversLicenseResponse.md +0 -15
package/dist/index.js
CHANGED
|
@@ -367,6 +367,60 @@ var AuthClient = class extends BaseServiceClient {
|
|
|
367
367
|
}
|
|
368
368
|
};
|
|
369
369
|
|
|
370
|
+
// src/models/openapi-generated/diagnostics/models/RapidTestResult.ts
|
|
371
|
+
function RapidTestResultToJSON(value) {
|
|
372
|
+
return value;
|
|
373
|
+
}
|
|
374
|
+
|
|
375
|
+
// src/models/openapi-generated/diagnostics/models/RapidTestType.ts
|
|
376
|
+
function RapidTestTypeToJSON(value) {
|
|
377
|
+
return value;
|
|
378
|
+
}
|
|
379
|
+
|
|
380
|
+
// src/models/openapi-generated/diagnostics/models/SpecimenType.ts
|
|
381
|
+
function SpecimenTypeToJSON(value) {
|
|
382
|
+
return value;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
// src/models/openapi-generated/diagnostics/models/CreateRapidTestRequest.ts
|
|
386
|
+
function CreateRapidTestRequestToJSON(json) {
|
|
387
|
+
return CreateRapidTestRequestToJSONTyped(json, false);
|
|
388
|
+
}
|
|
389
|
+
function CreateRapidTestRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
390
|
+
if (value == null) {
|
|
391
|
+
return value;
|
|
392
|
+
}
|
|
393
|
+
return {
|
|
394
|
+
"administered_date": value["administered_date"],
|
|
395
|
+
"device_name": value["device_name"],
|
|
396
|
+
"lot_number": value["lot_number"],
|
|
397
|
+
"notes": value["notes"],
|
|
398
|
+
"performed_date": value["performed_date"] == null ? value["performed_date"] : value["performed_date"].toISOString().substring(0, 10),
|
|
399
|
+
"performed_datetime": value["performed_datetime"] == null ? value["performed_datetime"] : value["performed_datetime"].toISOString(),
|
|
400
|
+
"quantitative_unit": value["quantitative_unit"],
|
|
401
|
+
"quantitative_value": value["quantitative_value"],
|
|
402
|
+
"result": RapidTestResultToJSON(value["result"]),
|
|
403
|
+
"specimen_type": SpecimenTypeToJSON(value["specimen_type"]),
|
|
404
|
+
"type": RapidTestTypeToJSON(value["type"])
|
|
405
|
+
};
|
|
406
|
+
}
|
|
407
|
+
|
|
408
|
+
// src/models/openapi-generated/diagnostics/models/GetScanUploadUrlRequest.ts
|
|
409
|
+
function GetScanUploadUrlRequestToJSON(json) {
|
|
410
|
+
return GetScanUploadUrlRequestToJSONTyped(json, false);
|
|
411
|
+
}
|
|
412
|
+
function GetScanUploadUrlRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
413
|
+
if (value == null) {
|
|
414
|
+
return value;
|
|
415
|
+
}
|
|
416
|
+
return {
|
|
417
|
+
"content_type": value["content_type"],
|
|
418
|
+
"filename": value["filename"],
|
|
419
|
+
"gtin": value["gtin"],
|
|
420
|
+
"test_id": value["test_id"]
|
|
421
|
+
};
|
|
422
|
+
}
|
|
423
|
+
|
|
370
424
|
// src/clients/DiagnosticsClient.ts
|
|
371
425
|
var DiagnosticsClient = class extends BaseServiceClient {
|
|
372
426
|
constructor(http) {
|
|
@@ -375,7 +429,7 @@ var DiagnosticsClient = class extends BaseServiceClient {
|
|
|
375
429
|
connect() {
|
|
376
430
|
return this.connectService();
|
|
377
431
|
}
|
|
378
|
-
// ─── Diagnostics
|
|
432
|
+
// ─── Diagnostics ───────────────────────────────────────────────────
|
|
379
433
|
/**
|
|
380
434
|
* List all diagnostics/observations for a patient.
|
|
381
435
|
* GET /patients/{patient_id}/diagnostics
|
|
@@ -385,10 +439,16 @@ var DiagnosticsClient = class extends BaseServiceClient {
|
|
|
385
439
|
pathParams: { patient_id: patientId }
|
|
386
440
|
});
|
|
387
441
|
}
|
|
388
|
-
// ─── GS1 Lookup
|
|
442
|
+
// ─── GS1 Lookup ───────────────────────────────────────────────────
|
|
389
443
|
/**
|
|
390
444
|
* Look up test information by GS1 barcode.
|
|
391
445
|
* GET /patients/{patient_id}/diagnostics/lookup?gs1=...
|
|
446
|
+
*
|
|
447
|
+
* Returns the loose-typed `Gs1LookupResult` (not the OpenAPI-generated
|
|
448
|
+
* `GS1LookupResponse`) because the mock `product` payload returned by the
|
|
449
|
+
* OraQuick lookup is still being normalized — the hand-maintained shape
|
|
450
|
+
* with `product?: Record<string, unknown> | null` tolerates that churn
|
|
451
|
+
* without a contract regenerate on every mock iteration.
|
|
392
452
|
*/
|
|
393
453
|
lookupByGs1(patientId, query) {
|
|
394
454
|
return this.send("GET", "/patients/{patient_id}/diagnostics/lookup", {
|
|
@@ -396,29 +456,31 @@ var DiagnosticsClient = class extends BaseServiceClient {
|
|
|
396
456
|
query
|
|
397
457
|
});
|
|
398
458
|
}
|
|
399
|
-
// ─── Scan Upload URL
|
|
459
|
+
// ─── Scan Upload URL ──────────────────────────────────────────────
|
|
400
460
|
/**
|
|
401
461
|
* Get a presigned S3/Wasabi upload URL for a diagnostic scan.
|
|
402
462
|
* POST /patients/{patient_id}/diagnostics/scan-upload-url
|
|
403
463
|
*/
|
|
404
464
|
getScanUploadUrl(patientId, request) {
|
|
465
|
+
const body = "type" in request && "test_id" in request ? GetScanUploadUrlRequestToJSON(request) : request;
|
|
405
466
|
return this.send("POST", "/patients/{patient_id}/diagnostics/scan-upload-url", {
|
|
406
467
|
pathParams: { patient_id: patientId },
|
|
407
|
-
body
|
|
468
|
+
body
|
|
408
469
|
});
|
|
409
470
|
}
|
|
410
|
-
// ─── Rapid Test
|
|
471
|
+
// ─── Rapid Test ───────────────────────────────────────────────────
|
|
411
472
|
/**
|
|
412
473
|
* Create a rapid test result for a patient.
|
|
413
474
|
* POST /patients/{patient_id}/diagnostics/rapid-tests
|
|
414
475
|
*/
|
|
415
476
|
createRapidTest(patientId, request) {
|
|
477
|
+
const body = "type" in request && "result" in request ? CreateRapidTestRequestToJSON(request) : request;
|
|
416
478
|
return this.send("POST", "/patients/{patient_id}/diagnostics/rapid-tests", {
|
|
417
479
|
pathParams: { patient_id: patientId },
|
|
418
|
-
body
|
|
480
|
+
body
|
|
419
481
|
});
|
|
420
482
|
}
|
|
421
|
-
// ─── Test Result
|
|
483
|
+
// ─── Test Result ──────────────────────────────────────────────────
|
|
422
484
|
/**
|
|
423
485
|
* Get a specific diagnostic test result by ID.
|
|
424
486
|
* GET /patients/{patient_id}/diagnostics/{test_id}
|
|
@@ -428,6 +490,17 @@ var DiagnosticsClient = class extends BaseServiceClient {
|
|
|
428
490
|
pathParams: { patient_id: patientId, test_id: testId }
|
|
429
491
|
});
|
|
430
492
|
}
|
|
493
|
+
// ─── Test Image (captured scan retrieval) ─────────────────────────
|
|
494
|
+
/**
|
|
495
|
+
* Get a short-lived presigned S3 GET URL for the image captured for a
|
|
496
|
+
* diagnostic test result — the retrieval counterpart to `getScanUploadUrl`.
|
|
497
|
+
* GET /patients/{patient_id}/diagnostics/{test_id}/image
|
|
498
|
+
*/
|
|
499
|
+
getTestImage(patientId, testId) {
|
|
500
|
+
return this.send("GET", "/patients/{patient_id}/diagnostics/{test_id}/image", {
|
|
501
|
+
pathParams: { patient_id: patientId, test_id: testId }
|
|
502
|
+
});
|
|
503
|
+
}
|
|
431
504
|
};
|
|
432
505
|
|
|
433
506
|
// src/clients/EhrClient.ts
|
|
@@ -868,99 +941,74 @@ function CreateMedicationRequestToJSONTyped(value, ignoreDiscriminator = false)
|
|
|
868
941
|
};
|
|
869
942
|
}
|
|
870
943
|
|
|
871
|
-
// src/models/openapi-generated/patient/models/
|
|
872
|
-
function
|
|
873
|
-
return
|
|
874
|
-
}
|
|
875
|
-
|
|
876
|
-
// src/models/openapi-generated/patient/models/EncounterHospitalization.ts
|
|
877
|
-
function EncounterHospitalizationToJSON(json) {
|
|
878
|
-
return EncounterHospitalizationToJSONTyped(json, false);
|
|
944
|
+
// src/models/openapi-generated/patient/models/CreateEncounterLocationRequest.ts
|
|
945
|
+
function CreateEncounterLocationRequestToJSON(json) {
|
|
946
|
+
return CreateEncounterLocationRequestToJSONTyped(json, false);
|
|
879
947
|
}
|
|
880
|
-
function
|
|
948
|
+
function CreateEncounterLocationRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
881
949
|
if (value == null) {
|
|
882
950
|
return value;
|
|
883
951
|
}
|
|
884
952
|
return {
|
|
885
|
-
"
|
|
886
|
-
"
|
|
887
|
-
"
|
|
888
|
-
"
|
|
889
|
-
"
|
|
890
|
-
"re_admission_code": value["re_admission_code"]
|
|
953
|
+
"location_display": value["location_display"],
|
|
954
|
+
"location_id": value["location_id"],
|
|
955
|
+
"period_end": value["period_end"],
|
|
956
|
+
"period_start": value["period_start"],
|
|
957
|
+
"status": value["status"]
|
|
891
958
|
};
|
|
892
959
|
}
|
|
893
960
|
|
|
894
|
-
// src/models/openapi-generated/patient/models/
|
|
895
|
-
function
|
|
896
|
-
return
|
|
961
|
+
// src/models/openapi-generated/patient/models/CreateEncounterParticipantRequest.ts
|
|
962
|
+
function CreateEncounterParticipantRequestToJSON(json) {
|
|
963
|
+
return CreateEncounterParticipantRequestToJSONTyped(json, false);
|
|
897
964
|
}
|
|
898
|
-
function
|
|
965
|
+
function CreateEncounterParticipantRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
899
966
|
if (value == null) {
|
|
900
967
|
return value;
|
|
901
968
|
}
|
|
902
969
|
return {
|
|
903
|
-
"
|
|
904
|
-
"
|
|
905
|
-
"
|
|
906
|
-
"
|
|
970
|
+
"participant_type": value["participant_type"],
|
|
971
|
+
"period_end": value["period_end"],
|
|
972
|
+
"period_start": value["period_start"],
|
|
973
|
+
"practitioner_display": value["practitioner_display"],
|
|
974
|
+
"practitioner_id": value["practitioner_id"]
|
|
907
975
|
};
|
|
908
976
|
}
|
|
909
977
|
|
|
910
|
-
// src/models/openapi-generated/patient/models/
|
|
911
|
-
function
|
|
912
|
-
return
|
|
913
|
-
}
|
|
914
|
-
|
|
915
|
-
// src/models/openapi-generated/patient/models/LocationStatus.ts
|
|
916
|
-
function LocationStatusToJSON(value) {
|
|
917
|
-
return value;
|
|
918
|
-
}
|
|
919
|
-
|
|
920
|
-
// src/models/openapi-generated/patient/models/EncounterLocation.ts
|
|
921
|
-
function EncounterLocationToJSON(json) {
|
|
922
|
-
return EncounterLocationToJSONTyped(json, false);
|
|
978
|
+
// src/models/openapi-generated/patient/models/CreateEncounterDiagnosisRequest.ts
|
|
979
|
+
function CreateEncounterDiagnosisRequestToJSON(json) {
|
|
980
|
+
return CreateEncounterDiagnosisRequestToJSONTyped(json, false);
|
|
923
981
|
}
|
|
924
|
-
function
|
|
982
|
+
function CreateEncounterDiagnosisRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
925
983
|
if (value == null) {
|
|
926
984
|
return value;
|
|
927
985
|
}
|
|
928
986
|
return {
|
|
929
|
-
"
|
|
930
|
-
"
|
|
931
|
-
"
|
|
932
|
-
"
|
|
933
|
-
"status": LocationStatusToJSON(value["status"])
|
|
987
|
+
"condition_display": value["condition_display"],
|
|
988
|
+
"condition_id": value["condition_id"],
|
|
989
|
+
"rank": value["rank"],
|
|
990
|
+
"use_code": value["use_code"]
|
|
934
991
|
};
|
|
935
992
|
}
|
|
936
993
|
|
|
937
|
-
// src/models/openapi-generated/patient/models/
|
|
938
|
-
function
|
|
939
|
-
return
|
|
940
|
-
}
|
|
941
|
-
|
|
942
|
-
// src/models/openapi-generated/patient/models/EncounterParticipant.ts
|
|
943
|
-
function EncounterParticipantToJSON(json) {
|
|
944
|
-
return EncounterParticipantToJSONTyped(json, false);
|
|
994
|
+
// src/models/openapi-generated/patient/models/CreateEncounterHospitalizationRequest.ts
|
|
995
|
+
function CreateEncounterHospitalizationRequestToJSON(json) {
|
|
996
|
+
return CreateEncounterHospitalizationRequestToJSONTyped(json, false);
|
|
945
997
|
}
|
|
946
|
-
function
|
|
998
|
+
function CreateEncounterHospitalizationRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
947
999
|
if (value == null) {
|
|
948
1000
|
return value;
|
|
949
1001
|
}
|
|
950
1002
|
return {
|
|
951
|
-
"
|
|
952
|
-
"
|
|
953
|
-
"
|
|
954
|
-
"
|
|
955
|
-
"
|
|
1003
|
+
"admit_source_code": value["admit_source_code"],
|
|
1004
|
+
"destination_id": value["destination_id"],
|
|
1005
|
+
"discharge_disposition": value["discharge_disposition"],
|
|
1006
|
+
"origin_id": value["origin_id"],
|
|
1007
|
+
"pre_admission_id": value["pre_admission_id"],
|
|
1008
|
+
"re_admission_code": value["re_admission_code"]
|
|
956
1009
|
};
|
|
957
1010
|
}
|
|
958
1011
|
|
|
959
|
-
// src/models/openapi-generated/patient/models/EncounterStatus.ts
|
|
960
|
-
function EncounterStatusToJSON(value) {
|
|
961
|
-
return value;
|
|
962
|
-
}
|
|
963
|
-
|
|
964
1012
|
// src/models/openapi-generated/patient/models/CreateEncounterRequest.ts
|
|
965
1013
|
function CreateEncounterRequestToJSON(json) {
|
|
966
1014
|
return CreateEncounterRequestToJSONTyped(json, false);
|
|
@@ -972,18 +1020,18 @@ function CreateEncounterRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
972
1020
|
return {
|
|
973
1021
|
"appointment_id": value["appointment_id"],
|
|
974
1022
|
"created_by": value["created_by"],
|
|
975
|
-
"created_date": value["created_date"]
|
|
976
|
-
"diagnoses": value["diagnoses"] == null ? void 0 : value["diagnoses"].map(
|
|
977
|
-
"encounter_class":
|
|
1023
|
+
"created_date": value["created_date"],
|
|
1024
|
+
"diagnoses": value["diagnoses"] == null ? void 0 : value["diagnoses"].map(CreateEncounterDiagnosisRequestToJSON),
|
|
1025
|
+
"encounter_class": value["encounter_class"],
|
|
978
1026
|
"encounter_id": value["encounter_id"],
|
|
979
1027
|
"fhir_id": value["fhir_id"],
|
|
980
|
-
"hospitalization":
|
|
1028
|
+
"hospitalization": CreateEncounterHospitalizationRequestToJSON(value["hospitalization"]),
|
|
981
1029
|
"length_minutes": value["length_minutes"],
|
|
982
|
-
"locations": value["locations"] == null ? void 0 : value["locations"].map(
|
|
983
|
-
"participants": value["participants"] == null ? void 0 : value["participants"].map(
|
|
1030
|
+
"locations": value["locations"] == null ? void 0 : value["locations"].map(CreateEncounterLocationRequestToJSON),
|
|
1031
|
+
"participants": value["participants"] == null ? void 0 : value["participants"].map(CreateEncounterParticipantRequestToJSON),
|
|
984
1032
|
"patient_id": value["patient_id"],
|
|
985
|
-
"period_end": value["period_end"]
|
|
986
|
-
"period_start": value["period_start"]
|
|
1033
|
+
"period_end": value["period_end"],
|
|
1034
|
+
"period_start": value["period_start"],
|
|
987
1035
|
"priority_code": value["priority_code"],
|
|
988
1036
|
"priority_display": value["priority_display"],
|
|
989
1037
|
"reason_code": value["reason_code"],
|
|
@@ -992,14 +1040,904 @@ function CreateEncounterRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
992
1040
|
"service_provider_id": value["service_provider_id"],
|
|
993
1041
|
"service_type_code": value["service_type_code"],
|
|
994
1042
|
"service_type_display": value["service_type_display"],
|
|
995
|
-
"status":
|
|
1043
|
+
"status": value["status"],
|
|
996
1044
|
"type_code": value["type_code"],
|
|
997
1045
|
"type_display": value["type_display"]
|
|
998
1046
|
};
|
|
999
1047
|
}
|
|
1000
1048
|
|
|
1049
|
+
// src/models/openapi-generated/patient/models/ProcedureStatus.ts
|
|
1050
|
+
function ProcedureStatusToJSON(value) {
|
|
1051
|
+
return value;
|
|
1052
|
+
}
|
|
1053
|
+
|
|
1054
|
+
// src/models/openapi-generated/patient/models/ProcedureLaterality.ts
|
|
1055
|
+
function ProcedureLateralityToJSON(value) {
|
|
1056
|
+
return value;
|
|
1057
|
+
}
|
|
1058
|
+
|
|
1059
|
+
// src/models/openapi-generated/patient/models/IntakeSurgery.ts
|
|
1060
|
+
function IntakeSurgeryToJSON(json) {
|
|
1061
|
+
return IntakeSurgeryToJSONTyped(json, false);
|
|
1062
|
+
}
|
|
1063
|
+
function IntakeSurgeryToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1064
|
+
if (value == null) {
|
|
1065
|
+
return value;
|
|
1066
|
+
}
|
|
1067
|
+
return {
|
|
1068
|
+
"anesthesia_type": value["anesthesia_type"],
|
|
1069
|
+
"body_sites": value["body_sites"],
|
|
1070
|
+
"complications": value["complications"],
|
|
1071
|
+
"cpt_code": value["cpt_code"],
|
|
1072
|
+
"description": value["description"],
|
|
1073
|
+
"facility": value["facility"],
|
|
1074
|
+
"indication": value["indication"],
|
|
1075
|
+
"laterality": ProcedureLateralityToJSON(value["laterality"]),
|
|
1076
|
+
"notes": value["notes"],
|
|
1077
|
+
"outcome": value["outcome"],
|
|
1078
|
+
"performed_date": value["performed_date"] == null ? value["performed_date"] : value["performed_date"].toISOString().substring(0, 10),
|
|
1079
|
+
"performed_date_end": value["performed_date_end"] == null ? value["performed_date_end"] : value["performed_date_end"].toISOString().substring(0, 10),
|
|
1080
|
+
"performer_name": value["performer_name"],
|
|
1081
|
+
"snomed_code": value["snomed_code"],
|
|
1082
|
+
"status": ProcedureStatusToJSON(value["status"])
|
|
1083
|
+
};
|
|
1084
|
+
}
|
|
1085
|
+
|
|
1086
|
+
// src/models/openapi-generated/patient/models/FamilyRelationship.ts
|
|
1087
|
+
function FamilyRelationshipToJSON(value) {
|
|
1088
|
+
return value;
|
|
1089
|
+
}
|
|
1090
|
+
|
|
1091
|
+
// src/models/openapi-generated/patient/models/FamilyHistoryStatus.ts
|
|
1092
|
+
function FamilyHistoryStatusToJSON(value) {
|
|
1093
|
+
return value;
|
|
1094
|
+
}
|
|
1095
|
+
|
|
1096
|
+
// src/models/openapi-generated/patient/models/FamilyCondition.ts
|
|
1097
|
+
function FamilyConditionToJSON(json) {
|
|
1098
|
+
return FamilyConditionToJSONTyped(json, false);
|
|
1099
|
+
}
|
|
1100
|
+
function FamilyConditionToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1101
|
+
if (value == null) {
|
|
1102
|
+
return value;
|
|
1103
|
+
}
|
|
1104
|
+
return {
|
|
1105
|
+
"age_at_death": value["age_at_death"],
|
|
1106
|
+
"age_at_onset": value["age_at_onset"],
|
|
1107
|
+
"condition": value["condition"],
|
|
1108
|
+
"icd10_code": value["icd10_code"],
|
|
1109
|
+
"notes": value["notes"],
|
|
1110
|
+
"snomed_code": value["snomed_code"]
|
|
1111
|
+
};
|
|
1112
|
+
}
|
|
1113
|
+
|
|
1114
|
+
// src/models/openapi-generated/patient/models/IntakeFamilyHistory.ts
|
|
1115
|
+
function IntakeFamilyHistoryToJSON(json) {
|
|
1116
|
+
return IntakeFamilyHistoryToJSONTyped(json, false);
|
|
1117
|
+
}
|
|
1118
|
+
function IntakeFamilyHistoryToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1119
|
+
if (value == null) {
|
|
1120
|
+
return value;
|
|
1121
|
+
}
|
|
1122
|
+
return {
|
|
1123
|
+
"age_at_death": value["age_at_death"],
|
|
1124
|
+
"biological": value["biological"],
|
|
1125
|
+
"born_date": value["born_date"] == null ? value["born_date"] : value["born_date"].toISOString().substring(0, 10),
|
|
1126
|
+
"cause_of_death": value["cause_of_death"],
|
|
1127
|
+
"conditions": value["conditions"] == null ? void 0 : value["conditions"].map(FamilyConditionToJSON),
|
|
1128
|
+
"deceased": value["deceased"],
|
|
1129
|
+
"member_name": value["member_name"],
|
|
1130
|
+
"notes": value["notes"],
|
|
1131
|
+
"recorded_date": value["recorded_date"] == null ? value["recorded_date"] : value["recorded_date"].toISOString().substring(0, 10),
|
|
1132
|
+
"relationship": FamilyRelationshipToJSON(value["relationship"]),
|
|
1133
|
+
"sex": value["sex"],
|
|
1134
|
+
"status": FamilyHistoryStatusToJSON(value["status"])
|
|
1135
|
+
};
|
|
1136
|
+
}
|
|
1137
|
+
|
|
1138
|
+
// src/models/openapi-generated/patient/models/PerinatalHistory.ts
|
|
1139
|
+
function PerinatalHistoryToJSON(json) {
|
|
1140
|
+
return PerinatalHistoryToJSONTyped(json, false);
|
|
1141
|
+
}
|
|
1142
|
+
function PerinatalHistoryToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1143
|
+
if (value == null) {
|
|
1144
|
+
return value;
|
|
1145
|
+
}
|
|
1146
|
+
return {
|
|
1147
|
+
"delivery_date": value["delivery_date"] == null ? value["delivery_date"] : value["delivery_date"].toISOString().substring(0, 10),
|
|
1148
|
+
"delivery_method": value["delivery_method"],
|
|
1149
|
+
"gestational_age_weeks": value["gestational_age_weeks"],
|
|
1150
|
+
"maternal_complications": value["maternal_complications"],
|
|
1151
|
+
"neonatal_complications": value["neonatal_complications"],
|
|
1152
|
+
"notes": value["notes"],
|
|
1153
|
+
"outcome": value["outcome"],
|
|
1154
|
+
"pregnancy_year": value["pregnancy_year"]
|
|
1155
|
+
};
|
|
1156
|
+
}
|
|
1157
|
+
|
|
1158
|
+
// src/models/openapi-generated/patient/models/GynHistory.ts
|
|
1159
|
+
function GynHistoryToJSON(json) {
|
|
1160
|
+
return GynHistoryToJSONTyped(json, false);
|
|
1161
|
+
}
|
|
1162
|
+
function GynHistoryToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1163
|
+
if (value == null) {
|
|
1164
|
+
return value;
|
|
1165
|
+
}
|
|
1166
|
+
return {
|
|
1167
|
+
"cervical_screening_history": value["cervical_screening_history"],
|
|
1168
|
+
"contraception": value["contraception"],
|
|
1169
|
+
"last_menstrual_period": value["last_menstrual_period"] == null ? value["last_menstrual_period"] : value["last_menstrual_period"].toISOString().substring(0, 10),
|
|
1170
|
+
"menarche_age": value["menarche_age"],
|
|
1171
|
+
"menopause_age": value["menopause_age"],
|
|
1172
|
+
"menstrual_history": value["menstrual_history"],
|
|
1173
|
+
"notes": value["notes"],
|
|
1174
|
+
"pregnancy_history": value["pregnancy_history"]
|
|
1175
|
+
};
|
|
1176
|
+
}
|
|
1177
|
+
|
|
1178
|
+
// src/models/openapi-generated/patient/models/SubstanceStatus.ts
|
|
1179
|
+
function SubstanceStatusToJSON(value) {
|
|
1180
|
+
return value;
|
|
1181
|
+
}
|
|
1182
|
+
|
|
1183
|
+
// src/models/openapi-generated/patient/models/SubstanceUse.ts
|
|
1184
|
+
function SubstanceUseToJSON(json) {
|
|
1185
|
+
return SubstanceUseToJSONTyped(json, false);
|
|
1186
|
+
}
|
|
1187
|
+
function SubstanceUseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1188
|
+
if (value == null) {
|
|
1189
|
+
return value;
|
|
1190
|
+
}
|
|
1191
|
+
return {
|
|
1192
|
+
"frequency": value["frequency"],
|
|
1193
|
+
"notes": value["notes"],
|
|
1194
|
+
"quit_year": value["quit_year"],
|
|
1195
|
+
"route": value["route"],
|
|
1196
|
+
"start_year": value["start_year"],
|
|
1197
|
+
"status": SubstanceStatusToJSON(value["status"]),
|
|
1198
|
+
"substance": value["substance"]
|
|
1199
|
+
};
|
|
1200
|
+
}
|
|
1201
|
+
|
|
1202
|
+
// src/models/openapi-generated/patient/models/DietCategory.ts
|
|
1203
|
+
function DietCategoryToJSON(value) {
|
|
1204
|
+
return value;
|
|
1205
|
+
}
|
|
1206
|
+
|
|
1207
|
+
// src/models/openapi-generated/patient/models/ExerciseFrequency.ts
|
|
1208
|
+
function ExerciseFrequencyToJSON(value) {
|
|
1209
|
+
return value;
|
|
1210
|
+
}
|
|
1211
|
+
|
|
1212
|
+
// src/models/openapi-generated/patient/models/LivingSituation.ts
|
|
1213
|
+
function LivingSituationToJSON(value) {
|
|
1214
|
+
return value;
|
|
1215
|
+
}
|
|
1216
|
+
|
|
1217
|
+
// src/models/openapi-generated/patient/models/SmokingStatus.ts
|
|
1218
|
+
function SmokingStatusToJSON(value) {
|
|
1219
|
+
return value;
|
|
1220
|
+
}
|
|
1221
|
+
|
|
1222
|
+
// src/models/openapi-generated/patient/models/TobaccoUse.ts
|
|
1223
|
+
function TobaccoUseToJSON(json) {
|
|
1224
|
+
return TobaccoUseToJSONTyped(json, false);
|
|
1225
|
+
}
|
|
1226
|
+
function TobaccoUseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1227
|
+
if (value == null) {
|
|
1228
|
+
return value;
|
|
1229
|
+
}
|
|
1230
|
+
return {
|
|
1231
|
+
"cessation_aids": value["cessation_aids"],
|
|
1232
|
+
"cigarettes_per_day": value["cigarettes_per_day"],
|
|
1233
|
+
"pack_years": value["pack_years"],
|
|
1234
|
+
"quit_year": value["quit_year"],
|
|
1235
|
+
"start_year": value["start_year"],
|
|
1236
|
+
"status": SmokingStatusToJSON(value["status"])
|
|
1237
|
+
};
|
|
1238
|
+
}
|
|
1239
|
+
|
|
1240
|
+
// src/models/openapi-generated/patient/models/AlcoholFrequency.ts
|
|
1241
|
+
function AlcoholFrequencyToJSON(value) {
|
|
1242
|
+
return value;
|
|
1243
|
+
}
|
|
1244
|
+
|
|
1245
|
+
// src/models/openapi-generated/patient/models/AlcoholUse.ts
|
|
1246
|
+
function AlcoholUseToJSON(json) {
|
|
1247
|
+
return AlcoholUseToJSONTyped(json, false);
|
|
1248
|
+
}
|
|
1249
|
+
function AlcoholUseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1250
|
+
if (value == null) {
|
|
1251
|
+
return value;
|
|
1252
|
+
}
|
|
1253
|
+
return {
|
|
1254
|
+
"binge_drinking": value["binge_drinking"],
|
|
1255
|
+
"drinks_per_week": value["drinks_per_week"],
|
|
1256
|
+
"frequency": AlcoholFrequencyToJSON(value["frequency"]),
|
|
1257
|
+
"notes": value["notes"]
|
|
1258
|
+
};
|
|
1259
|
+
}
|
|
1260
|
+
|
|
1261
|
+
// src/models/openapi-generated/patient/models/GenderIdentity.ts
|
|
1262
|
+
function GenderIdentityToJSON(value) {
|
|
1263
|
+
return value;
|
|
1264
|
+
}
|
|
1265
|
+
|
|
1266
|
+
// src/models/openapi-generated/patient/models/EducationLevel.ts
|
|
1267
|
+
function EducationLevelToJSON(value) {
|
|
1268
|
+
return value;
|
|
1269
|
+
}
|
|
1270
|
+
|
|
1271
|
+
// src/models/openapi-generated/patient/models/SexualOrientation.ts
|
|
1272
|
+
function SexualOrientationToJSON(value) {
|
|
1273
|
+
return value;
|
|
1274
|
+
}
|
|
1275
|
+
|
|
1276
|
+
// src/models/openapi-generated/patient/models/IntakeSocialHistory.ts
|
|
1277
|
+
function IntakeSocialHistoryToJSON(json) {
|
|
1278
|
+
return IntakeSocialHistoryToJSONTyped(json, false);
|
|
1279
|
+
}
|
|
1280
|
+
function IntakeSocialHistoryToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1281
|
+
if (value == null) {
|
|
1282
|
+
return value;
|
|
1283
|
+
}
|
|
1284
|
+
return {
|
|
1285
|
+
"alcohol": AlcoholUseToJSON(value["alcohol"]),
|
|
1286
|
+
"contraception": value["contraception"],
|
|
1287
|
+
"diet_category": DietCategoryToJSON(value["diet_category"]),
|
|
1288
|
+
"diet_description": value["diet_description"],
|
|
1289
|
+
"education": EducationLevelToJSON(value["education"]),
|
|
1290
|
+
"employer": value["employer"],
|
|
1291
|
+
"exercise_frequency": ExerciseFrequencyToJSON(value["exercise_frequency"]),
|
|
1292
|
+
"exercise_minutes_per_week": value["exercise_minutes_per_week"],
|
|
1293
|
+
"gender_identity": GenderIdentityToJSON(value["gender_identity"]),
|
|
1294
|
+
"living_situation": LivingSituationToJSON(value["living_situation"]),
|
|
1295
|
+
"notes": value["notes"],
|
|
1296
|
+
"number_of_dependents": value["number_of_dependents"],
|
|
1297
|
+
"occupation": value["occupation"],
|
|
1298
|
+
"occupational_exposures": value["occupational_exposures"],
|
|
1299
|
+
"sexual_orientation": SexualOrientationToJSON(value["sexual_orientation"]),
|
|
1300
|
+
"sexually_active": value["sexually_active"],
|
|
1301
|
+
"substances": value["substances"] == null ? void 0 : value["substances"].map(SubstanceUseToJSON),
|
|
1302
|
+
"tobacco": TobaccoUseToJSON(value["tobacco"]),
|
|
1303
|
+
"travel_history": value["travel_history"]
|
|
1304
|
+
};
|
|
1305
|
+
}
|
|
1306
|
+
|
|
1307
|
+
// src/models/openapi-generated/patient/models/CancerTreatmentStatus.ts
|
|
1308
|
+
function CancerTreatmentStatusToJSON(value) {
|
|
1309
|
+
return value;
|
|
1310
|
+
}
|
|
1311
|
+
|
|
1312
|
+
// src/models/openapi-generated/patient/models/TreatmentModality.ts
|
|
1313
|
+
function TreatmentModalityToJSON(value) {
|
|
1314
|
+
return value;
|
|
1315
|
+
}
|
|
1316
|
+
|
|
1317
|
+
// src/models/openapi-generated/patient/models/IntakeCancerTreatment.ts
|
|
1318
|
+
function IntakeCancerTreatmentToJSON(json) {
|
|
1319
|
+
return IntakeCancerTreatmentToJSONTyped(json, false);
|
|
1320
|
+
}
|
|
1321
|
+
function IntakeCancerTreatmentToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1322
|
+
if (value == null) {
|
|
1323
|
+
return value;
|
|
1324
|
+
}
|
|
1325
|
+
return {
|
|
1326
|
+
"description": value["description"],
|
|
1327
|
+
"end_date": value["end_date"] == null ? value["end_date"] : value["end_date"].toISOString().substring(0, 10),
|
|
1328
|
+
"facility": value["facility"],
|
|
1329
|
+
"modality": TreatmentModalityToJSON(value["modality"]),
|
|
1330
|
+
"notes": value["notes"],
|
|
1331
|
+
"provider_name": value["provider_name"],
|
|
1332
|
+
"response": value["response"],
|
|
1333
|
+
"start_date": value["start_date"] == null ? value["start_date"] : value["start_date"].toISOString().substring(0, 10),
|
|
1334
|
+
"status": CancerTreatmentStatusToJSON(value["status"])
|
|
1335
|
+
};
|
|
1336
|
+
}
|
|
1337
|
+
|
|
1338
|
+
// src/models/openapi-generated/patient/models/TNMStaging.ts
|
|
1339
|
+
function TNMStagingToJSON(json) {
|
|
1340
|
+
return TNMStagingToJSONTyped(json, false);
|
|
1341
|
+
}
|
|
1342
|
+
function TNMStagingToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1343
|
+
if (value == null) {
|
|
1344
|
+
return value;
|
|
1345
|
+
}
|
|
1346
|
+
return {
|
|
1347
|
+
"clinical": value["clinical"],
|
|
1348
|
+
"edition": value["edition"],
|
|
1349
|
+
"m": value["m"],
|
|
1350
|
+
"n": value["n"],
|
|
1351
|
+
"t": value["t"]
|
|
1352
|
+
};
|
|
1353
|
+
}
|
|
1354
|
+
|
|
1355
|
+
// src/models/openapi-generated/patient/models/CancerLaterality.ts
|
|
1356
|
+
function CancerLateralityToJSON(value) {
|
|
1357
|
+
return value;
|
|
1358
|
+
}
|
|
1359
|
+
|
|
1360
|
+
// src/models/openapi-generated/patient/models/CancerStage.ts
|
|
1361
|
+
function CancerStageToJSON(value) {
|
|
1362
|
+
return value;
|
|
1363
|
+
}
|
|
1364
|
+
|
|
1365
|
+
// src/models/openapi-generated/patient/models/IntakeCancerCase.ts
|
|
1366
|
+
function IntakeCancerCaseToJSON(json) {
|
|
1367
|
+
return IntakeCancerCaseToJSONTyped(json, false);
|
|
1368
|
+
}
|
|
1369
|
+
function IntakeCancerCaseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1370
|
+
if (value == null) {
|
|
1371
|
+
return value;
|
|
1372
|
+
}
|
|
1373
|
+
return {
|
|
1374
|
+
"biomarkers": value["biomarkers"],
|
|
1375
|
+
"cancer_type": value["cancer_type"],
|
|
1376
|
+
"diagnosis_date": value["diagnosis_date"] == null ? value["diagnosis_date"] : value["diagnosis_date"].toISOString().substring(0, 10),
|
|
1377
|
+
"diagnosis_method": value["diagnosis_method"],
|
|
1378
|
+
"grade": value["grade"],
|
|
1379
|
+
"histology": value["histology"],
|
|
1380
|
+
"histology_code": value["histology_code"],
|
|
1381
|
+
"icd10_code": value["icd10_code"],
|
|
1382
|
+
"laterality": CancerLateralityToJSON(value["laterality"]),
|
|
1383
|
+
"metastatic_sites": value["metastatic_sites"],
|
|
1384
|
+
"notes": value["notes"],
|
|
1385
|
+
"primary_site": value["primary_site"],
|
|
1386
|
+
"recurrence_date": value["recurrence_date"] == null ? value["recurrence_date"] : value["recurrence_date"].toISOString().substring(0, 10),
|
|
1387
|
+
"remission_date": value["remission_date"] == null ? value["remission_date"] : value["remission_date"].toISOString().substring(0, 10),
|
|
1388
|
+
"snomed_code": value["snomed_code"],
|
|
1389
|
+
"stage": CancerStageToJSON(value["stage"]),
|
|
1390
|
+
"subsite": value["subsite"],
|
|
1391
|
+
"tnm": TNMStagingToJSON(value["tnm"]),
|
|
1392
|
+
"treatments": value["treatments"] == null ? void 0 : value["treatments"].map(IntakeCancerTreatmentToJSON)
|
|
1393
|
+
};
|
|
1394
|
+
}
|
|
1395
|
+
|
|
1396
|
+
// src/models/openapi-generated/patient/models/IntakeMedication.ts
|
|
1397
|
+
function IntakeMedicationToJSON(json) {
|
|
1398
|
+
return IntakeMedicationToJSONTyped(json, false);
|
|
1399
|
+
}
|
|
1400
|
+
function IntakeMedicationToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1401
|
+
if (value == null) {
|
|
1402
|
+
return value;
|
|
1403
|
+
}
|
|
1404
|
+
return {
|
|
1405
|
+
"authored_on": value["authored_on"] == null ? value["authored_on"] : value["authored_on"].toISOString().substring(0, 10),
|
|
1406
|
+
"brand_name": value["brand_name"],
|
|
1407
|
+
"discontinued_reason": value["discontinued_reason"],
|
|
1408
|
+
"dosage": DosageToJSON(value["dosage"]),
|
|
1409
|
+
"end_date": value["end_date"] == null ? value["end_date"] : value["end_date"].toISOString().substring(0, 10),
|
|
1410
|
+
"generic_name": value["generic_name"],
|
|
1411
|
+
"indication": value["indication"],
|
|
1412
|
+
"name": value["name"],
|
|
1413
|
+
"ndc_code": value["ndc_code"],
|
|
1414
|
+
"notes": value["notes"],
|
|
1415
|
+
"pharmacy": value["pharmacy"],
|
|
1416
|
+
"prescriber_name": value["prescriber_name"],
|
|
1417
|
+
"refills_authorized": value["refills_authorized"],
|
|
1418
|
+
"refills_remaining": value["refills_remaining"],
|
|
1419
|
+
"route": MedicationRouteToJSON(value["route"]),
|
|
1420
|
+
"rxnorm_code": value["rxnorm_code"],
|
|
1421
|
+
"start_date": value["start_date"] == null ? value["start_date"] : value["start_date"].toISOString().substring(0, 10),
|
|
1422
|
+
"status": MedicationStatusToJSON(value["status"])
|
|
1423
|
+
};
|
|
1424
|
+
}
|
|
1425
|
+
|
|
1426
|
+
// src/models/openapi-generated/patient/models/AllergyStatus.ts
|
|
1427
|
+
function AllergyStatusToJSON(value) {
|
|
1428
|
+
return value;
|
|
1429
|
+
}
|
|
1430
|
+
|
|
1431
|
+
// src/models/openapi-generated/patient/models/AllergyCategory.ts
|
|
1432
|
+
function AllergyCategoryToJSON(value) {
|
|
1433
|
+
return value;
|
|
1434
|
+
}
|
|
1435
|
+
|
|
1436
|
+
// src/models/openapi-generated/patient/models/CodedConcept.ts
|
|
1437
|
+
function CodedConceptToJSON(json) {
|
|
1438
|
+
return CodedConceptToJSONTyped(json, false);
|
|
1439
|
+
}
|
|
1440
|
+
function CodedConceptToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1441
|
+
if (value == null) {
|
|
1442
|
+
return value;
|
|
1443
|
+
}
|
|
1444
|
+
return {
|
|
1445
|
+
"code": value["code"],
|
|
1446
|
+
"display": value["display"],
|
|
1447
|
+
"system": value["system"]
|
|
1448
|
+
};
|
|
1449
|
+
}
|
|
1450
|
+
|
|
1451
|
+
// src/models/openapi-generated/patient/models/IntoleranceType.ts
|
|
1452
|
+
function IntoleranceTypeToJSON(value) {
|
|
1453
|
+
return value;
|
|
1454
|
+
}
|
|
1455
|
+
|
|
1456
|
+
// src/models/openapi-generated/patient/models/ReactionSeverity.ts
|
|
1457
|
+
function ReactionSeverityToJSON(value) {
|
|
1458
|
+
return value;
|
|
1459
|
+
}
|
|
1460
|
+
|
|
1461
|
+
// src/models/openapi-generated/patient/models/AllergyReaction.ts
|
|
1462
|
+
function AllergyReactionToJSON(json) {
|
|
1463
|
+
return AllergyReactionToJSONTyped(json, false);
|
|
1464
|
+
}
|
|
1465
|
+
function AllergyReactionToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1466
|
+
if (value == null) {
|
|
1467
|
+
return value;
|
|
1468
|
+
}
|
|
1469
|
+
return {
|
|
1470
|
+
"manifestation": value["manifestation"],
|
|
1471
|
+
"manifestation_code": CodedConceptToJSON(value["manifestation_code"]),
|
|
1472
|
+
"notes": value["notes"],
|
|
1473
|
+
"onset": value["onset"] == null ? value["onset"] : value["onset"].toISOString().substring(0, 10),
|
|
1474
|
+
"severity": ReactionSeverityToJSON(value["severity"])
|
|
1475
|
+
};
|
|
1476
|
+
}
|
|
1477
|
+
|
|
1478
|
+
// src/models/openapi-generated/patient/models/AllergyCriticality.ts
|
|
1479
|
+
function AllergyCriticalityToJSON(value) {
|
|
1480
|
+
return value;
|
|
1481
|
+
}
|
|
1482
|
+
|
|
1483
|
+
// src/models/openapi-generated/patient/models/IntakeAllergy.ts
|
|
1484
|
+
function IntakeAllergyToJSON(json) {
|
|
1485
|
+
return IntakeAllergyToJSONTyped(json, false);
|
|
1486
|
+
}
|
|
1487
|
+
function IntakeAllergyToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1488
|
+
if (value == null) {
|
|
1489
|
+
return value;
|
|
1490
|
+
}
|
|
1491
|
+
return {
|
|
1492
|
+
"allergen": value["allergen"],
|
|
1493
|
+
"allergen_code": CodedConceptToJSON(value["allergen_code"]),
|
|
1494
|
+
"asserted_date": value["asserted_date"] == null ? value["asserted_date"] : value["asserted_date"].toISOString().substring(0, 10),
|
|
1495
|
+
"category": AllergyCategoryToJSON(value["category"]),
|
|
1496
|
+
"criticality": AllergyCriticalityToJSON(value["criticality"]),
|
|
1497
|
+
"intolerance_type": IntoleranceTypeToJSON(value["intolerance_type"]),
|
|
1498
|
+
"notes": value["notes"],
|
|
1499
|
+
"onset_date": value["onset_date"] == null ? value["onset_date"] : value["onset_date"].toISOString().substring(0, 10),
|
|
1500
|
+
"reactions": value["reactions"] == null ? void 0 : value["reactions"].map(AllergyReactionToJSON),
|
|
1501
|
+
"resolved_date": value["resolved_date"] == null ? value["resolved_date"] : value["resolved_date"].toISOString().substring(0, 10),
|
|
1502
|
+
"status": AllergyStatusToJSON(value["status"])
|
|
1503
|
+
};
|
|
1504
|
+
}
|
|
1505
|
+
|
|
1506
|
+
// src/models/openapi-generated/patient/models/ProblemCategory.ts
|
|
1507
|
+
function ProblemCategoryToJSON(value) {
|
|
1508
|
+
return value;
|
|
1509
|
+
}
|
|
1510
|
+
|
|
1511
|
+
// src/models/openapi-generated/patient/models/ProblemSeverity.ts
|
|
1512
|
+
function ProblemSeverityToJSON(value) {
|
|
1513
|
+
return value;
|
|
1514
|
+
}
|
|
1515
|
+
|
|
1516
|
+
// src/models/openapi-generated/patient/models/ProblemClinicalStatus.ts
|
|
1517
|
+
function ProblemClinicalStatusToJSON(value) {
|
|
1518
|
+
return value;
|
|
1519
|
+
}
|
|
1520
|
+
|
|
1521
|
+
// src/models/openapi-generated/patient/models/IntakeProblem.ts
|
|
1522
|
+
function IntakeProblemToJSON(json) {
|
|
1523
|
+
return IntakeProblemToJSONTyped(json, false);
|
|
1524
|
+
}
|
|
1525
|
+
function IntakeProblemToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1526
|
+
if (value == null) {
|
|
1527
|
+
return value;
|
|
1528
|
+
}
|
|
1529
|
+
return {
|
|
1530
|
+
"asserted_date": value["asserted_date"] == null ? value["asserted_date"] : value["asserted_date"].toISOString().substring(0, 10),
|
|
1531
|
+
"body_site": value["body_site"],
|
|
1532
|
+
"categories": value["categories"] == null ? void 0 : value["categories"].map(ProblemCategoryToJSON),
|
|
1533
|
+
"clinical_status": ProblemClinicalStatusToJSON(value["clinical_status"]),
|
|
1534
|
+
"description": value["description"],
|
|
1535
|
+
"icd10_code": value["icd10_code"],
|
|
1536
|
+
"laterality": value["laterality"],
|
|
1537
|
+
"notes": value["notes"],
|
|
1538
|
+
"onset_age": value["onset_age"],
|
|
1539
|
+
"onset_date": value["onset_date"] == null ? value["onset_date"] : value["onset_date"].toISOString().substring(0, 10),
|
|
1540
|
+
"recorded_date": value["recorded_date"] == null ? value["recorded_date"] : value["recorded_date"].toISOString(),
|
|
1541
|
+
"resolved_date": value["resolved_date"] == null ? value["resolved_date"] : value["resolved_date"].toISOString().substring(0, 10),
|
|
1542
|
+
"severity": ProblemSeverityToJSON(value["severity"]),
|
|
1543
|
+
"snomed_code": value["snomed_code"]
|
|
1544
|
+
};
|
|
1545
|
+
}
|
|
1546
|
+
|
|
1547
|
+
// src/models/openapi-generated/patient/models/VaccinationSite.ts
|
|
1548
|
+
function VaccinationSiteToJSON(value) {
|
|
1549
|
+
return value;
|
|
1550
|
+
}
|
|
1551
|
+
|
|
1552
|
+
// src/models/openapi-generated/patient/models/ImmunizationStatus.ts
|
|
1553
|
+
function ImmunizationStatusToJSON(value) {
|
|
1554
|
+
return value;
|
|
1555
|
+
}
|
|
1556
|
+
|
|
1557
|
+
// src/models/openapi-generated/patient/models/ImmunizationRoute.ts
|
|
1558
|
+
function ImmunizationRouteToJSON(value) {
|
|
1559
|
+
return value;
|
|
1560
|
+
}
|
|
1561
|
+
|
|
1562
|
+
// src/models/openapi-generated/patient/models/ImmunizationReaction.ts
|
|
1563
|
+
function ImmunizationReactionToJSON(json) {
|
|
1564
|
+
return ImmunizationReactionToJSONTyped(json, false);
|
|
1565
|
+
}
|
|
1566
|
+
function ImmunizationReactionToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1567
|
+
if (value == null) {
|
|
1568
|
+
return value;
|
|
1569
|
+
}
|
|
1570
|
+
return {
|
|
1571
|
+
"notes": value["notes"],
|
|
1572
|
+
"onset_date": value["onset_date"] == null ? value["onset_date"] : value["onset_date"].toISOString().substring(0, 10),
|
|
1573
|
+
"reaction": value["reaction"],
|
|
1574
|
+
"severity": ReactionSeverityToJSON(value["severity"])
|
|
1575
|
+
};
|
|
1576
|
+
}
|
|
1577
|
+
|
|
1578
|
+
// src/models/openapi-generated/patient/models/IntakeVaccine.ts
|
|
1579
|
+
function IntakeVaccineToJSON(json) {
|
|
1580
|
+
return IntakeVaccineToJSONTyped(json, false);
|
|
1581
|
+
}
|
|
1582
|
+
function IntakeVaccineToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1583
|
+
if (value == null) {
|
|
1584
|
+
return value;
|
|
1585
|
+
}
|
|
1586
|
+
return {
|
|
1587
|
+
"administered_by": value["administered_by"],
|
|
1588
|
+
"administered_date": value["administered_date"] == null ? value["administered_date"] : value["administered_date"].toISOString().substring(0, 10),
|
|
1589
|
+
"administered_datetime": value["administered_datetime"] == null ? value["administered_datetime"] : value["administered_datetime"].toISOString(),
|
|
1590
|
+
"cvx_code": value["cvx_code"],
|
|
1591
|
+
"dose_number": value["dose_number"],
|
|
1592
|
+
"dose_quantity": value["dose_quantity"],
|
|
1593
|
+
"dose_unit": value["dose_unit"],
|
|
1594
|
+
"expiration_date": value["expiration_date"] == null ? value["expiration_date"] : value["expiration_date"].toISOString().substring(0, 10),
|
|
1595
|
+
"lot_number": value["lot_number"],
|
|
1596
|
+
"manufacturer": value["manufacturer"],
|
|
1597
|
+
"mvx_code": value["mvx_code"],
|
|
1598
|
+
"not_done_reason": value["not_done_reason"],
|
|
1599
|
+
"notes": value["notes"],
|
|
1600
|
+
"reactions": value["reactions"] == null ? void 0 : value["reactions"].map(ImmunizationReactionToJSON),
|
|
1601
|
+
"reason_codes": value["reason_codes"],
|
|
1602
|
+
"route": ImmunizationRouteToJSON(value["route"]),
|
|
1603
|
+
"series_doses": value["series_doses"],
|
|
1604
|
+
"series_name": value["series_name"],
|
|
1605
|
+
"site": VaccinationSiteToJSON(value["site"]),
|
|
1606
|
+
"status": ImmunizationStatusToJSON(value["status"]),
|
|
1607
|
+
"vaccine_name": value["vaccine_name"],
|
|
1608
|
+
"vis_document_date": value["vis_document_date"] == null ? value["vis_document_date"] : value["vis_document_date"].toISOString().substring(0, 10)
|
|
1609
|
+
};
|
|
1610
|
+
}
|
|
1611
|
+
|
|
1612
|
+
// src/models/openapi-generated/patient/models/PatientIntakeRequest.ts
|
|
1613
|
+
function PatientIntakeRequestToJSON(json) {
|
|
1614
|
+
return PatientIntakeRequestToJSONTyped(json, false);
|
|
1615
|
+
}
|
|
1616
|
+
function PatientIntakeRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
1617
|
+
if (value == null) {
|
|
1618
|
+
return value;
|
|
1619
|
+
}
|
|
1620
|
+
return {
|
|
1621
|
+
"allergies": value["allergies"] == null ? void 0 : value["allergies"].map(IntakeAllergyToJSON),
|
|
1622
|
+
"cancer_cases": value["cancer_cases"] == null ? void 0 : value["cancer_cases"].map(IntakeCancerCaseToJSON),
|
|
1623
|
+
"family_history": value["family_history"] == null ? void 0 : value["family_history"].map(IntakeFamilyHistoryToJSON),
|
|
1624
|
+
"gyn_history": value["gyn_history"] == null ? void 0 : value["gyn_history"].map(GynHistoryToJSON),
|
|
1625
|
+
"medications": value["medications"] == null ? void 0 : value["medications"].map(IntakeMedicationToJSON),
|
|
1626
|
+
"perinatal_history": value["perinatal_history"] == null ? void 0 : value["perinatal_history"].map(PerinatalHistoryToJSON),
|
|
1627
|
+
"problems": value["problems"] == null ? void 0 : value["problems"].map(IntakeProblemToJSON),
|
|
1628
|
+
"social_history": value["social_history"] == null ? void 0 : value["social_history"].map(IntakeSocialHistoryToJSON),
|
|
1629
|
+
"surgical_history": value["surgical_history"] == null ? void 0 : value["surgical_history"].map(IntakeSurgeryToJSON),
|
|
1630
|
+
"vaccines": value["vaccines"] == null ? void 0 : value["vaccines"].map(IntakeVaccineToJSON)
|
|
1631
|
+
};
|
|
1632
|
+
}
|
|
1633
|
+
|
|
1634
|
+
// src/models/openapi-generated/patient/runtime.ts
|
|
1635
|
+
var BASE_PATH = "https://dev-api-patient.health.cloud".replace(/\/+$/, "");
|
|
1636
|
+
var Configuration = class {
|
|
1637
|
+
constructor(configuration = {}) {
|
|
1638
|
+
this.configuration = configuration;
|
|
1639
|
+
}
|
|
1640
|
+
set config(configuration) {
|
|
1641
|
+
this.configuration = configuration;
|
|
1642
|
+
}
|
|
1643
|
+
get basePath() {
|
|
1644
|
+
return this.configuration.basePath != null ? this.configuration.basePath : BASE_PATH;
|
|
1645
|
+
}
|
|
1646
|
+
get fetchApi() {
|
|
1647
|
+
return this.configuration.fetchApi;
|
|
1648
|
+
}
|
|
1649
|
+
get middleware() {
|
|
1650
|
+
return this.configuration.middleware || [];
|
|
1651
|
+
}
|
|
1652
|
+
get queryParamsStringify() {
|
|
1653
|
+
return this.configuration.queryParamsStringify || querystring;
|
|
1654
|
+
}
|
|
1655
|
+
get username() {
|
|
1656
|
+
return this.configuration.username;
|
|
1657
|
+
}
|
|
1658
|
+
get password() {
|
|
1659
|
+
return this.configuration.password;
|
|
1660
|
+
}
|
|
1661
|
+
get apiKey() {
|
|
1662
|
+
const apiKey = this.configuration.apiKey;
|
|
1663
|
+
if (apiKey) {
|
|
1664
|
+
return typeof apiKey === "function" ? apiKey : () => apiKey;
|
|
1665
|
+
}
|
|
1666
|
+
return void 0;
|
|
1667
|
+
}
|
|
1668
|
+
get accessToken() {
|
|
1669
|
+
const accessToken = this.configuration.accessToken;
|
|
1670
|
+
if (accessToken) {
|
|
1671
|
+
return typeof accessToken === "function" ? accessToken : async () => accessToken;
|
|
1672
|
+
}
|
|
1673
|
+
return void 0;
|
|
1674
|
+
}
|
|
1675
|
+
get headers() {
|
|
1676
|
+
return this.configuration.headers;
|
|
1677
|
+
}
|
|
1678
|
+
get credentials() {
|
|
1679
|
+
return this.configuration.credentials;
|
|
1680
|
+
}
|
|
1681
|
+
};
|
|
1682
|
+
var DefaultConfig = new Configuration();
|
|
1683
|
+
var _BaseAPI = class _BaseAPI {
|
|
1684
|
+
constructor(configuration = DefaultConfig) {
|
|
1685
|
+
this.configuration = configuration;
|
|
1686
|
+
this.fetchApi = async (url, init) => {
|
|
1687
|
+
let fetchParams = { url, init };
|
|
1688
|
+
for (const middleware of this.middleware) {
|
|
1689
|
+
if (middleware.pre) {
|
|
1690
|
+
fetchParams = await middleware.pre({
|
|
1691
|
+
fetch: this.fetchApi,
|
|
1692
|
+
...fetchParams
|
|
1693
|
+
}) || fetchParams;
|
|
1694
|
+
}
|
|
1695
|
+
}
|
|
1696
|
+
let response = void 0;
|
|
1697
|
+
try {
|
|
1698
|
+
response = await (this.configuration.fetchApi || fetch)(fetchParams.url, fetchParams.init);
|
|
1699
|
+
} catch (e) {
|
|
1700
|
+
for (const middleware of this.middleware) {
|
|
1701
|
+
if (middleware.onError) {
|
|
1702
|
+
response = await middleware.onError({
|
|
1703
|
+
fetch: this.fetchApi,
|
|
1704
|
+
url: fetchParams.url,
|
|
1705
|
+
init: fetchParams.init,
|
|
1706
|
+
error: e,
|
|
1707
|
+
response: response ? response.clone() : void 0
|
|
1708
|
+
}) || response;
|
|
1709
|
+
}
|
|
1710
|
+
}
|
|
1711
|
+
if (response === void 0) {
|
|
1712
|
+
if (e instanceof Error) {
|
|
1713
|
+
throw new FetchError(e, "The request failed and the interceptors did not return an alternative response");
|
|
1714
|
+
} else {
|
|
1715
|
+
throw e;
|
|
1716
|
+
}
|
|
1717
|
+
}
|
|
1718
|
+
}
|
|
1719
|
+
for (const middleware of this.middleware) {
|
|
1720
|
+
if (middleware.post) {
|
|
1721
|
+
response = await middleware.post({
|
|
1722
|
+
fetch: this.fetchApi,
|
|
1723
|
+
url: fetchParams.url,
|
|
1724
|
+
init: fetchParams.init,
|
|
1725
|
+
response: response.clone()
|
|
1726
|
+
}) || response;
|
|
1727
|
+
}
|
|
1728
|
+
}
|
|
1729
|
+
return response;
|
|
1730
|
+
};
|
|
1731
|
+
this.middleware = configuration.middleware;
|
|
1732
|
+
}
|
|
1733
|
+
withMiddleware(...middlewares) {
|
|
1734
|
+
const next = this.clone();
|
|
1735
|
+
next.middleware = next.middleware.concat(...middlewares);
|
|
1736
|
+
return next;
|
|
1737
|
+
}
|
|
1738
|
+
withPreMiddleware(...preMiddlewares) {
|
|
1739
|
+
const middlewares = preMiddlewares.map((pre) => ({ pre }));
|
|
1740
|
+
return this.withMiddleware(...middlewares);
|
|
1741
|
+
}
|
|
1742
|
+
withPostMiddleware(...postMiddlewares) {
|
|
1743
|
+
const middlewares = postMiddlewares.map((post) => ({ post }));
|
|
1744
|
+
return this.withMiddleware(...middlewares);
|
|
1745
|
+
}
|
|
1746
|
+
/**
|
|
1747
|
+
* Check if the given MIME is a JSON MIME.
|
|
1748
|
+
* JSON MIME examples:
|
|
1749
|
+
* application/json
|
|
1750
|
+
* application/json; charset=UTF8
|
|
1751
|
+
* APPLICATION/JSON
|
|
1752
|
+
* application/vnd.company+json
|
|
1753
|
+
* @param mime - MIME (Multipurpose Internet Mail Extensions)
|
|
1754
|
+
* @return True if the given MIME is JSON, false otherwise.
|
|
1755
|
+
*/
|
|
1756
|
+
isJsonMime(mime) {
|
|
1757
|
+
if (!mime) {
|
|
1758
|
+
return false;
|
|
1759
|
+
}
|
|
1760
|
+
return _BaseAPI.jsonRegex.test(mime);
|
|
1761
|
+
}
|
|
1762
|
+
async request(context, initOverrides) {
|
|
1763
|
+
const { url, init } = await this.createFetchParams(context, initOverrides);
|
|
1764
|
+
const response = await this.fetchApi(url, init);
|
|
1765
|
+
if (response && (response.status >= 200 && response.status < 300)) {
|
|
1766
|
+
return response;
|
|
1767
|
+
}
|
|
1768
|
+
throw new ResponseError(response, "Response returned an error code");
|
|
1769
|
+
}
|
|
1770
|
+
async createFetchParams(context, initOverrides) {
|
|
1771
|
+
let url = this.configuration.basePath + context.path;
|
|
1772
|
+
if (context.query !== void 0 && Object.keys(context.query).length !== 0) {
|
|
1773
|
+
url += "?" + this.configuration.queryParamsStringify(context.query);
|
|
1774
|
+
}
|
|
1775
|
+
const headers = Object.assign({}, this.configuration.headers, context.headers);
|
|
1776
|
+
Object.keys(headers).forEach((key) => headers[key] === void 0 ? delete headers[key] : {});
|
|
1777
|
+
const initOverrideFn = typeof initOverrides === "function" ? initOverrides : async () => initOverrides;
|
|
1778
|
+
const initParams = {
|
|
1779
|
+
method: context.method,
|
|
1780
|
+
headers,
|
|
1781
|
+
body: context.body,
|
|
1782
|
+
credentials: this.configuration.credentials
|
|
1783
|
+
};
|
|
1784
|
+
const overriddenInit = {
|
|
1785
|
+
...initParams,
|
|
1786
|
+
...await initOverrideFn({
|
|
1787
|
+
init: initParams,
|
|
1788
|
+
context
|
|
1789
|
+
})
|
|
1790
|
+
};
|
|
1791
|
+
let body;
|
|
1792
|
+
if (isFormData(overriddenInit.body) || overriddenInit.body instanceof URLSearchParams || isBlob(overriddenInit.body)) {
|
|
1793
|
+
body = overriddenInit.body;
|
|
1794
|
+
} else if (this.isJsonMime(headers["Content-Type"])) {
|
|
1795
|
+
body = JSON.stringify(overriddenInit.body);
|
|
1796
|
+
} else {
|
|
1797
|
+
body = overriddenInit.body;
|
|
1798
|
+
}
|
|
1799
|
+
const init = {
|
|
1800
|
+
...overriddenInit,
|
|
1801
|
+
body
|
|
1802
|
+
};
|
|
1803
|
+
return { url, init };
|
|
1804
|
+
}
|
|
1805
|
+
/**
|
|
1806
|
+
* Create a shallow clone of `this` by constructing a new instance
|
|
1807
|
+
* and then shallow cloning data members.
|
|
1808
|
+
*/
|
|
1809
|
+
clone() {
|
|
1810
|
+
const constructor = this.constructor;
|
|
1811
|
+
const next = new constructor(this.configuration);
|
|
1812
|
+
next.middleware = this.middleware.slice();
|
|
1813
|
+
return next;
|
|
1814
|
+
}
|
|
1815
|
+
};
|
|
1816
|
+
_BaseAPI.jsonRegex = /^(:?application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(:?;.*)?$/i;
|
|
1817
|
+
var BaseAPI = _BaseAPI;
|
|
1818
|
+
function isBlob(value) {
|
|
1819
|
+
return typeof Blob !== "undefined" && value instanceof Blob;
|
|
1820
|
+
}
|
|
1821
|
+
function isFormData(value) {
|
|
1822
|
+
return typeof FormData !== "undefined" && value instanceof FormData;
|
|
1823
|
+
}
|
|
1824
|
+
var ResponseError = class extends Error {
|
|
1825
|
+
constructor(response, msg) {
|
|
1826
|
+
super(msg);
|
|
1827
|
+
this.response = response;
|
|
1828
|
+
this.name = "ResponseError";
|
|
1829
|
+
const actualProto = new.target.prototype;
|
|
1830
|
+
if (Object.setPrototypeOf) {
|
|
1831
|
+
Object.setPrototypeOf(this, actualProto);
|
|
1832
|
+
}
|
|
1833
|
+
}
|
|
1834
|
+
};
|
|
1835
|
+
var FetchError = class extends Error {
|
|
1836
|
+
constructor(cause, msg) {
|
|
1837
|
+
super(msg);
|
|
1838
|
+
this.cause = cause;
|
|
1839
|
+
this.name = "FetchError";
|
|
1840
|
+
const actualProto = new.target.prototype;
|
|
1841
|
+
if (Object.setPrototypeOf) {
|
|
1842
|
+
Object.setPrototypeOf(this, actualProto);
|
|
1843
|
+
}
|
|
1844
|
+
}
|
|
1845
|
+
};
|
|
1846
|
+
function querystring(params, prefix = "") {
|
|
1847
|
+
return Object.keys(params).map((key) => querystringSingleKey(key, params[key], prefix)).filter((part) => part.length > 0).join("&");
|
|
1848
|
+
}
|
|
1849
|
+
function querystringSingleKey(key, value, keyPrefix = "") {
|
|
1850
|
+
const fullKey = keyPrefix + (keyPrefix.length ? `[${key}]` : key);
|
|
1851
|
+
if (value instanceof Array) {
|
|
1852
|
+
const multiValue = value.map((singleValue) => encodeURIComponent(String(singleValue))).join(`&${encodeURIComponent(fullKey)}=`);
|
|
1853
|
+
return `${encodeURIComponent(fullKey)}=${multiValue}`;
|
|
1854
|
+
}
|
|
1855
|
+
if (value instanceof Set) {
|
|
1856
|
+
const valueAsArray = Array.from(value);
|
|
1857
|
+
return querystringSingleKey(key, valueAsArray, keyPrefix);
|
|
1858
|
+
}
|
|
1859
|
+
if (value instanceof Date) {
|
|
1860
|
+
return `${encodeURIComponent(fullKey)}=${encodeURIComponent(value.toISOString())}`;
|
|
1861
|
+
}
|
|
1862
|
+
if (value instanceof Object) {
|
|
1863
|
+
return querystring(value, fullKey);
|
|
1864
|
+
}
|
|
1865
|
+
return `${encodeURIComponent(fullKey)}=${encodeURIComponent(String(value))}`;
|
|
1866
|
+
}
|
|
1867
|
+
function mapValues(data, fn) {
|
|
1868
|
+
const result = {};
|
|
1869
|
+
for (const key of Object.keys(data)) {
|
|
1870
|
+
result[key] = fn(data[key]);
|
|
1871
|
+
}
|
|
1872
|
+
return result;
|
|
1873
|
+
}
|
|
1874
|
+
|
|
1875
|
+
// src/models/openapi-generated/patient/models/IntakeVendorSectionStatus.ts
|
|
1876
|
+
function IntakeVendorSectionStatusFromJSON(json) {
|
|
1877
|
+
return IntakeVendorSectionStatusFromJSONTyped(json, false);
|
|
1878
|
+
}
|
|
1879
|
+
function IntakeVendorSectionStatusFromJSONTyped(json, ignoreDiscriminator) {
|
|
1880
|
+
if (json == null) {
|
|
1881
|
+
return json;
|
|
1882
|
+
}
|
|
1883
|
+
return {
|
|
1884
|
+
"mode": json["mode"] == null ? void 0 : json["mode"],
|
|
1885
|
+
"reason": json["reason"] === void 0 ? void 0 : json["reason"] === null ? null : json["reason"],
|
|
1886
|
+
"reference": json["reference"] === void 0 ? void 0 : json["reference"] === null ? null : json["reference"],
|
|
1887
|
+
"status": json["status"]
|
|
1888
|
+
};
|
|
1889
|
+
}
|
|
1890
|
+
|
|
1891
|
+
// src/models/openapi-generated/patient/models/IntakeVendorStatus.ts
|
|
1892
|
+
function IntakeVendorStatusFromJSON(json) {
|
|
1893
|
+
return IntakeVendorStatusFromJSONTyped(json, false);
|
|
1894
|
+
}
|
|
1895
|
+
function IntakeVendorStatusFromJSONTyped(json, ignoreDiscriminator) {
|
|
1896
|
+
if (json == null) {
|
|
1897
|
+
return json;
|
|
1898
|
+
}
|
|
1899
|
+
return {
|
|
1900
|
+
"mode": json["mode"] == null ? void 0 : json["mode"],
|
|
1901
|
+
"reason": json["reason"] === void 0 ? void 0 : json["reason"] === null ? null : json["reason"],
|
|
1902
|
+
"reference": json["reference"] === void 0 ? void 0 : json["reference"] === null ? null : json["reference"],
|
|
1903
|
+
"section_results": json["section_results"] == null ? void 0 : mapValues(json["section_results"], IntakeVendorSectionStatusFromJSON),
|
|
1904
|
+
"sections": json["sections"] == null ? void 0 : json["sections"],
|
|
1905
|
+
"status": json["status"]
|
|
1906
|
+
};
|
|
1907
|
+
}
|
|
1908
|
+
|
|
1909
|
+
// src/models/openapi-generated/patient/models/PatientIntakeResponse.ts
|
|
1910
|
+
function PatientIntakeResponseFromJSON(json) {
|
|
1911
|
+
return PatientIntakeResponseFromJSONTyped(json, false);
|
|
1912
|
+
}
|
|
1913
|
+
function PatientIntakeResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
1914
|
+
if (json == null) {
|
|
1915
|
+
return json;
|
|
1916
|
+
}
|
|
1917
|
+
return {
|
|
1918
|
+
"created_at": new Date(json["created_at"]),
|
|
1919
|
+
"storage_status": json["storage_status"],
|
|
1920
|
+
"submission_id": json["submission_id"],
|
|
1921
|
+
"vendors": mapValues(json["vendors"], IntakeVendorStatusFromJSON)
|
|
1922
|
+
};
|
|
1923
|
+
}
|
|
1924
|
+
|
|
1001
1925
|
// src/clients/PatientClient.ts
|
|
1002
1926
|
var PatientClient = class extends BaseServiceClient {
|
|
1927
|
+
/** Add patient-reported history; each call creates a new server-identified submission. */
|
|
1928
|
+
async submitPatientIntake(request) {
|
|
1929
|
+
const response = await this.send("POST", "/patients/health-record/intake", {
|
|
1930
|
+
body: PatientIntakeRequestToJSON(request)
|
|
1931
|
+
});
|
|
1932
|
+
return PatientIntakeResponseFromJSON(response);
|
|
1933
|
+
}
|
|
1934
|
+
/** Read the authenticated patient's submission metadata and vendor section statuses. */
|
|
1935
|
+
async getPatientIntake(submissionId) {
|
|
1936
|
+
const response = await this.send("GET", "/patients/health-record/intake/{submission_id}", {
|
|
1937
|
+
pathParams: { submission_id: submissionId }
|
|
1938
|
+
});
|
|
1939
|
+
return PatientIntakeResponseFromJSON(response);
|
|
1940
|
+
}
|
|
1003
1941
|
constructor(http) {
|
|
1004
1942
|
super(http, "patient");
|
|
1005
1943
|
}
|
|
@@ -1118,6 +2056,11 @@ var PatientClient = class extends BaseServiceClient {
|
|
|
1118
2056
|
body: request
|
|
1119
2057
|
});
|
|
1120
2058
|
}
|
|
2059
|
+
updateDriversLicense(request) {
|
|
2060
|
+
return this.send("PUT", "/patients/drivers-license", {
|
|
2061
|
+
body: request
|
|
2062
|
+
});
|
|
2063
|
+
}
|
|
1121
2064
|
updateDemographics(request) {
|
|
1122
2065
|
return this.send("PUT", "/patients/demographics", {
|
|
1123
2066
|
body: request
|