@awell-health/awell-extensions 1.0.216 → 1.0.218
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/extensions/athenahealth/actions/createAppointmentNote/createAppointmentNote.js +17 -2
- package/dist/extensions/athenahealth/actions/createAppointmentNote/createAppointmentNote.js.map +1 -1
- package/dist/extensions/athenahealth/api/client.d.ts +3 -2
- package/dist/extensions/athenahealth/api/client.js +1 -1
- package/dist/extensions/athenahealth/api/client.js.map +1 -1
- package/dist/extensions/athenahealth/api/schema/appointment.d.ts +3 -0
- package/dist/extensions/athenahealth/api/schema/appointment.js.map +1 -1
- package/dist/extensions/markdown.json +1 -1
- package/package.json +1 -1
@@ -18,12 +18,27 @@ exports.createAppointmentNote = {
|
|
18
18
|
fieldsSchema: config_1.FieldsValidationSchema,
|
19
19
|
payload,
|
20
20
|
});
|
21
|
-
await client.createAppointmentNote({
|
21
|
+
const res = await client.createAppointmentNote({
|
22
22
|
practiceId,
|
23
23
|
appointmentId: input.appointmentid,
|
24
24
|
data: (0, lodash_1.omit)(input, ['appointmentid']),
|
25
25
|
});
|
26
|
-
|
26
|
+
if (res.success === 'true') {
|
27
|
+
await onComplete();
|
28
|
+
return;
|
29
|
+
}
|
30
|
+
await onError({
|
31
|
+
events: [
|
32
|
+
{
|
33
|
+
date: new Date().toISOString(),
|
34
|
+
text: { en: 'Unable to create the appointment note' },
|
35
|
+
error: {
|
36
|
+
category: 'SERVER_ERROR',
|
37
|
+
message: 'Unable to create the appointment note',
|
38
|
+
},
|
39
|
+
},
|
40
|
+
],
|
41
|
+
});
|
27
42
|
},
|
28
43
|
};
|
29
44
|
//# sourceMappingURL=createAppointmentNote.js.map
|
package/dist/extensions/athenahealth/actions/createAppointmentNote/createAppointmentNote.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"createAppointmentNote.js","sourceRoot":"","sources":["../../../../../extensions/athenahealth/actions/createAppointmentNote/createAppointmentNote.ts"],"names":[],"mappings":";;;AAAA,mEAAqE;AAErE,qCAAqE;AACrE,2CAA8D;AAC9D,mCAA6B;AAEhB,QAAA,qBAAqB,GAI9B;IACF,GAAG,EAAE,uBAAuB;IAC5B,QAAQ,EAAE,0BAAQ,CAAC,gBAAgB;IACnC,KAAK,EAAE,yBAAyB;IAChC,WAAW,EAAE,2CAA2C;IACxD,MAAM,EAAN,eAAM;IACN,WAAW,EAAE,KAAK;IAClB,UAAU,EAAV,mBAAU;IACV,iBAAiB,EAAE,KAAK,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAiB,EAAE;QACvE,MAAM,EACJ,MAAM,EAAE,KAAK,EACb,MAAM,EACN,QAAQ,EAAE,EAAE,UAAU,EAAE,GACzB,GAAG,MAAM,IAAA,wCAA8B,EAAC;YACvC,YAAY,EAAE,+BAAsB;YACpC,OAAO;SACR,CAAC,CAAA;QAEF,MAAM,MAAM,CAAC,qBAAqB,CAAC;
|
1
|
+
{"version":3,"file":"createAppointmentNote.js","sourceRoot":"","sources":["../../../../../extensions/athenahealth/actions/createAppointmentNote/createAppointmentNote.ts"],"names":[],"mappings":";;;AAAA,mEAAqE;AAErE,qCAAqE;AACrE,2CAA8D;AAC9D,mCAA6B;AAEhB,QAAA,qBAAqB,GAI9B;IACF,GAAG,EAAE,uBAAuB;IAC5B,QAAQ,EAAE,0BAAQ,CAAC,gBAAgB;IACnC,KAAK,EAAE,yBAAyB;IAChC,WAAW,EAAE,2CAA2C;IACxD,MAAM,EAAN,eAAM;IACN,WAAW,EAAE,KAAK;IAClB,UAAU,EAAV,mBAAU;IACV,iBAAiB,EAAE,KAAK,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAiB,EAAE;QACvE,MAAM,EACJ,MAAM,EAAE,KAAK,EACb,MAAM,EACN,QAAQ,EAAE,EAAE,UAAU,EAAE,GACzB,GAAG,MAAM,IAAA,wCAA8B,EAAC;YACvC,YAAY,EAAE,+BAAsB;YACpC,OAAO;SACR,CAAC,CAAA;QAEF,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,qBAAqB,CAAC;YAC7C,UAAU;YACV,aAAa,EAAE,KAAK,CAAC,aAAa;YAClC,IAAI,EAAE,IAAA,aAAI,EAAC,KAAK,EAAE,CAAC,eAAe,CAAC,CAAC;SACrC,CAAC,CAAA;QAEF,IAAI,GAAG,CAAC,OAAO,KAAK,MAAM,EAAE;YAC1B,MAAM,UAAU,EAAE,CAAA;YAClB,OAAM;SACP;QAED,MAAM,OAAO,CAAC;YACZ,MAAM,EAAE;gBACN;oBACE,IAAI,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE;oBAC9B,IAAI,EAAE,EAAE,EAAE,EAAE,uCAAuC,EAAE;oBACrD,KAAK,EAAE;wBACL,QAAQ,EAAE,cAAc;wBACxB,OAAO,EAAE,uCAAuC;qBACjD;iBACF;aACF;SACF,CAAC,CAAA;IACJ,CAAC;CACF,CAAA"}
|
@@ -2,6 +2,7 @@ import { APIClient, DataWrapper, type DataWrapperCtor, type OAuthGrantClientCred
|
|
2
2
|
import { type CreateAppointmentNoteInputType } from '../actions/createAppointmentNote/config/fields';
|
3
3
|
import { type CreatePatientInputType } from '../actions/createPatient/config/fields';
|
4
4
|
import { type PatientSchemaType, type AppointmentSchemaType } from './schema';
|
5
|
+
import { type CreateAppointmentNoteResponseType } from './schema/appointment';
|
5
6
|
import { type CreatePatientResponseType } from './schema/patient';
|
6
7
|
export declare class AthenaDataWrapper extends DataWrapper {
|
7
8
|
createPatient({ practiceId, data, }: {
|
@@ -20,7 +21,7 @@ export declare class AthenaDataWrapper extends DataWrapper {
|
|
20
21
|
practiceId: string;
|
21
22
|
appointmentId: string;
|
22
23
|
data: Omit<CreateAppointmentNoteInputType, 'practiceid' | 'appointmentid'>;
|
23
|
-
}): Promise<
|
24
|
+
}): Promise<CreateAppointmentNoteResponseType>;
|
24
25
|
}
|
25
26
|
interface AthenaClientConstructorProps {
|
26
27
|
authUrl: string;
|
@@ -46,6 +47,6 @@ export declare class AthenaAPIClient extends APIClient<AthenaDataWrapper> {
|
|
46
47
|
practiceId: string;
|
47
48
|
appointmentId: string;
|
48
49
|
data: Omit<CreateAppointmentNoteInputType, 'practiceid' | 'appointmentid'>;
|
49
|
-
}): Promise<
|
50
|
+
}): Promise<CreateAppointmentNoteResponseType>;
|
50
51
|
}
|
51
52
|
export {};
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../../../extensions/athenahealth/api/client.ts"],"names":[],"mappings":";;;AAAA,mEAMsC;AAGtC,iDAA6C;
|
1
|
+
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../../../extensions/athenahealth/api/client.ts"],"names":[],"mappings":";;;AAAA,mEAMsC;AAGtC,iDAA6C;AAK7C,MAAa,iBAAkB,SAAQ,6BAAW;IACzC,KAAK,CAAC,aAAa,CAAC,EACzB,UAAU,EACV,IAAI,GAIL;QACC,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,OAAO,CAA8B;YAC7D,MAAM,EAAE,MAAM;YACd,GAAG,EAAE,OAAO,UAAU,WAAW;YACjC,OAAO,EAAE,EAAE,cAAc,EAAE,mCAAmC,EAAE;YAChE,IAAI;SACL,CAAC,CAAA;QAEF,OAAO,MAAM,CAAC,CAAC,CAAC,CAAA;IAClB,CAAC;IAEM,KAAK,CAAC,UAAU,CAAC,EACtB,UAAU,EACV,SAAS,GAIV;QACC,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,OAAO,CAAsB;YACrD,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,OAAO,UAAU,aAAa,SAAS,EAAE;SAC/C,CAAC,CAAA;QAEF,OAAO,MAAM,CAAC,CAAC,CAAC,CAAA;IAClB,CAAC;IAEM,KAAK,CAAC,cAAc,CAAC,EAC1B,UAAU,EACV,aAAa,GAId;QACC,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,OAAO,CAA0B;YACzD,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,OAAO,UAAU,iBAAiB,aAAa,EAAE;SACvD,CAAC,CAA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AAA;IACH,CAAC;IAEM,KAAK,CAAC,cAAc,CAAC,EAC1B,UAAU,EACV,aAAa,GAId;QACC,OAAO,MAAM,IAAI,CAAC,SAAS,CACzB,KAAK,EAAE,EAAE,EAAE,EAAE,CAAC,MAAM,EAAE,CAAC,cAAc,CAAC,EAAE,aAAa,EAAE,UAAU,EAAE,CAAC,CACrE,CAAA;IACH,CAAC;IAEM,KAAK,CAAC,qBAAqB,CAAC,EACjC,UAAU,EACV,aAAa,EACb,IAAI,GAKL;QACC,OAAO,MAAM,IAAI,CAAC,SAAS,CACzB,KAAK,EAAE,EAAE,EAAE,EAAE,CACX,MAAM,EAAE,CAAC,qBAAqB,CAAC,EAAE,aAAa,EAAE,UAAU,EAAE,IAAI,EAAE,CAAC,CACtE,CAAA;IACH,CAAC;CACF;AAvED,0CAuEC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"appointment.js","sourceRoot":"","sources":["../../../../../extensions/athenahealth/api/schema/appointment.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAmB;AACnB,iCAA6C;
|
1
|
+
{"version":3,"file":"appointment.js","sourceRoot":"","sources":["../../../../../extensions/athenahealth/api/schema/appointment.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAmB;AACnB,iCAA6C;AAMhC,QAAA,iBAAiB,GAAG,aAAC,CAAC,MAAM,CAAC;IACxC,iBAAiB,EAAE,aAAC,CAAC,MAAM,EAAE;IAC7B,eAAe,EAAE,aAAC,CAAC,MAAM,EAAE;IAC3B,0BAA0B,EAAE,aAAC,CAAC,MAAM,EAAE;IACtC,iBAAiB,EAAE,aAAC,CAAC,MAAM,EAAE;IAC7B,YAAY,EAAE,aAAC,CAAC,MAAM,EAAE;IACxB,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE;IACtB,IAAI,EAAE,2BAAoB;IAC1B,SAAS,EAAE,aAAC,CAAC,MAAM,EAAE;IACrB,QAAQ,EAAE,aAAC,CAAC,MAAM,EAAE;IACpB,SAAS,EAAE,aAAC,CAAC,MAAM,EAAE;CACtB,CAAC,CAAA"}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"athenahealth": {
|
3
|
-
"readme": "---\ntitle: Athena\ndescription: Athena offers medical groups, hospitals, and health systems cloud-based EHR, practice management, and patient engagement services that seamlessly connect care and drive results for every client. \n---\n\n## Actions\n\n### Create patient\n\nCreates a patient in athenahealth. First name, last name, date of birth, email, and department ID are required. If a patient with the same name, date of birth, and email already exists, a new patient record will not be created. Instead, the existing patient's ID will be returned.\n\n### Get patient\n\nRetrieve the details of a given patient within a given practice.\n\n### Get appointment\n\nRetrieve the details of an appointment
|
3
|
+
"readme": "---\ntitle: Athena\ndescription: Athena offers medical groups, hospitals, and health systems cloud-based EHR, practice management, and patient engagement services that seamlessly connect care and drive results for every client. \n---\n\n## Athenahealth\n\nAthena offers medical groups, hospitals, and health systems cloud-based EHR, practice management, and patient engagement services that seamlessly connect care and drive results for every client.\n\n## Extension settings\n\nFor the extension to function correctly, you must configure the following settings:\n\n- Auth server URL (e.g. https://api.preview.platform.athenahealth.com/oauth2/v1/token)\n- Client ID\n- Client secret\n- API URL (https://api.preview.platform.athenahealth.com)\n- Scope\n- Practice ID\n\n\n## Actions\n\n### Create patient\n\nCreates a patient in athenahealth. First name, last name, date of birth, email, and department ID are required. If a patient with the same name, date of birth, and email already exists, a new patient record will not be created. Instead, the existing patient's ID will be returned.\n\n### Get patient\n\nRetrieve the details of a given patient within a given practice.\n\n### Get appointment\n\nRetrieve the details of an appointment.\n\n### Create appointment note\n\nCreate a note which will be appended to an appointment",
|
4
4
|
"changelog": "# Athena changelog"
|
5
5
|
},
|
6
6
|
"avaAi": {
|