tychat-contracts 1.6.67 → 1.6.69

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.
@@ -1,4 +1,4 @@
1
- export declare const AI_TOOL_KEYS: readonly ["get_procedures_clinic", "get_clinic_opening_hours", "get_available_slots", "search_health_professionals", "update_patient", "search_patients_by_phone", "create_patient", "create_appointment", "add_appointment_procedures", "list_patient_appointments", "cancel_appointment", "submit_satisfaction"];
1
+ export declare const AI_TOOL_KEYS: readonly ["get_procedures_clinic", "get_clinic_opening_hours", "get_available_slots", "search_health_professionals", "update_patient", "search_patients_by_phone", "create_patient", "create_appointment", "add_appointment_procedures", "list_patient_appointments", "cancel_appointment", "reschedule_appointment", "submit_satisfaction"];
2
2
  export type AiToolKey = (typeof AI_TOOL_KEYS)[number];
3
3
  export declare const AI_TOOL_POLICY_LEVELS: readonly ["global", "plan", "tenant", "unit"];
4
4
  export type AiToolPolicyLevel = (typeof AI_TOOL_POLICY_LEVELS)[number];
@@ -1 +1 @@
1
- {"version":3,"file":"ai-tool-policy.enums.d.ts","sourceRoot":"","sources":["../../src/configurations/ai-tool-policy.enums.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,oTAaf,CAAC;AAEX,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,YAAY,CAAC,CAAC,MAAM,CAAC,CAAC;AAEtD,eAAO,MAAM,qBAAqB,+CAAgD,CAAC;AACnF,MAAM,MAAM,iBAAiB,GAAG,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC;AAEvE,eAAO,MAAM,sBAAsB,uDAGzB,CAAC;AACX,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,sBAAsB,CAAC,CAAC,MAAM,CAAC,CAAC"}
1
+ {"version":3,"file":"ai-tool-policy.enums.d.ts","sourceRoot":"","sources":["../../src/configurations/ai-tool-policy.enums.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,8UAcf,CAAC;AAEX,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,YAAY,CAAC,CAAC,MAAM,CAAC,CAAC;AAEtD,eAAO,MAAM,qBAAqB,+CAAgD,CAAC;AACnF,MAAM,MAAM,iBAAiB,GAAG,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC;AAEvE,eAAO,MAAM,sBAAsB,uDAGzB,CAAC;AACX,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,sBAAsB,CAAC,CAAC,MAAM,CAAC,CAAC"}
@@ -13,6 +13,7 @@ exports.AI_TOOL_KEYS = [
13
13
  'add_appointment_procedures',
14
14
  'list_patient_appointments',
15
15
  'cancel_appointment',
16
+ 'reschedule_appointment',
16
17
  'submit_satisfaction',
17
18
  ];
18
19
  exports.AI_TOOL_POLICY_LEVELS = ['global', 'plan', 'tenant', 'unit'];
@@ -19,6 +19,10 @@ export declare class SendWhatsAppOfficialTemplateDto {
19
19
  languageCode: string;
20
20
  bodyParameters?: string[];
21
21
  headerParameters?: string[];
22
+ buttonParameters?: Array<{
23
+ index: number;
24
+ payload: string;
25
+ }>;
22
26
  }
23
27
  /**
24
28
  * Payload to send a free-form text message via WhatsApp Official (Meta Cloud API).
@@ -1 +1 @@
1
- {"version":3,"file":"whatsapp-official.dto.d.ts","sourceRoot":"","sources":["../../src/connections/whatsapp-official.dto.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,qBAAa,iCAAiC;IAO5C,WAAW,EAAE,MAAM,CAAC;IAQpB,aAAa,EAAE,MAAM,CAAC;IAQtB,MAAM,EAAE,MAAM,CAAC;IAQf,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED;;;GAGG;AACH,qBAAa,+BAA+B;IAO1C,EAAE,EAAE,MAAM,CAAC;IAQX,YAAY,EAAE,MAAM,CAAC;IAQrB,YAAY,EAAE,MAAM,CAAC;IAWrB,cAAc,CAAC,EAAE,MAAM,EAAE,CAAC;IAS1B,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;CAC7B;AAED;;;GAGG;AACH,qBAAa,2BAA2B;IAOtC,EAAE,EAAE,MAAM,CAAC;IAQX,IAAI,EAAE,MAAM,CAAC;CACd"}
1
+ {"version":3,"file":"whatsapp-official.dto.d.ts","sourceRoot":"","sources":["../../src/connections/whatsapp-official.dto.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,qBAAa,iCAAiC;IAO5C,WAAW,EAAE,MAAM,CAAC;IAQpB,aAAa,EAAE,MAAM,CAAC;IAQtB,MAAM,EAAE,MAAM,CAAC;IAQf,kBAAkB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED;;;GAGG;AACH,qBAAa,+BAA+B;IAO1C,EAAE,EAAE,MAAM,CAAC;IAQX,YAAY,EAAE,MAAM,CAAC;IAQrB,YAAY,EAAE,MAAM,CAAC;IAWrB,cAAc,CAAC,EAAE,MAAM,EAAE,CAAC;IAS1B,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;IAW5B,gBAAgB,CAAC,EAAE,KAAK,CAAC;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;CAC9D;AAED;;;GAGG;AACH,qBAAa,2BAA2B;IAOtC,EAAE,EAAE,MAAM,CAAC;IAQX,IAAI,EAAE,MAAM,CAAC;CACd"}
@@ -70,6 +70,7 @@ class SendWhatsAppOfficialTemplateDto {
70
70
  languageCode;
71
71
  bodyParameters;
72
72
  headerParameters;
73
+ buttonParameters;
73
74
  }
74
75
  exports.SendWhatsAppOfficialTemplateDto = SendWhatsAppOfficialTemplateDto;
75
76
  __decorate([
@@ -120,6 +121,17 @@ __decorate([
120
121
  (0, class_validator_1.IsString)({ each: true }),
121
122
  __metadata("design:type", Array)
122
123
  ], SendWhatsAppOfficialTemplateDto.prototype, "headerParameters", void 0);
124
+ __decorate([
125
+ (0, swagger_1.ApiPropertyOptional)({
126
+ description: 'QUICK_REPLY button payloads (0-based index). Echoed by Meta webhook as button.payload.',
127
+ example: [
128
+ { index: 0, payload: 'confirm_presence' },
129
+ { index: 1, payload: 'reschedule' },
130
+ ],
131
+ }),
132
+ (0, class_validator_1.IsOptional)(),
133
+ __metadata("design:type", Array)
134
+ ], SendWhatsAppOfficialTemplateDto.prototype, "buttonParameters", void 0);
123
135
  /**
124
136
  * Payload to send a free-form text message via WhatsApp Official (Meta Cloud API).
125
137
  * Only works within the 24-hour customer service window.
@@ -8,6 +8,8 @@ export declare const TOPIC_APPOINTMENT_CHANGED = "APPOINTMENT_CHANGED";
8
8
  export declare const TOPIC_FOLLOWUP_LOG_LIST = "followup.log.list";
9
9
  /** Kafka request-reply: latest follow-up log by patient IDs. */
10
10
  export declare const TOPIC_FOLLOWUP_LOG_LATEST_BY_PATIENT_IDS = "followup.log.latestByPatientIds";
11
+ /** RPC: dispara satisfação pós-atendimento ao encerrar sessão manualmente. */
12
+ export declare const TOPIC_FOLLOWUP_SESSION_CLOSE_SATISFACTION = "followup.session.close.dispatchSatisfaction";
11
13
  export declare class FollowupConversationEventPayload {
12
14
  tenant: string;
13
15
  patientId: string;
@@ -1 +1 @@
1
- {"version":3,"file":"followup-events.dto.d.ts","sourceRoot":"","sources":["../../src/conversations/followup-events.dto.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,kBAAkB,iBAAiB,CAAC;AACjD,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AACzD,kFAAkF;AAClF,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AACzD,eAAO,MAAM,6BAA6B,4BAA4B,CAAC;AACvE,eAAO,MAAM,yBAAyB,wBAAwB,CAAC;AAE/D,qEAAqE;AACrE,eAAO,MAAM,uBAAuB,sBAAsB,CAAC;AAC3D,gEAAgE;AAChE,eAAO,MAAM,wCAAwC,oCAClB,CAAC;AAEpC,qBAAa,gCAAgC;IAK3C,MAAM,EAAE,MAAM,CAAC;IAMf,SAAS,EAAE,MAAM,CAAC;IAIlB,WAAW,EAAE,MAAM,CAAC;IAIpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAMhB,WAAW,EAAE,IAAI,GAAG,OAAO,GAAG,SAAS,CAAC;IAKxC,UAAU,CAAC,EAAE,OAAO,CAAC;IAIrB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,qBAAa,iCAAiC;IAK5C,MAAM,EAAE,MAAM,CAAC;IAIf,MAAM,CAAC,EAAE,MAAM,CAAC;IAMhB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAIhC,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,qBAAa,8BAA8B;IAKzC,MAAM,EAAE,MAAM,CAAC;IAIf,aAAa,EAAE,MAAM,CAAC;IAMtB,SAAS,EAAE,MAAM,CAAC;IAMlB,MAAM,EAAE,MAAM,CAAC;IAMf,cAAc,CAAC,EAAE,MAAM,CAAC;IAKxB,IAAI,CAAC,EAAE,MAAM,CAAC;IAKd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAKlB,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAI3B,UAAU,EAAE,MAAM,CAAC;CACpB"}
1
+ {"version":3,"file":"followup-events.dto.d.ts","sourceRoot":"","sources":["../../src/conversations/followup-events.dto.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,kBAAkB,iBAAiB,CAAC;AACjD,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AACzD,kFAAkF;AAClF,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AACzD,eAAO,MAAM,6BAA6B,4BAA4B,CAAC;AACvE,eAAO,MAAM,yBAAyB,wBAAwB,CAAC;AAE/D,qEAAqE;AACrE,eAAO,MAAM,uBAAuB,sBAAsB,CAAC;AAC3D,gEAAgE;AAChE,eAAO,MAAM,wCAAwC,oCAClB,CAAC;AAEpC,8EAA8E;AAC9E,eAAO,MAAM,yCAAyC,gDACP,CAAC;AAEhD,qBAAa,gCAAgC;IAK3C,MAAM,EAAE,MAAM,CAAC;IAMf,SAAS,EAAE,MAAM,CAAC;IAIlB,WAAW,EAAE,MAAM,CAAC;IAIpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAMhB,WAAW,EAAE,IAAI,GAAG,OAAO,GAAG,SAAS,CAAC;IAKxC,UAAU,CAAC,EAAE,OAAO,CAAC;IAIrB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,qBAAa,iCAAiC;IAK5C,MAAM,EAAE,MAAM,CAAC;IAIf,MAAM,CAAC,EAAE,MAAM,CAAC;IAMhB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAIhC,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,qBAAa,8BAA8B;IAKzC,MAAM,EAAE,MAAM,CAAC;IAIf,aAAa,EAAE,MAAM,CAAC;IAMtB,SAAS,EAAE,MAAM,CAAC;IAMlB,MAAM,EAAE,MAAM,CAAC;IAMf,cAAc,CAAC,EAAE,MAAM,CAAC;IAKxB,IAAI,CAAC,EAAE,MAAM,CAAC;IAKd,QAAQ,CAAC,EAAE,MAAM,CAAC;IAKlB,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAI3B,UAAU,EAAE,MAAM,CAAC;CACpB"}
@@ -9,7 +9,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.AppointmentChangedEventPayload = exports.FollowupConfigUpdatedEventPayload = exports.FollowupConversationEventPayload = exports.TOPIC_FOLLOWUP_LOG_LATEST_BY_PATIENT_IDS = exports.TOPIC_FOLLOWUP_LOG_LIST = exports.TOPIC_APPOINTMENT_CHANGED = exports.TOPIC_FOLLOWUP_CONFIG_UPDATED = exports.TOPIC_MESSAGE_REACTION = exports.TOPIC_MESSAGE_RECEIVED = exports.TOPIC_MESSAGE_SENT = void 0;
12
+ exports.AppointmentChangedEventPayload = exports.FollowupConfigUpdatedEventPayload = exports.FollowupConversationEventPayload = exports.TOPIC_FOLLOWUP_SESSION_CLOSE_SATISFACTION = exports.TOPIC_FOLLOWUP_LOG_LATEST_BY_PATIENT_IDS = exports.TOPIC_FOLLOWUP_LOG_LIST = exports.TOPIC_APPOINTMENT_CHANGED = exports.TOPIC_FOLLOWUP_CONFIG_UPDATED = exports.TOPIC_MESSAGE_REACTION = exports.TOPIC_MESSAGE_RECEIVED = exports.TOPIC_MESSAGE_SENT = void 0;
13
13
  const swagger_1 = require("@nestjs/swagger");
14
14
  const class_validator_1 = require("class-validator");
15
15
  exports.TOPIC_MESSAGE_SENT = 'MESSAGE_SENT';
@@ -22,6 +22,8 @@ exports.TOPIC_APPOINTMENT_CHANGED = 'APPOINTMENT_CHANGED';
22
22
  exports.TOPIC_FOLLOWUP_LOG_LIST = 'followup.log.list';
23
23
  /** Kafka request-reply: latest follow-up log by patient IDs. */
24
24
  exports.TOPIC_FOLLOWUP_LOG_LATEST_BY_PATIENT_IDS = 'followup.log.latestByPatientIds';
25
+ /** RPC: dispara satisfação pós-atendimento ao encerrar sessão manualmente. */
26
+ exports.TOPIC_FOLLOWUP_SESSION_CLOSE_SATISFACTION = 'followup.session.close.dispatchSatisfaction';
25
27
  class FollowupConversationEventPayload {
26
28
  tenant;
27
29
  patientId;
@@ -1,7 +1,7 @@
1
1
  import type { ParsedFilterDto } from '../filters/parsed-filter.dto';
2
2
  import { ConversationIntentionDto } from './conversation-intention.dto';
3
3
  import { FollowupTypeDto } from './followup-type.dto';
4
- export declare const FOLLOWUP_LOG_LIST_FILTER_KEYS: readonly ["id", "sessionUuid", "patientId", "attempt", "message", "intention", "followupType", "appointmentId", "sentAt"];
4
+ export declare const FOLLOWUP_LOG_LIST_FILTER_KEYS: readonly ["id", "sessionUuid", "patientId", "attempt", "message", "intention", "followupType", "appointmentId", "closedByAttendantId", "sentAt"];
5
5
  export type FollowupLogListFilterKeyDto = (typeof FOLLOWUP_LOG_LIST_FILTER_KEYS)[number];
6
6
  /**
7
7
  * Query parameters for listing follow-up logs (HTTP query + Kafka payload).
@@ -1 +1 @@
1
- {"version":3,"file":"followup-log-list-query.dto.d.ts","sourceRoot":"","sources":["../../src/conversations/followup-log-list-query.dto.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,EAEL,wBAAwB,EACzB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAkB,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAEtE,eAAO,MAAM,6BAA6B,2HAUhC,CAAC;AACX,MAAM,MAAM,2BAA2B,GAAG,CAAC,OAAO,6BAA6B,CAAC,CAAC,MAAM,CAAC,CAAC;AAEzF;;GAEG;AACH,qBAAa,uBAAuB;IAMlC,IAAI,CAAC,EAAE,MAAM,CAAC;IAQd,KAAK,CAAC,EAAE,MAAM,CAAC;IAKf,SAAS,CAAC,EAAE,MAAM,CAAC;IAKnB,WAAW,CAAC,EAAE,MAAM,CAAC;IAQrB,SAAS,CAAC,EAAE,wBAAwB,CAAC;IAQrC,YAAY,CAAC,EAAE,eAAe,CAAC;IAW/B,OAAO,CAAC,EAAE,eAAe,EAAE,CAAC;CAC7B"}
1
+ {"version":3,"file":"followup-log-list-query.dto.d.ts","sourceRoot":"","sources":["../../src/conversations/followup-log-list-query.dto.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,EAEL,wBAAwB,EACzB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAkB,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAEtE,eAAO,MAAM,6BAA6B,kJAWhC,CAAC;AACX,MAAM,MAAM,2BAA2B,GAAG,CAAC,OAAO,6BAA6B,CAAC,CAAC,MAAM,CAAC,CAAC;AAEzF;;GAEG;AACH,qBAAa,uBAAuB;IAMlC,IAAI,CAAC,EAAE,MAAM,CAAC;IAQd,KAAK,CAAC,EAAE,MAAM,CAAC;IAKf,SAAS,CAAC,EAAE,MAAM,CAAC;IAKnB,WAAW,CAAC,EAAE,MAAM,CAAC;IAQrB,SAAS,CAAC,EAAE,wBAAwB,CAAC;IAQrC,YAAY,CAAC,EAAE,eAAe,CAAC;IAW/B,OAAO,CAAC,EAAE,eAAe,EAAE,CAAC;CAC7B"}
@@ -24,6 +24,7 @@ exports.FOLLOWUP_LOG_LIST_FILTER_KEYS = [
24
24
  'intention',
25
25
  'followupType',
26
26
  'appointmentId',
27
+ 'closedByAttendantId',
27
28
  'sentAt',
28
29
  ];
29
30
  /**
@@ -12,6 +12,7 @@ export declare class FollowupLogResponseDto {
12
12
  intention?: string;
13
13
  followupType: FollowupTypeDto;
14
14
  appointmentId?: string | null;
15
+ closedByAttendantId?: string | null;
15
16
  sentAt: string;
16
17
  }
17
18
  //# sourceMappingURL=followup-log-response.dto.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"followup-log-response.dto.d.ts","sourceRoot":"","sources":["../../src/conversations/followup-log-response.dto.ts"],"names":[],"mappings":"AAEA,OAAO,EAAkB,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAEtE;;;GAGG;AACH,qBAAa,sBAAsB;IAIjC,EAAE,EAAE,MAAM,CAAC;IAKX,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAK5B,SAAS,EAAE,MAAM,CAAC;IAMlB,OAAO,EAAE,MAAM,CAAC;IAKhB,OAAO,EAAE,MAAM,CAAC;IAKhB,SAAS,CAAC,EAAE,MAAM,CAAC;IAQnB,YAAY,EAAE,eAAe,CAAC;IAK9B,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAK9B,MAAM,EAAE,MAAM,CAAC;CAChB"}
1
+ {"version":3,"file":"followup-log-response.dto.d.ts","sourceRoot":"","sources":["../../src/conversations/followup-log-response.dto.ts"],"names":[],"mappings":"AAEA,OAAO,EAAkB,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAEtE;;;GAGG;AACH,qBAAa,sBAAsB;IAIjC,EAAE,EAAE,MAAM,CAAC;IAKX,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAK5B,SAAS,EAAE,MAAM,CAAC;IAMlB,OAAO,EAAE,MAAM,CAAC;IAKhB,OAAO,EAAE,MAAM,CAAC;IAKhB,SAAS,CAAC,EAAE,MAAM,CAAC;IAQnB,YAAY,EAAE,eAAe,CAAC;IAK9B,aAAa,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAO9B,mBAAmB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAKpC,MAAM,EAAE,MAAM,CAAC;CAChB"}
@@ -26,6 +26,7 @@ class FollowupLogResponseDto {
26
26
  intention;
27
27
  followupType;
28
28
  appointmentId;
29
+ closedByAttendantId;
29
30
  sentAt;
30
31
  }
31
32
  exports.FollowupLogResponseDto = FollowupLogResponseDto;
@@ -81,6 +82,14 @@ __decorate([
81
82
  (0, class_validator_1.IsString)(),
82
83
  __metadata("design:type", Object)
83
84
  ], FollowupLogResponseDto.prototype, "appointmentId", void 0);
85
+ __decorate([
86
+ (0, swagger_1.ApiPropertyOptional)({
87
+ description: 'User id do atendente que concluiu o atendimento (quando aplicável)',
88
+ }),
89
+ (0, class_validator_1.IsOptional)(),
90
+ (0, class_validator_1.IsString)(),
91
+ __metadata("design:type", Object)
92
+ ], FollowupLogResponseDto.prototype, "closedByAttendantId", void 0);
84
93
  __decorate([
85
94
  (0, swagger_1.ApiProperty)({ description: 'Timestamp when the follow-up was sent (ISO 8601)' }),
86
95
  (0, class_validator_1.IsString)(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tychat-contracts",
3
- "version": "1.6.67",
3
+ "version": "1.6.69",
4
4
  "description": "DTOs compartilhados com class-validator (API e microserviços)",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -10,6 +10,7 @@ export const AI_TOOL_KEYS = [
10
10
  'add_appointment_procedures',
11
11
  'list_patient_appointments',
12
12
  'cancel_appointment',
13
+ 'reschedule_appointment',
13
14
  'submit_satisfaction',
14
15
  ] as const;
15
16
 
@@ -88,6 +88,17 @@ export class SendWhatsAppOfficialTemplateDto {
88
88
  @IsOptional()
89
89
  @IsString({ each: true })
90
90
  headerParameters?: string[];
91
+
92
+ @ApiPropertyOptional({
93
+ description:
94
+ 'QUICK_REPLY button payloads (0-based index). Echoed by Meta webhook as button.payload.',
95
+ example: [
96
+ { index: 0, payload: 'confirm_presence' },
97
+ { index: 1, payload: 'reschedule' },
98
+ ],
99
+ })
100
+ @IsOptional()
101
+ buttonParameters?: Array<{ index: number; payload: string }>;
91
102
  }
92
103
 
93
104
  /**
@@ -14,6 +14,10 @@ export const TOPIC_FOLLOWUP_LOG_LIST = 'followup.log.list';
14
14
  export const TOPIC_FOLLOWUP_LOG_LATEST_BY_PATIENT_IDS =
15
15
  'followup.log.latestByPatientIds';
16
16
 
17
+ /** RPC: dispara satisfação pós-atendimento ao encerrar sessão manualmente. */
18
+ export const TOPIC_FOLLOWUP_SESSION_CLOSE_SATISFACTION =
19
+ 'followup.session.close.dispatchSatisfaction';
20
+
17
21
  export class FollowupConversationEventPayload {
18
22
  @ApiProperty({ example: 'homolog' })
19
23
  @IsString()
@@ -24,6 +24,7 @@ export const FOLLOWUP_LOG_LIST_FILTER_KEYS = [
24
24
  'intention',
25
25
  'followupType',
26
26
  'appointmentId',
27
+ 'closedByAttendantId',
27
28
  'sentAt',
28
29
  ] as const;
29
30
  export type FollowupLogListFilterKeyDto = (typeof FOLLOWUP_LOG_LIST_FILTER_KEYS)[number];
@@ -51,6 +51,13 @@ export class FollowupLogResponseDto {
51
51
  @IsString()
52
52
  appointmentId?: string | null;
53
53
 
54
+ @ApiPropertyOptional({
55
+ description: 'User id do atendente que concluiu o atendimento (quando aplicável)',
56
+ })
57
+ @IsOptional()
58
+ @IsString()
59
+ closedByAttendantId?: string | null;
60
+
54
61
  @ApiProperty({ description: 'Timestamp when the follow-up was sent (ISO 8601)' })
55
62
  @IsString()
56
63
  @IsNotEmpty()
@@ -1,10 +1,10 @@
1
- export * from './create-patient.dto';
2
- export * from './update-patient.dto';
3
- export * from './patient-history-entry.dto';
4
- export * from './list-patients-query.dto';
5
- export * from './list-patients-filters.dto';
6
- export * from './upsert-patient-by-phone.dto';
7
- export * from './patient-status.dto';
8
- export * from './patient-document-response.dto';
9
- export * from './update-patient-document.dto';
10
-
1
+ export * from './create-patient.dto';
2
+ export * from './update-patient.dto';
3
+ export * from './patient-history-entry.dto';
4
+ export * from './list-patients-query.dto';
5
+ export * from './list-patients-filters.dto';
6
+ export * from './upsert-patient-by-phone.dto';
7
+ export * from './patient-status.dto';
8
+ export * from './patient-document-response.dto';
9
+ export * from './update-patient-document.dto';
10
+