@oystehr/sdk 4.1.8 → 4.1.10

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 (137) hide show
  1. package/dist/cjs/client/client.cjs.map +1 -1
  2. package/dist/cjs/errors/index.cjs.map +1 -1
  3. package/dist/cjs/index.cjs.map +1 -1
  4. package/dist/cjs/index.min.cjs +1 -1
  5. package/dist/cjs/index.min.cjs.map +1 -1
  6. package/dist/cjs/resources/classes/application.cjs.map +1 -1
  7. package/dist/cjs/resources/classes/charge.cjs.map +1 -1
  8. package/dist/cjs/resources/classes/conversation-ext.cjs.map +1 -1
  9. package/dist/cjs/resources/classes/conversation.cjs.map +1 -1
  10. package/dist/cjs/resources/classes/developer.cjs.map +1 -1
  11. package/dist/cjs/resources/classes/erx.cjs.map +1 -1
  12. package/dist/cjs/resources/classes/fax.cjs.map +1 -1
  13. package/dist/cjs/resources/classes/fhir-ext.cjs +14 -1
  14. package/dist/cjs/resources/classes/fhir-ext.cjs.map +1 -1
  15. package/dist/cjs/resources/classes/fhir.cjs.map +1 -1
  16. package/dist/cjs/resources/classes/index.cjs +0 -6
  17. package/dist/cjs/resources/classes/index.cjs.map +1 -1
  18. package/dist/cjs/resources/classes/index.d.ts +0 -4
  19. package/dist/cjs/resources/classes/lab.cjs.map +1 -1
  20. package/dist/cjs/resources/classes/m2m.cjs.map +1 -1
  21. package/dist/cjs/resources/classes/messaging.cjs.map +1 -1
  22. package/dist/cjs/resources/classes/paymentMethod.cjs.map +1 -1
  23. package/dist/cjs/resources/classes/project.cjs.map +1 -1
  24. package/dist/cjs/resources/classes/rcm.cjs.map +1 -1
  25. package/dist/cjs/resources/classes/role.cjs.map +1 -1
  26. package/dist/cjs/resources/classes/secret.cjs.map +1 -1
  27. package/dist/cjs/resources/classes/telemed.cjs.map +1 -1
  28. package/dist/cjs/resources/classes/transactionalSMS.cjs.map +1 -1
  29. package/dist/cjs/resources/classes/user.cjs +9 -0
  30. package/dist/cjs/resources/classes/user.cjs.map +1 -1
  31. package/dist/cjs/resources/classes/user.d.ts +8 -1
  32. package/dist/cjs/resources/classes/version.cjs.map +1 -1
  33. package/dist/cjs/resources/classes/z3-ext.cjs.map +1 -1
  34. package/dist/cjs/resources/classes/z3.cjs.map +1 -1
  35. package/dist/cjs/resources/classes/zambda-ext.cjs.map +1 -1
  36. package/dist/cjs/resources/classes/zambda.cjs.map +1 -1
  37. package/dist/cjs/resources/classes/zambdaLogStream.cjs.map +1 -1
  38. package/dist/cjs/resources/types/UserResetPasswordLinkParams.d.ts +7 -0
  39. package/dist/cjs/resources/types/UserUpdateParams.d.ts +4 -0
  40. package/dist/cjs/resources/types/index.d.ts +1 -12
  41. package/dist/esm/client/client.js.map +1 -1
  42. package/dist/esm/errors/index.js.map +1 -1
  43. package/dist/esm/index.js.map +1 -1
  44. package/dist/esm/index.min.js +1 -1
  45. package/dist/esm/index.min.js.map +1 -1
  46. package/dist/esm/resources/classes/application.js.map +1 -1
  47. package/dist/esm/resources/classes/charge.js.map +1 -1
  48. package/dist/esm/resources/classes/conversation-ext.js.map +1 -1
  49. package/dist/esm/resources/classes/conversation.js.map +1 -1
  50. package/dist/esm/resources/classes/developer.js.map +1 -1
  51. package/dist/esm/resources/classes/erx.js.map +1 -1
  52. package/dist/esm/resources/classes/fax.js.map +1 -1
  53. package/dist/esm/resources/classes/fhir-ext.js +14 -1
  54. package/dist/esm/resources/classes/fhir-ext.js.map +1 -1
  55. package/dist/esm/resources/classes/fhir.js.map +1 -1
  56. package/dist/esm/resources/classes/index.d.ts +0 -4
  57. package/dist/esm/resources/classes/index.js +0 -6
  58. package/dist/esm/resources/classes/index.js.map +1 -1
  59. package/dist/esm/resources/classes/lab.js.map +1 -1
  60. package/dist/esm/resources/classes/m2m.js.map +1 -1
  61. package/dist/esm/resources/classes/messaging.js.map +1 -1
  62. package/dist/esm/resources/classes/paymentMethod.js.map +1 -1
  63. package/dist/esm/resources/classes/project.js.map +1 -1
  64. package/dist/esm/resources/classes/rcm.js.map +1 -1
  65. package/dist/esm/resources/classes/role.js.map +1 -1
  66. package/dist/esm/resources/classes/secret.js.map +1 -1
  67. package/dist/esm/resources/classes/telemed.js.map +1 -1
  68. package/dist/esm/resources/classes/transactionalSMS.js.map +1 -1
  69. package/dist/esm/resources/classes/user.d.ts +8 -1
  70. package/dist/esm/resources/classes/user.js +9 -0
  71. package/dist/esm/resources/classes/user.js.map +1 -1
  72. package/dist/esm/resources/classes/version.js.map +1 -1
  73. package/dist/esm/resources/classes/z3-ext.js.map +1 -1
  74. package/dist/esm/resources/classes/z3.js.map +1 -1
  75. package/dist/esm/resources/classes/zambda-ext.js.map +1 -1
  76. package/dist/esm/resources/classes/zambda.js.map +1 -1
  77. package/dist/esm/resources/classes/zambdaLogStream.js.map +1 -1
  78. package/dist/esm/resources/types/UserResetPasswordLinkParams.d.ts +7 -0
  79. package/dist/esm/resources/types/UserUpdateParams.d.ts +4 -0
  80. package/dist/esm/resources/types/index.d.ts +1 -12
  81. package/package.json +5 -3
  82. package/src/resources/classes/fhir-ext.ts +16 -1
  83. package/src/resources/classes/index.ts +0 -6
  84. package/src/resources/classes/user.ts +10 -0
  85. package/src/resources/types/UserResetPasswordLinkParams.ts +9 -0
  86. package/src/resources/types/UserUpdateParams.ts +4 -0
  87. package/src/resources/types/index.ts +1 -12
  88. package/dist/cjs/resources/classes/erxV1.cjs +0 -46
  89. package/dist/cjs/resources/classes/erxV1.cjs.map +0 -1
  90. package/dist/cjs/resources/classes/erxV1.d.ts +0 -31
  91. package/dist/cjs/resources/classes/erxV2.cjs +0 -22
  92. package/dist/cjs/resources/classes/erxV2.cjs.map +0 -1
  93. package/dist/cjs/resources/classes/erxV2.d.ts +0 -15
  94. package/dist/cjs/resources/types/ErxV1AllergySearchParams.d.ts +0 -3
  95. package/dist/cjs/resources/types/ErxV1AllergySearchResponse.d.ts +0 -19
  96. package/dist/cjs/resources/types/ErxV1CancelOrderParams.d.ts +0 -6
  97. package/dist/cjs/resources/types/ErxV1CancelOrderResponse.d.ts +0 -6
  98. package/dist/cjs/resources/types/ErxV1CancelPrescriptionParams.d.ts +0 -6
  99. package/dist/cjs/resources/types/ErxV1CancelPrescriptionResponse.d.ts +0 -6
  100. package/dist/cjs/resources/types/ErxV1MedicationSearchParams.d.ts +0 -6
  101. package/dist/cjs/resources/types/ErxV1MedicationSearchResponse.d.ts +0 -38
  102. package/dist/cjs/resources/types/ErxV1SyncPatientParams.d.ts +0 -3
  103. package/dist/cjs/resources/types/ErxV1SyncPatientResponse.d.ts +0 -9
  104. package/dist/cjs/resources/types/ErxV2MedicationSearchParams.d.ts +0 -4
  105. package/dist/cjs/resources/types/ErxV2MedicationSearchResponse.d.ts +0 -38
  106. package/dist/esm/resources/classes/erxV1.d.ts +0 -31
  107. package/dist/esm/resources/classes/erxV1.js +0 -44
  108. package/dist/esm/resources/classes/erxV1.js.map +0 -1
  109. package/dist/esm/resources/classes/erxV2.d.ts +0 -15
  110. package/dist/esm/resources/classes/erxV2.js +0 -20
  111. package/dist/esm/resources/classes/erxV2.js.map +0 -1
  112. package/dist/esm/resources/types/ErxV1AllergySearchParams.d.ts +0 -3
  113. package/dist/esm/resources/types/ErxV1AllergySearchResponse.d.ts +0 -19
  114. package/dist/esm/resources/types/ErxV1CancelOrderParams.d.ts +0 -6
  115. package/dist/esm/resources/types/ErxV1CancelOrderResponse.d.ts +0 -6
  116. package/dist/esm/resources/types/ErxV1CancelPrescriptionParams.d.ts +0 -6
  117. package/dist/esm/resources/types/ErxV1CancelPrescriptionResponse.d.ts +0 -6
  118. package/dist/esm/resources/types/ErxV1MedicationSearchParams.d.ts +0 -6
  119. package/dist/esm/resources/types/ErxV1MedicationSearchResponse.d.ts +0 -38
  120. package/dist/esm/resources/types/ErxV1SyncPatientParams.d.ts +0 -3
  121. package/dist/esm/resources/types/ErxV1SyncPatientResponse.d.ts +0 -9
  122. package/dist/esm/resources/types/ErxV2MedicationSearchParams.d.ts +0 -4
  123. package/dist/esm/resources/types/ErxV2MedicationSearchResponse.d.ts +0 -38
  124. package/src/resources/classes/erxV1.ts +0 -73
  125. package/src/resources/classes/erxV2.ts +0 -34
  126. package/src/resources/types/ErxV1AllergySearchParams.ts +0 -5
  127. package/src/resources/types/ErxV1AllergySearchResponse.ts +0 -21
  128. package/src/resources/types/ErxV1CancelOrderParams.ts +0 -8
  129. package/src/resources/types/ErxV1CancelOrderResponse.ts +0 -8
  130. package/src/resources/types/ErxV1CancelPrescriptionParams.ts +0 -8
  131. package/src/resources/types/ErxV1CancelPrescriptionResponse.ts +0 -8
  132. package/src/resources/types/ErxV1MedicationSearchParams.ts +0 -8
  133. package/src/resources/types/ErxV1MedicationSearchResponse.ts +0 -40
  134. package/src/resources/types/ErxV1SyncPatientParams.ts +0 -5
  135. package/src/resources/types/ErxV1SyncPatientResponse.ts +0 -11
  136. package/src/resources/types/ErxV2MedicationSearchParams.ts +0 -6
  137. package/src/resources/types/ErxV2MedicationSearchResponse.ts +0 -40
