@awell-health/awell-extensions 1.1.42 → 1.1.43-beta42

Sign up to get free protection for your applications and to get access to all the features.
Files changed (254) hide show
  1. package/dist/extensions/awell/v1/webhooks/index.d.ts +1 -1
  2. package/dist/extensions/awell/v1/webhooks/pathwayStart.d.ts +3 -1
  3. package/dist/extensions/awell/v1/webhooks/pathwayStart.js +13 -3
  4. package/dist/extensions/awell/v1/webhooks/pathwayStart.js.map +1 -1
  5. package/dist/extensions/calDotCom/webhooks/index.d.ts +1 -1
  6. package/dist/extensions/calendly/webhooks/index.d.ts +1 -1
  7. package/dist/extensions/elation/actions/updatePatient.js +1 -0
  8. package/dist/extensions/elation/actions/updatePatient.js.map +1 -1
  9. package/dist/extensions/elation/webhooks/index.d.ts +1 -1
  10. package/dist/extensions/healthie/lib/sdk/createSdk.d.ts +10 -0
  11. package/dist/extensions/healthie/lib/sdk/createSdk.js +17 -0
  12. package/dist/extensions/healthie/lib/sdk/createSdk.js.map +1 -0
  13. package/dist/extensions/healthie/lib/sdk/errors.d.ts +1 -0
  14. package/dist/extensions/healthie/lib/sdk/errors.js +42 -1
  15. package/dist/extensions/healthie/lib/sdk/errors.js.map +1 -1
  16. package/dist/extensions/healthie/lib/sdk/generated/sdk.d.ts +373 -9
  17. package/dist/extensions/healthie/lib/sdk/generated/sdk.js +110 -3
  18. package/dist/extensions/healthie/lib/sdk/generated/sdk.js.map +1 -1
  19. package/dist/extensions/healthie/lib/sdk/validatePayloadAndCreateSdk.d.ts +11 -1
  20. package/dist/extensions/healthie/lib/sdk/validatePayloadAndCreateSdk.js +15 -1
  21. package/dist/extensions/healthie/lib/sdk/validatePayloadAndCreateSdk.js.map +1 -1
  22. package/dist/extensions/healthie/lib/types.d.ts +1 -0
  23. package/dist/extensions/healthie/lib/types.js +2 -0
  24. package/dist/extensions/healthie/lib/types.js.map +1 -1
  25. package/dist/extensions/healthie/webhooks/appliedTagCreated.d.ts +2 -1
  26. package/dist/extensions/healthie/webhooks/appliedTagCreated.js +19 -7
  27. package/dist/extensions/healthie/webhooks/appliedTagCreated.js.map +1 -1
  28. package/dist/extensions/healthie/webhooks/appliedTagDeleted.d.ts +2 -1
  29. package/dist/extensions/healthie/webhooks/appliedTagDeleted.js +19 -7
  30. package/dist/extensions/healthie/webhooks/appliedTagDeleted.js.map +1 -1
  31. package/dist/extensions/healthie/webhooks/appointmentCreated.d.ts +6 -1
  32. package/dist/extensions/healthie/webhooks/appointmentCreated.js +25 -6
  33. package/dist/extensions/healthie/webhooks/appointmentCreated.js.map +1 -1
  34. package/dist/extensions/healthie/webhooks/appointmentDeleted.d.ts +2 -1
  35. package/dist/extensions/healthie/webhooks/appointmentDeleted.js +21 -6
  36. package/dist/extensions/healthie/webhooks/appointmentDeleted.js.map +1 -1
  37. package/dist/extensions/healthie/webhooks/appointmentUpdated.d.ts +6 -1
  38. package/dist/extensions/healthie/webhooks/appointmentUpdated.js +25 -6
  39. package/dist/extensions/healthie/webhooks/appointmentUpdated.js.map +1 -1
  40. package/dist/extensions/healthie/webhooks/formAnswerGroupCreated.d.ts +6 -1
  41. package/dist/extensions/healthie/webhooks/formAnswerGroupCreated.js +26 -7
  42. package/dist/extensions/healthie/webhooks/formAnswerGroupCreated.js.map +1 -1
  43. package/dist/extensions/healthie/webhooks/formAnswerGroupDeleted.d.ts +2 -1
  44. package/dist/extensions/healthie/webhooks/formAnswerGroupDeleted.js +20 -6
  45. package/dist/extensions/healthie/webhooks/formAnswerGroupDeleted.js.map +1 -1
  46. package/dist/extensions/healthie/webhooks/formAnswerGroupLocked.d.ts +6 -1
  47. package/dist/extensions/healthie/webhooks/formAnswerGroupLocked.js +25 -6
  48. package/dist/extensions/healthie/webhooks/formAnswerGroupLocked.js.map +1 -1
  49. package/dist/extensions/healthie/webhooks/formAnswerGroupSigned.d.ts +6 -1
  50. package/dist/extensions/healthie/webhooks/formAnswerGroupSigned.js +25 -6
  51. package/dist/extensions/healthie/webhooks/formAnswerGroupSigned.js.map +1 -1
  52. package/dist/extensions/healthie/webhooks/goalCreated.d.ts +3 -2
  53. package/dist/extensions/healthie/webhooks/goalCreated.js +21 -9
  54. package/dist/extensions/healthie/webhooks/goalCreated.js.map +1 -1
  55. package/dist/extensions/healthie/webhooks/goalUpdated.d.ts +2 -1
  56. package/dist/extensions/healthie/webhooks/goalUpdated.js +20 -8
  57. package/dist/extensions/healthie/webhooks/goalUpdated.js.map +1 -1
  58. package/dist/extensions/healthie/webhooks/index.d.ts +316 -5
  59. package/dist/extensions/healthie/webhooks/index.js +0 -8
  60. package/dist/extensions/healthie/webhooks/index.js.map +1 -1
  61. package/dist/extensions/healthie/webhooks/labOrderCreated.d.ts +2 -1
  62. package/dist/extensions/healthie/webhooks/labOrderCreated.js +19 -7
  63. package/dist/extensions/healthie/webhooks/labOrderCreated.js.map +1 -1
  64. package/dist/extensions/healthie/webhooks/labOrderUpdated.d.ts +2 -1
  65. package/dist/extensions/healthie/webhooks/labOrderUpdated.js +19 -7
  66. package/dist/extensions/healthie/webhooks/labOrderUpdated.js.map +1 -1
  67. package/dist/extensions/healthie/webhooks/messageCreated.d.ts +2 -1
  68. package/dist/extensions/healthie/webhooks/messageCreated.js +20 -7
  69. package/dist/extensions/healthie/webhooks/messageCreated.js.map +1 -1
  70. package/dist/extensions/healthie/webhooks/messageDeleted.d.ts +2 -1
  71. package/dist/extensions/healthie/webhooks/messageDeleted.js +20 -7
  72. package/dist/extensions/healthie/webhooks/messageDeleted.js.map +1 -1
  73. package/dist/extensions/healthie/webhooks/metricEntryCreated.d.ts +2 -1
  74. package/dist/extensions/healthie/webhooks/metricEntryCreated.js +19 -7
  75. package/dist/extensions/healthie/webhooks/metricEntryCreated.js.map +1 -1
  76. package/dist/extensions/healthie/webhooks/metricEntryUpdated.d.ts +2 -1
  77. package/dist/extensions/healthie/webhooks/metricEntryUpdated.js +19 -7
  78. package/dist/extensions/healthie/webhooks/metricEntryUpdated.js.map +1 -1
  79. package/dist/extensions/healthie/webhooks/patientCreated.js +5 -0
  80. package/dist/extensions/healthie/webhooks/patientCreated.js.map +1 -1
  81. package/dist/extensions/healthie/webhooks/patientUpdated.js +5 -0
  82. package/dist/extensions/healthie/webhooks/patientUpdated.js.map +1 -1
  83. package/dist/extensions/healthie/webhooks/requestedFormCompletionCreated.d.ts +2 -1
  84. package/dist/extensions/healthie/webhooks/requestedFormCompletionCreated.js +19 -7
  85. package/dist/extensions/healthie/webhooks/requestedFormCompletionCreated.js.map +1 -1
  86. package/dist/extensions/healthie/webhooks/requestedFormCompletionUpdated.d.ts +2 -1
  87. package/dist/extensions/healthie/webhooks/requestedFormCompletionUpdated.js +19 -7
  88. package/dist/extensions/healthie/webhooks/requestedFormCompletionUpdated.js.map +1 -1
  89. package/dist/extensions/healthie/webhooks/taskCreated.d.ts +2 -1
  90. package/dist/extensions/healthie/webhooks/taskCreated.js +19 -7
  91. package/dist/extensions/healthie/webhooks/taskCreated.js.map +1 -1
  92. package/dist/extensions/healthie/webhooks/taskUpdated.d.ts +2 -1
  93. package/dist/extensions/healthie/webhooks/taskUpdated.js +20 -8
  94. package/dist/extensions/healthie/webhooks/taskUpdated.js.map +1 -1
  95. package/dist/extensions/hello-world/webhooks/index.d.ts +1 -1
  96. package/dist/extensions/markdown.json +0 -4
  97. package/dist/extensions/zusHealth/webhooks/index.d.ts +37 -1
  98. package/dist/extensions/zusHealth/webhooks/patientAdmitted.d.ts +2 -1
  99. package/dist/extensions/zusHealth/webhooks/patientAdmitted.js.map +1 -1
  100. package/dist/extensions/zusHealth/webhooks/patientDischarged.d.ts +2 -1
  101. package/dist/extensions/zusHealth/webhooks/patientDischarged.js.map +1 -1
  102. package/dist/src/test-server.js +4 -0
  103. package/dist/src/test-server.js.map +1 -1
  104. package/package.json +6 -5
  105. package/dist/extensions/healthie/webhooks/goalDeleted.d.ts +0 -11
  106. package/dist/extensions/healthie/webhooks/goalDeleted.js +0 -30
  107. package/dist/extensions/healthie/webhooks/goalDeleted.js.map +0 -1
  108. package/dist/extensions/healthie/webhooks/metricEntryDeleted.d.ts +0 -11
  109. package/dist/extensions/healthie/webhooks/metricEntryDeleted.js +0 -30
  110. package/dist/extensions/healthie/webhooks/metricEntryDeleted.js.map +0 -1
  111. package/dist/extensions/healthie/webhooks/requestedFormCompletionDeleted.d.ts +0 -11
  112. package/dist/extensions/healthie/webhooks/requestedFormCompletionDeleted.js +0 -30
  113. package/dist/extensions/healthie/webhooks/requestedFormCompletionDeleted.js.map +0 -1
  114. package/dist/extensions/healthie/webhooks/taskDeleted.d.ts +0 -11
  115. package/dist/extensions/healthie/webhooks/taskDeleted.js +0 -30
  116. package/dist/extensions/healthie/webhooks/taskDeleted.js.map +0 -1
  117. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/checkFlourishCustomer.d.ts +0 -11
  118. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/checkFlourishCustomer.js +0 -39
  119. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/checkFlourishCustomer.js.map +0 -1
  120. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/checkFlourishCustomer.test.d.ts +0 -1
  121. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/checkFlourishCustomer.test.js +0 -85
  122. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/checkFlourishCustomer.test.js.map +0 -1
  123. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/config/fields.d.ts +0 -18
  124. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/config/fields.js +0 -18
  125. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/config/fields.js.map +0 -1
  126. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/config/index.d.ts +0 -2
  127. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/config/index.js +0 -9
  128. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/config/index.js.map +0 -1
  129. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/config/settings.d.ts +0 -35
  130. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/config/settings.js +0 -17
  131. package/dist/extensions/wellinks-public/actions/checkFlourishCustomer/config/settings.js.map +0 -1
  132. package/dist/extensions/wellinks-public/actions/checkForChat/checkForChat.d.ts +0 -33
  133. package/dist/extensions/wellinks-public/actions/checkForChat/checkForChat.js +0 -129
  134. package/dist/extensions/wellinks-public/actions/checkForChat/checkForChat.js.map +0 -1
  135. package/dist/extensions/wellinks-public/actions/checkForChat/checkForChat.test.d.ts +0 -1
  136. package/dist/extensions/wellinks-public/actions/checkForChat/checkForChat.test.js +0 -154
  137. package/dist/extensions/wellinks-public/actions/checkForChat/checkForChat.test.js.map +0 -1
  138. package/dist/extensions/wellinks-public/actions/checkForCheckInOverride/checkForCheckInOverride.d.ts +0 -26
  139. package/dist/extensions/wellinks-public/actions/checkForCheckInOverride/checkForCheckInOverride.js +0 -139
  140. package/dist/extensions/wellinks-public/actions/checkForCheckInOverride/checkForCheckInOverride.js.map +0 -1
  141. package/dist/extensions/wellinks-public/actions/checkForCheckInOverride/checkForCheckInOverride.test.d.ts +0 -1
  142. package/dist/extensions/wellinks-public/actions/checkForCheckInOverride/checkForCheckInOverride.test.js +0 -185
  143. package/dist/extensions/wellinks-public/actions/checkForCheckInOverride/checkForCheckInOverride.test.js.map +0 -1
  144. package/dist/extensions/wellinks-public/actions/checkForOverride/checkForOverride.d.ts +0 -23
  145. package/dist/extensions/wellinks-public/actions/checkForOverride/checkForOverride.js +0 -153
  146. package/dist/extensions/wellinks-public/actions/checkForOverride/checkForOverride.js.map +0 -1
  147. package/dist/extensions/wellinks-public/actions/checkForOverride/checkForOverride.test.d.ts +0 -1
  148. package/dist/extensions/wellinks-public/actions/checkForOverride/checkForOverride.test.js +0 -184
  149. package/dist/extensions/wellinks-public/actions/checkForOverride/checkForOverride.test.js.map +0 -1
  150. package/dist/extensions/wellinks-public/actions/checkForScheduledAppointment/checkForScheduledAppointment.d.ts +0 -26
  151. package/dist/extensions/wellinks-public/actions/checkForScheduledAppointment/checkForScheduledAppointment.js +0 -118
  152. package/dist/extensions/wellinks-public/actions/checkForScheduledAppointment/checkForScheduledAppointment.js.map +0 -1
  153. package/dist/extensions/wellinks-public/actions/checkForScheduledAppointment/checkForScheduledAppointment.test.d.ts +0 -1
  154. package/dist/extensions/wellinks-public/actions/checkForScheduledAppointment/checkForScheduledAppointment.test.js +0 -119
  155. package/dist/extensions/wellinks-public/actions/checkForScheduledAppointment/checkForScheduledAppointment.test.js.map +0 -1
  156. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/config/fields.d.ts +0 -82
  157. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/config/fields.js +0 -78
  158. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/config/fields.js.map +0 -1
  159. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/config/index.d.ts +0 -1
  160. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/config/index.js +0 -6
  161. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/config/index.js.map +0 -1
  162. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/createChartingNoteAdvanced-fail.test.d.ts +0 -1
  163. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/createChartingNoteAdvanced-fail.test.js +0 -152
  164. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/createChartingNoteAdvanced-fail.test.js.map +0 -1
  165. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/createChartingNoteAdvanced.d.ts +0 -4
  166. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/createChartingNoteAdvanced.js +0 -86
  167. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/createChartingNoteAdvanced.js.map +0 -1
  168. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/createChartingNoteAdvanced.test.d.ts +0 -1
  169. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/createChartingNoteAdvanced.test.js +0 -42
  170. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/createChartingNoteAdvanced.test.js.map +0 -1
  171. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/index.d.ts +0 -1
  172. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/index.js +0 -6
  173. package/dist/extensions/wellinks-public/actions/createChartingNoteAdvanced/index.js.map +0 -1
  174. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/config/fields.d.ts +0 -58
  175. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/config/fields.js +0 -56
  176. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/config/fields.js.map +0 -1
  177. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/config/index.d.ts +0 -2
  178. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/config/index.js +0 -9
  179. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/config/index.js.map +0 -1
  180. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/config/settings.d.ts +0 -35
  181. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/config/settings.js +0 -17
  182. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/config/settings.js.map +0 -1
  183. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/createFlourishCustomer.d.ts +0 -11
  184. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/createFlourishCustomer.js +0 -56
  185. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/createFlourishCustomer.js.map +0 -1
  186. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/createFlourishCustomer.test.d.ts +0 -1
  187. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/createFlourishCustomer.test.js +0 -53
  188. package/dist/extensions/wellinks-public/actions/createFlourishCustomer/createFlourishCustomer.test.js.map +0 -1
  189. package/dist/extensions/wellinks-public/actions/index.d.ts +0 -967
  190. package/dist/extensions/wellinks-public/actions/index.js +0 -24
  191. package/dist/extensions/wellinks-public/actions/index.js.map +0 -1
  192. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/config/fields.d.ts +0 -78
  193. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/config/fields.js +0 -66
  194. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/config/fields.js.map +0 -1
  195. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/config/index.d.ts +0 -2
  196. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/config/index.js +0 -9
  197. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/config/index.js.map +0 -1
  198. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/config/settings.d.ts +0 -38
  199. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/config/settings.js +0 -11
  200. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/config/settings.js.map +0 -1
  201. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/insertMemberListEvent.d.ts +0 -11
  202. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/insertMemberListEvent.js +0 -75
  203. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/insertMemberListEvent.js.map +0 -1
  204. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/insertMemberListEvent.test.d.ts +0 -1
  205. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/insertMemberListEvent.test.js +0 -133
  206. package/dist/extensions/wellinks-public/actions/insertMemberListEvent/insertMemberListEvent.test.js.map +0 -1
  207. package/dist/extensions/wellinks-public/actions/submitPamSurvey/config/fields.d.ts +0 -188
  208. package/dist/extensions/wellinks-public/actions/submitPamSurvey/config/fields.js +0 -160
  209. package/dist/extensions/wellinks-public/actions/submitPamSurvey/config/fields.js.map +0 -1
  210. package/dist/extensions/wellinks-public/actions/submitPamSurvey/config/index.d.ts +0 -2
  211. package/dist/extensions/wellinks-public/actions/submitPamSurvey/config/index.js +0 -9
  212. package/dist/extensions/wellinks-public/actions/submitPamSurvey/config/index.js.map +0 -1
  213. package/dist/extensions/wellinks-public/actions/submitPamSurvey/config/settings.d.ts +0 -35
  214. package/dist/extensions/wellinks-public/actions/submitPamSurvey/config/settings.js +0 -17
  215. package/dist/extensions/wellinks-public/actions/submitPamSurvey/config/settings.js.map +0 -1
  216. package/dist/extensions/wellinks-public/actions/submitPamSurvey/submitPamSurvey.d.ts +0 -19
  217. package/dist/extensions/wellinks-public/actions/submitPamSurvey/submitPamSurvey.js +0 -66
  218. package/dist/extensions/wellinks-public/actions/submitPamSurvey/submitPamSurvey.js.map +0 -1
  219. package/dist/extensions/wellinks-public/actions/submitPamSurvey/submitPamSurvey.test.d.ts +0 -1
  220. package/dist/extensions/wellinks-public/actions/submitPamSurvey/submitPamSurvey.test.js +0 -125
  221. package/dist/extensions/wellinks-public/actions/submitPamSurvey/submitPamSurvey.test.js.map +0 -1
  222. package/dist/extensions/wellinks-public/api/clients/wellinksClient.d.ts +0 -16
  223. package/dist/extensions/wellinks-public/api/clients/wellinksClient.js +0 -40
  224. package/dist/extensions/wellinks-public/api/clients/wellinksClient.js.map +0 -1
  225. package/dist/extensions/wellinks-public/api/clients/wellinksFlourishClient.d.ts +0 -14
  226. package/dist/extensions/wellinks-public/api/clients/wellinksFlourishClient.js +0 -201
  227. package/dist/extensions/wellinks-public/api/clients/wellinksFlourishClient.js.map +0 -1
  228. package/dist/extensions/wellinks-public/api/clients/wellinksGraphqlClient.d.ts +0 -3
  229. package/dist/extensions/wellinks-public/api/clients/wellinksGraphqlClient.js +0 -23
  230. package/dist/extensions/wellinks-public/api/clients/wellinksGraphqlClient.js.map +0 -1
  231. package/dist/extensions/wellinks-public/api/test/wellinksFlourishClient.test.d.ts +0 -1
  232. package/dist/extensions/wellinks-public/api/test/wellinksFlourishClient.test.js +0 -192
  233. package/dist/extensions/wellinks-public/api/test/wellinksFlourishClient.test.js.map +0 -1
  234. package/dist/extensions/wellinks-public/codegen.d.ts +0 -3
  235. package/dist/extensions/wellinks-public/codegen.js +0 -21
  236. package/dist/extensions/wellinks-public/codegen.js.map +0 -1
  237. package/dist/extensions/wellinks-public/config/settings.d.ts +0 -107
  238. package/dist/extensions/wellinks-public/config/settings.js +0 -89
  239. package/dist/extensions/wellinks-public/config/settings.js.map +0 -1
  240. package/dist/extensions/wellinks-public/config/types.d.ts +0 -5
  241. package/dist/extensions/wellinks-public/config/types.js +0 -3
  242. package/dist/extensions/wellinks-public/config/types.js.map +0 -1
  243. package/dist/extensions/wellinks-public/gql/wellinksSdk.d.ts +0 -24110
  244. package/dist/extensions/wellinks-public/gql/wellinksSdk.js +0 -635
  245. package/dist/extensions/wellinks-public/gql/wellinksSdk.js.map +0 -1
  246. package/dist/extensions/wellinks-public/graphql/mutations.d.ts +0 -1
  247. package/dist/extensions/wellinks-public/graphql/mutations.js +0 -17
  248. package/dist/extensions/wellinks-public/graphql/mutations.js.map +0 -1
  249. package/dist/extensions/wellinks-public/graphql/queries.d.ts +0 -5
  250. package/dist/extensions/wellinks-public/graphql/queries.js +0 -66
  251. package/dist/extensions/wellinks-public/graphql/queries.js.map +0 -1
  252. package/dist/extensions/wellinks-public/index.d.ts +0 -2
  253. package/dist/extensions/wellinks-public/index.js +0 -20
  254. package/dist/extensions/wellinks-public/index.js.map +0 -1
