candidhealth 0.35.0 → 0.35.2

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.
Files changed (378) hide show
  1. package/api/resources/auth/resources/v2/client/Client.js +1 -1
  2. package/api/resources/billingNotes/resources/v2/client/Client.js +1 -1
  3. package/api/resources/contracts/resources/v2/client/Client.js +5 -5
  4. package/api/resources/credentialing/resources/v2/client/Client.d.ts +1 -0
  5. package/api/resources/credentialing/resources/v2/client/Client.js +11 -6
  6. package/api/resources/credentialing/resources/v2/client/getAll.d.ts +7 -1
  7. package/api/resources/credentialing/resources/v2/client/getAll.js +11 -0
  8. package/api/resources/credentialing/resources/v2/client/requests/GetAllProviderCredentialingSpansRequest.d.ts +7 -2
  9. package/api/resources/customSchemas/resources/v1/client/Client.js +4 -4
  10. package/api/resources/diagnoses/client/Client.js +3 -3
  11. package/api/resources/eligibility/resources/v2/client/Client.js +3 -3
  12. package/api/resources/encounterProviders/resources/v2/client/Client.js +12 -12
  13. package/api/resources/encounters/resources/v4/client/Client.js +5 -5
  14. package/api/resources/expectedNetworkStatus/resources/v1/client/Client.js +1 -1
  15. package/api/resources/expectedNetworkStatus/resources/v2/client/Client.js +2 -2
  16. package/api/resources/exports/resources/v3/client/Client.d.ts +3 -2
  17. package/api/resources/exports/resources/v3/client/Client.js +4 -3
  18. package/api/resources/externalPaymentAccountConfig/resources/v1/client/Client.js +1 -1
  19. package/api/resources/feeSchedules/resources/v3/client/Client.js +10 -10
  20. package/api/resources/guarantor/resources/v1/client/Client.js +3 -3
  21. package/api/resources/guarantor/resources/v1/types/GuarantorBase.d.ts +1 -1
  22. package/api/resources/importInvoice/resources/v1/client/Client.js +4 -4
  23. package/api/resources/index.d.ts +1 -0
  24. package/api/resources/index.js +2 -1
  25. package/api/resources/insuranceAdjudications/resources/v1/client/Client.d.ts +2 -1
  26. package/api/resources/insuranceAdjudications/resources/v1/client/Client.js +5 -4
  27. package/api/resources/insuranceAdjudications/resources/v1/types/InsuranceAdjudicationCreate.d.ts +1 -0
  28. package/api/resources/insurancePayments/resources/v1/client/Client.js +5 -5
  29. package/api/resources/insuranceRefunds/resources/v1/client/Client.js +5 -5
  30. package/api/resources/medicationDispense/resources/v1/client/Client.js +1 -1
  31. package/api/resources/nonInsurancePayerPayments/resources/v1/client/Client.js +5 -5
  32. package/api/resources/nonInsurancePayerRefunds/resources/v1/client/Client.js +5 -5
  33. package/api/resources/nonInsurancePayers/resources/v1/client/Client.js +6 -6
  34. package/api/resources/organizationProviders/resources/v3/client/Client.js +4 -4
  35. package/api/resources/organizationServiceFacilities/resources/v2/client/Client.js +5 -5
  36. package/api/resources/patientPayments/resources/v4/client/Client.js +5 -5
  37. package/api/resources/patientRefunds/resources/v1/client/Client.js +5 -5
  38. package/api/resources/payers/resources/v3/client/Client.js +2 -2
  39. package/api/resources/preEncounter/resources/appointments/resources/v1/client/Client.js +6 -6
  40. package/api/resources/preEncounter/resources/appointments/resources/v1/client/create.d.ts +3 -3
  41. package/api/resources/preEncounter/resources/appointments/resources/v1/client/deactivate.d.ts +3 -3
  42. package/api/resources/preEncounter/resources/appointments/resources/v1/client/get.d.ts +3 -3
  43. package/api/resources/preEncounter/resources/appointments/resources/v1/client/getHistory.d.ts +3 -3
  44. package/api/resources/preEncounter/resources/appointments/resources/v1/client/update.d.ts +3 -3
  45. package/api/resources/preEncounter/resources/appointments/resources/v1/types/AppointmentWorkQueue.d.ts +2 -1
  46. package/api/resources/preEncounter/resources/appointments/resources/v1/types/AppointmentWorkQueue.js +1 -0
  47. package/api/resources/preEncounter/resources/common/types/{ErrorBase.d.ts → ErrorBase4Xx.d.ts} +2 -1
  48. package/api/resources/preEncounter/resources/common/types/ExternalProvider.d.ts +1 -0
  49. package/api/resources/preEncounter/resources/common/types/VersionConflictErrorBody.d.ts +2 -3
  50. package/api/resources/preEncounter/resources/common/types/index.d.ts +1 -2
  51. package/api/resources/preEncounter/resources/common/types/index.js +1 -2
  52. package/api/resources/preEncounter/resources/coverages/resources/v1/client/Client.js +8 -8
  53. package/api/resources/preEncounter/resources/coverages/resources/v1/client/getHistory.d.ts +3 -3
  54. package/api/resources/preEncounter/resources/coverages/resources/v1/client/update.d.ts +3 -3
  55. package/api/resources/preEncounter/resources/coverages/resources/v1/types/CoverageBenefits.d.ts +1 -0
  56. package/api/resources/preEncounter/resources/lists/resources/v1/client/Client.d.ts +2 -2
  57. package/api/resources/preEncounter/resources/lists/resources/v1/client/Client.js +4 -4
  58. package/api/resources/preEncounter/resources/lists/resources/v1/client/getPatientList.d.ts +3 -3
  59. package/api/resources/preEncounter/resources/lists/resources/v1/client/requests/AppointmentsGetListRequest.d.ts +3 -3
  60. package/api/resources/preEncounter/resources/lists/resources/v1/client/requests/PatientListRequest.d.ts +5 -2
  61. package/api/resources/preEncounter/resources/lists/resources/v1/types/AppointmentListItem.d.ts +1 -0
  62. package/api/resources/preEncounter/resources/lists/resources/v1/types/SortFieldString.d.ts +11 -0
  63. package/api/resources/preEncounter/resources/lists/resources/v1/types/SortFieldString.js +10 -0
  64. package/api/resources/preEncounter/resources/lists/resources/v1/types/index.d.ts +1 -0
  65. package/api/resources/preEncounter/resources/lists/resources/v1/types/index.js +1 -0
  66. package/api/resources/preEncounter/resources/patients/resources/v1/client/Client.d.ts +177 -2
  67. package/api/resources/preEncounter/resources/patients/resources/v1/client/Client.js +246 -11
  68. package/api/resources/preEncounter/resources/patients/resources/v1/client/create.d.ts +1 -7
  69. package/api/resources/preEncounter/resources/patients/resources/v1/client/create.js +0 -11
  70. package/api/resources/preEncounter/resources/patients/resources/v1/client/createWithMrn.d.ts +34 -0
  71. package/api/resources/preEncounter/resources/patients/resources/v1/client/createWithMrn.js +69 -0
  72. package/api/resources/preEncounter/resources/patients/resources/v1/client/deactivate.d.ts +3 -3
  73. package/api/resources/preEncounter/resources/patients/resources/v1/client/get.d.ts +3 -3
  74. package/api/resources/preEncounter/resources/patients/resources/v1/client/getHistory.d.ts +3 -3
  75. package/api/resources/preEncounter/resources/patients/resources/v1/client/index.d.ts +1 -0
  76. package/api/resources/preEncounter/resources/patients/resources/v1/client/index.js +2 -1
  77. package/api/resources/preEncounter/resources/patients/resources/v1/client/requests/CreatePatientRequest.d.ts +2 -1
  78. package/api/resources/preEncounter/resources/patients/resources/v1/client/requests/CreatePatientWithMrnRequest.d.ts +175 -0
  79. package/api/resources/preEncounter/resources/patients/resources/v1/client/requests/index.d.ts +1 -0
  80. package/api/resources/preEncounter/resources/patients/resources/v1/client/update.d.ts +3 -3
  81. package/api/resources/preEncounter/resources/patients/resources/v1/types/DoNotInvoiceReason.d.ts +10 -0
  82. package/api/resources/preEncounter/resources/patients/resources/v1/types/DoNotInvoiceReason.js +12 -0
  83. package/api/resources/preEncounter/resources/patients/resources/v1/types/MutablePatient.d.ts +2 -0
  84. package/api/resources/preEncounter/resources/patients/resources/v1/types/MutablePatientWithMrn.d.ts +8 -0
  85. package/api/resources/preEncounter/resources/patients/resources/v1/types/index.d.ts +2 -2
  86. package/api/resources/preEncounter/resources/patients/resources/v1/types/index.js +2 -2
  87. package/api/resources/remitDrafts/index.d.ts +1 -0
  88. package/api/resources/remitDrafts/index.js +17 -0
  89. package/api/resources/remitDrafts/resources/index.d.ts +1 -0
  90. package/api/resources/remitDrafts/resources/index.js +27 -0
  91. package/api/resources/remitDrafts/resources/v1/index.d.ts +1 -0
  92. package/api/resources/remitDrafts/resources/v1/index.js +17 -0
  93. package/api/resources/remitDrafts/resources/v1/types/RemitDraftId.d.ts +8 -0
  94. package/api/resources/remitDrafts/resources/v1/types/RemitDraftId.js +10 -0
  95. package/api/resources/remitDrafts/resources/v1/types/index.d.ts +1 -0
  96. package/api/resources/remitDrafts/resources/v1/types/index.js +17 -0
  97. package/api/resources/serviceFacility/client/Client.js +1 -1
  98. package/api/resources/serviceLines/resources/v2/client/Client.js +3 -3
  99. package/api/resources/tasks/resources/v3/client/Client.js +5 -5
  100. package/api/resources/writeOffs/resources/v1/client/Client.js +4 -4
  101. package/api/resources/x12/resources/v1/types/Rarc.d.ts +8 -1
  102. package/api/resources/x12/resources/v1/types/Rarc.js +7 -0
  103. package/dist/api/resources/auth/resources/v2/client/Client.js +1 -1
  104. package/dist/api/resources/billingNotes/resources/v2/client/Client.js +1 -1
  105. package/dist/api/resources/contracts/resources/v2/client/Client.js +5 -5
  106. package/dist/api/resources/credentialing/resources/v2/client/Client.d.ts +1 -0
  107. package/dist/api/resources/credentialing/resources/v2/client/Client.js +11 -6
  108. package/dist/api/resources/credentialing/resources/v2/client/getAll.d.ts +7 -1
  109. package/dist/api/resources/credentialing/resources/v2/client/getAll.js +11 -0
  110. package/dist/api/resources/credentialing/resources/v2/client/requests/GetAllProviderCredentialingSpansRequest.d.ts +7 -2
  111. package/dist/api/resources/customSchemas/resources/v1/client/Client.js +4 -4
  112. package/dist/api/resources/diagnoses/client/Client.js +3 -3
  113. package/dist/api/resources/eligibility/resources/v2/client/Client.js +3 -3
  114. package/dist/api/resources/encounterProviders/resources/v2/client/Client.js +12 -12
  115. package/dist/api/resources/encounters/resources/v4/client/Client.js +5 -5
  116. package/dist/api/resources/expectedNetworkStatus/resources/v1/client/Client.js +1 -1
  117. package/dist/api/resources/expectedNetworkStatus/resources/v2/client/Client.js +2 -2
  118. package/dist/api/resources/exports/resources/v3/client/Client.d.ts +3 -2
  119. package/dist/api/resources/exports/resources/v3/client/Client.js +4 -3
  120. package/dist/api/resources/externalPaymentAccountConfig/resources/v1/client/Client.js +1 -1
  121. package/dist/api/resources/feeSchedules/resources/v3/client/Client.js +10 -10
  122. package/dist/api/resources/guarantor/resources/v1/client/Client.js +3 -3
  123. package/dist/api/resources/guarantor/resources/v1/types/GuarantorBase.d.ts +1 -1
  124. package/dist/api/resources/importInvoice/resources/v1/client/Client.js +4 -4
  125. package/dist/api/resources/index.d.ts +1 -0
  126. package/dist/api/resources/index.js +2 -1
  127. package/dist/api/resources/insuranceAdjudications/resources/v1/client/Client.d.ts +2 -1
  128. package/dist/api/resources/insuranceAdjudications/resources/v1/client/Client.js +5 -4
  129. package/dist/api/resources/insuranceAdjudications/resources/v1/types/InsuranceAdjudicationCreate.d.ts +1 -0
  130. package/dist/api/resources/insurancePayments/resources/v1/client/Client.js +5 -5
  131. package/dist/api/resources/insuranceRefunds/resources/v1/client/Client.js +5 -5
  132. package/dist/api/resources/medicationDispense/resources/v1/client/Client.js +1 -1
  133. package/dist/api/resources/nonInsurancePayerPayments/resources/v1/client/Client.js +5 -5
  134. package/dist/api/resources/nonInsurancePayerRefunds/resources/v1/client/Client.js +5 -5
  135. package/dist/api/resources/nonInsurancePayers/resources/v1/client/Client.js +6 -6
  136. package/dist/api/resources/organizationProviders/resources/v3/client/Client.js +4 -4
  137. package/dist/api/resources/organizationServiceFacilities/resources/v2/client/Client.js +5 -5
  138. package/dist/api/resources/patientPayments/resources/v4/client/Client.js +5 -5
  139. package/dist/api/resources/patientRefunds/resources/v1/client/Client.js +5 -5
  140. package/dist/api/resources/payers/resources/v3/client/Client.js +2 -2
  141. package/dist/api/resources/preEncounter/resources/appointments/resources/v1/client/Client.js +6 -6
  142. package/dist/api/resources/preEncounter/resources/appointments/resources/v1/client/create.d.ts +3 -3
  143. package/dist/api/resources/preEncounter/resources/appointments/resources/v1/client/deactivate.d.ts +3 -3
  144. package/dist/api/resources/preEncounter/resources/appointments/resources/v1/client/get.d.ts +3 -3
  145. package/dist/api/resources/preEncounter/resources/appointments/resources/v1/client/getHistory.d.ts +3 -3
  146. package/dist/api/resources/preEncounter/resources/appointments/resources/v1/client/update.d.ts +3 -3
  147. package/dist/api/resources/preEncounter/resources/appointments/resources/v1/types/AppointmentWorkQueue.d.ts +2 -1
  148. package/dist/api/resources/preEncounter/resources/appointments/resources/v1/types/AppointmentWorkQueue.js +1 -0
  149. package/dist/api/resources/preEncounter/resources/common/types/{ErrorBase.d.ts → ErrorBase4Xx.d.ts} +2 -1
  150. package/dist/api/resources/preEncounter/resources/common/types/ExternalProvider.d.ts +1 -0
  151. package/dist/api/resources/preEncounter/resources/common/types/VersionConflictErrorBody.d.ts +2 -3
  152. package/dist/api/resources/preEncounter/resources/common/types/index.d.ts +1 -2
  153. package/dist/api/resources/preEncounter/resources/common/types/index.js +1 -2
  154. package/dist/api/resources/preEncounter/resources/coverages/resources/v1/client/Client.js +8 -8
  155. package/dist/api/resources/preEncounter/resources/coverages/resources/v1/client/getHistory.d.ts +3 -3
  156. package/dist/api/resources/preEncounter/resources/coverages/resources/v1/client/update.d.ts +3 -3
  157. package/dist/api/resources/preEncounter/resources/coverages/resources/v1/types/CoverageBenefits.d.ts +1 -0
  158. package/dist/api/resources/preEncounter/resources/lists/resources/v1/client/Client.d.ts +2 -2
  159. package/dist/api/resources/preEncounter/resources/lists/resources/v1/client/Client.js +4 -4
  160. package/dist/api/resources/preEncounter/resources/lists/resources/v1/client/getPatientList.d.ts +3 -3
  161. package/dist/api/resources/preEncounter/resources/lists/resources/v1/client/requests/AppointmentsGetListRequest.d.ts +3 -3
  162. package/dist/api/resources/preEncounter/resources/lists/resources/v1/client/requests/PatientListRequest.d.ts +5 -2
  163. package/dist/api/resources/preEncounter/resources/lists/resources/v1/types/AppointmentListItem.d.ts +1 -0
  164. package/dist/api/resources/preEncounter/resources/lists/resources/v1/types/SortFieldString.d.ts +11 -0
  165. package/dist/api/resources/preEncounter/resources/lists/resources/v1/types/SortFieldString.js +10 -0
  166. package/dist/api/resources/preEncounter/resources/lists/resources/v1/types/index.d.ts +1 -0
  167. package/dist/api/resources/preEncounter/resources/lists/resources/v1/types/index.js +1 -0
  168. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/Client.d.ts +177 -2
  169. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/Client.js +246 -11
  170. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/create.d.ts +1 -7
  171. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/create.js +0 -11
  172. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/createWithMrn.d.ts +34 -0
  173. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/createWithMrn.js +69 -0
  174. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/deactivate.d.ts +3 -3
  175. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/get.d.ts +3 -3
  176. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/getHistory.d.ts +3 -3
  177. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/index.d.ts +1 -0
  178. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/index.js +2 -1
  179. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/requests/CreatePatientRequest.d.ts +2 -1
  180. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/requests/CreatePatientWithMrnRequest.d.ts +175 -0
  181. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/requests/index.d.ts +1 -0
  182. package/dist/api/resources/preEncounter/resources/patients/resources/v1/client/update.d.ts +3 -3
  183. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/DoNotInvoiceReason.d.ts +10 -0
  184. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/DoNotInvoiceReason.js +12 -0
  185. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/MutablePatient.d.ts +2 -0
  186. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/MutablePatientWithMrn.d.ts +8 -0
  187. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/index.d.ts +2 -2
  188. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/index.js +2 -2
  189. package/dist/api/resources/remitDrafts/index.d.ts +1 -0
  190. package/dist/api/resources/remitDrafts/index.js +17 -0
  191. package/dist/api/resources/remitDrafts/resources/index.d.ts +1 -0
  192. package/dist/api/resources/remitDrafts/resources/index.js +27 -0
  193. package/dist/api/resources/remitDrafts/resources/v1/index.d.ts +1 -0
  194. package/dist/api/resources/remitDrafts/resources/v1/index.js +17 -0
  195. package/dist/api/resources/remitDrafts/resources/v1/types/RemitDraftId.d.ts +8 -0
  196. package/dist/api/resources/remitDrafts/resources/v1/types/RemitDraftId.js +10 -0
  197. package/dist/api/resources/remitDrafts/resources/v1/types/index.d.ts +1 -0
  198. package/dist/api/resources/remitDrafts/resources/v1/types/index.js +17 -0
  199. package/dist/api/resources/serviceFacility/client/Client.js +1 -1
  200. package/dist/api/resources/serviceLines/resources/v2/client/Client.js +3 -3
  201. package/dist/api/resources/tasks/resources/v3/client/Client.js +5 -5
  202. package/dist/api/resources/writeOffs/resources/v1/client/Client.js +4 -4
  203. package/dist/api/resources/x12/resources/v1/types/Rarc.d.ts +8 -1
  204. package/dist/api/resources/x12/resources/v1/types/Rarc.js +7 -0
  205. package/dist/serialization/resources/credentialing/resources/v2/client/getAll.d.ts +6 -1
  206. package/dist/serialization/resources/credentialing/resources/v2/client/getAll.js +6 -0
  207. package/dist/serialization/resources/guarantor/resources/v1/types/GuarantorBase.d.ts +1 -1
  208. package/dist/serialization/resources/guarantor/resources/v1/types/GuarantorBase.js +1 -1
  209. package/dist/serialization/resources/index.d.ts +1 -0
  210. package/dist/serialization/resources/index.js +2 -1
  211. package/dist/serialization/resources/insuranceAdjudications/resources/v1/types/InsuranceAdjudicationCreate.d.ts +2 -0
  212. package/dist/serialization/resources/insuranceAdjudications/resources/v1/types/InsuranceAdjudicationCreate.js +2 -0
  213. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/create.d.ts +2 -2
  214. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/create.js +2 -2
  215. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/deactivate.d.ts +2 -2
  216. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/deactivate.js +2 -2
  217. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/get.d.ts +2 -2
  218. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/get.js +2 -2
  219. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/getHistory.d.ts +2 -2
  220. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/getHistory.js +2 -2
  221. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/update.d.ts +2 -2
  222. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/client/update.js +2 -2
  223. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/types/AppointmentWorkQueue.d.ts +1 -1
  224. package/dist/serialization/resources/preEncounter/resources/appointments/resources/v1/types/AppointmentWorkQueue.js +1 -1
  225. package/dist/serialization/resources/preEncounter/resources/common/types/{ErrorBase.d.ts → ErrorBase4Xx.d.ts} +3 -2
  226. package/dist/serialization/resources/preEncounter/resources/common/types/{ErrorBase.js → ErrorBase4Xx.js} +3 -2
  227. package/dist/serialization/resources/preEncounter/resources/common/types/VersionConflictErrorBody.d.ts +3 -4
  228. package/dist/serialization/resources/preEncounter/resources/common/types/VersionConflictErrorBody.js +3 -4
  229. package/dist/serialization/resources/preEncounter/resources/common/types/index.d.ts +1 -2
  230. package/dist/serialization/resources/preEncounter/resources/common/types/index.js +1 -2
  231. package/dist/serialization/resources/preEncounter/resources/coverages/resources/v1/client/getHistory.d.ts +2 -2
  232. package/dist/serialization/resources/preEncounter/resources/coverages/resources/v1/client/getHistory.js +2 -2
  233. package/dist/serialization/resources/preEncounter/resources/coverages/resources/v1/client/update.d.ts +2 -2
  234. package/dist/serialization/resources/preEncounter/resources/coverages/resources/v1/client/update.js +2 -2
  235. package/dist/serialization/resources/preEncounter/resources/coverages/resources/v1/types/CoverageBenefits.d.ts +1 -0
  236. package/dist/serialization/resources/preEncounter/resources/coverages/resources/v1/types/CoverageBenefits.js +1 -0
  237. package/dist/serialization/resources/preEncounter/resources/lists/resources/v1/client/getPatientList.d.ts +2 -2
  238. package/dist/serialization/resources/preEncounter/resources/lists/resources/v1/client/getPatientList.js +2 -2
  239. package/dist/serialization/resources/preEncounter/resources/lists/resources/v1/types/AppointmentListItem.d.ts +2 -0
  240. package/dist/serialization/resources/preEncounter/resources/lists/resources/v1/types/AppointmentListItem.js +2 -0
  241. package/dist/serialization/resources/preEncounter/resources/lists/resources/v1/types/SortFieldString.d.ts +10 -0
  242. package/dist/serialization/resources/preEncounter/resources/lists/resources/v1/types/SortFieldString.js +35 -0
  243. package/dist/serialization/resources/preEncounter/resources/lists/resources/v1/types/index.d.ts +1 -0
  244. package/dist/serialization/resources/preEncounter/resources/lists/resources/v1/types/index.js +1 -0
  245. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/create.d.ts +1 -6
  246. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/create.js +0 -6
  247. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/createWithMrn.d.ts +20 -0
  248. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/createWithMrn.js +67 -0
  249. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/deactivate.d.ts +2 -2
  250. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/deactivate.js +2 -2
  251. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/get.d.ts +2 -2
  252. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/get.js +2 -2
  253. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/getHistory.d.ts +2 -2
  254. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/getHistory.js +2 -2
  255. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/index.d.ts +1 -0
  256. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/index.js +2 -1
  257. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/update.d.ts +2 -2
  258. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/client/update.js +2 -2
  259. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/DoNotInvoiceReason.d.ts +10 -0
  260. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/DoNotInvoiceReason.js +31 -0
  261. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/MutablePatient.d.ts +2 -0
  262. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/MutablePatient.js +2 -0
  263. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/MutablePatientWithMrn.d.ts +13 -0
  264. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/MutablePatientWithMrn.js +36 -0
  265. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/index.d.ts +2 -2
  266. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/index.js +2 -2
  267. package/dist/serialization/resources/remitDrafts/index.d.ts +1 -0
  268. package/dist/serialization/resources/remitDrafts/index.js +17 -0
  269. package/dist/serialization/resources/remitDrafts/resources/index.d.ts +1 -0
  270. package/dist/serialization/resources/remitDrafts/resources/index.js +27 -0
  271. package/dist/serialization/resources/remitDrafts/resources/v1/index.d.ts +1 -0
  272. package/dist/serialization/resources/remitDrafts/resources/v1/index.js +17 -0
  273. package/dist/serialization/resources/remitDrafts/resources/v1/types/RemitDraftId.d.ts +10 -0
  274. package/dist/serialization/resources/{preEncounter/resources/common/types/NotFoundErrorBody.js → remitDrafts/resources/v1/types/RemitDraftId.js} +6 -7
  275. package/dist/serialization/resources/remitDrafts/resources/v1/types/index.d.ts +1 -0
  276. package/dist/serialization/resources/remitDrafts/resources/v1/types/index.js +17 -0
  277. package/dist/serialization/resources/x12/resources/v1/types/Rarc.d.ts +1 -1
  278. package/dist/serialization/resources/x12/resources/v1/types/Rarc.js +7 -0
  279. package/package.json +1 -1
  280. package/reference.md +259 -4
  281. package/serialization/resources/credentialing/resources/v2/client/getAll.d.ts +6 -1
  282. package/serialization/resources/credentialing/resources/v2/client/getAll.js +6 -0
  283. package/serialization/resources/guarantor/resources/v1/types/GuarantorBase.d.ts +1 -1
  284. package/serialization/resources/guarantor/resources/v1/types/GuarantorBase.js +1 -1
  285. package/serialization/resources/index.d.ts +1 -0
  286. package/serialization/resources/index.js +2 -1
  287. package/serialization/resources/insuranceAdjudications/resources/v1/types/InsuranceAdjudicationCreate.d.ts +2 -0
  288. package/serialization/resources/insuranceAdjudications/resources/v1/types/InsuranceAdjudicationCreate.js +2 -0
  289. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/create.d.ts +2 -2
  290. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/create.js +2 -2
  291. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/deactivate.d.ts +2 -2
  292. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/deactivate.js +2 -2
  293. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/get.d.ts +2 -2
  294. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/get.js +2 -2
  295. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/getHistory.d.ts +2 -2
  296. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/getHistory.js +2 -2
  297. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/update.d.ts +2 -2
  298. package/serialization/resources/preEncounter/resources/appointments/resources/v1/client/update.js +2 -2
  299. package/serialization/resources/preEncounter/resources/appointments/resources/v1/types/AppointmentWorkQueue.d.ts +1 -1
  300. package/serialization/resources/preEncounter/resources/appointments/resources/v1/types/AppointmentWorkQueue.js +1 -1
  301. package/serialization/resources/preEncounter/resources/common/types/{ErrorBase.d.ts → ErrorBase4Xx.d.ts} +3 -2
  302. package/serialization/resources/preEncounter/resources/common/types/{ErrorBase.js → ErrorBase4Xx.js} +3 -2
  303. package/serialization/resources/preEncounter/resources/common/types/VersionConflictErrorBody.d.ts +3 -4
  304. package/serialization/resources/preEncounter/resources/common/types/VersionConflictErrorBody.js +3 -4
  305. package/serialization/resources/preEncounter/resources/common/types/index.d.ts +1 -2
  306. package/serialization/resources/preEncounter/resources/common/types/index.js +1 -2
  307. package/serialization/resources/preEncounter/resources/coverages/resources/v1/client/getHistory.d.ts +2 -2
  308. package/serialization/resources/preEncounter/resources/coverages/resources/v1/client/getHistory.js +2 -2
  309. package/serialization/resources/preEncounter/resources/coverages/resources/v1/client/update.d.ts +2 -2
  310. package/serialization/resources/preEncounter/resources/coverages/resources/v1/client/update.js +2 -2
  311. package/serialization/resources/preEncounter/resources/coverages/resources/v1/types/CoverageBenefits.d.ts +1 -0
  312. package/serialization/resources/preEncounter/resources/coverages/resources/v1/types/CoverageBenefits.js +1 -0
  313. package/serialization/resources/preEncounter/resources/lists/resources/v1/client/getPatientList.d.ts +2 -2
  314. package/serialization/resources/preEncounter/resources/lists/resources/v1/client/getPatientList.js +2 -2
  315. package/serialization/resources/preEncounter/resources/lists/resources/v1/types/AppointmentListItem.d.ts +2 -0
  316. package/serialization/resources/preEncounter/resources/lists/resources/v1/types/AppointmentListItem.js +2 -0
  317. package/serialization/resources/preEncounter/resources/lists/resources/v1/types/SortFieldString.d.ts +10 -0
  318. package/serialization/resources/preEncounter/resources/lists/resources/v1/types/SortFieldString.js +35 -0
  319. package/serialization/resources/preEncounter/resources/lists/resources/v1/types/index.d.ts +1 -0
  320. package/serialization/resources/preEncounter/resources/lists/resources/v1/types/index.js +1 -0
  321. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/create.d.ts +1 -6
  322. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/create.js +0 -6
  323. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/createWithMrn.d.ts +20 -0
  324. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/createWithMrn.js +67 -0
  325. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/deactivate.d.ts +2 -2
  326. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/deactivate.js +2 -2
  327. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/get.d.ts +2 -2
  328. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/get.js +2 -2
  329. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/getHistory.d.ts +2 -2
  330. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/getHistory.js +2 -2
  331. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/index.d.ts +1 -0
  332. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/index.js +2 -1
  333. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/update.d.ts +2 -2
  334. package/serialization/resources/preEncounter/resources/patients/resources/v1/client/update.js +2 -2
  335. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/DoNotInvoiceReason.d.ts +10 -0
  336. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/DoNotInvoiceReason.js +31 -0
  337. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/MutablePatient.d.ts +2 -0
  338. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/MutablePatient.js +2 -0
  339. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/MutablePatientWithMrn.d.ts +13 -0
  340. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/MutablePatientWithMrn.js +36 -0
  341. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/index.d.ts +2 -2
  342. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/index.js +2 -2
  343. package/serialization/resources/remitDrafts/index.d.ts +1 -0
  344. package/serialization/resources/remitDrafts/index.js +17 -0
  345. package/serialization/resources/remitDrafts/resources/index.d.ts +1 -0
  346. package/serialization/resources/remitDrafts/resources/index.js +27 -0
  347. package/serialization/resources/remitDrafts/resources/v1/index.d.ts +1 -0
  348. package/serialization/resources/remitDrafts/resources/v1/index.js +17 -0
  349. package/serialization/resources/remitDrafts/resources/v1/types/RemitDraftId.d.ts +10 -0
  350. package/serialization/resources/{preEncounter/resources/common/types/NotFoundErrorBody.js → remitDrafts/resources/v1/types/RemitDraftId.js} +6 -7
  351. package/serialization/resources/remitDrafts/resources/v1/types/index.d.ts +1 -0
  352. package/serialization/resources/remitDrafts/resources/v1/types/index.js +17 -0
  353. package/serialization/resources/x12/resources/v1/types/Rarc.d.ts +1 -1
  354. package/serialization/resources/x12/resources/v1/types/Rarc.js +7 -0
  355. package/api/resources/preEncounter/resources/common/types/NotFoundErrorBody.d.ts +0 -7
  356. package/api/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatient.d.ts +0 -8
  357. package/api/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatientsErrorBody.d.ts +0 -8
  358. package/dist/api/resources/preEncounter/resources/common/types/NotFoundErrorBody.d.ts +0 -7
  359. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatient.d.ts +0 -8
  360. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatient.js +0 -5
  361. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatientsErrorBody.d.ts +0 -8
  362. package/dist/api/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatientsErrorBody.js +0 -5
  363. package/dist/serialization/resources/preEncounter/resources/common/types/NotFoundErrorBody.d.ts +0 -13
  364. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatient.d.ts +0 -14
  365. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatient.js +0 -35
  366. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatientsErrorBody.d.ts +0 -15
  367. package/dist/serialization/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatientsErrorBody.js +0 -38
  368. package/serialization/resources/preEncounter/resources/common/types/NotFoundErrorBody.d.ts +0 -13
  369. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatient.d.ts +0 -14
  370. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatient.js +0 -35
  371. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatientsErrorBody.d.ts +0 -15
  372. package/serialization/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatientsErrorBody.js +0 -38
  373. /package/api/resources/preEncounter/resources/common/types/{ErrorBase.js → ErrorBase4Xx.js} +0 -0
  374. /package/api/resources/preEncounter/resources/{common/types/NotFoundErrorBody.js → patients/resources/v1/client/requests/CreatePatientWithMrnRequest.js} +0 -0
  375. /package/api/resources/preEncounter/resources/patients/resources/v1/types/{PotentialDuplicatePatient.js → MutablePatientWithMrn.js} +0 -0
  376. /package/{api/resources/preEncounter/resources/patients/resources/v1/types/PotentialDuplicatePatientsErrorBody.js → dist/api/resources/preEncounter/resources/common/types/ErrorBase4Xx.js} +0 -0
  377. /package/dist/api/resources/preEncounter/resources/{common/types/ErrorBase.js → patients/resources/v1/client/requests/CreatePatientWithMrnRequest.js} +0 -0
  378. /package/dist/api/resources/preEncounter/resources/{common/types/NotFoundErrorBody.js → patients/resources/v1/types/MutablePatientWithMrn.js} +0 -0
