@candesk/contracts 6.78.0 → 6.80.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/gen/treatment.d.ts +38 -0
- package/dist/gen/treatment.js +9 -1
- package/dist/nest/treatment.d.ts +39 -0
- package/dist/nest/treatment.js +10 -1
- package/package.json +1 -1
- package/proto/treatment.proto +43 -0
package/dist/gen/treatment.d.ts
CHANGED
|
@@ -65,6 +65,13 @@ export declare enum MedicalRejectionReason {
|
|
|
65
65
|
MEDICAL_REJECTION_REASON_OTHER = 3,
|
|
66
66
|
UNRECOGNIZED = -1
|
|
67
67
|
}
|
|
68
|
+
export declare enum RequestStatsPeriod {
|
|
69
|
+
REQUEST_STATS_PERIOD_UNSPECIFIED = 0,
|
|
70
|
+
REQUEST_STATS_PERIOD_TODAY = 1,
|
|
71
|
+
REQUEST_STATS_PERIOD_WEEK = 2,
|
|
72
|
+
REQUEST_STATS_PERIOD_MONTH = 3,
|
|
73
|
+
UNRECOGNIZED = -1
|
|
74
|
+
}
|
|
68
75
|
export declare enum MedicalReviewScope {
|
|
69
76
|
MEDICAL_REVIEW_SCOPE_UNSPECIFIED = 0,
|
|
70
77
|
MEDICAL_REVIEW_SCOPE_QUEUE = 1,
|
|
@@ -173,6 +180,7 @@ export interface TreatmentRequest {
|
|
|
173
180
|
patientName?: string | undefined;
|
|
174
181
|
appointmentAt?: string | undefined;
|
|
175
182
|
patientBlockedAt?: string | undefined;
|
|
183
|
+
reviewDueAt?: string | undefined;
|
|
176
184
|
}
|
|
177
185
|
export interface PatientSnapshot {
|
|
178
186
|
firstName: string;
|
|
@@ -347,6 +355,7 @@ export interface MedicalReviewCount {
|
|
|
347
355
|
queue: number;
|
|
348
356
|
inReview: number;
|
|
349
357
|
done: number;
|
|
358
|
+
overdue: number;
|
|
350
359
|
}
|
|
351
360
|
export interface CountMedicalReviewsResponse {
|
|
352
361
|
counts: MedicalReviewCount[];
|
|
@@ -428,6 +437,34 @@ export interface ListAppointmentsResponse {
|
|
|
428
437
|
nextCursor?: string | undefined;
|
|
429
438
|
total: number;
|
|
430
439
|
}
|
|
440
|
+
export interface GetRequestStatsRequest {
|
|
441
|
+
period: RequestStatsPeriod;
|
|
442
|
+
}
|
|
443
|
+
export interface RequestStatsTotals {
|
|
444
|
+
paid: number;
|
|
445
|
+
paidAmount: number;
|
|
446
|
+
refunded: number;
|
|
447
|
+
refundedAmount: number;
|
|
448
|
+
averageDecisionMinutes?: number | undefined;
|
|
449
|
+
}
|
|
450
|
+
export interface RequestStatsDay {
|
|
451
|
+
day: string;
|
|
452
|
+
paid: number;
|
|
453
|
+
}
|
|
454
|
+
export interface DoctorReviewStats {
|
|
455
|
+
doctorId: string;
|
|
456
|
+
inReview: number;
|
|
457
|
+
decided: number;
|
|
458
|
+
averageReviewMinutes?: number | undefined;
|
|
459
|
+
}
|
|
460
|
+
export interface GetRequestStatsResponse {
|
|
461
|
+
from: string;
|
|
462
|
+
current: RequestStatsTotals | undefined;
|
|
463
|
+
previous: RequestStatsTotals | undefined;
|
|
464
|
+
overdue: number;
|
|
465
|
+
days: RequestStatsDay[];
|
|
466
|
+
doctors: DoctorReviewStats[];
|
|
467
|
+
}
|
|
431
468
|
export interface TreatmentService {
|
|
432
469
|
getQuestionnaire(request: GetQuestionnaireRequest): Promise<GetQuestionnaireResponse>;
|
|
433
470
|
saveQuestionnaire(request: SaveQuestionnaireRequest): Promise<SaveQuestionnaireResponse>;
|
|
@@ -459,4 +496,5 @@ export interface TreatmentService {
|
|
|
459
496
|
retryRefund(request: RetryRefundRequest): Promise<RetryRefundResponse>;
|
|
460
497
|
listAppointmentSlots(request: ListAppointmentSlotsRequest): Promise<ListAppointmentSlotsResponse>;
|
|
461
498
|
listAppointments(request: ListAppointmentsRequest): Promise<ListAppointmentsResponse>;
|
|
499
|
+
getRequestStats(request: GetRequestStatsRequest): Promise<GetRequestStatsResponse>;
|
|
462
500
|
}
|
package/dist/gen/treatment.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
// protoc v3.21.12
|
|
6
6
|
// source: treatment.proto
|
|
7
7
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
-
exports.WithdrawalRejectionReason = exports.WithdrawalStatus = exports.MedicalReviewDecision = exports.MedicalReviewScope = exports.MedicalRejectionReason = exports.TreatmentRequestStatus = exports.TreatmentType = exports.ProductType = exports.IntakeMethod = exports.SymptomDuration = exports.Symptom = exports.QuestionnaireStatus = exports.protobufFileName = exports.protobufPackage = void 0;
|
|
8
|
+
exports.WithdrawalRejectionReason = exports.WithdrawalStatus = exports.MedicalReviewDecision = exports.MedicalReviewScope = exports.RequestStatsPeriod = exports.MedicalRejectionReason = exports.TreatmentRequestStatus = exports.TreatmentType = exports.ProductType = exports.IntakeMethod = exports.SymptomDuration = exports.Symptom = exports.QuestionnaireStatus = exports.protobufFileName = exports.protobufPackage = void 0;
|
|
9
9
|
/* eslint-disable */
|
|
10
10
|
exports.protobufPackage = "treatment.v1";
|
|
11
11
|
exports.protobufFileName = "treatment.proto";
|
|
@@ -82,6 +82,14 @@ var MedicalRejectionReason;
|
|
|
82
82
|
MedicalRejectionReason[MedicalRejectionReason["MEDICAL_REJECTION_REASON_OTHER"] = 3] = "MEDICAL_REJECTION_REASON_OTHER";
|
|
83
83
|
MedicalRejectionReason[MedicalRejectionReason["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
84
84
|
})(MedicalRejectionReason || (exports.MedicalRejectionReason = MedicalRejectionReason = {}));
|
|
85
|
+
var RequestStatsPeriod;
|
|
86
|
+
(function (RequestStatsPeriod) {
|
|
87
|
+
RequestStatsPeriod[RequestStatsPeriod["REQUEST_STATS_PERIOD_UNSPECIFIED"] = 0] = "REQUEST_STATS_PERIOD_UNSPECIFIED";
|
|
88
|
+
RequestStatsPeriod[RequestStatsPeriod["REQUEST_STATS_PERIOD_TODAY"] = 1] = "REQUEST_STATS_PERIOD_TODAY";
|
|
89
|
+
RequestStatsPeriod[RequestStatsPeriod["REQUEST_STATS_PERIOD_WEEK"] = 2] = "REQUEST_STATS_PERIOD_WEEK";
|
|
90
|
+
RequestStatsPeriod[RequestStatsPeriod["REQUEST_STATS_PERIOD_MONTH"] = 3] = "REQUEST_STATS_PERIOD_MONTH";
|
|
91
|
+
RequestStatsPeriod[RequestStatsPeriod["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
92
|
+
})(RequestStatsPeriod || (exports.RequestStatsPeriod = RequestStatsPeriod = {}));
|
|
85
93
|
var MedicalReviewScope;
|
|
86
94
|
(function (MedicalReviewScope) {
|
|
87
95
|
MedicalReviewScope[MedicalReviewScope["MEDICAL_REVIEW_SCOPE_UNSPECIFIED"] = 0] = "MEDICAL_REVIEW_SCOPE_UNSPECIFIED";
|
package/dist/nest/treatment.d.ts
CHANGED
|
@@ -66,6 +66,13 @@ export declare enum MedicalRejectionReason {
|
|
|
66
66
|
MEDICAL_REJECTION_REASON_OTHER = 3,
|
|
67
67
|
UNRECOGNIZED = -1
|
|
68
68
|
}
|
|
69
|
+
export declare enum RequestStatsPeriod {
|
|
70
|
+
REQUEST_STATS_PERIOD_UNSPECIFIED = 0,
|
|
71
|
+
REQUEST_STATS_PERIOD_TODAY = 1,
|
|
72
|
+
REQUEST_STATS_PERIOD_WEEK = 2,
|
|
73
|
+
REQUEST_STATS_PERIOD_MONTH = 3,
|
|
74
|
+
UNRECOGNIZED = -1
|
|
75
|
+
}
|
|
69
76
|
export declare enum MedicalReviewScope {
|
|
70
77
|
MEDICAL_REVIEW_SCOPE_UNSPECIFIED = 0,
|
|
71
78
|
MEDICAL_REVIEW_SCOPE_QUEUE = 1,
|
|
@@ -174,6 +181,7 @@ export interface TreatmentRequest {
|
|
|
174
181
|
patientName?: string | undefined;
|
|
175
182
|
appointmentAt?: string | undefined;
|
|
176
183
|
patientBlockedAt?: string | undefined;
|
|
184
|
+
reviewDueAt?: string | undefined;
|
|
177
185
|
}
|
|
178
186
|
export interface PatientSnapshot {
|
|
179
187
|
firstName: string;
|
|
@@ -348,6 +356,7 @@ export interface MedicalReviewCount {
|
|
|
348
356
|
queue: number;
|
|
349
357
|
inReview: number;
|
|
350
358
|
done: number;
|
|
359
|
+
overdue: number;
|
|
351
360
|
}
|
|
352
361
|
export interface CountMedicalReviewsResponse {
|
|
353
362
|
counts: MedicalReviewCount[];
|
|
@@ -429,6 +438,34 @@ export interface ListAppointmentsResponse {
|
|
|
429
438
|
nextCursor?: string | undefined;
|
|
430
439
|
total: number;
|
|
431
440
|
}
|
|
441
|
+
export interface GetRequestStatsRequest {
|
|
442
|
+
period: RequestStatsPeriod;
|
|
443
|
+
}
|
|
444
|
+
export interface RequestStatsTotals {
|
|
445
|
+
paid: number;
|
|
446
|
+
paidAmount: number;
|
|
447
|
+
refunded: number;
|
|
448
|
+
refundedAmount: number;
|
|
449
|
+
averageDecisionMinutes?: number | undefined;
|
|
450
|
+
}
|
|
451
|
+
export interface RequestStatsDay {
|
|
452
|
+
day: string;
|
|
453
|
+
paid: number;
|
|
454
|
+
}
|
|
455
|
+
export interface DoctorReviewStats {
|
|
456
|
+
doctorId: string;
|
|
457
|
+
inReview: number;
|
|
458
|
+
decided: number;
|
|
459
|
+
averageReviewMinutes?: number | undefined;
|
|
460
|
+
}
|
|
461
|
+
export interface GetRequestStatsResponse {
|
|
462
|
+
from: string;
|
|
463
|
+
current: RequestStatsTotals | undefined;
|
|
464
|
+
previous: RequestStatsTotals | undefined;
|
|
465
|
+
overdue: number;
|
|
466
|
+
days: RequestStatsDay[];
|
|
467
|
+
doctors: DoctorReviewStats[];
|
|
468
|
+
}
|
|
432
469
|
export declare const TREATMENT_V1_PACKAGE_NAME = "treatment.v1";
|
|
433
470
|
export interface TreatmentServiceClient {
|
|
434
471
|
getQuestionnaire(request: GetQuestionnaireRequest): Observable<GetQuestionnaireResponse>;
|
|
@@ -461,6 +498,7 @@ export interface TreatmentServiceClient {
|
|
|
461
498
|
retryRefund(request: RetryRefundRequest): Observable<RetryRefundResponse>;
|
|
462
499
|
listAppointmentSlots(request: ListAppointmentSlotsRequest): Observable<ListAppointmentSlotsResponse>;
|
|
463
500
|
listAppointments(request: ListAppointmentsRequest): Observable<ListAppointmentsResponse>;
|
|
501
|
+
getRequestStats(request: GetRequestStatsRequest): Observable<GetRequestStatsResponse>;
|
|
464
502
|
}
|
|
465
503
|
export interface TreatmentServiceController {
|
|
466
504
|
getQuestionnaire(request: GetQuestionnaireRequest): Promise<GetQuestionnaireResponse> | Observable<GetQuestionnaireResponse> | GetQuestionnaireResponse;
|
|
@@ -493,6 +531,7 @@ export interface TreatmentServiceController {
|
|
|
493
531
|
retryRefund(request: RetryRefundRequest): Promise<RetryRefundResponse> | Observable<RetryRefundResponse> | RetryRefundResponse;
|
|
494
532
|
listAppointmentSlots(request: ListAppointmentSlotsRequest): Promise<ListAppointmentSlotsResponse> | Observable<ListAppointmentSlotsResponse> | ListAppointmentSlotsResponse;
|
|
495
533
|
listAppointments(request: ListAppointmentsRequest): Promise<ListAppointmentsResponse> | Observable<ListAppointmentsResponse> | ListAppointmentsResponse;
|
|
534
|
+
getRequestStats(request: GetRequestStatsRequest): Promise<GetRequestStatsResponse> | Observable<GetRequestStatsResponse> | GetRequestStatsResponse;
|
|
496
535
|
}
|
|
497
536
|
export declare function TreatmentServiceControllerMethods(): (constructor: Function) => void;
|
|
498
537
|
export declare const TREATMENT_SERVICE_NAME = "TreatmentService";
|
package/dist/nest/treatment.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
// protoc v3.21.12
|
|
6
6
|
// source: treatment.proto
|
|
7
7
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
-
exports.TREATMENT_SERVICE_NAME = exports.TREATMENT_V1_PACKAGE_NAME = exports.WithdrawalRejectionReason = exports.WithdrawalStatus = exports.MedicalReviewDecision = exports.MedicalReviewScope = exports.MedicalRejectionReason = exports.TreatmentRequestStatus = exports.TreatmentType = exports.ProductType = exports.IntakeMethod = exports.SymptomDuration = exports.Symptom = exports.QuestionnaireStatus = exports.protobufFileName = exports.protobufPackage = void 0;
|
|
8
|
+
exports.TREATMENT_SERVICE_NAME = exports.TREATMENT_V1_PACKAGE_NAME = exports.WithdrawalRejectionReason = exports.WithdrawalStatus = exports.MedicalReviewDecision = exports.MedicalReviewScope = exports.RequestStatsPeriod = exports.MedicalRejectionReason = exports.TreatmentRequestStatus = exports.TreatmentType = exports.ProductType = exports.IntakeMethod = exports.SymptomDuration = exports.Symptom = exports.QuestionnaireStatus = exports.protobufFileName = exports.protobufPackage = void 0;
|
|
9
9
|
exports.TreatmentServiceControllerMethods = TreatmentServiceControllerMethods;
|
|
10
10
|
/* eslint-disable */
|
|
11
11
|
const microservices_1 = require("@nestjs/microservices");
|
|
@@ -84,6 +84,14 @@ var MedicalRejectionReason;
|
|
|
84
84
|
MedicalRejectionReason[MedicalRejectionReason["MEDICAL_REJECTION_REASON_OTHER"] = 3] = "MEDICAL_REJECTION_REASON_OTHER";
|
|
85
85
|
MedicalRejectionReason[MedicalRejectionReason["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
86
86
|
})(MedicalRejectionReason || (exports.MedicalRejectionReason = MedicalRejectionReason = {}));
|
|
87
|
+
var RequestStatsPeriod;
|
|
88
|
+
(function (RequestStatsPeriod) {
|
|
89
|
+
RequestStatsPeriod[RequestStatsPeriod["REQUEST_STATS_PERIOD_UNSPECIFIED"] = 0] = "REQUEST_STATS_PERIOD_UNSPECIFIED";
|
|
90
|
+
RequestStatsPeriod[RequestStatsPeriod["REQUEST_STATS_PERIOD_TODAY"] = 1] = "REQUEST_STATS_PERIOD_TODAY";
|
|
91
|
+
RequestStatsPeriod[RequestStatsPeriod["REQUEST_STATS_PERIOD_WEEK"] = 2] = "REQUEST_STATS_PERIOD_WEEK";
|
|
92
|
+
RequestStatsPeriod[RequestStatsPeriod["REQUEST_STATS_PERIOD_MONTH"] = 3] = "REQUEST_STATS_PERIOD_MONTH";
|
|
93
|
+
RequestStatsPeriod[RequestStatsPeriod["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
94
|
+
})(RequestStatsPeriod || (exports.RequestStatsPeriod = RequestStatsPeriod = {}));
|
|
87
95
|
var MedicalReviewScope;
|
|
88
96
|
(function (MedicalReviewScope) {
|
|
89
97
|
MedicalReviewScope[MedicalReviewScope["MEDICAL_REVIEW_SCOPE_UNSPECIFIED"] = 0] = "MEDICAL_REVIEW_SCOPE_UNSPECIFIED";
|
|
@@ -149,6 +157,7 @@ function TreatmentServiceControllerMethods() {
|
|
|
149
157
|
"retryRefund",
|
|
150
158
|
"listAppointmentSlots",
|
|
151
159
|
"listAppointments",
|
|
160
|
+
"getRequestStats",
|
|
152
161
|
];
|
|
153
162
|
for (const method of grpcMethods) {
|
|
154
163
|
const descriptor = Reflect.getOwnPropertyDescriptor(constructor.prototype, method);
|
package/package.json
CHANGED
package/proto/treatment.proto
CHANGED
|
@@ -33,6 +33,7 @@ service TreatmentService {
|
|
|
33
33
|
rpc RetryRefund (RetryRefundRequest) returns (RetryRefundResponse);
|
|
34
34
|
rpc ListAppointmentSlots (ListAppointmentSlotsRequest) returns (ListAppointmentSlotsResponse);
|
|
35
35
|
rpc ListAppointments (ListAppointmentsRequest) returns (ListAppointmentsResponse);
|
|
36
|
+
rpc GetRequestStats (GetRequestStatsRequest) returns (GetRequestStatsResponse);
|
|
36
37
|
}
|
|
37
38
|
|
|
38
39
|
enum QuestionnaireStatus {
|
|
@@ -100,6 +101,13 @@ enum MedicalRejectionReason {
|
|
|
100
101
|
MEDICAL_REJECTION_REASON_OTHER = 3;
|
|
101
102
|
}
|
|
102
103
|
|
|
104
|
+
enum RequestStatsPeriod {
|
|
105
|
+
REQUEST_STATS_PERIOD_UNSPECIFIED = 0;
|
|
106
|
+
REQUEST_STATS_PERIOD_TODAY = 1;
|
|
107
|
+
REQUEST_STATS_PERIOD_WEEK = 2;
|
|
108
|
+
REQUEST_STATS_PERIOD_MONTH = 3;
|
|
109
|
+
}
|
|
110
|
+
|
|
103
111
|
enum MedicalReviewScope {
|
|
104
112
|
MEDICAL_REVIEW_SCOPE_UNSPECIFIED = 0;
|
|
105
113
|
MEDICAL_REVIEW_SCOPE_QUEUE = 1;
|
|
@@ -213,6 +221,7 @@ message TreatmentRequest {
|
|
|
213
221
|
optional string patient_name = 23;
|
|
214
222
|
optional string appointment_at = 24;
|
|
215
223
|
optional string patient_blocked_at = 25;
|
|
224
|
+
optional string review_due_at = 26;
|
|
216
225
|
}
|
|
217
226
|
|
|
218
227
|
message PatientSnapshot {
|
|
@@ -430,6 +439,7 @@ message MedicalReviewCount {
|
|
|
430
439
|
int32 queue = 2;
|
|
431
440
|
int32 in_review = 3;
|
|
432
441
|
int32 done = 4;
|
|
442
|
+
int32 overdue = 5;
|
|
433
443
|
}
|
|
434
444
|
|
|
435
445
|
message CountMedicalReviewsResponse {
|
|
@@ -533,3 +543,36 @@ message ListAppointmentsResponse {
|
|
|
533
543
|
optional string next_cursor = 2;
|
|
534
544
|
int32 total = 3;
|
|
535
545
|
}
|
|
546
|
+
|
|
547
|
+
message GetRequestStatsRequest {
|
|
548
|
+
RequestStatsPeriod period = 1;
|
|
549
|
+
}
|
|
550
|
+
|
|
551
|
+
message RequestStatsTotals {
|
|
552
|
+
int32 paid = 1;
|
|
553
|
+
int32 paid_amount = 2;
|
|
554
|
+
int32 refunded = 3;
|
|
555
|
+
int32 refunded_amount = 4;
|
|
556
|
+
optional int32 average_decision_minutes = 5;
|
|
557
|
+
}
|
|
558
|
+
|
|
559
|
+
message RequestStatsDay {
|
|
560
|
+
string day = 1;
|
|
561
|
+
int32 paid = 2;
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
message DoctorReviewStats {
|
|
565
|
+
string doctor_id = 1;
|
|
566
|
+
int32 in_review = 2;
|
|
567
|
+
int32 decided = 3;
|
|
568
|
+
optional int32 average_review_minutes = 4;
|
|
569
|
+
}
|
|
570
|
+
|
|
571
|
+
message GetRequestStatsResponse {
|
|
572
|
+
string from = 1;
|
|
573
|
+
RequestStatsTotals current = 2;
|
|
574
|
+
RequestStatsTotals previous = 3;
|
|
575
|
+
int32 overdue = 4;
|
|
576
|
+
repeated RequestStatsDay days = 5;
|
|
577
|
+
repeated DoctorReviewStats doctors = 6;
|
|
578
|
+
}
|