@@ -13,16 +13,327 @@ export type { LabOrderUpdated } from './labOrderUpdated';
13
13
  export type { MessageCreated } from './messageCreated';
14
14
  export type { MessageDeleted } from './messageDeleted';
15
15
  export type { MetricEntryCreated } from './metricEntryCreated';
16
- export type { MetricEntryDeleted } from './metricEntryDeleted';
17
16
  export type { MetricEntryUpdated } from './metricEntryUpdated';
18
17
  export type { PatientUpdated } from './patientUpdated';
19
18
  export type { RequestFormCompletionCreated } from './requestedFormCompletionCreated';
20
- export type { RequestFormCompletionDeleted } from './requestedFormCompletionDeleted';
21
19
  export type { RequestFormCompletionUpdated } from './requestedFormCompletionUpdated';
22
20
  export type { TaskCreated } from './taskCreated';
23
- export type { TaskDeleted } from './taskDeleted';
24
21
  export type { TaskUpdated } from './taskUpdated';
25
22
  export type { GoalCreated } from './goalCreated';
26
23
  export type { GoalUpdated } from './goalUpdated';
27
- export type { GoalDeleted } from './goalDeleted';
28
- export declare const webhooks: (import("@awell-health/extensions-core").Webhook<"appointmentId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"patientId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"createdAppliedTagId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"deletedAppliedTagId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"deletedAppointmentId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"updatedAppointmentId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"createdFormAnswerGroupId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"deletedFormAnswerGroupId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"lockedFormAnswerGroupId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"signedFormAnswerGroupId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"createdLabOrderId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"updatedLabOrderId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"createdMessageId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"deletedMessageId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"createdMetricId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"deletedMetricId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"updatedMetricId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"updatedPatientId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"createdFormCompletionId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"deletedFormCompletionId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"updatedFormCompletionId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"createdTaskId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"deletedTaskId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"updatedTaskId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"createdGoalId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"updatedGoalId", import("../lib/types").HealthieWebhookPayload> | import("@awell-health/extensions-core").Webhook<"deletedGoalId", import("../lib/types").HealthieWebhookPayload>)[];
24
+ export declare const webhooks: (import("@awell-health/extensions-core").Webhook<"appointmentId" | "appointment", import("../lib/types").HealthieWebhookPayload, {
25
+ apiUrl: {
26
+ key: string;
27
+ label: string;
28
+ obfuscated: false;
29
+ required: true;
30
+ description: string;
31
+ };
32
+ apiKey: {
33
+ key: string;
34
+ label: string;
35
+ obfuscated: true;
36
+ required: true;
37
+ description: string;
38
+ };
39
+ }> | import("@awell-health/extensions-core").Webhook<"patientId", import("../lib/types").HealthieWebhookPayload, Record<string, import("@awell-health/extensions-core").Setting>> | import("@awell-health/extensions-core").Webhook<"createdAppliedTagId", import("../lib/types").HealthieWebhookPayload, {
40
+ apiUrl: {
41
+ key: string;
42
+ label: string;
43
+ obfuscated: false;
44
+ required: true;
45
+ description: string;
46
+ };
47
+ apiKey: {
48
+ key: string;
49
+ label: string;
50
+ obfuscated: true;
51
+ required: true;
52
+ description: string;
53
+ };
54
+ }> | import("@awell-health/extensions-core").Webhook<"deletedAppliedTagId", import("../lib/types").HealthieWebhookPayload, {
55
+ apiUrl: {
56
+ key: string;
57
+ label: string;
58
+ obfuscated: false;
59
+ required: true;
60
+ description: string;
61
+ };
62
+ apiKey: {
63
+ key: string;
64
+ label: string;
65
+ obfuscated: true;
66
+ required: true;
67
+ description: string;
68
+ };
69
+ }> | import("@awell-health/extensions-core").Webhook<"deletedAppointmentId", import("../lib/types").HealthieWebhookPayload, {
70
+ apiUrl: {
71
+ key: string;
72
+ label: string;
73
+ obfuscated: false;
74
+ required: true;
75
+ description: string;
76
+ };
77
+ apiKey: {
78
+ key: string;
79
+ label: string;
80
+ obfuscated: true;
81
+ required: true;
82
+ description: string;
83
+ };
84
+ }> | import("@awell-health/extensions-core").Webhook<"appointment" | "updatedAppointmentId", import("../lib/types").HealthieWebhookPayload, {
85
+ apiUrl: {
86
+ key: string;
87
+ label: string;
88
+ obfuscated: false;
89
+ required: true;
90
+ description: string;
91
+ };
92
+ apiKey: {
93
+ key: string;
94
+ label: string;
95
+ obfuscated: true;
96
+ required: true;
97
+ description: string;
98
+ };
99
+ }> | import("@awell-health/extensions-core").Webhook<"createdFormAnswerGroupId" | "createdFormAnswerGroup", import("../lib/types").HealthieWebhookPayload, {
100
+ apiUrl: {
101
+ key: string;
102
+ label: string;
103
+ obfuscated: false;
104
+ required: true;
105
+ description: string;
106
+ };
107
+ apiKey: {
108
+ key: string;
109
+ label: string;
110
+ obfuscated: true;
111
+ required: true;
112
+ description: string;
113
+ };
114
+ }> | import("@awell-health/extensions-core").Webhook<"deletedFormAnswerGroupId", import("../lib/types").HealthieWebhookPayload, {
115
+ apiUrl: {
116
+ key: string;
117
+ label: string;
118
+ obfuscated: false;
119
+ required: true;
120
+ description: string;
121
+ };
122
+ apiKey: {
123
+ key: string;
124
+ label: string;
125
+ obfuscated: true;
126
+ required: true;
127
+ description: string;
128
+ };
129
+ }> | import("@awell-health/extensions-core").Webhook<"lockedFormAnswerGroupId" | "lockedFormAnswerGroup", import("../lib/types").HealthieWebhookPayload, {
130
+ apiUrl: {
131
+ key: string;
132
+ label: string;
133
+ obfuscated: false;
134
+ required: true;
135
+ description: string;
136
+ };
137
+ apiKey: {
138
+ key: string;
139
+ label: string;
140
+ obfuscated: true;
141
+ required: true;
142
+ description: string;
143
+ };
144
+ }> | import("@awell-health/extensions-core").Webhook<"signedFormAnswerGroupId" | "signedFormAnswerGroup", import("../lib/types").HealthieWebhookPayload, {
145
+ apiUrl: {
146
+ key: string;
147
+ label: string;
148
+ obfuscated: false;
149
+ required: true;
150
+ description: string;
151
+ };
152
+ apiKey: {
153
+ key: string;
154
+ label: string;
155
+ obfuscated: true;
156
+ required: true;
157
+ description: string;
158
+ };
159
+ }> | import("@awell-health/extensions-core").Webhook<"createdLabOrderId", import("../lib/types").HealthieWebhookPayload, {
160
+ apiUrl: {
161
+ key: string;
162
+ label: string;
163
+ obfuscated: false;
164
+ required: true;
165
+ description: string;
166
+ };
167
+ apiKey: {
168
+ key: string;
169
+ label: string;
170
+ obfuscated: true;
171
+ required: true;
172
+ description: string;
173
+ };
174
+ }> | import("@awell-health/extensions-core").Webhook<"updatedLabOrderId", import("../lib/types").HealthieWebhookPayload, {
175
+ apiUrl: {
176
+ key: string;
177
+ label: string;
178
+ obfuscated: false;
179
+ required: true;
180
+ description: string;
181
+ };
182
+ apiKey: {
183
+ key: string;
184
+ label: string;
185
+ obfuscated: true;
186
+ required: true;
187
+ description: string;
188
+ };
189
+ }> | import("@awell-health/extensions-core").Webhook<"createdMessageId", import("../lib/types").HealthieWebhookPayload, {
190
+ apiUrl: {
191
+ key: string;
192
+ label: string;
193
+ obfuscated: false;
194
+ required: true;
195
+ description: string;
196
+ };
197
+ apiKey: {
198
+ key: string;
199
+ label: string;
200
+ obfuscated: true;
201
+ required: true;
202
+ description: string;
203
+ };
204
+ }> | import("@awell-health/extensions-core").Webhook<"deletedMessageId", import("../lib/types").HealthieWebhookPayload, {
205
+ apiUrl: {
206
+ key: string;
207
+ label: string;
208
+ obfuscated: false;
209
+ required: true;
210
+ description: string;
211
+ };
212
+ apiKey: {
213
+ key: string;
214
+ label: string;
215
+ obfuscated: true;
216
+ required: true;
217
+ description: string;
218
+ };
219
+ }> | import("@awell-health/extensions-core").Webhook<"createdMetricId", import("../lib/types").HealthieWebhookPayload, {
220
+ apiUrl: {
221
+ key: string;
222
+ label: string;
223
+ obfuscated: false;
224
+ required: true;
225
+ description: string;
226
+ };
227
+ apiKey: {
228
+ key: string;
229
+ label: string;
230
+ obfuscated: true;
231
+ required: true;
232
+ description: string;
233
+ };
234
+ }> | import("@awell-health/extensions-core").Webhook<"updatedMetricId", import("../lib/types").HealthieWebhookPayload, {
235
+ apiUrl: {
236
+ key: string;
237
+ label: string;
238
+ obfuscated: false;
239
+ required: true;
240
+ description: string;
241
+ };
242
+ apiKey: {
243
+ key: string;
244
+ label: string;
245
+ obfuscated: true;
246
+ required: true;
247
+ description: string;
248
+ };
249
+ }> | import("@awell-health/extensions-core").Webhook<"updatedPatientId", import("../lib/types").HealthieWebhookPayload, Record<string, import("@awell-health/extensions-core").Setting>> | import("@awell-health/extensions-core").Webhook<"createdFormCompletionId", import("../lib/types").HealthieWebhookPayload, {
250
+ apiUrl: {
251
+ key: string;
252
+ label: string;
253
+ obfuscated: false;
254
+ required: true;
255
+ description: string;
256
+ };
257
+ apiKey: {
258
+ key: string;
259
+ label: string;
260
+ obfuscated: true;
261
+ required: true;
262
+ description: string;
263
+ };
264
+ }> | import("@awell-health/extensions-core").Webhook<"updatedFormCompletionId", import("../lib/types").HealthieWebhookPayload, {
265
+ apiUrl: {
266
+ key: string;
267
+ label: string;
268
+ obfuscated: false;
269
+ required: true;
270
+ description: string;
271
+ };
272
+ apiKey: {
273
+ key: string;
274
+ label: string;
275
+ obfuscated: true;
276
+ required: true;
277
+ description: string;
278
+ };
279
+ }> | import("@awell-health/extensions-core").Webhook<"createdTaskId", import("../lib/types").HealthieWebhookPayload, {
280
+ apiUrl: {
281
+ key: string;
282
+ label: string;
283
+ obfuscated: false;
284
+ required: true;
285
+ description: string;
286
+ };
287
+ apiKey: {
288
+ key: string;
289
+ label: string;
290
+ obfuscated: true;
291
+ required: true;
292
+ description: string;
293
+ };
294
+ }> | import("@awell-health/extensions-core").Webhook<"updatedTaskId", import("../lib/types").HealthieWebhookPayload, {
295
+ apiUrl: {
296
+ key: string;
297
+ label: string;
298
+ obfuscated: false;
299
+ required: true;
300
+ description: string;
301
+ };
302
+ apiKey: {
303
+ key: string;
304
+ label: string;
305
+ obfuscated: true;
306
+ required: true;
307
+ description: string;
308
+ };
309
+ }> | import("@awell-health/extensions-core").Webhook<"createdGoalId", import("../lib/types").HealthieWebhookPayload, {
310
+ apiUrl: {
311
+ key: string;
312
+ label: string;
313
+ obfuscated: false;
314
+ required: true;
315
+ description: string;
316
+ };
317
+ apiKey: {
318
+ key: string;
319
+ label: string;
320
+ obfuscated: true;
321
+ required: true;
322
+ description: string;
323
+ };
324
+ }> | import("@awell-health/extensions-core").Webhook<"updatedGoalId", import("../lib/types").HealthieWebhookPayload, {
325
+ apiUrl: {
326
+ key: string;
327
+ label: string;
328
+ obfuscated: false;
329
+ required: true;
330
+ description: string;
331
+ };
332
+ apiKey: {
333
+ key: string;
334
+ label: string;
335
+ obfuscated: true;
336
+ required: true;
337
+ description: string;
338
+ };
339
+ }>)[];
@@ -16,18 +16,14 @@ const labOrderUpdated_1 = require("./labOrderUpdated");
16
16
  const messageCreated_1 = require("./messageCreated");
17
17
  const messageDeleted_1 = require("./messageDeleted");
18
18
  const metricEntryCreated_1 = require("./metricEntryCreated");
19
- const metricEntryDeleted_1 = require("./metricEntryDeleted");
20
19
  const metricEntryUpdated_1 = require("./metricEntryUpdated");
21
20
  const patientUpdated_1 = require("./patientUpdated");
22
21
  const requestedFormCompletionCreated_1 = require("./requestedFormCompletionCreated");
23
- const requestedFormCompletionDeleted_1 = require("./requestedFormCompletionDeleted");
24
22
  const requestedFormCompletionUpdated_1 = require("./requestedFormCompletionUpdated");
25
23
  const taskCreated_1 = require("./taskCreated");
26
- const taskDeleted_1 = require("./taskDeleted");
27
24
  const taskUpdated_1 = require("./taskUpdated");
28
25
  const goalCreated_1 = require("./goalCreated");
29
26
  const goalUpdated_1 = require("./goalUpdated");
30
- const goalDeleted_1 = require("./goalDeleted");
31
27
  exports.webhooks = [
32
28
  appointmentCreated_1.appointmentCreated,
33
29
  patientCreated_1.patientCreated,
@@ -44,17 +40,13 @@ exports.webhooks = [
44
40
  messageCreated_1.messageCreated,
45
41
  messageDeleted_1.messageDeleted,
46
42
  metricEntryCreated_1.metricEntryCreated,
47
- metricEntryDeleted_1.metricEntryDeleted,
48
43
  metricEntryUpdated_1.metricEntryUpdated,
49
44
  patientUpdated_1.patientUpdated,
50
45
  requestedFormCompletionCreated_1.requestFormCompletionCreated,
51
- requestedFormCompletionDeleted_1.requestFormCompletionDeleted,
52
46
  requestedFormCompletionUpdated_1.requestFormCompletionUpdated,
53
47
  taskCreated_1.taskCreated,
54
- taskDeleted_1.taskDeleted,
55
48
  taskUpdated_1.taskUpdated,
56
49
  goalCreated_1.goalCreated,
57
50
  goalUpdated_1.goalUpdated,
58
- goalDeleted_1.goalDeleted,
59
51
  ];
60
52
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../extensions/healthie/webhooks/index.ts"],"names":[],"mappings":";;;AAAA,6DAAyD;AACzD,qDAAiD;AACjD,2DAAuD;AACvD,2DAAuD;AACvD,6DAAyD;AACzD,6DAAyD;AACzD,qEAAiE;AACjE,qEAAiE;AACjE,mEAA+D;AAC/D,mEAA+D;AAC/D,uDAAmD;AACnD,uDAAmD;AACnD,qDAAiD;AACjD,qDAAiD;AACjD,6DAAyD;AACzD,6DAAyD;AACzD,6DAAyD;AACzD,qDAAiD;AACjD,qFAA+E;AAC/E,qFAA+E;AAC/E,qFAA+E;AAC/E,+CAA2C;AAC3C,+CAA2C;AAC3C,+CAA2C;AAC3C,+CAA2C;AAC3C,+CAA2C;AAC3C,+CAA2C;AA8B9B,QAAA,QAAQ,GAAG;IACtB,uCAAkB;IAClB,+BAAc;IACd,qCAAiB;IACjB,qCAAiB;IACjB,uCAAkB;IAClB,uCAAkB;IAClB,+CAAsB;IACtB,+CAAsB;IACtB,6CAAqB;IACrB,6CAAqB;IACrB,iCAAe;IACf,iCAAe;IACf,+BAAc;IACd,+BAAc;IACd,uCAAkB;IAClB,uCAAkB;IAClB,uCAAkB;IAClB,+BAAc;IACd,6DAA4B;IAC5B,6DAA4B;IAC5B,6DAA4B;IAC5B,yBAAW;IACX,yBAAW;IACX,yBAAW;IACX,yBAAW;IACX,yBAAW;IACX,yBAAW;CACZ,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../extensions/healthie/webhooks/index.ts"],"names":[],"mappings":";;;AAAA,6DAAyD;AACzD,qDAAiD;AACjD,2DAAuD;AACvD,2DAAuD;AACvD,6DAAyD;AACzD,6DAAyD;AACzD,qEAAiE;AACjE,qEAAiE;AACjE,mEAA+D;AAC/D,mEAA+D;AAC/D,uDAAmD;AACnD,uDAAmD;AACnD,qDAAiD;AACjD,qDAAiD;AACjD,6DAAyD;AACzD,6DAAyD;AACzD,qDAAiD;AACjD,qFAA+E;AAC/E,qFAA+E;AAC/E,+CAA2C;AAC3C,+CAA2C;AAC3C,+CAA2C;AAC3C,+CAA2C;AA0B9B,QAAA,QAAQ,GAAG;IACtB,uCAAkB;IAClB,+BAAc;IACd,qCAAiB;IACjB,qCAAiB;IACjB,uCAAkB;IAClB,uCAAkB;IAClB,+CAAsB;IACtB,+CAAsB;IACtB,6CAAqB;IACrB,6CAAqB;IACrB,iCAAe;IACf,iCAAe;IACf,+BAAc;IACd,+BAAc;IACd,uCAAkB;IAClB,uCAAkB;IAClB,+BAAc;IACd,6DAA4B;IAC5B,6DAA4B;IAC5B,yBAAW;IACX,yBAAW;IACX,yBAAW;IACX,yBAAW;CACZ,CAAA"}
@@ -1,11 +1,12 @@
1
1
  import { type Webhook } from '@awell-health/extensions-core';
2
2
  import { type HealthieWebhookPayload } from '../lib/types';
3
+ import { type settings } from '../settings';
3
4
  declare const dataPoints: {
4
5
  createdLabOrderId: {
5
6
  key: string;
6
7
  valueType: "string";
7
8
  };
8
9
  };
9
- export declare const labOrderCreated: Webhook<keyof typeof dataPoints, HealthieWebhookPayload>;
10
+ export declare const labOrderCreated: Webhook<keyof typeof dataPoints, HealthieWebhookPayload, typeof settings>;
10
11
  export type LabOrderCreated = typeof labOrderCreated;
11
12
  export {};
@@ -2,6 +2,9 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.labOrderCreated = void 0;
4
4
  const lodash_1 = require("lodash");
5
+ const types_1 = require("../lib/types");
6
+ const errors_1 = require("../lib/sdk/errors");
7
+ const createSdk_1 = require("../lib/sdk/createSdk");
5
8
  const dataPoints = {
6
9
  createdLabOrderId: {
7
10
  key: 'createdLabOrderId',
@@ -12,19 +15,28 @@ exports.labOrderCreated = {
12
15
  key: 'labOrderCreated',
13
16
  dataPoints,
14
17
  onWebhookReceived: async ({ payload, settings }, onSuccess, onError) => {
15
- const { resource_id: createdLabOrderId } = payload;
16
- if ((0, lodash_1.isNil)(createdLabOrderId)) {
17
- await onError({
18
- // We should automatically send a 400 here, so no need to provide info
19
- });
20
- }
21
- else {
18
+ var _a, _b, _c;
19
+ try {
20
+ const { sdk } = await (0, createSdk_1.createSdk)({ settings });
21
+ const createdLabOrderId = payload.resource_id.toString();
22
+ const response = await sdk.getLabOrder({ id: createdLabOrderId });
23
+ const healthiePatientId = (_c = (_b = (_a = response === null || response === void 0 ? void 0 : response.data) === null || _a === void 0 ? void 0 : _a.labOrder) === null || _b === void 0 ? void 0 : _b.patient) === null || _c === void 0 ? void 0 : _c.id;
22
24
  await onSuccess({
23
25
  data_points: {
24
26
  createdLabOrderId,
25
27
  },
28
+ ...(!(0, lodash_1.isNil)(healthiePatientId) && {
29
+ patient_identifier: {
30
+ system: types_1.HEALTHIE_IDENTIFIER,
31
+ value: healthiePatientId,
32
+ },
33
+ }),
26
34
  });
27
35
  }
36
+ catch (error) {
37
+ const formattedError = (0, errors_1.formatErrors)(error);
38
+ await onError(formattedError);
39
+ }
28
40
  },
29
41
  };
30
42
  //# sourceMappingURL=labOrderCreated.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"labOrderCreated.js","sourceRoot":"","sources":["../../../../extensions/healthie/webhooks/labOrderCreated.ts"],"names":[],"mappings":";;;AAAA,mCAA8B;AAO9B,MAAM,UAAU,GAAG;IACjB,iBAAiB,EAAE;QACjB,GAAG,EAAE,mBAAmB;QACxB,SAAS,EAAE,QAAQ;KACpB;CAC4C,CAAA;AAElC,QAAA,eAAe,GAGxB;IACF,GAAG,EAAE,iBAAiB;IACtB,UAAU;IACV,iBAAiB,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE;QACrE,MAAM,EAAE,WAAW,EAAE,iBAAiB,EAAE,GAAG,OAAO,CAAA;QAElD,IAAI,IAAA,cAAK,EAAC,iBAAiB,CAAC,EAAE;YAC5B,MAAM,OAAO,CAAC;YACZ,sEAAsE;aACvE,CAAC,CAAA;SACH;aAAM;YACL,MAAM,SAAS,CAAC;gBACd,WAAW,EAAE;oBACX,iBAAiB;iBAClB;aACF,CAAC,CAAA;SACH;IACH,CAAC;CACF,CAAA"}
1
+ {"version":3,"file":"labOrderCreated.js","sourceRoot":"","sources":["../../../../extensions/healthie/webhooks/labOrderCreated.ts"],"names":[],"mappings":";;;AAAA,mCAA8B;AAK9B,wCAA+E;AAE/E,8CAAgD;AAChD,oDAAgD;AAEhD,MAAM,UAAU,GAAG;IACjB,iBAAiB,EAAE;QACjB,GAAG,EAAE,mBAAmB;QACxB,SAAS,EAAE,QAAQ;KACpB;CAC4C,CAAA;AAElC,QAAA,eAAe,GAIxB;IACF,GAAG,EAAE,iBAAiB;IACtB,UAAU;IACV,iBAAiB,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE;;QACrE,IAAI;YACF,MAAM,EAAE,GAAG,EAAE,GAAG,MAAM,IAAA,qBAAS,EAAC,EAAC,QAAQ,EAAC,CAAC,CAAA;YAC3C,MAAM,iBAAiB,GAAG,OAAO,CAAC,WAAW,CAAC,QAAQ,EAAE,CAAA;YAExD,MAAM,QAAQ,GAAG,MAAM,GAAG,CAAC,WAAW,CAAC,EAAE,EAAE,EAAE,iBAAiB,EAAE,CAAC,CAAA;YACjE,MAAM,iBAAiB,GAAG,MAAA,MAAA,MAAA,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,IAAI,0CAAE,QAAQ,0CAAE,OAAO,0CAAE,EAAE,CAAA;YAC/D,MAAM,SAAS,CAAC;gBACd,WAAW,EAAE;oBACX,iBAAiB;iBAClB;gBACD,GAAG,CAAC,CAAC,IAAA,cAAK,EAAC,iBAAiB,CAAC,IAAI;oBAC/B,kBAAkB,EAAE;wBAClB,MAAM,EAAE,2BAAmB;wBAC3B,KAAK,EAAE,iBAAiB;qBACzB;iBACF,CAAC;aACH,CAAC,CAAA;SACH;QAAC,OAAO,KAAK,EAAE;YACd,MAAM,cAAc,GAAG,IAAA,qBAAY,EAAC,KAAK,CAAC,CAAA;YAC1C,MAAM,OAAO,CAAC,cAAc,CAAC,CAAA;SAC9B;IACH,CAAC;CACF,CAAA"}
@@ -1,11 +1,12 @@
1
1
  import { type Webhook } from '@awell-health/extensions-core';
2
2
  import { type HealthieWebhookPayload } from '../lib/types';
3
+ import { type settings } from '../settings';
3
4
  declare const dataPoints: {
4
5
  updatedLabOrderId: {
5
6
  key: string;
6
7
  valueType: "string";
7
8
  };
8
9
  };
9
- export declare const labOrderUpdated: Webhook<keyof typeof dataPoints, HealthieWebhookPayload>;
10
+ export declare const labOrderUpdated: Webhook<keyof typeof dataPoints, HealthieWebhookPayload, typeof settings>;
10
11
  export type LabOrderUpdated = typeof labOrderUpdated;
11
12
  export {};
@@ -2,6 +2,9 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.labOrderUpdated = void 0;
4
4
  const lodash_1 = require("lodash");
5
+ const types_1 = require("../lib/types");
6
+ const errors_1 = require("../lib/sdk/errors");
7
+ const createSdk_1 = require("../lib/sdk/createSdk");
5
8
  const dataPoints = {
6
9
  updatedLabOrderId: {
7
10
  key: 'updatedLabOrderId',
@@ -12,19 +15,28 @@ exports.labOrderUpdated = {
12
15
  key: 'labOrderUpdated',
13
16
  dataPoints,
14
17
  onWebhookReceived: async ({ payload, settings }, onSuccess, onError) => {
15
- const { resource_id: updatedLabOrderId } = payload;
16
- if ((0, lodash_1.isNil)(updatedLabOrderId)) {
17
- await onError({
18
- // We should automatically send a 400 here, so no need to provide info
19
- });
20
- }
21
- else {
18
+ var _a, _b, _c;
19
+ try {
20
+ const { sdk } = await (0, createSdk_1.createSdk)({ settings });
21
+ const updatedLabOrderId = payload.resource_id.toString();
22
+ const response = await sdk.getLabOrder({ id: updatedLabOrderId });
23
+ const healthiePatientId = (_c = (_b = (_a = response === null || response === void 0 ? void 0 : response.data) === null || _a === void 0 ? void 0 : _a.labOrder) === null || _b === void 0 ? void 0 : _b.patient) === null || _c === void 0 ? void 0 : _c.id;
22
24
  await onSuccess({
23
25
  data_points: {
24
26
  updatedLabOrderId,
25
27
  },
28
+ ...(!(0, lodash_1.isNil)(healthiePatientId) && {
29
+ patient_identifier: {
30
+ system: types_1.HEALTHIE_IDENTIFIER,
31
+ value: healthiePatientId,
32
+ },
33
+ }),
26
34
  });
27
35
  }
36
+ catch (error) {
37
+ const formattedError = (0, errors_1.formatErrors)(error);
38
+ await onError(formattedError);
39
+ }
28
40
  },
29
41
  };
30
42
  //# sourceMappingURL=labOrderUpdated.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"labOrderUpdated.js","sourceRoot":"","sources":["../../../../extensions/healthie/webhooks/labOrderUpdated.ts"],"names":[],"mappings":";;;AAAA,mCAA8B;AAO9B,MAAM,UAAU,GAAG;IACjB,iBAAiB,EAAE;QACjB,GAAG,EAAE,mBAAmB;QACxB,SAAS,EAAE,QAAQ;KACpB;CAC4C,CAAA;AAElC,QAAA,eAAe,GAGxB;IACF,GAAG,EAAE,iBAAiB;IACtB,UAAU;IACV,iBAAiB,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE;QACrE,MAAM,EAAE,WAAW,EAAE,iBAAiB,EAAE,GAAG,OAAO,CAAA;QAElD,IAAI,IAAA,cAAK,EAAC,iBAAiB,CAAC,EAAE;YAC5B,MAAM,OAAO,CAAC;YACZ,sEAAsE;aACvE,CAAC,CAAA;SACH;aAAM;YACL,MAAM,SAAS,CAAC;gBACd,WAAW,EAAE;oBACX,iBAAiB;iBAClB;aACF,CAAC,CAAA;SACH;IACH,CAAC;CACF,CAAA"}
1
+ {"version":3,"file":"labOrderUpdated.js","sourceRoot":"","sources":["../../../../extensions/healthie/webhooks/labOrderUpdated.ts"],"names":[],"mappings":";;;AAAA,mCAA8B;AAK9B,wCAA+E;AAE/E,8CAAgD;AAChD,oDAAgD;AAEhD,MAAM,UAAU,GAAG;IACjB,iBAAiB,EAAE;QACjB,GAAG,EAAE,mBAAmB;QACxB,SAAS,EAAE,QAAQ;KACpB;CAC4C,CAAA;AAElC,QAAA,eAAe,GAIxB;IACF,GAAG,EAAE,iBAAiB;IACtB,UAAU;IACV,iBAAiB,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE;;QACrE,IAAI;YACF,MAAM,EAAE,GAAG,EAAE,GAAG,MAAM,IAAA,qBAAS,EAAC,EAAE,QAAQ,EAAE,CAAC,CAAA;YAC7C,MAAM,iBAAiB,GAAG,OAAO,CAAC,WAAW,CAAC,QAAQ,EAAE,CAAA;YAExD,MAAM,QAAQ,GAAG,MAAM,GAAG,CAAC,WAAW,CAAC,EAAE,EAAE,EAAE,iBAAiB,EAAE,CAAC,CAAA;YACjE,MAAM,iBAAiB,GAAG,MAAA,MAAA,MAAA,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,IAAI,0CAAE,QAAQ,0CAAE,OAAO,0CAAE,EAAE,CAAA;YAC/D,MAAM,SAAS,CAAC;gBACd,WAAW,EAAE;oBACV,iBAAiB;iBAClB;gBACF,GAAG,CAAC,CAAC,IAAA,cAAK,EAAC,iBAAiB,CAAC,IAAI;oBAC/B,kBAAkB,EAAE;wBAClB,MAAM,EAAE,2BAAmB;wBAC3B,KAAK,EAAE,iBAAiB;qBACzB;iBACF,CAAC;aACH,CAAC,CAAA;SACH;QAAC,OAAO,KAAK,EAAE;YACd,MAAM,cAAc,GAAG,IAAA,qBAAY,EAAC,KAAK,CAAC,CAAA;YAC1C,MAAM,OAAO,CAAC,cAAc,CAAC,CAAA;SAC9B;IACH,CAAC;CACF,CAAA"}
@@ -1,11 +1,12 @@
1
1
  import { type Webhook } from '@awell-health/extensions-core';
2
2
  import { type HealthieWebhookPayload } from '../lib/types';
3
+ import { type settings } from '../settings';
3
4
  declare const dataPoints: {
4
5
  createdMessageId: {
5
6
  key: string;
6
7
  valueType: "string";
7
8
  };
8
9
  };
9
- export declare const messageCreated: Webhook<keyof typeof dataPoints, HealthieWebhookPayload>;
10
+ export declare const messageCreated: Webhook<keyof typeof dataPoints, HealthieWebhookPayload, typeof settings>;
10
11
  export type MessageCreated = typeof messageCreated;
11
12
  export {};
@@ -2,6 +2,9 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.messageCreated = void 0;
4
4
  const lodash_1 = require("lodash");
5
+ const types_1 = require("../lib/types");
6
+ const errors_1 = require("../lib/sdk/errors");
7
+ const createSdk_1 = require("../lib/sdk/createSdk");
5
8
  const dataPoints = {
6
9
  createdMessageId: {
7
10
  key: 'createdMessageId',
@@ -12,19 +15,29 @@ exports.messageCreated = {
12
15
  key: 'messageCreated',
13
16
  dataPoints,
14
17
  onWebhookReceived: async ({ payload, settings }, onSuccess, onError) => {
15
- const { resource_id: createdMessageId } = payload;
16
- if ((0, lodash_1.isNil)(createdMessageId)) {
17
- await onError({
18
- // We should automatically send a 400 here, so no need to provide info
19
- });
20
- }
21
- else {
18
+ var _a, _b, _c, _d;
19
+ try {
20
+ const { sdk } = await (0, createSdk_1.createSdk)({ settings });
21
+ const createdMessageId = payload.resource_id.toString();
22
+ const messageResponse = await sdk.getMessage({ id: createdMessageId });
23
+ const conversationResponse = await sdk.getConversation({ id: (_b = (_a = messageResponse === null || messageResponse === void 0 ? void 0 : messageResponse.data) === null || _a === void 0 ? void 0 : _a.note) === null || _b === void 0 ? void 0 : _b.conversation_id });
24
+ const healthiePatientId = (_d = (_c = conversationResponse === null || conversationResponse === void 0 ? void 0 : conversationResponse.data) === null || _c === void 0 ? void 0 : _c.conversation) === null || _d === void 0 ? void 0 : _d.patient_id;
22
25
  await onSuccess({
23
26
  data_points: {
24
27
  createdMessageId,
25
28
  },
29
+ ...(!(0, lodash_1.isNil)(healthiePatientId) && {
30
+ patient_identifier: {
31
+ system: types_1.HEALTHIE_IDENTIFIER,
32
+ value: healthiePatientId,
33
+ }
34
+ })
26
35
  });
27
36
  }
37
+ catch (error) {
38
+ const formattedError = (0, errors_1.formatErrors)(error);
39
+ await onError(formattedError);
40
+ }
28
41
  },
29
42
  };
30
43
  //# sourceMappingURL=messageCreated.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"messageCreated.js","sourceRoot":"","sources":["../../../../extensions/healthie/webhooks/messageCreated.ts"],"names":[],"mappings":";;;AAAA,mCAA8B;AAO9B,MAAM,UAAU,GAAG;IACjB,gBAAgB,EAAE;QAChB,GAAG,EAAE,kBAAkB;QACvB,SAAS,EAAE,QAAQ;KACpB;CAC4C,CAAA;AAElC,QAAA,cAAc,GAGvB;IACF,GAAG,EAAE,gBAAgB;IACrB,UAAU;IACV,iBAAiB,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE;QACrE,MAAM,EAAE,WAAW,EAAE,gBAAgB,EAAE,GAAG,OAAO,CAAA;QAEjD,IAAI,IAAA,cAAK,EAAC,gBAAgB,CAAC,EAAE;YAC3B,MAAM,OAAO,CAAC;YACZ,sEAAsE;aACvE,CAAC,CAAA;SACH;aAAM;YACL,MAAM,SAAS,CAAC;gBACd,WAAW,EAAE;oBACX,gBAAgB;iBACjB;aACF,CAAC,CAAA;SACH;IACH,CAAC;CACF,CAAA"}
1
+ {"version":3,"file":"messageCreated.js","sourceRoot":"","sources":["../../../../extensions/healthie/webhooks/messageCreated.ts"],"names":[],"mappings":";;;AAAA,mCAA8B;AAK9B,wCAA+E;AAE/E,8CAAgD;AAChD,oDAAgD;AAEhD,MAAM,UAAU,GAAG;IACjB,gBAAgB,EAAE;QAChB,GAAG,EAAE,kBAAkB;QACvB,SAAS,EAAE,QAAQ;KACpB;CAC4C,CAAA;AAElC,QAAA,cAAc,GAIvB;IACF,GAAG,EAAE,gBAAgB;IACrB,UAAU;IACV,iBAAiB,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE;;QACrE,IAAI;YACF,MAAM,EAAE,GAAG,EAAE,GAAG,MAAM,IAAA,qBAAS,EAAC,EAAE,QAAQ,EAAE,CAAC,CAAA;YAC7C,MAAM,gBAAgB,GAAG,OAAO,CAAC,WAAW,CAAC,QAAQ,EAAE,CAAA;YAEvD,MAAM,eAAe,GAAG,MAAM,GAAG,CAAC,UAAU,CAAC,EAAE,EAAE,EAAE,gBAAgB,EAAE,CAAC,CAAA;YACtE,MAAM,oBAAoB,GAAG,MAAM,GAAG,CAAC,eAAe,CAAC,EAAE,EAAE,EAAE,MAAA,MAAA,eAAe,aAAf,eAAe,uBAAf,eAAe,CAAE,IAAI,0CAAE,IAAI,0CAAE,eAAe,EAAE,CAAC,CAAA;YAC5G,MAAM,iBAAiB,GAAG,MAAA,MAAA,oBAAoB,aAApB,oBAAoB,uBAApB,oBAAoB,CAAE,IAAI,0CAAE,YAAY,0CAAE,UAAU,CAAA;YAC9E,MAAM,SAAS,CAAC;gBACd,WAAW,EAAE;oBACX,gBAAgB;iBACjB;gBACD,GAAG,CAAC,CAAC,IAAA,cAAK,EAAC,iBAAiB,CAAC,IAAI;oBAC/B,kBAAkB,EAAE;wBAClB,MAAM,EAAE,2BAAmB;wBAC3B,KAAK,EAAE,iBAAiB;qBACzB;iBACF,CAAC;aACH,CAAC,CAAA;SACH;QAAC,OAAO,KAAK,EAAE;YACd,MAAM,cAAc,GAAG,IAAA,qBAAY,EAAC,KAAK,CAAC,CAAA;YAC1C,MAAM,OAAO,CAAC,cAAc,CAAC,CAAA;SAC9B;IACH,CAAC;CACF,CAAA"}
@@ -1,11 +1,12 @@
1
1
  import { type Webhook } from '@awell-health/extensions-core';
2
2
  import { type HealthieWebhookPayload } from '../lib/types';
3
+ import { type settings } from '../settings';
3
4
  declare const dataPoints: {
4
5
  deletedMessageId: {
5
6
  key: string;
6
7
  valueType: "string";
7
8
  };
8
9
  };
9
- export declare const messageDeleted: Webhook<keyof typeof dataPoints, HealthieWebhookPayload>;
10
+ export declare const messageDeleted: Webhook<keyof typeof dataPoints, HealthieWebhookPayload, typeof settings>;
10
11
  export type MessageDeleted = typeof messageDeleted;
11
12
  export {};
@@ -2,6 +2,9 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.messageDeleted = void 0;
4
4
  const lodash_1 = require("lodash");
5
+ const types_1 = require("../lib/types");
6
+ const errors_1 = require("../lib/sdk/errors");
7
+ const createSdk_1 = require("../lib/sdk/createSdk");
5
8
  const dataPoints = {
6
9
  deletedMessageId: {
7
10
  key: 'deletedMessageId',
@@ -12,19 +15,29 @@ exports.messageDeleted = {
12
15
  key: 'messageDeleted',
13
16
  dataPoints,
14
17
  onWebhookReceived: async ({ payload, settings }, onSuccess, onError) => {
15
- const { resource_id: deletedMessageId } = payload;
16
- if ((0, lodash_1.isNil)(deletedMessageId)) {
17
- await onError({
18
- // We should automatically send a 400 here, so no need to provide info
19
- });
20
- }
21
- else {
18
+ var _a, _b, _c, _d;
19
+ try {
20
+ const { sdk } = await (0, createSdk_1.createSdk)({ settings });
21
+ const deletedMessageId = payload.resource_id.toString();
22
+ const messageResponse = await sdk.getMessage({ id: deletedMessageId });
23
+ const conversationResponse = await sdk.getConversation({ id: (_b = (_a = messageResponse === null || messageResponse === void 0 ? void 0 : messageResponse.data) === null || _a === void 0 ? void 0 : _a.note) === null || _b === void 0 ? void 0 : _b.conversation_id });
24
+ const healthiePatientId = (_d = (_c = conversationResponse === null || conversationResponse === void 0 ? void 0 : conversationResponse.data) === null || _c === void 0 ? void 0 : _c.conversation) === null || _d === void 0 ? void 0 : _d.patient_id;
22
25
  await onSuccess({
23
26
  data_points: {
24
27
  deletedMessageId,
25
28
  },
29
+ ...(!(0, lodash_1.isNil)(healthiePatientId) && {
30
+ patient_identifier: {
31
+ system: types_1.HEALTHIE_IDENTIFIER,
32
+ value: healthiePatientId,
33
+ }
34
+ }),
26
35
  });
27
36
  }
37
+ catch (error) {
38
+ const formattedError = (0, errors_1.formatErrors)(error);
39
+ await onError(formattedError);
40
+ }
28
41
  },
29
42
  };
30
43
  //# sourceMappingURL=messageDeleted.js.map