@@ -214,7 +214,8 @@ class V1 {
214
214
  * },
215
215
  * referralNumber: "string"
216
216
  * }],
217
- * primaryServiceFacilityId: "string"
217
+ * primaryServiceFacilityId: "string",
218
+ * doNotInvoiceReason: CandidApi.preEncounter.patients.v1.DoNotInvoiceReason.Bankruptcy
218
219
  * }
219
220
  * })
220
221
  */
@@ -234,7 +235,7 @@ class V1 {
234
235
  Authorization: yield this._getAuthorizationHeader(),
235
236
  "X-Fern-Language": "JavaScript",
236
237
  "X-Fern-SDK-Name": "candidhealth",
237
- "X-Fern-SDK-Version": "0.35.0",
238
+ "X-Fern-SDK-Version": "0.35.2",
238
239
  "X-Fern-Runtime": core.RUNTIME.type,
239
240
  "X-Fern-Runtime-Version": core.RUNTIME.version,
240
241
  },
@@ -262,7 +263,6 @@ class V1 {
262
263
  if (_response.error.reason === "status-code") {
263
264
  switch ((_b = _response.error.body) === null || _b === void 0 ? void 0 : _b.errorName) {
264
265
  case "VersionConflictError":
265
- case "PotentialDuplicatePatients":
266
266
  return {
267
267
  ok: false,
268
268
  error: serializers.preEncounter.patients.v1.create.Error.parseOrThrow(_response.error.body, {
@@ -280,6 +280,240 @@ class V1 {
280
280
  };
281
281
  });
282
282
  }
283
+ /**
284
+ * Adds a patient and hydrates their MRN with a pre-existing MRN. Once this patient is created their MRN will not be editable. BadRequestError is returned when the MRN is greater than 20 characters. VersionConflictError is returned when the patient's external ID is already in use.
285
+ *
286
+ * @param {CandidApi.preEncounter.patients.v1.CreatePatientWithMrnRequest} request
287
+ * @param {V1.RequestOptions} requestOptions - Request-specific configuration.
288
+ *
289
+ * @example
290
+ * await client.preEncounter.patients.v1.createWithMrn({
291
+ * skipDuplicateCheck: true,
292
+ * body: {
293
+ * mrn: "string",
294
+ * name: {
295
+ * family: "string",
296
+ * given: ["string"],
297
+ * use: CandidApi.preEncounter.NameUse.Usual,
298
+ * period: {}
299
+ * },
300
+ * otherNames: [{
301
+ * family: "string",
302
+ * given: ["string"],
303
+ * use: CandidApi.preEncounter.NameUse.Usual,
304
+ * period: {}
305
+ * }],
306
+ * gender: CandidApi.preEncounter.Gender.Man,
307
+ * birthDate: "2023-01-15",
308
+ * socialSecurityNumber: "string",
309
+ * biologicalSex: CandidApi.preEncounter.Sex.Female,
310
+ * sexualOrientation: CandidApi.preEncounter.SexualOrientation.Heterosexual,
311
+ * race: CandidApi.preEncounter.Race.AmericanIndianOrAlaskaNative,
312
+ * ethnicity: CandidApi.preEncounter.Ethnicity.HispanicOrLatino,
313
+ * disabilityStatus: CandidApi.preEncounter.DisabilityStatus.Disabled,
314
+ * maritalStatus: CandidApi.preEncounter.patients.v1.MaritalStatus.Annulled,
315
+ * deceased: new Date("2024-01-15T09:30:00.000Z"),
316
+ * multipleBirth: 1,
317
+ * primaryAddress: {
318
+ * use: CandidApi.preEncounter.AddressUse.Home,
319
+ * line: ["string"],
320
+ * city: "string",
321
+ * state: "string",
322
+ * postalCode: "string",
323
+ * country: "string",
324
+ * period: {}
325
+ * },
326
+ * otherAddresses: [{
327
+ * use: CandidApi.preEncounter.AddressUse.Home,
328
+ * line: ["string"],
329
+ * city: "string",
330
+ * state: "string",
331
+ * postalCode: "string",
332
+ * country: "string",
333
+ * period: {}
334
+ * }],
335
+ * primaryTelecom: {
336
+ * value: "string",
337
+ * use: CandidApi.preEncounter.ContactPointUse.Home
338
+ * },
339
+ * otherTelecoms: [{
340
+ * value: "string",
341
+ * use: CandidApi.preEncounter.ContactPointUse.Home
342
+ * }],
343
+ * email: "string",
344
+ * electronicCommunicationOptIn: true,
345
+ * photo: "string",
346
+ * language: "string",
347
+ * externalProvenance: {
348
+ * externalId: "string",
349
+ * systemName: "string"
350
+ * },
351
+ * contacts: [{
352
+ * relationship: [CandidApi.preEncounter.Relationship.Self],
353
+ * name: {
354
+ * family: "string",
355
+ * given: ["string"],
356
+ * use: CandidApi.preEncounter.NameUse.Usual,
357
+ * period: {}
358
+ * },
359
+ * telecoms: [{
360
+ * value: "string",
361
+ * use: CandidApi.preEncounter.ContactPointUse.Home
362
+ * }],
363
+ * addresses: [{
364
+ * use: CandidApi.preEncounter.AddressUse.Home,
365
+ * line: ["string"],
366
+ * city: "string",
367
+ * state: "string",
368
+ * postalCode: "string",
369
+ * country: "string",
370
+ * period: {}
371
+ * }],
372
+ * period: {},
373
+ * hipaaAuthorization: true
374
+ * }],
375
+ * generalPractitioners: [{
376
+ * name: {
377
+ * family: "string",
378
+ * given: ["string"],
379
+ * use: CandidApi.preEncounter.NameUse.Usual,
380
+ * period: {}
381
+ * },
382
+ * type: CandidApi.preEncounter.ExternalProviderType.Primary,
383
+ * npi: "string",
384
+ * telecoms: [{
385
+ * value: "string",
386
+ * use: CandidApi.preEncounter.ContactPointUse.Home
387
+ * }],
388
+ * addresses: [],
389
+ * period: {},
390
+ * canonicalId: CandidApi.preEncounter.CanonicalProviderId("string")
391
+ * }],
392
+ * filingOrder: {
393
+ * coverages: [CandidApi.preEncounter.CoverageId("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32")]
394
+ * },
395
+ * nonInsurancePayers: [CandidApi.preEncounter.CanonicalNonInsurancePayerId("string")],
396
+ * nonInsurancePayerAssociations: [{
397
+ * id: CandidApi.preEncounter.CanonicalNonInsurancePayerId("string")
398
+ * }],
399
+ * guarantor: {
400
+ * name: {
401
+ * family: "string",
402
+ * given: ["string"],
403
+ * use: CandidApi.preEncounter.NameUse.Usual,
404
+ * period: {}
405
+ * },
406
+ * telecom: {
407
+ * value: "string",
408
+ * use: CandidApi.preEncounter.ContactPointUse.Home
409
+ * },
410
+ * email: "string",
411
+ * birthDate: "2023-01-15",
412
+ * address: {
413
+ * use: CandidApi.preEncounter.AddressUse.Home,
414
+ * line: ["string"],
415
+ * city: "string",
416
+ * state: "string",
417
+ * postalCode: "string",
418
+ * country: "string",
419
+ * period: {}
420
+ * }
421
+ * },
422
+ * selfPay: true,
423
+ * authorizations: [{
424
+ * payerId: CandidApi.preEncounter.PayerId("string"),
425
+ * payerName: "string",
426
+ * authorizationNumber: "string",
427
+ * cptCode: "string",
428
+ * units: CandidApi.preEncounter.patients.v1.AuthorizationUnit.Visit
429
+ * }],
430
+ * referrals: [{
431
+ * provider: {
432
+ * name: {
433
+ * family: "string",
434
+ * given: ["string"],
435
+ * use: CandidApi.preEncounter.NameUse.Usual,
436
+ * period: {}
437
+ * },
438
+ * type: CandidApi.preEncounter.ExternalProviderType.Primary,
439
+ * npi: "string",
440
+ * telecoms: [{
441
+ * value: "string",
442
+ * use: CandidApi.preEncounter.ContactPointUse.Home
443
+ * }],
444
+ * addresses: [],
445
+ * period: {},
446
+ * canonicalId: CandidApi.preEncounter.CanonicalProviderId("string")
447
+ * },
448
+ * referralNumber: "string"
449
+ * }],
450
+ * primaryServiceFacilityId: "string",
451
+ * doNotInvoiceReason: CandidApi.preEncounter.patients.v1.DoNotInvoiceReason.Bankruptcy
452
+ * }
453
+ * })
454
+ */
455
+ createWithMrn(request, requestOptions) {
456
+ var _a, _b;
457
+ return __awaiter(this, void 0, void 0, function* () {
458
+ const { skipDuplicateCheck, body: _body } = request;
459
+ const _queryParams = {};
460
+ if (skipDuplicateCheck != null) {
461
+ _queryParams["skip_duplicate_check"] = skipDuplicateCheck.toString();
462
+ }
463
+ const _response = yield core.fetcher({
464
+ url: (0, url_join_1.default)(((_a = (yield core.Supplier.get(this._options.environment))) !== null && _a !== void 0 ? _a : environments.CandidApiEnvironment.Production)
465
+ .preEncounter, "/patients/v1/with_mrn"),
466
+ method: "POST",
467
+ headers: {
468
+ Authorization: yield this._getAuthorizationHeader(),
469
+ "X-Fern-Language": "JavaScript",
470
+ "X-Fern-SDK-Name": "candidhealth",
471
+ "X-Fern-SDK-Version": "0.35.2",
472
+ "X-Fern-Runtime": core.RUNTIME.type,
473
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
474
+ },
475
+ contentType: "application/json",
476
+ queryParameters: _queryParams,
477
+ requestType: "json",
478
+ body: serializers.preEncounter.patients.v1.MutablePatientWithMrn.jsonOrThrow(_body, {
479
+ unrecognizedObjectKeys: "strip",
480
+ }),
481
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
482
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
483
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
484
+ });
485
+ if (_response.ok) {
486
+ return {
487
+ ok: true,
488
+ body: serializers.preEncounter.patients.v1.Patient.parseOrThrow(_response.body, {
489
+ unrecognizedObjectKeys: "passthrough",
490
+ allowUnrecognizedUnionMembers: true,
491
+ allowUnrecognizedEnumValues: true,
492
+ breadcrumbsPrefix: ["response"],
493
+ }),
494
+ };
495
+ }
496
+ if (_response.error.reason === "status-code") {
497
+ switch ((_b = _response.error.body) === null || _b === void 0 ? void 0 : _b.errorName) {
498
+ case "VersionConflictError":
499
+ case "BadRequestError":
500
+ return {
501
+ ok: false,
502
+ error: serializers.preEncounter.patients.v1.createWithMrn.Error.parseOrThrow(_response.error.body, {
503
+ unrecognizedObjectKeys: "passthrough",
504
+ allowUnrecognizedUnionMembers: true,
505
+ allowUnrecognizedEnumValues: true,
506
+ breadcrumbsPrefix: ["response"],
507
+ }),
508
+ };
509
+ }
510
+ }
511
+ return {
512
+ ok: false,
513
+ error: CandidApi.preEncounter.patients.v1.createWithMrn.Error._unknown(_response.error),
514
+ };
515
+ });
516
+ }
283
517
  /**
284
518
  * Searches for patients that match the query parameters.
285
519
  *
@@ -323,7 +557,7 @@ class V1 {
323
557
  Authorization: yield this._getAuthorizationHeader(),
324
558
  "X-Fern-Language": "JavaScript",
325
559
  "X-Fern-SDK-Name": "candidhealth",
326
- "X-Fern-SDK-Version": "0.35.0",
560
+ "X-Fern-SDK-Version": "0.35.2",
327
561
  "X-Fern-Runtime": core.RUNTIME.type,
328
562
  "X-Fern-Runtime-Version": core.RUNTIME.version,
329
563
  },
@@ -371,7 +605,7 @@ class V1 {
371
605
  Authorization: yield this._getAuthorizationHeader(),
372
606
  "X-Fern-Language": "JavaScript",
373
607
  "X-Fern-SDK-Name": "candidhealth",
374
- "X-Fern-SDK-Version": "0.35.0",
608
+ "X-Fern-SDK-Version": "0.35.2",
375
609
  "X-Fern-Runtime": core.RUNTIME.type,
376
610
  "X-Fern-Runtime-Version": core.RUNTIME.version,
377
611
  },
@@ -432,7 +666,7 @@ class V1 {
432
666
  Authorization: yield this._getAuthorizationHeader(),
433
667
  "X-Fern-Language": "JavaScript",
434
668
  "X-Fern-SDK-Name": "candidhealth",
435
- "X-Fern-SDK-Version": "0.35.0",
669
+ "X-Fern-SDK-Version": "0.35.2",
436
670
  "X-Fern-Runtime": core.RUNTIME.type,
437
671
  "X-Fern-Runtime-Version": core.RUNTIME.version,
438
672
  },
@@ -639,7 +873,8 @@ class V1 {
639
873
  * },
640
874
  * referralNumber: "string"
641
875
  * }],
642
- * primaryServiceFacilityId: "string"
876
+ * primaryServiceFacilityId: "string",
877
+ * doNotInvoiceReason: CandidApi.preEncounter.patients.v1.DoNotInvoiceReason.Bankruptcy
643
878
  * })
644
879
  */
645
880
  update(id, version, request, requestOptions) {
@@ -653,7 +888,7 @@ class V1 {
653
888
  Authorization: yield this._getAuthorizationHeader(),
654
889
  "X-Fern-Language": "JavaScript",
655
890
  "X-Fern-SDK-Name": "candidhealth",
656
- "X-Fern-SDK-Version": "0.35.0",
891
+ "X-Fern-SDK-Version": "0.35.2",
657
892
  "X-Fern-Runtime": core.RUNTIME.type,
658
893
  "X-Fern-Runtime-Version": core.RUNTIME.version,
659
894
  },
@@ -719,7 +954,7 @@ class V1 {
719
954
  Authorization: yield this._getAuthorizationHeader(),
720
955
  "X-Fern-Language": "JavaScript",
721
956
  "X-Fern-SDK-Name": "candidhealth",
722
- "X-Fern-SDK-Version": "0.35.0",
957
+ "X-Fern-SDK-Version": "0.35.2",
723
958
  "X-Fern-Runtime": core.RUNTIME.type,
724
959
  "X-Fern-Runtime-Version": core.RUNTIME.version,
725
960
  },
@@ -787,7 +1022,7 @@ class V1 {
787
1022
  Authorization: yield this._getAuthorizationHeader(),
788
1023
  "X-Fern-Language": "JavaScript",
789
1024
  "X-Fern-SDK-Name": "candidhealth",
790
- "X-Fern-SDK-Version": "0.35.0",
1025
+ "X-Fern-SDK-Version": "0.35.2",
791
1026
  "X-Fern-Runtime": core.RUNTIME.type,
792
1027
  "X-Fern-Runtime-Version": core.RUNTIME.version,
793
1028
  },
@@ -840,7 +1075,7 @@ class V1 {
840
1075
  Authorization: yield this._getAuthorizationHeader(),
841
1076
  "X-Fern-Language": "JavaScript",
842
1077
  "X-Fern-SDK-Name": "candidhealth",
843
- "X-Fern-SDK-Version": "0.35.0",
1078
+ "X-Fern-SDK-Version": "0.35.2",
844
1079
  "X-Fern-Runtime": core.RUNTIME.type,
845
1080
  "X-Fern-Runtime-Version": core.RUNTIME.version,
846
1081
  },
@@ -3,16 +3,12 @@
3
3
  */
4
4
  import * as CandidApi from "../../../../../../../index";
5
5
  import * as core from "../../../../../../../../core";
6
- export declare type Error = CandidApi.preEncounter.patients.v1.create.Error.VersionConflictError | CandidApi.preEncounter.patients.v1.create.Error.PotentialDuplicatePatients | CandidApi.preEncounter.patients.v1.create.Error._Unknown;
6
+ export declare type Error = CandidApi.preEncounter.patients.v1.create.Error.VersionConflictError | CandidApi.preEncounter.patients.v1.create.Error._Unknown;
7
7
  export declare namespace Error {
8
8
  interface VersionConflictError extends _Utils {
9
9
  errorName: "VersionConflictError";
10
10
  content: CandidApi.preEncounter.VersionConflictErrorBody;
11
11
  }
12
- interface PotentialDuplicatePatients extends _Utils {
13
- errorName: "PotentialDuplicatePatients";
14
- content: CandidApi.preEncounter.patients.v1.PotentialDuplicatePatientsErrorBody;
15
- }
16
12
  interface _Unknown extends _Utils {
17
13
  errorName: void;
18
14
  content: core.Fetcher.Error;
@@ -22,13 +18,11 @@ export declare namespace Error {
22
18
  }
23
19
  interface _Visitor<_Result> {
24
20
  versionConflictError: (value: CandidApi.preEncounter.VersionConflictErrorBody) => _Result;
25
- potentialDuplicatePatients: (value: CandidApi.preEncounter.patients.v1.PotentialDuplicatePatientsErrorBody) => _Result;
26
21
  _other: (value: core.Fetcher.Error) => _Result;
27
22
  }
28
23
  }
29
24
  export declare const Error: {
30
25
  readonly versionConflictError: (value: CandidApi.preEncounter.VersionConflictErrorBody) => CandidApi.preEncounter.patients.v1.create.Error.VersionConflictError;
31
- readonly potentialDuplicatePatients: (value: CandidApi.preEncounter.patients.v1.PotentialDuplicatePatientsErrorBody) => CandidApi.preEncounter.patients.v1.create.Error.PotentialDuplicatePatients;
32
26
  readonly _unknown: (fetcherError: core.Fetcher.Error) => CandidApi.preEncounter.patients.v1.create.Error._Unknown;
33
27
  readonly _visit: <_Result>(value: CandidApi.preEncounter.patients.v1.create.Error, visitor: CandidApi.preEncounter.patients.v1.create.Error._Visitor<_Result>) => _Result;
34
28
  };
@@ -38,15 +38,6 @@ exports.Error = {
38
38
  },
39
39
  };
40
40
  },
41
- potentialDuplicatePatients: (value) => {
42
- return {
43
- content: value,
44
- errorName: "PotentialDuplicatePatients",
45
- _visit: function (visitor) {
46
- return CandidApi.preEncounter.patients.v1.create.Error._visit(this, visitor);
47
- },
48
- };
49
- },
50
41
  _unknown: (fetcherError) => {
51
42
  return {
52
43
  errorName: undefined,
@@ -60,8 +51,6 @@ exports.Error = {
60
51
  switch (value.errorName) {
61
52
  case "VersionConflictError":
62
53
  return visitor.versionConflictError(value.content);
63
- case "PotentialDuplicatePatients":
64
- return visitor.potentialDuplicatePatients(value.content);
65
54
  default:
66
55
  return visitor._other(value);
67
56
  }
@@ -0,0 +1,34 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as CandidApi from "../../../../../../../index";
5
+ import * as core from "../../../../../../../../core";
6
+ export declare type Error = CandidApi.preEncounter.patients.v1.createWithMrn.Error.VersionConflictError | CandidApi.preEncounter.patients.v1.createWithMrn.Error.BadRequestError | CandidApi.preEncounter.patients.v1.createWithMrn.Error._Unknown;
7
+ export declare namespace Error {
8
+ interface VersionConflictError extends _Utils {
9
+ errorName: "VersionConflictError";
10
+ content: CandidApi.preEncounter.VersionConflictErrorBody;
11
+ }
12
+ interface BadRequestError extends _Utils {
13
+ errorName: "BadRequestError";
14
+ content: CandidApi.preEncounter.ErrorBase4Xx;
15
+ }
16
+ interface _Unknown extends _Utils {
17
+ errorName: void;
18
+ content: core.Fetcher.Error;
19
+ }
20
+ interface _Utils {
21
+ _visit: <_Result>(visitor: CandidApi.preEncounter.patients.v1.createWithMrn.Error._Visitor<_Result>) => _Result;
22
+ }
23
+ interface _Visitor<_Result> {
24
+ versionConflictError: (value: CandidApi.preEncounter.VersionConflictErrorBody) => _Result;
25
+ badRequestError: (value: CandidApi.preEncounter.ErrorBase4Xx) => _Result;
26
+ _other: (value: core.Fetcher.Error) => _Result;
27
+ }
28
+ }
29
+ export declare const Error: {
30
+ readonly versionConflictError: (value: CandidApi.preEncounter.VersionConflictErrorBody) => CandidApi.preEncounter.patients.v1.createWithMrn.Error.VersionConflictError;
31
+ readonly badRequestError: (value: CandidApi.preEncounter.ErrorBase4Xx) => CandidApi.preEncounter.patients.v1.createWithMrn.Error.BadRequestError;
32
+ readonly _unknown: (fetcherError: core.Fetcher.Error) => CandidApi.preEncounter.patients.v1.createWithMrn.Error._Unknown;
33
+ readonly _visit: <_Result>(value: CandidApi.preEncounter.patients.v1.createWithMrn.Error, visitor: CandidApi.preEncounter.patients.v1.createWithMrn.Error._Visitor<_Result>) => _Result;
34
+ };
@@ -0,0 +1,69 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ exports.Error = void 0;
30
+ const CandidApi = __importStar(require("../../../../../../../index"));
31
+ exports.Error = {
32
+ versionConflictError: (value) => {
33
+ return {
34
+ content: value,
35
+ errorName: "VersionConflictError",
36
+ _visit: function (visitor) {
37
+ return CandidApi.preEncounter.patients.v1.createWithMrn.Error._visit(this, visitor);
38
+ },
39
+ };
40
+ },
41
+ badRequestError: (value) => {
42
+ return {
43
+ content: value,
44
+ errorName: "BadRequestError",
45
+ _visit: function (visitor) {
46
+ return CandidApi.preEncounter.patients.v1.createWithMrn.Error._visit(this, visitor);
47
+ },
48
+ };
49
+ },
50
+ _unknown: (fetcherError) => {
51
+ return {
52
+ errorName: undefined,
53
+ content: fetcherError,
54
+ _visit: function (visitor) {
55
+ return CandidApi.preEncounter.patients.v1.createWithMrn.Error._visit(this, visitor);
56
+ },
57
+ };
58
+ },
59
+ _visit: (value, visitor) => {
60
+ switch (value.errorName) {
61
+ case "VersionConflictError":
62
+ return visitor.versionConflictError(value.content);
63
+ case "BadRequestError":
64
+ return visitor.badRequestError(value.content);
65
+ default:
66
+ return visitor._other(value);
67
+ }
68
+ },
69
+ };
@@ -7,7 +7,7 @@ export declare type Error = CandidApi.preEncounter.patients.v1.deactivate.Error.
7
7
  export declare namespace Error {
8
8
  interface NotFoundError extends _Utils {
9
9
  errorName: "NotFoundError";
10
- content: CandidApi.preEncounter.NotFoundErrorBody;
10
+ content: CandidApi.preEncounter.ErrorBase4Xx;
11
11
  }
12
12
  interface VersionConflictError extends _Utils {
13
13
  errorName: "VersionConflictError";
@@ -21,13 +21,13 @@ export declare namespace Error {
21
21
  _visit: <_Result>(visitor: CandidApi.preEncounter.patients.v1.deactivate.Error._Visitor<_Result>) => _Result;
22
22
  }
23
23
  interface _Visitor<_Result> {
24
- notFoundError: (value: CandidApi.preEncounter.NotFoundErrorBody) => _Result;
24
+ notFoundError: (value: CandidApi.preEncounter.ErrorBase4Xx) => _Result;
25
25
  versionConflictError: (value: CandidApi.preEncounter.VersionConflictErrorBody) => _Result;
26
26
  _other: (value: core.Fetcher.Error) => _Result;
27
27
  }
28
28
  }
29
29
  export declare const Error: {
30
- readonly notFoundError: (value: CandidApi.preEncounter.NotFoundErrorBody) => CandidApi.preEncounter.patients.v1.deactivate.Error.NotFoundError;
30
+ readonly notFoundError: (value: CandidApi.preEncounter.ErrorBase4Xx) => CandidApi.preEncounter.patients.v1.deactivate.Error.NotFoundError;
31
31
  readonly versionConflictError: (value: CandidApi.preEncounter.VersionConflictErrorBody) => CandidApi.preEncounter.patients.v1.deactivate.Error.VersionConflictError;
32
32
  readonly _unknown: (fetcherError: core.Fetcher.Error) => CandidApi.preEncounter.patients.v1.deactivate.Error._Unknown;
33
33
  readonly _visit: <_Result>(value: CandidApi.preEncounter.patients.v1.deactivate.Error, visitor: CandidApi.preEncounter.patients.v1.deactivate.Error._Visitor<_Result>) => _Result;
@@ -7,7 +7,7 @@ export declare type Error = CandidApi.preEncounter.patients.v1.get.Error.NotFoun
7
7
  export declare namespace Error {
8
8
  interface NotFoundError extends _Utils {
9
9
  errorName: "NotFoundError";
10
- content: CandidApi.preEncounter.NotFoundErrorBody;
10
+ content: CandidApi.preEncounter.ErrorBase4Xx;
11
11
  }
12
12
  interface _Unknown extends _Utils {
13
13
  errorName: void;
@@ -17,12 +17,12 @@ export declare namespace Error {
17
17
  _visit: <_Result>(visitor: CandidApi.preEncounter.patients.v1.get.Error._Visitor<_Result>) => _Result;
18
18
  }
19
19
  interface _Visitor<_Result> {
20
- notFoundError: (value: CandidApi.preEncounter.NotFoundErrorBody) => _Result;
20
+ notFoundError: (value: CandidApi.preEncounter.ErrorBase4Xx) => _Result;
21
21
  _other: (value: core.Fetcher.Error) => _Result;
22
22
  }
23
23
  }
24
24
  export declare const Error: {
25
- readonly notFoundError: (value: CandidApi.preEncounter.NotFoundErrorBody) => CandidApi.preEncounter.patients.v1.get.Error.NotFoundError;
25
+ readonly notFoundError: (value: CandidApi.preEncounter.ErrorBase4Xx) => CandidApi.preEncounter.patients.v1.get.Error.NotFoundError;
26
26
  readonly _unknown: (fetcherError: core.Fetcher.Error) => CandidApi.preEncounter.patients.v1.get.Error._Unknown;
27
27
  readonly _visit: <_Result>(value: CandidApi.preEncounter.patients.v1.get.Error, visitor: CandidApi.preEncounter.patients.v1.get.Error._Visitor<_Result>) => _Result;
28
28
  };
@@ -7,7 +7,7 @@ export declare type Error = CandidApi.preEncounter.patients.v1.getHistory.Error.
7
7
  export declare namespace Error {
8
8
  interface NotFoundError extends _Utils {
9
9
  errorName: "NotFoundError";
10
- content: CandidApi.preEncounter.NotFoundErrorBody;
10
+ content: CandidApi.preEncounter.ErrorBase4Xx;
11
11
  }
12
12
  interface _Unknown extends _Utils {
13
13
  errorName: void;
@@ -17,12 +17,12 @@ export declare namespace Error {
17
17
  _visit: <_Result>(visitor: CandidApi.preEncounter.patients.v1.getHistory.Error._Visitor<_Result>) => _Result;
18
18
  }
19
19
  interface _Visitor<_Result> {
20
- notFoundError: (value: CandidApi.preEncounter.NotFoundErrorBody) => _Result;
20
+ notFoundError: (value: CandidApi.preEncounter.ErrorBase4Xx) => _Result;
21
21
  _other: (value: core.Fetcher.Error) => _Result;
22
22
  }
23
23
  }
24
24
  export declare const Error: {
25
- readonly notFoundError: (value: CandidApi.preEncounter.NotFoundErrorBody) => CandidApi.preEncounter.patients.v1.getHistory.Error.NotFoundError;
25
+ readonly notFoundError: (value: CandidApi.preEncounter.ErrorBase4Xx) => CandidApi.preEncounter.patients.v1.getHistory.Error.NotFoundError;
26
26
  readonly _unknown: (fetcherError: core.Fetcher.Error) => CandidApi.preEncounter.patients.v1.getHistory.Error._Unknown;
27
27
  readonly _visit: <_Result>(value: CandidApi.preEncounter.patients.v1.getHistory.Error, visitor: CandidApi.preEncounter.patients.v1.getHistory.Error._Visitor<_Result>) => _Result;
28
28
  };
@@ -1,5 +1,6 @@
1
1
  export * from "./requests";
2
2
  export * as create from "./create";
3
+ export * as createWithMrn from "./createWithMrn";
3
4
  export * as getMulti from "./getMulti";
4
5
  export * as get from "./get";
5
6
  export * as getHistory from "./getHistory";
@@ -26,9 +26,10 @@ var __importStar = (this && this.__importStar) || function (mod) {
26
26
  return result;
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.scan = exports.search = exports.deactivate = exports.update = exports.getHistory = exports.get = exports.getMulti = exports.create = void 0;
29
+ exports.scan = exports.search = exports.deactivate = exports.update = exports.getHistory = exports.get = exports.getMulti = exports.createWithMrn = exports.create = void 0;
30
30
  __exportStar(require("./requests"), exports);
31
31
  exports.create = __importStar(require("./create"));
32
+ exports.createWithMrn = __importStar(require("./createWithMrn"));
32
33
  exports.getMulti = __importStar(require("./getMulti"));
33
34
  exports.get = __importStar(require("./get"));
34
35
  exports.getHistory = __importStar(require("./getHistory"));
@@ -163,7 +163,8 @@ import * as CandidApi from "../../../../../../../../index";
163
163
  * },
164
164
  * referralNumber: "string"
165
165
  * }],
166
- * primaryServiceFacilityId: "string"
166
+ * primaryServiceFacilityId: "string",
167
+ * doNotInvoiceReason: CandidApi.preEncounter.patients.v1.DoNotInvoiceReason.Bankruptcy
167
168
  * }
168
169
  * }
169
170
  */