@@ -1,73 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- import {
4
- ErxV1AllergySearchParams,
5
- ErxV1AllergySearchResponse,
6
- ErxV1CancelOrderParams,
7
- ErxV1CancelOrderResponse,
8
- ErxV1CancelPrescriptionParams,
9
- ErxV1CancelPrescriptionResponse,
10
- ErxV1MedicationSearchParams,
11
- ErxV1MedicationSearchResponse,
12
- ErxV1SyncPatientParams,
13
- ErxV1SyncPatientResponse,
14
- OystehrClientRequest,
15
- } from '../..';
16
- import { SDKResource } from '../../client/client';
17
- import { OystehrConfig } from '../../config';
18
-
19
- export class ErxV1 extends SDKResource {
20
- constructor(config: OystehrConfig) {
21
- super(config);
22
- }
23
- #baseUrlThunk(): string {
24
- return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';
25
- }
26
- /**
27
- * Retrieve patient properties from FHIR service and sync them with eRx service
28
- */
29
- syncPatient(params: ErxV1SyncPatientParams, request?: OystehrClientRequest): Promise<ErxV1SyncPatientResponse> {
30
- return this.request('/erx/sync-patient/{patientId}', 'post', this.#baseUrlThunk.bind(this))(params, request);
31
- }
32
- /**
33
- * Search for allergies
34
- */
35
- allergySearch(params: ErxV1AllergySearchParams, request?: OystehrClientRequest): Promise<ErxV1AllergySearchResponse> {
36
- return this.request('/erx/allergy/search', 'get', this.#baseUrlThunk.bind(this))(params, request);
37
- }
38
- /**
39
- * Cancel photon order
40
- */
41
- cancelOrder(params: ErxV1CancelOrderParams, request?: OystehrClientRequest): Promise<ErxV1CancelOrderResponse> {
42
- return this.request('/erx/cancel-order', 'post', this.#baseUrlThunk.bind(this))(params, request);
43
- }
44
- /**
45
- * Cancel photon prescription
46
- */
47
- cancelPrescription(
48
- params: ErxV1CancelPrescriptionParams,
49
- request?: OystehrClientRequest
50
- ): Promise<ErxV1CancelPrescriptionResponse> {
51
- return this.request('/erx/cancel-prescription', 'post', this.#baseUrlThunk.bind(this))(params, request);
52
- }
53
- /**
54
- * Search for medications. Provide at least one of code or name filters
55
- */
56
- medicationSearch(
57
- params: ErxV1MedicationSearchParams,
58
- request?: OystehrClientRequest
59
- ): Promise<ErxV1MedicationSearchResponse>;
60
- /**
61
- * Search for medications. Provide at least one of code or name filters
62
- */
63
- medicationSearch(request?: OystehrClientRequest): Promise<ErxV1MedicationSearchResponse>;
64
- /**
65
- * Search for medications. Provide at least one of code or name filters
66
- */
67
- medicationSearch(
68
- params?: ErxV1MedicationSearchParams | OystehrClientRequest,
69
- request?: OystehrClientRequest
70
- ): Promise<ErxV1MedicationSearchResponse> {
71
- return this.request('/erx/medication/search', 'get', this.#baseUrlThunk.bind(this))(params, request);
72
- }
73
- }
@@ -1,34 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- import { ErxV2MedicationSearchParams, ErxV2MedicationSearchResponse, OystehrClientRequest } from '../..';
4
- import { SDKResource } from '../../client/client';
5
- import { OystehrConfig } from '../../config';
6
-
7
- export class ErxV2 extends SDKResource {
8
- constructor(config: OystehrConfig) {
9
- super(config);
10
- }
11
- #baseUrlThunk(): string {
12
- return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';
13
- }
14
- /**
15
- * Search for medications. Provide at least one of code or name filters
16
- */
17
- medicationSearch(
18
- params: ErxV2MedicationSearchParams,
19
- request?: OystehrClientRequest
20
- ): Promise<ErxV2MedicationSearchResponse>;
21
- /**
22
- * Search for medications. Provide at least one of code or name filters
23
- */
24
- medicationSearch(request?: OystehrClientRequest): Promise<ErxV2MedicationSearchResponse>;
25
- /**
26
- * Search for medications. Provide at least one of code or name filters
27
- */
28
- medicationSearch(
29
- params?: ErxV2MedicationSearchParams | OystehrClientRequest,
30
- request?: OystehrClientRequest
31
- ): Promise<ErxV2MedicationSearchResponse> {
32
- return this.request('/erx/v2/medication/search', 'get', this.#baseUrlThunk.bind(this))(params, request);
33
- }
34
- }
@@ -1,5 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- export interface ErxV1AllergySearchParams {
4
- name: string;
5
- }
@@ -1,21 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- /**
4
- * Allergens
5
- */
6
- export interface ErxV1AllergySearchResponse {
7
- allergens?: {
8
- /**
9
- * The Photon identifier for the allergen.
10
- */
11
- id?: string;
12
- /**
13
- * Human readible name of allergen.
14
- */
15
- name?: string;
16
- /**
17
- * RxNorm Concept Unique (RxCUI) identifier of allergen.
18
- */
19
- rxcui?: string;
20
- }[];
21
- }
@@ -1,8 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- export interface ErxV1CancelOrderParams {
4
- /**
5
- * A photon id of the order to cancel.
6
- */
7
- orderId: string;
8
- }
@@ -1,8 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- /**
4
- * Cancelled order
5
- */
6
- export interface ErxV1CancelOrderResponse {
7
- orderId: string;
8
- }
@@ -1,8 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- export interface ErxV1CancelPrescriptionParams {
4
- /**
5
- * A photon id of the prescription to cancel.
6
- */
7
- prescriptionId: string;
8
- }
@@ -1,8 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- /**
4
- * Cancelled prescription
5
- */
6
- export interface ErxV1CancelPrescriptionResponse {
7
- prescriptionId: string;
8
- }
@@ -1,8 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- export interface ErxV1MedicationSearchParams {
4
- name?: string;
5
- code?: string;
6
- after?: string;
7
- first?: number;
8
- }
@@ -1,40 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- /**
4
- * Medications
5
- */
6
- export interface ErxV1MedicationSearchResponse {
7
- medications?: {
8
- /**
9
- * The Photon identifier for the medication.
10
- */
11
- id: string;
12
- /**
13
- * Human readible name of medication.
14
- */
15
- name: string;
16
- codes: {
17
- /**
18
- * RxNorm Concept Unique (RxCUI) identifier of medication.
19
- */
20
- rxcui?: string | null;
21
- productNDC?: string | null;
22
- packageNDC?: string | null;
23
- SKU?: string | null;
24
- HCPCS?: string | null;
25
- };
26
- /**
27
- * Null implies a medication can not be prescribed
28
- */
29
- type?: ('RX' | 'OTC') | null;
30
- concept: 'DRUG' | 'PRODUCT' | 'PACKAGE';
31
- schedule?: ('I' | 'II' | 'III' | 'IV' | 'V') | null;
32
- controlled: boolean;
33
- brandName?: string | null;
34
- genericName?: string | null;
35
- strength?: string | null;
36
- form?: string | null;
37
- manufacturer?: string | null;
38
- description?: string | null;
39
- }[];
40
- }
@@ -1,5 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- export interface ErxV1SyncPatientParams {
4
- patientId: string;
5
- }
@@ -1,11 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- /**
4
- * Photon sync response
5
- */
6
- export interface ErxV1SyncPatientResponse {
7
- /**
8
- * The Photon identifier for the patient.
9
- */
10
- photonPatientId?: string;
11
- }
@@ -1,6 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- export interface ErxV2MedicationSearchParams {
4
- name?: string;
5
- code?: string;
6
- }
@@ -1,40 +0,0 @@
1
- // AUTOGENERATED -- DO NOT EDIT
2
-
3
- /**
4
- * Medications
5
- */
6
- export interface ErxV2MedicationSearchResponse {
7
- medications?: {
8
- /**
9
- * Internal identifier for the medication.
10
- */
11
- id: string;
12
- /**
13
- * Human readible name of medication.
14
- */
15
- name: string;
16
- codes: {
17
- /**
18
- * RxNorm Concept Unique (RxCUI) identifier of medication.
19
- */
20
- rxcui?: string | null;
21
- productNDC?: string | null;
22
- packageNDC?: string | null;
23
- SKU?: string | null;
24
- HCPCS?: string | null;
25
- };
26
- /**
27
- * Null implies a medication can not be prescribed
28
- */
29
- type?: ('RX' | 'OTC') | null;
30
- concept?: ('DRUG' | 'PRODUCT' | 'PACKAGE') | null;
31
- schedule?: ('I' | 'II' | 'III' | 'IV' | 'V') | null;
32
- controlled?: boolean | null;
33
- brandName?: string | null;
34
- genericName?: string | null;
35
- strength?: string | null;
36
- form?: string | null;
37
- manufacturer?: string | null;
38
- description?: string | null;
39
- }[];
40
- }