@oystehr/sdk 4.0.0-alpha.4 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/client/client.cjs +259 -0
- package/dist/cjs/client/client.cjs.map +1 -0
- package/dist/cjs/errors/index.cjs +58 -0
- package/dist/cjs/errors/index.cjs.map +1 -0
- package/dist/cjs/index.cjs +11 -1980
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs/index.min.cjs +1 -1
- package/dist/cjs/index.min.cjs.map +1 -1
- package/dist/cjs/resources/classes/application.cjs +88 -0
- package/dist/cjs/resources/classes/application.cjs.map +1 -0
- package/dist/cjs/resources/classes/charge.cjs +44 -0
- package/dist/cjs/resources/classes/charge.cjs.map +1 -0
- package/dist/cjs/resources/classes/conversation-ext.cjs +31 -0
- package/dist/cjs/resources/classes/conversation-ext.cjs.map +1 -0
- package/dist/cjs/resources/classes/conversation.cjs +84 -0
- package/dist/cjs/resources/classes/conversation.cjs.map +1 -0
- package/dist/cjs/resources/classes/developer.cjs +72 -0
- package/dist/cjs/resources/classes/developer.cjs.map +1 -0
- package/dist/cjs/resources/classes/erx.cjs +88 -0
- package/dist/cjs/resources/classes/erx.cjs.map +1 -0
- package/dist/cjs/resources/classes/erx.d.ts +5 -1
- package/dist/cjs/resources/classes/erxV1.cjs +46 -0
- package/dist/cjs/resources/classes/erxV1.cjs.map +1 -0
- package/dist/cjs/resources/classes/erxV2.cjs +22 -0
- package/dist/cjs/resources/classes/erxV2.cjs.map +1 -0
- package/dist/cjs/resources/classes/fax.cjs +46 -0
- package/dist/cjs/resources/classes/fax.cjs.map +1 -0
- package/dist/cjs/resources/classes/fhir-ext.cjs +200 -0
- package/dist/cjs/resources/classes/fhir-ext.cjs.map +1 -0
- package/dist/cjs/resources/classes/fhir-ext.d.ts +8 -8
- package/dist/cjs/resources/classes/fhir.cjs +34 -0
- package/dist/cjs/resources/classes/fhir.cjs.map +1 -0
- package/dist/cjs/resources/classes/fhir.d.ts +2 -2
- package/dist/cjs/resources/classes/index.cjs +88 -0
- package/dist/cjs/resources/classes/index.cjs.map +1 -0
- package/dist/cjs/resources/classes/lab.cjs +76 -0
- package/dist/cjs/resources/classes/lab.cjs.map +1 -0
- package/dist/cjs/resources/classes/m2m.cjs +81 -0
- package/dist/cjs/resources/classes/m2m.cjs.map +1 -0
- package/dist/cjs/resources/classes/messaging.cjs +22 -0
- package/dist/cjs/resources/classes/messaging.cjs.map +1 -0
- package/dist/cjs/resources/classes/paymentMethod.cjs +88 -0
- package/dist/cjs/resources/classes/paymentMethod.cjs.map +1 -0
- package/dist/cjs/resources/classes/project.cjs +34 -0
- package/dist/cjs/resources/classes/project.cjs.map +1 -0
- package/dist/cjs/resources/classes/rcm.cjs +55 -0
- package/dist/cjs/resources/classes/rcm.cjs.map +1 -0
- package/dist/cjs/resources/classes/role.cjs +62 -0
- package/dist/cjs/resources/classes/role.cjs.map +1 -0
- package/dist/cjs/resources/classes/secret.cjs +52 -0
- package/dist/cjs/resources/classes/secret.cjs.map +1 -0
- package/dist/cjs/resources/classes/telemed.cjs +43 -0
- package/dist/cjs/resources/classes/telemed.cjs.map +1 -0
- package/dist/cjs/resources/classes/transactionalSMS.cjs +34 -0
- package/dist/cjs/resources/classes/transactionalSMS.cjs.map +1 -0
- package/dist/cjs/resources/classes/user.cjs +80 -0
- package/dist/cjs/resources/classes/user.cjs.map +1 -0
- package/dist/cjs/resources/classes/version.cjs +22 -0
- package/dist/cjs/resources/classes/version.cjs.map +1 -0
- package/dist/cjs/resources/classes/z3-ext.cjs +81 -0
- package/dist/cjs/resources/classes/z3-ext.cjs.map +1 -0
- package/dist/cjs/resources/classes/z3.cjs +88 -0
- package/dist/cjs/resources/classes/z3.cjs.map +1 -0
- package/dist/cjs/resources/classes/zambda-ext.cjs +15 -0
- package/dist/cjs/resources/classes/zambda-ext.cjs.map +1 -0
- package/dist/cjs/resources/classes/zambda.cjs +89 -0
- package/dist/cjs/resources/classes/zambda.cjs.map +1 -0
- package/dist/cjs/resources/classes/zambdaLogStream.cjs +43 -0
- package/dist/cjs/resources/classes/zambdaLogStream.cjs.map +1 -0
- package/dist/cjs/resources/types/ErxGetConfigurationResponse.d.ts +9 -0
- package/dist/cjs/resources/types/ZambdaCreateParams.d.ts +12 -0
- package/dist/cjs/resources/types/ZambdaFunction.d.ts +8 -0
- package/dist/cjs/resources/types/ZambdaUpdateParams.d.ts +8 -0
- package/dist/cjs/resources/types/fhir.d.ts +12 -12
- package/dist/cjs/resources/types/index.d.ts +1 -0
- package/dist/esm/client/client.js +68 -67
- package/dist/esm/client/client.js.map +1 -1
- package/dist/esm/errors/index.js +3 -2
- package/dist/esm/errors/index.js.map +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/index.min.js +1 -1
- package/dist/esm/index.min.js.map +1 -1
- package/dist/esm/resources/classes/application.js +11 -15
- package/dist/esm/resources/classes/application.js.map +1 -1
- package/dist/esm/resources/classes/charge.js +5 -9
- package/dist/esm/resources/classes/charge.js.map +1 -1
- package/dist/esm/resources/classes/conversation-ext.js +4 -5
- package/dist/esm/resources/classes/conversation-ext.js.map +1 -1
- package/dist/esm/resources/classes/conversation.js +16 -20
- package/dist/esm/resources/classes/conversation.js.map +1 -1
- package/dist/esm/resources/classes/developer.js +9 -13
- package/dist/esm/resources/classes/developer.js.map +1 -1
- package/dist/esm/resources/classes/erx.d.ts +5 -1
- package/dist/esm/resources/classes/erx.js +20 -18
- package/dist/esm/resources/classes/erx.js.map +1 -1
- package/dist/esm/resources/classes/erxV1.js +8 -12
- package/dist/esm/resources/classes/erxV1.js.map +1 -1
- package/dist/esm/resources/classes/erxV2.js +4 -8
- package/dist/esm/resources/classes/erxV2.js.map +1 -1
- package/dist/esm/resources/classes/fax.js +6 -10
- package/dist/esm/resources/classes/fax.js.map +1 -1
- package/dist/esm/resources/classes/fhir-ext.d.ts +8 -8
- package/dist/esm/resources/classes/fhir-ext.js +71 -62
- package/dist/esm/resources/classes/fhir-ext.js.map +1 -1
- package/dist/esm/resources/classes/fhir.d.ts +2 -2
- package/dist/esm/resources/classes/fhir.js +20 -20
- package/dist/esm/resources/classes/fhir.js.map +1 -1
- package/dist/esm/resources/classes/index.js +28 -5
- package/dist/esm/resources/classes/index.js.map +1 -1
- package/dist/esm/resources/classes/lab.js +9 -13
- package/dist/esm/resources/classes/lab.js.map +1 -1
- package/dist/esm/resources/classes/m2m.js +10 -14
- package/dist/esm/resources/classes/m2m.js.map +1 -1
- package/dist/esm/resources/classes/messaging.js +4 -8
- package/dist/esm/resources/classes/messaging.js.map +1 -1
- package/dist/esm/resources/classes/paymentMethod.js +7 -11
- package/dist/esm/resources/classes/paymentMethod.js.map +1 -1
- package/dist/esm/resources/classes/project.js +5 -9
- package/dist/esm/resources/classes/project.js.map +1 -1
- package/dist/esm/resources/classes/rcm.js +6 -10
- package/dist/esm/resources/classes/rcm.js.map +1 -1
- package/dist/esm/resources/classes/role.js +8 -12
- package/dist/esm/resources/classes/role.js.map +1 -1
- package/dist/esm/resources/classes/secret.js +7 -11
- package/dist/esm/resources/classes/secret.js.map +1 -1
- package/dist/esm/resources/classes/telemed.js +5 -9
- package/dist/esm/resources/classes/telemed.js.map +1 -1
- package/dist/esm/resources/classes/transactionalSMS.js +4 -8
- package/dist/esm/resources/classes/transactionalSMS.js.map +1 -1
- package/dist/esm/resources/classes/user.js +10 -14
- package/dist/esm/resources/classes/user.js.map +1 -1
- package/dist/esm/resources/classes/version.js +4 -8
- package/dist/esm/resources/classes/version.js.map +1 -1
- package/dist/esm/resources/classes/z3-ext.js +47 -56
- package/dist/esm/resources/classes/z3-ext.js.map +1 -1
- package/dist/esm/resources/classes/z3.js +26 -30
- package/dist/esm/resources/classes/z3.js.map +1 -1
- package/dist/esm/resources/classes/zambda-ext.js +6 -11
- package/dist/esm/resources/classes/zambda-ext.js.map +1 -1
- package/dist/esm/resources/classes/zambda.js +12 -16
- package/dist/esm/resources/classes/zambda.js.map +1 -1
- package/dist/esm/resources/classes/zambdaLogStream.js +6 -10
- package/dist/esm/resources/classes/zambdaLogStream.js.map +1 -1
- package/dist/esm/resources/types/ErxGetConfigurationResponse.d.ts +9 -0
- package/dist/esm/resources/types/ZambdaCreateParams.d.ts +12 -0
- package/dist/esm/resources/types/ZambdaFunction.d.ts +8 -0
- package/dist/esm/resources/types/ZambdaUpdateParams.d.ts +8 -0
- package/dist/esm/resources/types/fhir.d.ts +12 -12
- package/dist/esm/resources/types/index.d.ts +1 -0
- package/package.json +4 -3
- package/rollup.config-cjs.mjs +97 -18
- package/src/resources/classes/erx.ts +7 -0
- package/src/resources/classes/fhir-ext.ts +6 -6
- package/src/resources/types/ErxGetConfigurationResponse.ts +11 -0
- package/src/resources/types/ZambdaCreateParams.ts +12 -0
- package/src/resources/types/ZambdaFunction.ts +8 -0
- package/src/resources/types/ZambdaUpdateParams.ts +8 -0
- package/src/resources/types/fhir.ts +12 -12
- package/src/resources/types/index.ts +1 -0
- package/dist/esm/node_modules/tslib/tslib.es6.js +0 -40
- package/dist/esm/node_modules/tslib/tslib.es6.js.map +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { __classPrivateFieldGet } from '../../node_modules/tslib/tslib.es6.js';
|
|
2
1
|
import { SDKResource } from '../../client/client.js';
|
|
3
2
|
|
|
4
3
|
// AUTOGENERATED -- DO NOT EDIT
|
|
5
|
-
var _Application_instances, _Application_baseUrlThunk;
|
|
6
4
|
class Application extends SDKResource {
|
|
7
5
|
constructor(config) {
|
|
8
6
|
super(config);
|
|
9
|
-
|
|
7
|
+
}
|
|
8
|
+
#baseUrlThunk() {
|
|
9
|
+
return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';
|
|
10
10
|
}
|
|
11
11
|
/**
|
|
12
12
|
* Get a list of Applications. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.
|
|
@@ -15,7 +15,7 @@ class Application extends SDKResource {
|
|
|
15
15
|
* Access Policy Resource: `App:Application`
|
|
16
16
|
*/
|
|
17
17
|
list(request) {
|
|
18
|
-
return this.request('/application', 'get',
|
|
18
|
+
return this.request('/application', 'get', this.#baseUrlThunk.bind(this))(request);
|
|
19
19
|
}
|
|
20
20
|
/**
|
|
21
21
|
* Create a new Application. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.
|
|
@@ -24,7 +24,7 @@ class Application extends SDKResource {
|
|
|
24
24
|
* Access Policy Resource: `App:Application`
|
|
25
25
|
*/
|
|
26
26
|
create(params, request) {
|
|
27
|
-
return this.request('/application', 'post',
|
|
27
|
+
return this.request('/application', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
28
28
|
}
|
|
29
29
|
/**
|
|
30
30
|
* Get the Application with the provided ID. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.
|
|
@@ -33,7 +33,7 @@ class Application extends SDKResource {
|
|
|
33
33
|
* Access Policy Resource: `App:Application`
|
|
34
34
|
*/
|
|
35
35
|
get(params, request) {
|
|
36
|
-
return this.request('/application/{id}', 'get',
|
|
36
|
+
return this.request('/application/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
37
37
|
}
|
|
38
38
|
/**
|
|
39
39
|
* Update the Application with the provided ID. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.
|
|
@@ -42,7 +42,7 @@ class Application extends SDKResource {
|
|
|
42
42
|
* Access Policy Resource: `App:Application`
|
|
43
43
|
*/
|
|
44
44
|
update(params, request) {
|
|
45
|
-
return this.request('/application/{id}', 'patch',
|
|
45
|
+
return this.request('/application/{id}', 'patch', this.#baseUrlThunk.bind(this))(params, request);
|
|
46
46
|
}
|
|
47
47
|
/**
|
|
48
48
|
* Delete the Application with the provided ID. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.
|
|
@@ -51,7 +51,7 @@ class Application extends SDKResource {
|
|
|
51
51
|
* Access Policy Resource: `App:Application`
|
|
52
52
|
*/
|
|
53
53
|
delete(params, request) {
|
|
54
|
-
return this.request('/application/{id}', 'delete',
|
|
54
|
+
return this.request('/application/{id}', 'delete', this.#baseUrlThunk.bind(this))(params, request);
|
|
55
55
|
}
|
|
56
56
|
/**
|
|
57
57
|
* Rotate client's secrete associated with an application.
|
|
@@ -60,7 +60,7 @@ class Application extends SDKResource {
|
|
|
60
60
|
* Access Policy Resource: `App:Application`
|
|
61
61
|
*/
|
|
62
62
|
rotateSecret(params, request) {
|
|
63
|
-
return this.request('/application/{id}/rotate-secret', 'post',
|
|
63
|
+
return this.request('/application/{id}/rotate-secret', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
64
64
|
}
|
|
65
65
|
/**
|
|
66
66
|
* Revokes user's refresh token issued for the application.
|
|
@@ -69,7 +69,7 @@ class Application extends SDKResource {
|
|
|
69
69
|
* Access Policy Resource: `App:Application`
|
|
70
70
|
*/
|
|
71
71
|
revokeRefreshToken(params, request) {
|
|
72
|
-
return this.request('/application/{id}/revoke-refresh-token', 'post',
|
|
72
|
+
return this.request('/application/{id}/revoke-refresh-token', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
73
73
|
}
|
|
74
74
|
/**
|
|
75
75
|
* Revokes user's access token issued for the application.
|
|
@@ -78,13 +78,9 @@ class Application extends SDKResource {
|
|
|
78
78
|
* Access Policy Resource: `App:Application`
|
|
79
79
|
*/
|
|
80
80
|
revokeAccessToken(params, request) {
|
|
81
|
-
return this.request('/application/{id}/revoke-access-token', 'post',
|
|
81
|
+
return this.request('/application/{id}/revoke-access-token', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
|
-
_Application_instances = new WeakSet(), _Application_baseUrlThunk = function _Application_baseUrlThunk() {
|
|
85
|
-
var _a, _b;
|
|
86
|
-
return (_b = (_a = this.config.services) === null || _a === void 0 ? void 0 : _a['projectApiUrl']) !== null && _b !== void 0 ? _b : 'https://project-api.zapehr.com/v1';
|
|
87
|
-
};
|
|
88
84
|
|
|
89
85
|
export { Application };
|
|
90
86
|
//# sourceMappingURL=application.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"application.js","sources":["../../../../src/resources/classes/application.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n ApplicationCreateParams,\n ApplicationCreateResponse,\n ApplicationDeleteParams,\n ApplicationGetParams,\n ApplicationGetResponse,\n ApplicationListResponse,\n ApplicationRevokeAccessTokenParams,\n ApplicationRevokeAccessTokenResponse,\n ApplicationRevokeRefreshTokenParams,\n ApplicationRevokeRefreshTokenResponse,\n ApplicationRotateSecretParams,\n ApplicationRotateSecretResponse,\n ApplicationUpdateParams,\n ApplicationUpdateResponse,\n OystehrClientRequest,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Application extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Get a list of Applications. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:ListAllApplications`\n * Access Policy Resource: `App:Application`\n */\n list(request?: OystehrClientRequest): Promise<ApplicationListResponse> {\n return this.request('/application', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Create a new Application. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:CreateApplication`\n * Access Policy Resource: `App:Application`\n */\n create(params: ApplicationCreateParams, request?: OystehrClientRequest): Promise<ApplicationCreateResponse> {\n return this.request('/application', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get the Application with the provided ID. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:GetApplication`\n * Access Policy Resource: `App:Application`\n */\n get(params: ApplicationGetParams, request?: OystehrClientRequest): Promise<ApplicationGetResponse> {\n return this.request('/application/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Update the Application with the provided ID. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:UpdateApplication`\n * Access Policy Resource: `App:Application`\n */\n update(params: ApplicationUpdateParams, request?: OystehrClientRequest): Promise<ApplicationUpdateResponse> {\n return this.request('/application/{id}', 'patch', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Application with the provided ID. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:DeleteApplication`\n * Access Policy Resource: `App:Application`\n */\n delete(params: ApplicationDeleteParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/application/{id}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Rotate client's secrete associated with an application.\n *\n * Access Policy Action: `App:RotateApplicationSecret`\n * Access Policy Resource: `App:Application`\n */\n rotateSecret(\n params: ApplicationRotateSecretParams,\n request?: OystehrClientRequest\n ): Promise<ApplicationRotateSecretResponse> {\n return this.request('/application/{id}/rotate-secret', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Revokes user's refresh token issued for the application.\n *\n * Access Policy Action: `App:RevokeRefreshToken`\n * Access Policy Resource: `App:Application`\n */\n revokeRefreshToken(\n params: ApplicationRevokeRefreshTokenParams,\n request?: OystehrClientRequest\n ): Promise<ApplicationRevokeRefreshTokenResponse> {\n return this.request(\n '/application/{id}/revoke-refresh-token',\n 'post',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Revokes user's access token issued for the application.\n *\n * Access Policy Action: `App:RevokeAccessToken`\n * Access Policy Resource: `App:Application`\n */\n revokeAccessToken(\n params: ApplicationRevokeAccessTokenParams,\n request?: OystehrClientRequest\n ): Promise<ApplicationRevokeAccessTokenResponse> {\n return this.request(\n '/application/{id}/revoke-access-token',\n 'post',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n}\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"application.js","sources":["../../../../src/resources/classes/application.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n ApplicationCreateParams,\n ApplicationCreateResponse,\n ApplicationDeleteParams,\n ApplicationGetParams,\n ApplicationGetResponse,\n ApplicationListResponse,\n ApplicationRevokeAccessTokenParams,\n ApplicationRevokeAccessTokenResponse,\n ApplicationRevokeRefreshTokenParams,\n ApplicationRevokeRefreshTokenResponse,\n ApplicationRotateSecretParams,\n ApplicationRotateSecretResponse,\n ApplicationUpdateParams,\n ApplicationUpdateResponse,\n OystehrClientRequest,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Application extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Get a list of Applications. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:ListAllApplications`\n * Access Policy Resource: `App:Application`\n */\n list(request?: OystehrClientRequest): Promise<ApplicationListResponse> {\n return this.request('/application', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Create a new Application. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:CreateApplication`\n * Access Policy Resource: `App:Application`\n */\n create(params: ApplicationCreateParams, request?: OystehrClientRequest): Promise<ApplicationCreateResponse> {\n return this.request('/application', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get the Application with the provided ID. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:GetApplication`\n * Access Policy Resource: `App:Application`\n */\n get(params: ApplicationGetParams, request?: OystehrClientRequest): Promise<ApplicationGetResponse> {\n return this.request('/application/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Update the Application with the provided ID. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:UpdateApplication`\n * Access Policy Resource: `App:Application`\n */\n update(params: ApplicationUpdateParams, request?: OystehrClientRequest): Promise<ApplicationUpdateResponse> {\n return this.request('/application/{id}', 'patch', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Delete the Application with the provided ID. [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) provide authentication in front of the web and mobile apps you build on Oystehr.\n *\n * Access Policy Action: `App:DeleteApplication`\n * Access Policy Resource: `App:Application`\n */\n delete(params: ApplicationDeleteParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/application/{id}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Rotate client's secrete associated with an application.\n *\n * Access Policy Action: `App:RotateApplicationSecret`\n * Access Policy Resource: `App:Application`\n */\n rotateSecret(\n params: ApplicationRotateSecretParams,\n request?: OystehrClientRequest\n ): Promise<ApplicationRotateSecretResponse> {\n return this.request('/application/{id}/rotate-secret', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Revokes user's refresh token issued for the application.\n *\n * Access Policy Action: `App:RevokeRefreshToken`\n * Access Policy Resource: `App:Application`\n */\n revokeRefreshToken(\n params: ApplicationRevokeRefreshTokenParams,\n request?: OystehrClientRequest\n ): Promise<ApplicationRevokeRefreshTokenResponse> {\n return this.request(\n '/application/{id}/revoke-refresh-token',\n 'post',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Revokes user's access token issued for the application.\n *\n * Access Policy Action: `App:RevokeAccessToken`\n * Access Policy Resource: `App:Application`\n */\n revokeAccessToken(\n params: ApplicationRevokeAccessTokenParams,\n request?: OystehrClientRequest\n ): Promise<ApplicationRevokeAccessTokenResponse> {\n return this.request(\n '/application/{id}/revoke-access-token',\n 'post',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n}\n"],"names":[],"mappings":";;AAAA;AAsBM,MAAO,WAAY,SAAQ,WAAW,CAAA;AAC1C,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC,CAAC;KACf;IACD,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,eAAe,CAAC,IAAI,mCAAmC,CAAC;KACvF;AACD;;;;;AAKG;AACH,IAAA,IAAI,CAAC,OAA8B,EAAA;QACjC,OAAO,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;KACpF;AACD;;;;;AAKG;IACH,MAAM,CAAC,MAA+B,EAAE,OAA8B,EAAA;QACpE,OAAO,IAAI,CAAC,OAAO,CAAC,cAAc,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KAC7F;AACD;;;;;AAKG;IACH,GAAG,CAAC,MAA4B,EAAE,OAA8B,EAAA;QAC9D,OAAO,IAAI,CAAC,OAAO,CAAC,mBAAmB,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACjG;AACD;;;;;AAKG;IACH,MAAM,CAAC,MAA+B,EAAE,OAA8B,EAAA;QACpE,OAAO,IAAI,CAAC,OAAO,CAAC,mBAAmB,EAAE,OAAO,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACnG;AACD;;;;;AAKG;IACH,MAAM,CAAC,MAA+B,EAAE,OAA8B,EAAA;QACpE,OAAO,IAAI,CAAC,OAAO,CAAC,mBAAmB,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACpG;AACD;;;;;AAKG;IACH,YAAY,CACV,MAAqC,EACrC,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,iCAAiC,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KAChH;AACD;;;;;AAKG;IACH,kBAAkB,CAChB,MAA2C,EAC3C,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CACjB,wCAAwC,EACxC,MAAM,EACN,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAC9B,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACpB;AACD;;;;;AAKG;IACH,iBAAiB,CACf,MAA0C,EAC1C,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CACjB,uCAAuC,EACvC,MAAM,EACN,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAC9B,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACpB;AACF;;;;"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { __classPrivateFieldGet } from '../../node_modules/tslib/tslib.es6.js';
|
|
2
1
|
import { SDKResource } from '../../client/client.js';
|
|
3
2
|
|
|
4
3
|
// AUTOGENERATED -- DO NOT EDIT
|
|
5
|
-
var _Charge_instances, _Charge_baseUrlThunk;
|
|
6
4
|
class Charge extends SDKResource {
|
|
7
5
|
constructor(config) {
|
|
8
6
|
super(config);
|
|
9
|
-
|
|
7
|
+
}
|
|
8
|
+
#baseUrlThunk() {
|
|
9
|
+
return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';
|
|
10
10
|
}
|
|
11
11
|
/**
|
|
12
12
|
* Charge patient's default payment method for a specified encounter or charge item.
|
|
@@ -20,7 +20,7 @@ class Charge extends SDKResource {
|
|
|
20
20
|
* Access Policy Resources: `FHIR:Patient:*,FHIR:Encounter:*,FHIR:Coverage:*`
|
|
21
21
|
*/
|
|
22
22
|
issue(params, request) {
|
|
23
|
-
return this.request('/payment/charge/issue', 'post',
|
|
23
|
+
return this.request('/payment/charge/issue', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
24
24
|
}
|
|
25
25
|
/**
|
|
26
26
|
* Retrieve charge status for a specified encounter or charge item.
|
|
@@ -34,13 +34,9 @@ class Charge extends SDKResource {
|
|
|
34
34
|
* Access Policy Resources: `FHIR:Patient:*,FHIR:Encounter:*,FHIR:Coverage:*`
|
|
35
35
|
*/
|
|
36
36
|
status(params, request) {
|
|
37
|
-
return this.request('/payment/charge/status', 'post',
|
|
37
|
+
return this.request('/payment/charge/status', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
|
-
_Charge_instances = new WeakSet(), _Charge_baseUrlThunk = function _Charge_baseUrlThunk() {
|
|
41
|
-
var _a, _b;
|
|
42
|
-
return (_b = (_a = this.config.services) === null || _a === void 0 ? void 0 : _a['projectApiUrl']) !== null && _b !== void 0 ? _b : 'https://project-api.zapehr.com/v1';
|
|
43
|
-
};
|
|
44
40
|
|
|
45
41
|
export { Charge };
|
|
46
42
|
//# sourceMappingURL=charge.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"charge.js","sources":["../../../../src/resources/classes/charge.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport { ChargeIssueParams, ChargeStatusParams, ChargeStatusResponse, OystehrClientRequest } from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Charge extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Charge patient's default payment method for a specified encounter or charge item.\n *\n * Access Policy Requirements:\n * Action: `Payment:Issue`\n * Access Policy Resource: `Payment:Charge`\n * Actions: `FHIR:Read,FHIR:Create,FHIR:Update`\n * Access Policy Resource: `FHIR:ChargeItem:*,`FHIR:PaymentReconciliation:*`\n * Action: `FHIR:Read`\n * Access Policy Resources: `FHIR:Patient:*,FHIR:Encounter:*,FHIR:Coverage:*`\n */\n issue(params: ChargeIssueParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/payment/charge/issue', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Retrieve charge status for a specified encounter or charge item.\n *\n * Access Policy Requirements:\n * Action: `Payment:Status`\n * Access Policy Resource: `Payment:Charge`\n * Actions: `FHIR:Read,FHIR:Create,FHIR:Update`\n * Access Policy Resource: `FHIR:ChargeItem:*,`FHIR:PaymentReconciliation:*`\n * Action: `FHIR:Read`\n * Access Policy Resources: `FHIR:Patient:*,FHIR:Encounter:*,FHIR:Coverage:*`\n */\n status(params: ChargeStatusParams, request?: OystehrClientRequest): Promise<ChargeStatusResponse> {\n return this.request('/payment/charge/status', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"charge.js","sources":["../../../../src/resources/classes/charge.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport { ChargeIssueParams, ChargeStatusParams, ChargeStatusResponse, OystehrClientRequest } from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Charge extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Charge patient's default payment method for a specified encounter or charge item.\n *\n * Access Policy Requirements:\n * Action: `Payment:Issue`\n * Access Policy Resource: `Payment:Charge`\n * Actions: `FHIR:Read,FHIR:Create,FHIR:Update`\n * Access Policy Resource: `FHIR:ChargeItem:*,`FHIR:PaymentReconciliation:*`\n * Action: `FHIR:Read`\n * Access Policy Resources: `FHIR:Patient:*,FHIR:Encounter:*,FHIR:Coverage:*`\n */\n issue(params: ChargeIssueParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/payment/charge/issue', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Retrieve charge status for a specified encounter or charge item.\n *\n * Access Policy Requirements:\n * Action: `Payment:Status`\n * Access Policy Resource: `Payment:Charge`\n * Actions: `FHIR:Read,FHIR:Create,FHIR:Update`\n * Access Policy Resource: `FHIR:ChargeItem:*,`FHIR:PaymentReconciliation:*`\n * Action: `FHIR:Read`\n * Access Policy Resources: `FHIR:Patient:*,FHIR:Encounter:*,FHIR:Coverage:*`\n */\n status(params: ChargeStatusParams, request?: OystehrClientRequest): Promise<ChargeStatusResponse> {\n return this.request('/payment/charge/status', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":";;AAAA;AAMM,MAAO,MAAO,SAAQ,WAAW,CAAA;AACrC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC,CAAC;KACf;IACD,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,eAAe,CAAC,IAAI,mCAAmC,CAAC;KACvF;AACD;;;;;;;;;;AAUG;IACH,KAAK,CAAC,MAAyB,EAAE,OAA8B,EAAA;QAC7D,OAAO,IAAI,CAAC,OAAO,CAAC,uBAAuB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACtG;AACD;;;;;;;;;;AAUG;IACH,MAAM,CAAC,MAA0B,EAAE,OAA8B,EAAA;QAC/D,OAAO,IAAI,CAAC,OAAO,CAAC,wBAAwB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACvG;AACF;;;;"}
|
|
@@ -10,17 +10,16 @@ function isR5Encounter(encounter) {
|
|
|
10
10
|
* @returns conversationId
|
|
11
11
|
*/
|
|
12
12
|
function getConversationIdFromEncounter(encounter) {
|
|
13
|
-
var _a, _b, _c;
|
|
14
13
|
if (isR5Encounter(encounter)) {
|
|
15
|
-
const virtualService =
|
|
16
|
-
return virtualService
|
|
14
|
+
const virtualService = encounter.virtualService?.find((vs) => vs.channelType?.system === ENCOUNTER_VS_CODING_SYSTEM);
|
|
15
|
+
return virtualService?.addressString;
|
|
17
16
|
}
|
|
18
17
|
if (!encounter.extension)
|
|
19
18
|
return;
|
|
20
19
|
const virtualServiceExtension = encounter.extension.find((extension) => extension.url === ENCOUNTER_VS_EXTENSION_URL);
|
|
21
|
-
if (!
|
|
20
|
+
if (!virtualServiceExtension?.extension)
|
|
22
21
|
return;
|
|
23
|
-
const conversationId =
|
|
22
|
+
const conversationId = virtualServiceExtension.extension?.find((extension) => extension.url === ENCOUNTER_VS_EXTENSION_RELATIVE_URL)?.valueString;
|
|
24
23
|
return conversationId;
|
|
25
24
|
}
|
|
26
25
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conversation-ext.js","sources":["../../../../src/resources/classes/conversation-ext.ts"],"sourcesContent":["import { Encounter as EncounterR4B } from 'fhir/r4b';\nimport { Encounter as EncounterR5 } from 'fhir/r5';\n\nexport const ENCOUNTER_VS_EXTENSION_URL = 'https://extensions.fhir.zapehr.com/encounter-virtual-service-pre-release';\nexport const ENCOUNTER_VS_EXTENSION_RELATIVE_URL = 'addressString';\nconst ENCOUNTER_VS_CODING_SYSTEM = 'https://fhir.zapehr.com/virtual-service-type';\n\nfunction isR5Encounter(encounter: EncounterR4B | EncounterR5): encounter is EncounterR5 {\n return Object.hasOwn(encounter as EncounterR5, 'virtualService');\n}\n\n/**\n * Helper function to get a conversationId from an encounter created as an Oystehr Conversation\n * @param encounter well-formed FHIR R4B or R5 Encounter\n * @returns conversationId\n */\nexport function getConversationIdFromEncounter(encounter: EncounterR4B | EncounterR5): string | undefined {\n if (isR5Encounter(encounter)) {\n const virtualService = encounter.virtualService?.find(\n (vs) => vs.channelType?.system === ENCOUNTER_VS_CODING_SYSTEM\n );\n return virtualService?.addressString;\n }\n if (!encounter.extension) return;\n const virtualServiceExtension = encounter.extension.find((extension) => extension.url === ENCOUNTER_VS_EXTENSION_URL);\n if (!virtualServiceExtension?.extension) return;\n const conversationId = virtualServiceExtension.extension?.find(\n (extension) => extension.url === ENCOUNTER_VS_EXTENSION_RELATIVE_URL\n )?.valueString;\n return conversationId;\n}\n"],"names":[],"mappings":"AAGO,MAAM,0BAA0B,GAAG,2EAA2E;AAC9G,MAAM,mCAAmC,GAAG,gBAAgB;AACnE,MAAM,0BAA0B,GAAG,8CAA8C,CAAC;AAElF,SAAS,aAAa,CAAC,SAAqC,EAAA;IAC1D,OAAO,MAAM,CAAC,MAAM,CAAC,SAAwB,EAAE,gBAAgB,CAAC,CAAC;AACnE,CAAC;AAED;;;;AAIG;AACG,SAAU,8BAA8B,CAAC,SAAqC,EAAA
|
|
1
|
+
{"version":3,"file":"conversation-ext.js","sources":["../../../../src/resources/classes/conversation-ext.ts"],"sourcesContent":["import { Encounter as EncounterR4B } from 'fhir/r4b';\nimport { Encounter as EncounterR5 } from 'fhir/r5';\n\nexport const ENCOUNTER_VS_EXTENSION_URL = 'https://extensions.fhir.zapehr.com/encounter-virtual-service-pre-release';\nexport const ENCOUNTER_VS_EXTENSION_RELATIVE_URL = 'addressString';\nconst ENCOUNTER_VS_CODING_SYSTEM = 'https://fhir.zapehr.com/virtual-service-type';\n\nfunction isR5Encounter(encounter: EncounterR4B | EncounterR5): encounter is EncounterR5 {\n return Object.hasOwn(encounter as EncounterR5, 'virtualService');\n}\n\n/**\n * Helper function to get a conversationId from an encounter created as an Oystehr Conversation\n * @param encounter well-formed FHIR R4B or R5 Encounter\n * @returns conversationId\n */\nexport function getConversationIdFromEncounter(encounter: EncounterR4B | EncounterR5): string | undefined {\n if (isR5Encounter(encounter)) {\n const virtualService = encounter.virtualService?.find(\n (vs) => vs.channelType?.system === ENCOUNTER_VS_CODING_SYSTEM\n );\n return virtualService?.addressString;\n }\n if (!encounter.extension) return;\n const virtualServiceExtension = encounter.extension.find((extension) => extension.url === ENCOUNTER_VS_EXTENSION_URL);\n if (!virtualServiceExtension?.extension) return;\n const conversationId = virtualServiceExtension.extension?.find(\n (extension) => extension.url === ENCOUNTER_VS_EXTENSION_RELATIVE_URL\n )?.valueString;\n return conversationId;\n}\n"],"names":[],"mappings":"AAGO,MAAM,0BAA0B,GAAG,2EAA2E;AAC9G,MAAM,mCAAmC,GAAG,gBAAgB;AACnE,MAAM,0BAA0B,GAAG,8CAA8C,CAAC;AAElF,SAAS,aAAa,CAAC,SAAqC,EAAA;IAC1D,OAAO,MAAM,CAAC,MAAM,CAAC,SAAwB,EAAE,gBAAgB,CAAC,CAAC;AACnE,CAAC;AAED;;;;AAIG;AACG,SAAU,8BAA8B,CAAC,SAAqC,EAAA;AAClF,IAAA,IAAI,aAAa,CAAC,SAAS,CAAC,EAAE;QAC5B,MAAM,cAAc,GAAG,SAAS,CAAC,cAAc,EAAE,IAAI,CACnD,CAAC,EAAE,KAAK,EAAE,CAAC,WAAW,EAAE,MAAM,KAAK,0BAA0B,CAC9D,CAAC;QACF,OAAO,cAAc,EAAE,aAAa,CAAC;KACtC;IACD,IAAI,CAAC,SAAS,CAAC,SAAS;QAAE,OAAO;AACjC,IAAA,MAAM,uBAAuB,GAAG,SAAS,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,SAAS,KAAK,SAAS,CAAC,GAAG,KAAK,0BAA0B,CAAC,CAAC;IACtH,IAAI,CAAC,uBAAuB,EAAE,SAAS;QAAE,OAAO;IAChD,MAAM,cAAc,GAAG,uBAAuB,CAAC,SAAS,EAAE,IAAI,CAC5D,CAAC,SAAS,KAAK,SAAS,CAAC,GAAG,KAAK,mCAAmC,CACrE,EAAE,WAAW,CAAC;AACf,IAAA,OAAO,cAAc,CAAC;AACxB;;;;"}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { __classPrivateFieldGet } from '../../node_modules/tslib/tslib.es6.js';
|
|
2
1
|
import { SDKResource } from '../../client/client.js';
|
|
3
2
|
import { ENCOUNTER_VS_EXTENSION_URL, ENCOUNTER_VS_EXTENSION_RELATIVE_URL, getConversationIdFromEncounter } from './conversation-ext.js';
|
|
4
3
|
|
|
5
4
|
// AUTOGENERATED -- DO NOT EDIT
|
|
6
|
-
var _Conversation_instances, _Conversation_baseUrlThunk;
|
|
7
5
|
class Conversation extends SDKResource {
|
|
8
6
|
constructor(config) {
|
|
9
7
|
super(config);
|
|
10
|
-
_Conversation_instances.add(this);
|
|
11
|
-
this.ENCOUNTER_VS_EXTENSION_URL = ENCOUNTER_VS_EXTENSION_URL;
|
|
12
|
-
this.ENCOUNTER_VS_EXTENSION_RELATIVE_URL = ENCOUNTER_VS_EXTENSION_RELATIVE_URL;
|
|
13
|
-
/**
|
|
14
|
-
* Helper function to get a conversationId from an encounter created as an Oystehr Conversation
|
|
15
|
-
* @param encounter well-formed FHIR R4B or R5 Encounter
|
|
16
|
-
* @returns conversationId
|
|
17
|
-
*/
|
|
18
|
-
this.getConversationIdFromEncounter = getConversationIdFromEncounter;
|
|
19
8
|
}
|
|
9
|
+
#baseUrlThunk() {
|
|
10
|
+
return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';
|
|
11
|
+
}
|
|
12
|
+
ENCOUNTER_VS_EXTENSION_URL = ENCOUNTER_VS_EXTENSION_URL;
|
|
13
|
+
ENCOUNTER_VS_EXTENSION_RELATIVE_URL = ENCOUNTER_VS_EXTENSION_RELATIVE_URL;
|
|
14
|
+
/**
|
|
15
|
+
* Helper function to get a conversationId from an encounter created as an Oystehr Conversation
|
|
16
|
+
* @param encounter well-formed FHIR R4B or R5 Encounter
|
|
17
|
+
* @returns conversationId
|
|
18
|
+
*/
|
|
19
|
+
getConversationIdFromEncounter = getConversationIdFromEncounter;
|
|
20
20
|
/**
|
|
21
21
|
* Create a new Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.
|
|
22
22
|
*
|
|
@@ -29,7 +29,7 @@ class Conversation extends SDKResource {
|
|
|
29
29
|
* Access Policy Resource: `FHIR:Encounter`
|
|
30
30
|
*/
|
|
31
31
|
create(params, request) {
|
|
32
|
-
return this.request('/messaging/conversation', 'post',
|
|
32
|
+
return this.request('/messaging/conversation', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
33
33
|
}
|
|
34
34
|
/**
|
|
35
35
|
* Get a Conversation Token. Conversation Tokens are used to join the Conversation with the Twilio Conversations SDKs. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.
|
|
@@ -38,7 +38,7 @@ class Conversation extends SDKResource {
|
|
|
38
38
|
* Access Policy Resource: `Messaging:Conversation`.
|
|
39
39
|
*/
|
|
40
40
|
getToken(request) {
|
|
41
|
-
return this.request('/messaging/conversation/token', 'get',
|
|
41
|
+
return this.request('/messaging/conversation/token', 'get', this.#baseUrlThunk.bind(this))(request);
|
|
42
42
|
}
|
|
43
43
|
/**
|
|
44
44
|
* Add a participant to a Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.
|
|
@@ -52,7 +52,7 @@ class Conversation extends SDKResource {
|
|
|
52
52
|
* Access Policy Resource: `FHIR:Encounter`
|
|
53
53
|
*/
|
|
54
54
|
addParticipant(params, request) {
|
|
55
|
-
return this.request('/messaging/conversation/{conversationId}/participant', 'post',
|
|
55
|
+
return this.request('/messaging/conversation/{conversationId}/participant', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
56
56
|
}
|
|
57
57
|
/**
|
|
58
58
|
* Remove a participant from a Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.
|
|
@@ -64,7 +64,7 @@ class Conversation extends SDKResource {
|
|
|
64
64
|
* Access Policy Resource: `FHIR:Patient`, `FHIR:Practitioner`, or `FHIR:RelatedPerson`
|
|
65
65
|
*/
|
|
66
66
|
removeParticipant(params, request) {
|
|
67
|
-
return this.request('/messaging/conversation/{conversationId}/participant', 'delete',
|
|
67
|
+
return this.request('/messaging/conversation/{conversationId}/participant', 'delete', this.#baseUrlThunk.bind(this))(params, request);
|
|
68
68
|
}
|
|
69
69
|
/**
|
|
70
70
|
* Send a message to a Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.
|
|
@@ -74,13 +74,9 @@ class Conversation extends SDKResource {
|
|
|
74
74
|
* Access Policy Resource: `Messaging:Conversation`
|
|
75
75
|
*/
|
|
76
76
|
message(params, request) {
|
|
77
|
-
return this.request('/messaging/conversation/{conversationId}/message', 'post',
|
|
77
|
+
return this.request('/messaging/conversation/{conversationId}/message', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
78
78
|
}
|
|
79
79
|
}
|
|
80
|
-
_Conversation_instances = new WeakSet(), _Conversation_baseUrlThunk = function _Conversation_baseUrlThunk() {
|
|
81
|
-
var _a, _b;
|
|
82
|
-
return (_b = (_a = this.config.services) === null || _a === void 0 ? void 0 : _a['projectApiUrl']) !== null && _b !== void 0 ? _b : 'https://project-api.zapehr.com/v1';
|
|
83
|
-
};
|
|
84
80
|
|
|
85
81
|
export { Conversation };
|
|
86
82
|
//# sourceMappingURL=conversation.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conversation.js","sources":["../../../../src/resources/classes/conversation.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n ConversationAddParticipantParams,\n ConversationCreateParams,\n ConversationCreateResponse,\n ConversationGetTokenResponse,\n ConversationMessageParams,\n ConversationRemoveParticipantParams,\n OystehrClientRequest,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './conversation-ext';\n\nexport class Conversation extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n ENCOUNTER_VS_EXTENSION_URL = ext.ENCOUNTER_VS_EXTENSION_URL;\n ENCOUNTER_VS_EXTENSION_RELATIVE_URL = ext.ENCOUNTER_VS_EXTENSION_RELATIVE_URL;\n /**\n * Helper function to get a conversationId from an encounter created as an Oystehr Conversation\n * @param encounter well-formed FHIR R4B or R5 Encounter\n * @returns conversationId\n */\n getConversationIdFromEncounter = ext.getConversationIdFromEncounter;\n /**\n * Create a new Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Requirements:\n * Action: `Messaging:CreateConversation`\n * Access Policy Resource: `Messaging:Conversation`\n * Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:Encounter`\n * Action: `FHIR:Update`\n * Access Policy Resource: `FHIR:Encounter`\n */\n create(params: ConversationCreateParams, request?: OystehrClientRequest): Promise<ConversationCreateResponse> {\n return this.request('/messaging/conversation', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get a Conversation Token. Conversation Tokens are used to join the Conversation with the Twilio Conversations SDKs. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Action: `Messaging:GetConversationToken`\n * Access Policy Resource: `Messaging:Conversation`.\n */\n getToken(request?: OystehrClientRequest): Promise<ConversationGetTokenResponse> {\n return this.request('/messaging/conversation/token', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Add a participant to a Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Requirements:\n * Action: `Messaging:ConversationAddParticipant`\n * Access Policy Resource: `Messaging:Conversation`\n * Action: `FHIR:Read`\n * Access Policy Resource: `FHIR:Encounter`\n * Action: `FHIR:Update`\n * Access Policy Resource: `FHIR:Encounter`\n */\n addParticipant(params: ConversationAddParticipantParams, request?: OystehrClientRequest): Promise<void> {\n return this.request(\n '/messaging/conversation/{conversationId}/participant',\n 'post',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Remove a participant from a Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Requirements:\n * Action: `Messaging:ConversationRemoveParticipant`\n * Access Policy Resource: `Messaging:Conversation`\n * Action: `FHIR:Read`\n * Access Policy Resource: `FHIR:Patient`, `FHIR:Practitioner`, or `FHIR:RelatedPerson`\n */\n removeParticipant(params: ConversationRemoveParticipantParams, request?: OystehrClientRequest): Promise<void> {\n return this.request(\n '/messaging/conversation/{conversationId}/participant',\n 'delete',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Send a message to a Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Requirements:\n * Action: `Messaging:ConversationSendMessage`\n * Access Policy Resource: `Messaging:Conversation`\n */\n message(params: ConversationMessageParams, request?: OystehrClientRequest): Promise<void> {\n return this.request(\n '/messaging/conversation/{conversationId}/message',\n 'post',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n}\n"],"names":["ext.ENCOUNTER_VS_EXTENSION_URL","ext.ENCOUNTER_VS_EXTENSION_RELATIVE_URL","ext.getConversationIdFromEncounter"],"mappings":"
|
|
1
|
+
{"version":3,"file":"conversation.js","sources":["../../../../src/resources/classes/conversation.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n ConversationAddParticipantParams,\n ConversationCreateParams,\n ConversationCreateResponse,\n ConversationGetTokenResponse,\n ConversationMessageParams,\n ConversationRemoveParticipantParams,\n OystehrClientRequest,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\nimport * as ext from './conversation-ext';\n\nexport class Conversation extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n ENCOUNTER_VS_EXTENSION_URL = ext.ENCOUNTER_VS_EXTENSION_URL;\n ENCOUNTER_VS_EXTENSION_RELATIVE_URL = ext.ENCOUNTER_VS_EXTENSION_RELATIVE_URL;\n /**\n * Helper function to get a conversationId from an encounter created as an Oystehr Conversation\n * @param encounter well-formed FHIR R4B or R5 Encounter\n * @returns conversationId\n */\n getConversationIdFromEncounter = ext.getConversationIdFromEncounter;\n /**\n * Create a new Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Requirements:\n * Action: `Messaging:CreateConversation`\n * Access Policy Resource: `Messaging:Conversation`\n * Action: `FHIR:Create`\n * Access Policy Resource: `FHIR:Encounter`\n * Action: `FHIR:Update`\n * Access Policy Resource: `FHIR:Encounter`\n */\n create(params: ConversationCreateParams, request?: OystehrClientRequest): Promise<ConversationCreateResponse> {\n return this.request('/messaging/conversation', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Get a Conversation Token. Conversation Tokens are used to join the Conversation with the Twilio Conversations SDKs. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Action: `Messaging:GetConversationToken`\n * Access Policy Resource: `Messaging:Conversation`.\n */\n getToken(request?: OystehrClientRequest): Promise<ConversationGetTokenResponse> {\n return this.request('/messaging/conversation/token', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Add a participant to a Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Requirements:\n * Action: `Messaging:ConversationAddParticipant`\n * Access Policy Resource: `Messaging:Conversation`\n * Action: `FHIR:Read`\n * Access Policy Resource: `FHIR:Encounter`\n * Action: `FHIR:Update`\n * Access Policy Resource: `FHIR:Encounter`\n */\n addParticipant(params: ConversationAddParticipantParams, request?: OystehrClientRequest): Promise<void> {\n return this.request(\n '/messaging/conversation/{conversationId}/participant',\n 'post',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Remove a participant from a Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Requirements:\n * Action: `Messaging:ConversationRemoveParticipant`\n * Access Policy Resource: `Messaging:Conversation`\n * Action: `FHIR:Read`\n * Access Policy Resource: `FHIR:Patient`, `FHIR:Practitioner`, or `FHIR:RelatedPerson`\n */\n removeParticipant(params: ConversationRemoveParticipantParams, request?: OystehrClientRequest): Promise<void> {\n return this.request(\n '/messaging/conversation/{conversationId}/participant',\n 'delete',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n /**\n * Send a message to a Conversation. [Conversations](https://docs.oystehr.com/oystehr/services/messaging/conversations/) allow you to build multi-channel bi-directional messaging workflows. For example, you might create a Conversation where a provider messages with a patient through a web app, and the patient receives and responds to messages via SMS on their phone.\n *\n * Access Policy Requirements:\n * Action: `Messaging:ConversationSendMessage`\n * Access Policy Resource: `Messaging:Conversation`\n */\n message(params: ConversationMessageParams, request?: OystehrClientRequest): Promise<void> {\n return this.request(\n '/messaging/conversation/{conversationId}/message',\n 'post',\n this.#baseUrlThunk.bind(this)\n )(params, request);\n }\n}\n"],"names":["ext.ENCOUNTER_VS_EXTENSION_URL","ext.ENCOUNTER_VS_EXTENSION_RELATIVE_URL","ext.getConversationIdFromEncounter"],"mappings":";;;AAAA;AAeM,MAAO,YAAa,SAAQ,WAAW,CAAA;AAC3C,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC,CAAC;KACf;IACD,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,eAAe,CAAC,IAAI,mCAAmC,CAAC;KACvF;AACD,IAAA,0BAA0B,GAAGA,0BAA8B,CAAC;AAC5D,IAAA,mCAAmC,GAAGC,mCAAuC,CAAC;AAC9E;;;;AAIG;AACH,IAAA,8BAA8B,GAAGC,8BAAkC,CAAC;AACpE;;;;;;;;;;AAUG;IACH,MAAM,CAAC,MAAgC,EAAE,OAA8B,EAAA;QACrE,OAAO,IAAI,CAAC,OAAO,CAAC,yBAAyB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACxG;AACD;;;;;AAKG;AACH,IAAA,QAAQ,CAAC,OAA8B,EAAA;QACrC,OAAO,IAAI,CAAC,OAAO,CAAC,+BAA+B,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;KACrG;AACD;;;;;;;;;;AAUG;IACH,cAAc,CAAC,MAAwC,EAAE,OAA8B,EAAA;QACrF,OAAO,IAAI,CAAC,OAAO,CACjB,sDAAsD,EACtD,MAAM,EACN,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAC9B,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACpB;AACD;;;;;;;;AAQG;IACH,iBAAiB,CAAC,MAA2C,EAAE,OAA8B,EAAA;QAC3F,OAAO,IAAI,CAAC,OAAO,CACjB,sDAAsD,EACtD,QAAQ,EACR,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAC9B,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACpB;AACD;;;;;;AAMG;IACH,OAAO,CAAC,MAAiC,EAAE,OAA8B,EAAA;QACvE,OAAO,IAAI,CAAC,OAAO,CACjB,kDAAkD,EAClD,MAAM,EACN,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAC9B,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACpB;AACF;;;;"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { __classPrivateFieldGet } from '../../node_modules/tslib/tslib.es6.js';
|
|
2
1
|
import { SDKResource } from '../../client/client.js';
|
|
3
2
|
|
|
4
3
|
// AUTOGENERATED -- DO NOT EDIT
|
|
5
|
-
var _Developer_instances, _Developer_baseUrlThunk;
|
|
6
4
|
class Developer extends SDKResource {
|
|
7
5
|
constructor(config) {
|
|
8
6
|
super(config);
|
|
9
|
-
|
|
7
|
+
}
|
|
8
|
+
#baseUrlThunk() {
|
|
9
|
+
return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';
|
|
10
10
|
}
|
|
11
11
|
/**
|
|
12
12
|
* Get the Developer with the provided ID. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.
|
|
@@ -15,7 +15,7 @@ class Developer extends SDKResource {
|
|
|
15
15
|
* Access Policy Resource: `IAM:Developer`
|
|
16
16
|
*/
|
|
17
17
|
get(params, request) {
|
|
18
|
-
return this.request('/developer/{id}', 'get',
|
|
18
|
+
return this.request('/developer/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
19
19
|
}
|
|
20
20
|
/**
|
|
21
21
|
* Update the Developer with the provided ID. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.
|
|
@@ -24,7 +24,7 @@ class Developer extends SDKResource {
|
|
|
24
24
|
* Access Policy Resource: `IAM:Developer`
|
|
25
25
|
*/
|
|
26
26
|
update(params, request) {
|
|
27
|
-
return this.request('/developer/{id}', 'patch',
|
|
27
|
+
return this.request('/developer/{id}', 'patch', this.#baseUrlThunk.bind(this))(params, request);
|
|
28
28
|
}
|
|
29
29
|
/**
|
|
30
30
|
* Remove the Developer with the provided ID from the project. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.
|
|
@@ -33,7 +33,7 @@ class Developer extends SDKResource {
|
|
|
33
33
|
* Access Policy Resource: `IAM:Developer`
|
|
34
34
|
*/
|
|
35
35
|
delete(params, request) {
|
|
36
|
-
return this.request('/developer/{id}', 'delete',
|
|
36
|
+
return this.request('/developer/{id}', 'delete', this.#baseUrlThunk.bind(this))(params, request);
|
|
37
37
|
}
|
|
38
38
|
/**
|
|
39
39
|
* Invite a new Developer to the Project. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.
|
|
@@ -42,7 +42,7 @@ class Developer extends SDKResource {
|
|
|
42
42
|
* Access Policy Resource: `IAM:Developer`
|
|
43
43
|
*/
|
|
44
44
|
invite(params, request) {
|
|
45
|
-
return this.request('/developer/invite', 'post',
|
|
45
|
+
return this.request('/developer/invite', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
46
46
|
}
|
|
47
47
|
/**
|
|
48
48
|
* DEPRECATED. Please use [v2/list](https://api-reference.oystehr.com/reference/get_developer-v2-list) instead.
|
|
@@ -53,7 +53,7 @@ class Developer extends SDKResource {
|
|
|
53
53
|
* Access Policy Resource: `IAM:Developer`
|
|
54
54
|
*/
|
|
55
55
|
list(request) {
|
|
56
|
-
return this.request('/developer', 'get',
|
|
56
|
+
return this.request('/developer', 'get', this.#baseUrlThunk.bind(this))(request);
|
|
57
57
|
}
|
|
58
58
|
/**
|
|
59
59
|
* Get Developers in the Project with pagination, sort, sort order and filtering. [Users](https://docs.oystehr.com/oystehr/services/app/users/) are the people who log into the [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) you configure for securing the apps you build on top of Oystehr.
|
|
@@ -62,13 +62,9 @@ class Developer extends SDKResource {
|
|
|
62
62
|
* Access Policy Resource: `Project:Settings`
|
|
63
63
|
*/
|
|
64
64
|
listV2(params, request) {
|
|
65
|
-
return this.request('/developer/v2/list', 'get',
|
|
65
|
+
return this.request('/developer/v2/list', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
|
-
_Developer_instances = new WeakSet(), _Developer_baseUrlThunk = function _Developer_baseUrlThunk() {
|
|
69
|
-
var _a, _b;
|
|
70
|
-
return (_b = (_a = this.config.services) === null || _a === void 0 ? void 0 : _a['projectApiUrl']) !== null && _b !== void 0 ? _b : 'https://project-api.zapehr.com/v1';
|
|
71
|
-
};
|
|
72
68
|
|
|
73
69
|
export { Developer };
|
|
74
70
|
//# sourceMappingURL=developer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"developer.js","sources":["../../../../src/resources/classes/developer.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n DeveloperDeleteParams,\n DeveloperGetParams,\n DeveloperGetResponse,\n DeveloperInviteParams,\n DeveloperInviteResponse,\n DeveloperListResponse,\n DeveloperListV2Params,\n DeveloperListV2Response,\n DeveloperUpdateParams,\n DeveloperUpdateResponse,\n OystehrClientRequest,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Developer extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Get the Developer with the provided ID. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:GetDeveloper`\n * Access Policy Resource: `IAM:Developer`\n */\n get(params: DeveloperGetParams, request?: OystehrClientRequest): Promise<DeveloperGetResponse> {\n return this.request('/developer/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Update the Developer with the provided ID. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:UpdateDeveloper`\n * Access Policy Resource: `IAM:Developer`\n */\n update(params: DeveloperUpdateParams, request?: OystehrClientRequest): Promise<DeveloperUpdateResponse> {\n return this.request('/developer/{id}', 'patch', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Remove the Developer with the provided ID from the project. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:RemoveDeveloper`\n * Access Policy Resource: `IAM:Developer`\n */\n delete(params: DeveloperDeleteParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/developer/{id}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Invite a new Developer to the Project. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:InviteDeveloper`\n * Access Policy Resource: `IAM:Developer`\n */\n invite(params: DeveloperInviteParams, request?: OystehrClientRequest): Promise<DeveloperInviteResponse> {\n return this.request('/developer/invite', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * DEPRECATED. Please use [v2/list](https://api-reference.oystehr.com/reference/get_developer-v2-list) instead.\n *\n * Get a list of all Developers who are part of the Project. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:ListAllDevelopers`\n * Access Policy Resource: `IAM:Developer`\n */\n list(request?: OystehrClientRequest): Promise<DeveloperListResponse> {\n return this.request('/developer', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Get Developers in the Project with pagination, sort, sort order and filtering. [Users](https://docs.oystehr.com/oystehr/services/app/users/) are the people who log into the [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) you configure for securing the apps you build on top of Oystehr.\n *\n * Access Policy Action: `Project:ListAllUsers`\n * Access Policy Resource: `Project:Settings`\n */\n listV2(params: DeveloperListV2Params, request?: OystehrClientRequest): Promise<DeveloperListV2Response>;\n /**\n * Get Developers in the Project with pagination, sort, sort order and filtering. [Users](https://docs.oystehr.com/oystehr/services/app/users/) are the people who log into the [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) you configure for securing the apps you build on top of Oystehr.\n *\n * Access Policy Action: `Project:ListAllUsers`\n * Access Policy Resource: `Project:Settings`\n */\n listV2(request?: OystehrClientRequest): Promise<DeveloperListV2Response>;\n /**\n * Get Developers in the Project with pagination, sort, sort order and filtering. [Users](https://docs.oystehr.com/oystehr/services/app/users/) are the people who log into the [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) you configure for securing the apps you build on top of Oystehr.\n *\n * Access Policy Action: `Project:ListAllUsers`\n * Access Policy Resource: `Project:Settings`\n */\n listV2(\n params?: DeveloperListV2Params | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<DeveloperListV2Response> {\n return this.request('/developer/v2/list', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"developer.js","sources":["../../../../src/resources/classes/developer.ts"],"sourcesContent":["// AUTOGENERATED -- DO NOT EDIT\n\nimport {\n DeveloperDeleteParams,\n DeveloperGetParams,\n DeveloperGetResponse,\n DeveloperInviteParams,\n DeveloperInviteResponse,\n DeveloperListResponse,\n DeveloperListV2Params,\n DeveloperListV2Response,\n DeveloperUpdateParams,\n DeveloperUpdateResponse,\n OystehrClientRequest,\n} from '../..';\nimport { SDKResource } from '../../client/client';\nimport { OystehrConfig } from '../../config';\n\nexport class Developer extends SDKResource {\n constructor(config: OystehrConfig) {\n super(config);\n }\n #baseUrlThunk(): string {\n return this.config.services?.['projectApiUrl'] ?? 'https://project-api.zapehr.com/v1';\n }\n /**\n * Get the Developer with the provided ID. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:GetDeveloper`\n * Access Policy Resource: `IAM:Developer`\n */\n get(params: DeveloperGetParams, request?: OystehrClientRequest): Promise<DeveloperGetResponse> {\n return this.request('/developer/{id}', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Update the Developer with the provided ID. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:UpdateDeveloper`\n * Access Policy Resource: `IAM:Developer`\n */\n update(params: DeveloperUpdateParams, request?: OystehrClientRequest): Promise<DeveloperUpdateResponse> {\n return this.request('/developer/{id}', 'patch', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Remove the Developer with the provided ID from the project. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:RemoveDeveloper`\n * Access Policy Resource: `IAM:Developer`\n */\n delete(params: DeveloperDeleteParams, request?: OystehrClientRequest): Promise<void> {\n return this.request('/developer/{id}', 'delete', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * Invite a new Developer to the Project. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:InviteDeveloper`\n * Access Policy Resource: `IAM:Developer`\n */\n invite(params: DeveloperInviteParams, request?: OystehrClientRequest): Promise<DeveloperInviteResponse> {\n return this.request('/developer/invite', 'post', this.#baseUrlThunk.bind(this))(params, request);\n }\n /**\n * DEPRECATED. Please use [v2/list](https://api-reference.oystehr.com/reference/get_developer-v2-list) instead.\n *\n * Get a list of all Developers who are part of the Project. Developer accounts are used to log into the [Developer Console](https://console.oystehr.com/) and administrate [Projects](https://docs.oystehr.com/oystehr/services/project/). [Developers](https://docs.oystehr.com/oystehr/services/iam/developers/) are the only people who can belong to and act across multiple Projects, because they exist above the Project level.\n *\n * Access Policy Action: `IAM:ListAllDevelopers`\n * Access Policy Resource: `IAM:Developer`\n */\n list(request?: OystehrClientRequest): Promise<DeveloperListResponse> {\n return this.request('/developer', 'get', this.#baseUrlThunk.bind(this))(request);\n }\n /**\n * Get Developers in the Project with pagination, sort, sort order and filtering. [Users](https://docs.oystehr.com/oystehr/services/app/users/) are the people who log into the [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) you configure for securing the apps you build on top of Oystehr.\n *\n * Access Policy Action: `Project:ListAllUsers`\n * Access Policy Resource: `Project:Settings`\n */\n listV2(params: DeveloperListV2Params, request?: OystehrClientRequest): Promise<DeveloperListV2Response>;\n /**\n * Get Developers in the Project with pagination, sort, sort order and filtering. [Users](https://docs.oystehr.com/oystehr/services/app/users/) are the people who log into the [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) you configure for securing the apps you build on top of Oystehr.\n *\n * Access Policy Action: `Project:ListAllUsers`\n * Access Policy Resource: `Project:Settings`\n */\n listV2(request?: OystehrClientRequest): Promise<DeveloperListV2Response>;\n /**\n * Get Developers in the Project with pagination, sort, sort order and filtering. [Users](https://docs.oystehr.com/oystehr/services/app/users/) are the people who log into the [Applications](https://docs.oystehr.com/oystehr/services/app/applications/) you configure for securing the apps you build on top of Oystehr.\n *\n * Access Policy Action: `Project:ListAllUsers`\n * Access Policy Resource: `Project:Settings`\n */\n listV2(\n params?: DeveloperListV2Params | OystehrClientRequest,\n request?: OystehrClientRequest\n ): Promise<DeveloperListV2Response> {\n return this.request('/developer/v2/list', 'get', this.#baseUrlThunk.bind(this))(params, request);\n }\n}\n"],"names":[],"mappings":";;AAAA;AAkBM,MAAO,SAAU,SAAQ,WAAW,CAAA;AACxC,IAAA,WAAA,CAAY,MAAqB,EAAA;QAC/B,KAAK,CAAC,MAAM,CAAC,CAAC;KACf;IACD,aAAa,GAAA;QACX,OAAO,IAAI,CAAC,MAAM,CAAC,QAAQ,GAAG,eAAe,CAAC,IAAI,mCAAmC,CAAC;KACvF;AACD;;;;;AAKG;IACH,GAAG,CAAC,MAA0B,EAAE,OAA8B,EAAA;QAC5D,OAAO,IAAI,CAAC,OAAO,CAAC,iBAAiB,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KAC/F;AACD;;;;;AAKG;IACH,MAAM,CAAC,MAA6B,EAAE,OAA8B,EAAA;QAClE,OAAO,IAAI,CAAC,OAAO,CAAC,iBAAiB,EAAE,OAAO,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KACjG;AACD;;;;;AAKG;IACH,MAAM,CAAC,MAA6B,EAAE,OAA8B,EAAA;QAClE,OAAO,IAAI,CAAC,OAAO,CAAC,iBAAiB,EAAE,QAAQ,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KAClG;AACD;;;;;AAKG;IACH,MAAM,CAAC,MAA6B,EAAE,OAA8B,EAAA;QAClE,OAAO,IAAI,CAAC,OAAO,CAAC,mBAAmB,EAAE,MAAM,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KAClG;AACD;;;;;;;AAOG;AACH,IAAA,IAAI,CAAC,OAA8B,EAAA;QACjC,OAAO,IAAI,CAAC,OAAO,CAAC,YAAY,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;KAClF;AAeD;;;;;AAKG;IACH,MAAM,CACJ,MAAqD,EACrD,OAA8B,EAAA;QAE9B,OAAO,IAAI,CAAC,OAAO,CAAC,oBAAoB,EAAE,KAAK,EAAE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;KAClG;AACF;;;;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ErxCancelPrescriptionParams, ErxCheckAllergyInteractionsParams, ErxCheckAllergyInteractionsResponse, ErxCheckMedicationInteractionsParams, ErxCheckMedicationInteractionsResponse, ErxCheckPractitionerEnrollmentParams, ErxCheckPractitionerEnrollmentResponse, ErxCheckPrecheckInteractionsParams, ErxCheckPrecheckInteractionsResponse, ErxConnectPractitionerParams, ErxConnectPractitionerResponse, ErxEnrollPractitionerParams, ErxSearchAllergensParams, ErxSearchAllergensResponse, ErxSearchMedicationsParams, ErxSearchMedicationsResponse, ErxSyncPatientParams, ErxUnenrollPractitionerParams, OystehrClientRequest } from '../..';
|
|
1
|
+
import { ErxCancelPrescriptionParams, ErxCheckAllergyInteractionsParams, ErxCheckAllergyInteractionsResponse, ErxCheckMedicationInteractionsParams, ErxCheckMedicationInteractionsResponse, ErxCheckPractitionerEnrollmentParams, ErxCheckPractitionerEnrollmentResponse, ErxCheckPrecheckInteractionsParams, ErxCheckPrecheckInteractionsResponse, ErxConnectPractitionerParams, ErxConnectPractitionerResponse, ErxEnrollPractitionerParams, ErxGetConfigurationResponse, ErxSearchAllergensParams, ErxSearchAllergensResponse, ErxSearchMedicationsParams, ErxSearchMedicationsResponse, ErxSyncPatientParams, ErxUnenrollPractitionerParams, OystehrClientRequest } from '../..';
|
|
2
2
|
import { SDKResource } from '../../client/client';
|
|
3
3
|
import { OystehrConfig } from '../../config';
|
|
4
4
|
export declare class Erx extends SDKResource {
|
|
@@ -12,6 +12,10 @@ export declare class Erx extends SDKResource {
|
|
|
12
12
|
* Search for medications.
|
|
13
13
|
*/
|
|
14
14
|
searchMedications(params: ErxSearchMedicationsParams, request?: OystehrClientRequest): Promise<ErxSearchMedicationsResponse>;
|
|
15
|
+
/**
|
|
16
|
+
* Get eRx configuration for project.
|
|
17
|
+
*/
|
|
18
|
+
getConfiguration(request?: OystehrClientRequest): Promise<ErxGetConfigurationResponse>;
|
|
15
19
|
/**
|
|
16
20
|
* Checks for drug-allergy interactions for a patient. This endpoint requires the patient's allergies to be synced with the upstream eRx provider.
|
|
17
21
|
*/
|
|
@@ -1,84 +1,86 @@
|
|
|
1
|
-
import { __classPrivateFieldGet } from '../../node_modules/tslib/tslib.es6.js';
|
|
2
1
|
import { SDKResource } from '../../client/client.js';
|
|
3
2
|
|
|
4
3
|
// AUTOGENERATED -- DO NOT EDIT
|
|
5
|
-
var _Erx_instances, _Erx_baseUrlThunk;
|
|
6
4
|
class Erx extends SDKResource {
|
|
7
5
|
constructor(config) {
|
|
8
6
|
super(config);
|
|
9
|
-
|
|
7
|
+
}
|
|
8
|
+
#baseUrlThunk() {
|
|
9
|
+
return this.config.services?.['erxApiUrl'] ?? 'https://erx-api.zapehr.com/v3';
|
|
10
10
|
}
|
|
11
11
|
/**
|
|
12
12
|
* Search for allergens.
|
|
13
13
|
*/
|
|
14
14
|
searchAllergens(params, request) {
|
|
15
|
-
return this.request('/allergen', 'get',
|
|
15
|
+
return this.request('/allergen', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
16
16
|
}
|
|
17
17
|
/**
|
|
18
18
|
* Search for medications.
|
|
19
19
|
*/
|
|
20
20
|
searchMedications(params, request) {
|
|
21
|
-
return this.request('/medication', 'get',
|
|
21
|
+
return this.request('/medication', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Get eRx configuration for project.
|
|
25
|
+
*/
|
|
26
|
+
getConfiguration(request) {
|
|
27
|
+
return this.request('/config', 'get', this.#baseUrlThunk.bind(this))(request);
|
|
22
28
|
}
|
|
23
29
|
/**
|
|
24
30
|
* Checks for drug-allergy interactions for a patient. This endpoint requires the patient's allergies to be synced with the upstream eRx provider.
|
|
25
31
|
*/
|
|
26
32
|
checkAllergyInteractions(params, request) {
|
|
27
|
-
return this.request('/patient/{patientId}/interactions/allergy', 'get',
|
|
33
|
+
return this.request('/patient/{patientId}/interactions/allergy', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
28
34
|
}
|
|
29
35
|
/**
|
|
30
36
|
* Checks for drug-drug interactions for a patient. This endpoint requires the patient's medications to be synced with the upstream eRx provider.
|
|
31
37
|
*/
|
|
32
38
|
checkMedicationInteractions(params, request) {
|
|
33
|
-
return this.request('/patient/{patientId}/interactions/medication', 'get',
|
|
39
|
+
return this.request('/patient/{patientId}/interactions/medication', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
34
40
|
}
|
|
35
41
|
/**
|
|
36
42
|
* Checks for drug-allergy and drug-drug interactions with a specific drug for a patient. This endpoint requires the patient's allergies and medications to be synced with the upstream eRx provider.
|
|
37
43
|
*/
|
|
38
44
|
checkPrecheckInteractions(params, request) {
|
|
39
|
-
return this.request('/patient/{patientId}/interactions/precheck/{drugId}', 'get',
|
|
45
|
+
return this.request('/patient/{patientId}/interactions/precheck/{drugId}', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
40
46
|
}
|
|
41
47
|
/**
|
|
42
48
|
* Cancel prescription for patient.
|
|
43
49
|
*/
|
|
44
50
|
cancelPrescription(params, request) {
|
|
45
|
-
return this.request('/patient/{patientId}/prescriptions/{medicationRequestId}', 'delete',
|
|
51
|
+
return this.request('/patient/{patientId}/prescriptions/{medicationRequestId}', 'delete', this.#baseUrlThunk.bind(this))(params, request);
|
|
46
52
|
}
|
|
47
53
|
/**
|
|
48
54
|
* Syncs demographic, allergy, and medication data for a patient with the upstream eRx provider.
|
|
49
55
|
*/
|
|
50
56
|
syncPatient(params, request) {
|
|
51
|
-
return this.request('/patient/{patientId}/sync', 'post',
|
|
57
|
+
return this.request('/patient/{patientId}/sync', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
52
58
|
}
|
|
53
59
|
/**
|
|
54
60
|
* Create an SSO link for a practitioner. This link can be used to log in to the eRx service as the specified practitioner.
|
|
55
61
|
*/
|
|
56
62
|
connectPractitioner(params, request) {
|
|
57
|
-
return this.request('/practitioner/connect', 'get',
|
|
63
|
+
return this.request('/practitioner/connect', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
58
64
|
}
|
|
59
65
|
/**
|
|
60
66
|
* Check eRx enrollment for a practitioner.
|
|
61
67
|
*/
|
|
62
68
|
checkPractitionerEnrollment(params, request) {
|
|
63
|
-
return this.request('/practitioner/{practitionerId}', 'get',
|
|
69
|
+
return this.request('/practitioner/{practitionerId}', 'get', this.#baseUrlThunk.bind(this))(params, request);
|
|
64
70
|
}
|
|
65
71
|
/**
|
|
66
72
|
* Enroll a practitioner in the eRx service.
|
|
67
73
|
*/
|
|
68
74
|
enrollPractitioner(params, request) {
|
|
69
|
-
return this.request('/practitioner/{practitionerId}', 'post',
|
|
75
|
+
return this.request('/practitioner/{practitionerId}', 'post', this.#baseUrlThunk.bind(this))(params, request);
|
|
70
76
|
}
|
|
71
77
|
/**
|
|
72
78
|
* Unenroll a practitioner from the eRx service.
|
|
73
79
|
*/
|
|
74
80
|
unenrollPractitioner(params, request) {
|
|
75
|
-
return this.request('/practitioner/{practitionerId}', 'delete',
|
|
81
|
+
return this.request('/practitioner/{practitionerId}', 'delete', this.#baseUrlThunk.bind(this))(params, request);
|
|
76
82
|
}
|
|
77
83
|
}
|
|
78
|
-
_Erx_instances = new WeakSet(), _Erx_baseUrlThunk = function _Erx_baseUrlThunk() {
|
|
79
|
-
var _a, _b;
|
|
80
|
-
return (_b = (_a = this.config.services) === null || _a === void 0 ? void 0 : _a['erxApiUrl']) !== null && _b !== void 0 ? _b : 'https://erx-api.zapehr.com/v3';
|
|
81
|
-
};
|
|
82
84
|
|
|
83
85
|
export { Erx };
|
|
84
86
|
//# sourceMappingURL=erx.js.map
|