evo360-types 1.3.559 → 1.3.562
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/apps/evo-csq/zod-schemas.d.ts +58 -0
- package/dist/apps/evo-csq/zod-schemas.js +4 -0
- package/dist/apps/evo-csq/zod-schemas.ts +4 -0
- package/dist/types/evo-crm/lead/index.d.ts +27 -0
- package/dist/types/evo-crm/lead/index.ts +27 -0
- package/dist/types/evo-csq/index.d.ts +7 -0
- package/dist/types/evo-csq/index.ts +7 -0
- package/package.json +1 -1
|
@@ -66,6 +66,8 @@ export declare const zCsqAlertSchema: z.ZodObject<{
|
|
|
66
66
|
verification: z.ZodOptional<z.ZodEnum<["pending", "confirmed_ok", "confirmed", "inconclusive"]>>;
|
|
67
67
|
recheck_after: z.ZodOptional<z.ZodEffects<z.ZodDate, Date, unknown>>;
|
|
68
68
|
resolved_in_ticket: z.ZodOptional<z.ZodString>;
|
|
69
|
+
appointment_id: z.ZodOptional<z.ZodString>;
|
|
70
|
+
calendar_id: z.ZodOptional<z.ZodString>;
|
|
69
71
|
first_seen_ticket_id: z.ZodString;
|
|
70
72
|
created_at: z.ZodEffects<z.ZodDate, Date, unknown>;
|
|
71
73
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -85,6 +87,8 @@ export declare const zCsqAlertSchema: z.ZodObject<{
|
|
|
85
87
|
}[];
|
|
86
88
|
first_seen_ticket_id: string;
|
|
87
89
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
90
|
+
calendar_id?: string | undefined;
|
|
91
|
+
appointment_id?: string | undefined;
|
|
88
92
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
89
93
|
suggested_action?: string | undefined;
|
|
90
94
|
recheck_after?: Date | undefined;
|
|
@@ -106,6 +110,8 @@ export declare const zCsqAlertSchema: z.ZodObject<{
|
|
|
106
110
|
first_seen_ticket_id: string;
|
|
107
111
|
created_at?: unknown;
|
|
108
112
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
113
|
+
calendar_id?: string | undefined;
|
|
114
|
+
appointment_id?: string | undefined;
|
|
109
115
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
110
116
|
suggested_action?: string | undefined;
|
|
111
117
|
recheck_after?: unknown;
|
|
@@ -1879,12 +1885,16 @@ export declare const zCsqCrossCheckSchema: z.ZodObject<{
|
|
|
1879
1885
|
found: z.ZodNullable<z.ZodString>;
|
|
1880
1886
|
alert_code: z.ZodOptional<z.ZodEnum<["AGENDAMENTO_INFORMADO_NAO_REGISTRADO", "AGENDAMENTO_DIVERGENTE", "AGENDAMENTO_SOBREPOSTO", "CONTRADICAO_PREMISSA_ANTERIOR", "ORIENTACAO_CLINICA_INDEVIDA", "POLITICA_VIOLADA", "ULTIMA_MENSAGEM_SEM_RESPOSTA", "PERGUNTA_NAO_RESPONDIDA", "PROMESSA_NAO_CUMPRIDA", "IDENTIDADE_ERRADA", "DADO_JA_INFORMADO_RECOLETADO", "DADO_OBRIGATORIO_NAO_COLETADO", "FLUXO_VENDA_NAO_SEGUIDO", "MOTIVO_ENCERRAMENTO_INCOMPATIVEL", "SLA_RESPOSTA_ALTO", "LEAD_QUENTE_SEM_FOLLOWUP", "LEAD_ORIGEM_INCONSISTENTE", "LEAD_QUALIFICACAO_INCONSISTENTE", "AUTOMACAO_CONFLITANTE", "DADO_SENSIVEL_SOLICITADO", "URGENCIA_NAO_ENCAMINHADA", "NF_NAO_ENVIADA", "COBRANCA_NAO_ENVIADA"]>>;
|
|
1881
1887
|
note: z.ZodOptional<z.ZodString>;
|
|
1888
|
+
appointment_id: z.ZodOptional<z.ZodString>;
|
|
1889
|
+
calendar_id: z.ZodOptional<z.ZodString>;
|
|
1882
1890
|
}, "strip", z.ZodTypeAny, {
|
|
1883
1891
|
result: "match" | "inconclusive" | "mismatch" | "missing";
|
|
1884
1892
|
expected: string;
|
|
1885
1893
|
claim_type: "promise" | "appointment_informed" | "data_collected" | "required_data" | "outcome" | "question_requires_answer" | "first_concrete_offer" | "patient_status" | "price_informed";
|
|
1886
1894
|
found: string | null;
|
|
1887
1895
|
note?: string | undefined;
|
|
1896
|
+
calendar_id?: string | undefined;
|
|
1897
|
+
appointment_id?: string | undefined;
|
|
1888
1898
|
alert_code?: "AGENDAMENTO_INFORMADO_NAO_REGISTRADO" | "AGENDAMENTO_DIVERGENTE" | "AGENDAMENTO_SOBREPOSTO" | "CONTRADICAO_PREMISSA_ANTERIOR" | "ORIENTACAO_CLINICA_INDEVIDA" | "POLITICA_VIOLADA" | "ULTIMA_MENSAGEM_SEM_RESPOSTA" | "PERGUNTA_NAO_RESPONDIDA" | "PROMESSA_NAO_CUMPRIDA" | "IDENTIDADE_ERRADA" | "DADO_JA_INFORMADO_RECOLETADO" | "DADO_OBRIGATORIO_NAO_COLETADO" | "FLUXO_VENDA_NAO_SEGUIDO" | "MOTIVO_ENCERRAMENTO_INCOMPATIVEL" | "SLA_RESPOSTA_ALTO" | "LEAD_QUENTE_SEM_FOLLOWUP" | "LEAD_ORIGEM_INCONSISTENTE" | "LEAD_QUALIFICACAO_INCONSISTENTE" | "AUTOMACAO_CONFLITANTE" | "DADO_SENSIVEL_SOLICITADO" | "URGENCIA_NAO_ENCAMINHADA" | "NF_NAO_ENVIADA" | "COBRANCA_NAO_ENVIADA" | undefined;
|
|
1889
1899
|
}, {
|
|
1890
1900
|
result: "match" | "inconclusive" | "mismatch" | "missing";
|
|
@@ -1892,6 +1902,8 @@ export declare const zCsqCrossCheckSchema: z.ZodObject<{
|
|
|
1892
1902
|
claim_type: "promise" | "appointment_informed" | "data_collected" | "required_data" | "outcome" | "question_requires_answer" | "first_concrete_offer" | "patient_status" | "price_informed";
|
|
1893
1903
|
found: string | null;
|
|
1894
1904
|
note?: string | undefined;
|
|
1905
|
+
calendar_id?: string | undefined;
|
|
1906
|
+
appointment_id?: string | undefined;
|
|
1895
1907
|
alert_code?: "AGENDAMENTO_INFORMADO_NAO_REGISTRADO" | "AGENDAMENTO_DIVERGENTE" | "AGENDAMENTO_SOBREPOSTO" | "CONTRADICAO_PREMISSA_ANTERIOR" | "ORIENTACAO_CLINICA_INDEVIDA" | "POLITICA_VIOLADA" | "ULTIMA_MENSAGEM_SEM_RESPOSTA" | "PERGUNTA_NAO_RESPONDIDA" | "PROMESSA_NAO_CUMPRIDA" | "IDENTIDADE_ERRADA" | "DADO_JA_INFORMADO_RECOLETADO" | "DADO_OBRIGATORIO_NAO_COLETADO" | "FLUXO_VENDA_NAO_SEGUIDO" | "MOTIVO_ENCERRAMENTO_INCOMPATIVEL" | "SLA_RESPOSTA_ALTO" | "LEAD_QUENTE_SEM_FOLLOWUP" | "LEAD_ORIGEM_INCONSISTENTE" | "LEAD_QUALIFICACAO_INCONSISTENTE" | "AUTOMACAO_CONFLITANTE" | "DADO_SENSIVEL_SOLICITADO" | "URGENCIA_NAO_ENCAMINHADA" | "NF_NAO_ENVIADA" | "COBRANCA_NAO_ENVIADA" | undefined;
|
|
1896
1908
|
}>;
|
|
1897
1909
|
export declare const zCsqCriterionScoreSchema: z.ZodObject<{
|
|
@@ -3317,6 +3329,8 @@ export declare const zCsqJudgeOutputSchema: z.ZodObject<{
|
|
|
3317
3329
|
verification: z.ZodOptional<z.ZodEnum<["pending", "confirmed_ok", "confirmed", "inconclusive"]>>;
|
|
3318
3330
|
recheck_after: z.ZodOptional<z.ZodEffects<z.ZodDate, Date, unknown>>;
|
|
3319
3331
|
resolved_in_ticket: z.ZodOptional<z.ZodString>;
|
|
3332
|
+
appointment_id: z.ZodOptional<z.ZodString>;
|
|
3333
|
+
calendar_id: z.ZodOptional<z.ZodString>;
|
|
3320
3334
|
first_seen_ticket_id: z.ZodString;
|
|
3321
3335
|
created_at: z.ZodEffects<z.ZodDate, Date, unknown>;
|
|
3322
3336
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -3336,6 +3350,8 @@ export declare const zCsqJudgeOutputSchema: z.ZodObject<{
|
|
|
3336
3350
|
}[];
|
|
3337
3351
|
first_seen_ticket_id: string;
|
|
3338
3352
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
3353
|
+
calendar_id?: string | undefined;
|
|
3354
|
+
appointment_id?: string | undefined;
|
|
3339
3355
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
3340
3356
|
suggested_action?: string | undefined;
|
|
3341
3357
|
recheck_after?: Date | undefined;
|
|
@@ -3357,6 +3373,8 @@ export declare const zCsqJudgeOutputSchema: z.ZodObject<{
|
|
|
3357
3373
|
first_seen_ticket_id: string;
|
|
3358
3374
|
created_at?: unknown;
|
|
3359
3375
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
3376
|
+
calendar_id?: string | undefined;
|
|
3377
|
+
appointment_id?: string | undefined;
|
|
3360
3378
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
3361
3379
|
suggested_action?: string | undefined;
|
|
3362
3380
|
recheck_after?: unknown;
|
|
@@ -3600,6 +3618,8 @@ export declare const zCsqJudgeOutputSchema: z.ZodObject<{
|
|
|
3600
3618
|
}[];
|
|
3601
3619
|
first_seen_ticket_id: string;
|
|
3602
3620
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
3621
|
+
calendar_id?: string | undefined;
|
|
3622
|
+
appointment_id?: string | undefined;
|
|
3603
3623
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
3604
3624
|
suggested_action?: string | undefined;
|
|
3605
3625
|
recheck_after?: Date | undefined;
|
|
@@ -3842,6 +3862,8 @@ export declare const zCsqJudgeOutputSchema: z.ZodObject<{
|
|
|
3842
3862
|
first_seen_ticket_id: string;
|
|
3843
3863
|
created_at?: unknown;
|
|
3844
3864
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
3865
|
+
calendar_id?: string | undefined;
|
|
3866
|
+
appointment_id?: string | undefined;
|
|
3845
3867
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
3846
3868
|
suggested_action?: string | undefined;
|
|
3847
3869
|
recheck_after?: unknown;
|
|
@@ -6046,12 +6068,16 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
6046
6068
|
found: z.ZodNullable<z.ZodString>;
|
|
6047
6069
|
alert_code: z.ZodOptional<z.ZodEnum<["AGENDAMENTO_INFORMADO_NAO_REGISTRADO", "AGENDAMENTO_DIVERGENTE", "AGENDAMENTO_SOBREPOSTO", "CONTRADICAO_PREMISSA_ANTERIOR", "ORIENTACAO_CLINICA_INDEVIDA", "POLITICA_VIOLADA", "ULTIMA_MENSAGEM_SEM_RESPOSTA", "PERGUNTA_NAO_RESPONDIDA", "PROMESSA_NAO_CUMPRIDA", "IDENTIDADE_ERRADA", "DADO_JA_INFORMADO_RECOLETADO", "DADO_OBRIGATORIO_NAO_COLETADO", "FLUXO_VENDA_NAO_SEGUIDO", "MOTIVO_ENCERRAMENTO_INCOMPATIVEL", "SLA_RESPOSTA_ALTO", "LEAD_QUENTE_SEM_FOLLOWUP", "LEAD_ORIGEM_INCONSISTENTE", "LEAD_QUALIFICACAO_INCONSISTENTE", "AUTOMACAO_CONFLITANTE", "DADO_SENSIVEL_SOLICITADO", "URGENCIA_NAO_ENCAMINHADA", "NF_NAO_ENVIADA", "COBRANCA_NAO_ENVIADA"]>>;
|
|
6048
6070
|
note: z.ZodOptional<z.ZodString>;
|
|
6071
|
+
appointment_id: z.ZodOptional<z.ZodString>;
|
|
6072
|
+
calendar_id: z.ZodOptional<z.ZodString>;
|
|
6049
6073
|
}, "strip", z.ZodTypeAny, {
|
|
6050
6074
|
result: "match" | "inconclusive" | "mismatch" | "missing";
|
|
6051
6075
|
expected: string;
|
|
6052
6076
|
claim_type: "promise" | "appointment_informed" | "data_collected" | "required_data" | "outcome" | "question_requires_answer" | "first_concrete_offer" | "patient_status" | "price_informed";
|
|
6053
6077
|
found: string | null;
|
|
6054
6078
|
note?: string | undefined;
|
|
6079
|
+
calendar_id?: string | undefined;
|
|
6080
|
+
appointment_id?: string | undefined;
|
|
6055
6081
|
alert_code?: "AGENDAMENTO_INFORMADO_NAO_REGISTRADO" | "AGENDAMENTO_DIVERGENTE" | "AGENDAMENTO_SOBREPOSTO" | "CONTRADICAO_PREMISSA_ANTERIOR" | "ORIENTACAO_CLINICA_INDEVIDA" | "POLITICA_VIOLADA" | "ULTIMA_MENSAGEM_SEM_RESPOSTA" | "PERGUNTA_NAO_RESPONDIDA" | "PROMESSA_NAO_CUMPRIDA" | "IDENTIDADE_ERRADA" | "DADO_JA_INFORMADO_RECOLETADO" | "DADO_OBRIGATORIO_NAO_COLETADO" | "FLUXO_VENDA_NAO_SEGUIDO" | "MOTIVO_ENCERRAMENTO_INCOMPATIVEL" | "SLA_RESPOSTA_ALTO" | "LEAD_QUENTE_SEM_FOLLOWUP" | "LEAD_ORIGEM_INCONSISTENTE" | "LEAD_QUALIFICACAO_INCONSISTENTE" | "AUTOMACAO_CONFLITANTE" | "DADO_SENSIVEL_SOLICITADO" | "URGENCIA_NAO_ENCAMINHADA" | "NF_NAO_ENVIADA" | "COBRANCA_NAO_ENVIADA" | undefined;
|
|
6056
6082
|
}, {
|
|
6057
6083
|
result: "match" | "inconclusive" | "mismatch" | "missing";
|
|
@@ -6059,6 +6085,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
6059
6085
|
claim_type: "promise" | "appointment_informed" | "data_collected" | "required_data" | "outcome" | "question_requires_answer" | "first_concrete_offer" | "patient_status" | "price_informed";
|
|
6060
6086
|
found: string | null;
|
|
6061
6087
|
note?: string | undefined;
|
|
6088
|
+
calendar_id?: string | undefined;
|
|
6089
|
+
appointment_id?: string | undefined;
|
|
6062
6090
|
alert_code?: "AGENDAMENTO_INFORMADO_NAO_REGISTRADO" | "AGENDAMENTO_DIVERGENTE" | "AGENDAMENTO_SOBREPOSTO" | "CONTRADICAO_PREMISSA_ANTERIOR" | "ORIENTACAO_CLINICA_INDEVIDA" | "POLITICA_VIOLADA" | "ULTIMA_MENSAGEM_SEM_RESPOSTA" | "PERGUNTA_NAO_RESPONDIDA" | "PROMESSA_NAO_CUMPRIDA" | "IDENTIDADE_ERRADA" | "DADO_JA_INFORMADO_RECOLETADO" | "DADO_OBRIGATORIO_NAO_COLETADO" | "FLUXO_VENDA_NAO_SEGUIDO" | "MOTIVO_ENCERRAMENTO_INCOMPATIVEL" | "SLA_RESPOSTA_ALTO" | "LEAD_QUENTE_SEM_FOLLOWUP" | "LEAD_ORIGEM_INCONSISTENTE" | "LEAD_QUALIFICACAO_INCONSISTENTE" | "AUTOMACAO_CONFLITANTE" | "DADO_SENSIVEL_SOLICITADO" | "URGENCIA_NAO_ENCAMINHADA" | "NF_NAO_ENVIADA" | "COBRANCA_NAO_ENVIADA" | undefined;
|
|
6063
6091
|
}>, "many">;
|
|
6064
6092
|
criteria: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
@@ -6213,6 +6241,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
6213
6241
|
verification: z.ZodOptional<z.ZodEnum<["pending", "confirmed_ok", "confirmed", "inconclusive"]>>;
|
|
6214
6242
|
recheck_after: z.ZodOptional<z.ZodEffects<z.ZodDate, Date, unknown>>;
|
|
6215
6243
|
resolved_in_ticket: z.ZodOptional<z.ZodString>;
|
|
6244
|
+
appointment_id: z.ZodOptional<z.ZodString>;
|
|
6245
|
+
calendar_id: z.ZodOptional<z.ZodString>;
|
|
6216
6246
|
first_seen_ticket_id: z.ZodString;
|
|
6217
6247
|
created_at: z.ZodEffects<z.ZodDate, Date, unknown>;
|
|
6218
6248
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -6232,6 +6262,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
6232
6262
|
}[];
|
|
6233
6263
|
first_seen_ticket_id: string;
|
|
6234
6264
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
6265
|
+
calendar_id?: string | undefined;
|
|
6266
|
+
appointment_id?: string | undefined;
|
|
6235
6267
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
6236
6268
|
suggested_action?: string | undefined;
|
|
6237
6269
|
recheck_after?: Date | undefined;
|
|
@@ -6253,6 +6285,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
6253
6285
|
first_seen_ticket_id: string;
|
|
6254
6286
|
created_at?: unknown;
|
|
6255
6287
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
6288
|
+
calendar_id?: string | undefined;
|
|
6289
|
+
appointment_id?: string | undefined;
|
|
6256
6290
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
6257
6291
|
suggested_action?: string | undefined;
|
|
6258
6292
|
recheck_after?: unknown;
|
|
@@ -8045,12 +8079,16 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
8045
8079
|
found: z.ZodNullable<z.ZodString>;
|
|
8046
8080
|
alert_code: z.ZodOptional<z.ZodEnum<["AGENDAMENTO_INFORMADO_NAO_REGISTRADO", "AGENDAMENTO_DIVERGENTE", "AGENDAMENTO_SOBREPOSTO", "CONTRADICAO_PREMISSA_ANTERIOR", "ORIENTACAO_CLINICA_INDEVIDA", "POLITICA_VIOLADA", "ULTIMA_MENSAGEM_SEM_RESPOSTA", "PERGUNTA_NAO_RESPONDIDA", "PROMESSA_NAO_CUMPRIDA", "IDENTIDADE_ERRADA", "DADO_JA_INFORMADO_RECOLETADO", "DADO_OBRIGATORIO_NAO_COLETADO", "FLUXO_VENDA_NAO_SEGUIDO", "MOTIVO_ENCERRAMENTO_INCOMPATIVEL", "SLA_RESPOSTA_ALTO", "LEAD_QUENTE_SEM_FOLLOWUP", "LEAD_ORIGEM_INCONSISTENTE", "LEAD_QUALIFICACAO_INCONSISTENTE", "AUTOMACAO_CONFLITANTE", "DADO_SENSIVEL_SOLICITADO", "URGENCIA_NAO_ENCAMINHADA", "NF_NAO_ENVIADA", "COBRANCA_NAO_ENVIADA"]>>;
|
|
8047
8081
|
note: z.ZodOptional<z.ZodString>;
|
|
8082
|
+
appointment_id: z.ZodOptional<z.ZodString>;
|
|
8083
|
+
calendar_id: z.ZodOptional<z.ZodString>;
|
|
8048
8084
|
}, "strip", z.ZodTypeAny, {
|
|
8049
8085
|
result: "match" | "inconclusive" | "mismatch" | "missing";
|
|
8050
8086
|
expected: string;
|
|
8051
8087
|
claim_type: "promise" | "appointment_informed" | "data_collected" | "required_data" | "outcome" | "question_requires_answer" | "first_concrete_offer" | "patient_status" | "price_informed";
|
|
8052
8088
|
found: string | null;
|
|
8053
8089
|
note?: string | undefined;
|
|
8090
|
+
calendar_id?: string | undefined;
|
|
8091
|
+
appointment_id?: string | undefined;
|
|
8054
8092
|
alert_code?: "AGENDAMENTO_INFORMADO_NAO_REGISTRADO" | "AGENDAMENTO_DIVERGENTE" | "AGENDAMENTO_SOBREPOSTO" | "CONTRADICAO_PREMISSA_ANTERIOR" | "ORIENTACAO_CLINICA_INDEVIDA" | "POLITICA_VIOLADA" | "ULTIMA_MENSAGEM_SEM_RESPOSTA" | "PERGUNTA_NAO_RESPONDIDA" | "PROMESSA_NAO_CUMPRIDA" | "IDENTIDADE_ERRADA" | "DADO_JA_INFORMADO_RECOLETADO" | "DADO_OBRIGATORIO_NAO_COLETADO" | "FLUXO_VENDA_NAO_SEGUIDO" | "MOTIVO_ENCERRAMENTO_INCOMPATIVEL" | "SLA_RESPOSTA_ALTO" | "LEAD_QUENTE_SEM_FOLLOWUP" | "LEAD_ORIGEM_INCONSISTENTE" | "LEAD_QUALIFICACAO_INCONSISTENTE" | "AUTOMACAO_CONFLITANTE" | "DADO_SENSIVEL_SOLICITADO" | "URGENCIA_NAO_ENCAMINHADA" | "NF_NAO_ENVIADA" | "COBRANCA_NAO_ENVIADA" | undefined;
|
|
8055
8093
|
}, {
|
|
8056
8094
|
result: "match" | "inconclusive" | "mismatch" | "missing";
|
|
@@ -8058,6 +8096,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
8058
8096
|
claim_type: "promise" | "appointment_informed" | "data_collected" | "required_data" | "outcome" | "question_requires_answer" | "first_concrete_offer" | "patient_status" | "price_informed";
|
|
8059
8097
|
found: string | null;
|
|
8060
8098
|
note?: string | undefined;
|
|
8099
|
+
calendar_id?: string | undefined;
|
|
8100
|
+
appointment_id?: string | undefined;
|
|
8061
8101
|
alert_code?: "AGENDAMENTO_INFORMADO_NAO_REGISTRADO" | "AGENDAMENTO_DIVERGENTE" | "AGENDAMENTO_SOBREPOSTO" | "CONTRADICAO_PREMISSA_ANTERIOR" | "ORIENTACAO_CLINICA_INDEVIDA" | "POLITICA_VIOLADA" | "ULTIMA_MENSAGEM_SEM_RESPOSTA" | "PERGUNTA_NAO_RESPONDIDA" | "PROMESSA_NAO_CUMPRIDA" | "IDENTIDADE_ERRADA" | "DADO_JA_INFORMADO_RECOLETADO" | "DADO_OBRIGATORIO_NAO_COLETADO" | "FLUXO_VENDA_NAO_SEGUIDO" | "MOTIVO_ENCERRAMENTO_INCOMPATIVEL" | "SLA_RESPOSTA_ALTO" | "LEAD_QUENTE_SEM_FOLLOWUP" | "LEAD_ORIGEM_INCONSISTENTE" | "LEAD_QUALIFICACAO_INCONSISTENTE" | "AUTOMACAO_CONFLITANTE" | "DADO_SENSIVEL_SOLICITADO" | "URGENCIA_NAO_ENCAMINHADA" | "NF_NAO_ENVIADA" | "COBRANCA_NAO_ENVIADA" | undefined;
|
|
8062
8102
|
}>, "many">;
|
|
8063
8103
|
criteria: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
@@ -8212,6 +8252,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
8212
8252
|
verification: z.ZodOptional<z.ZodEnum<["pending", "confirmed_ok", "confirmed", "inconclusive"]>>;
|
|
8213
8253
|
recheck_after: z.ZodOptional<z.ZodEffects<z.ZodDate, Date, unknown>>;
|
|
8214
8254
|
resolved_in_ticket: z.ZodOptional<z.ZodString>;
|
|
8255
|
+
appointment_id: z.ZodOptional<z.ZodString>;
|
|
8256
|
+
calendar_id: z.ZodOptional<z.ZodString>;
|
|
8215
8257
|
first_seen_ticket_id: z.ZodString;
|
|
8216
8258
|
created_at: z.ZodEffects<z.ZodDate, Date, unknown>;
|
|
8217
8259
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -8231,6 +8273,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
8231
8273
|
}[];
|
|
8232
8274
|
first_seen_ticket_id: string;
|
|
8233
8275
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
8276
|
+
calendar_id?: string | undefined;
|
|
8277
|
+
appointment_id?: string | undefined;
|
|
8234
8278
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
8235
8279
|
suggested_action?: string | undefined;
|
|
8236
8280
|
recheck_after?: Date | undefined;
|
|
@@ -8252,6 +8296,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
8252
8296
|
first_seen_ticket_id: string;
|
|
8253
8297
|
created_at?: unknown;
|
|
8254
8298
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
8299
|
+
calendar_id?: string | undefined;
|
|
8300
|
+
appointment_id?: string | undefined;
|
|
8255
8301
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
8256
8302
|
suggested_action?: string | undefined;
|
|
8257
8303
|
recheck_after?: unknown;
|
|
@@ -10044,12 +10090,16 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
10044
10090
|
found: z.ZodNullable<z.ZodString>;
|
|
10045
10091
|
alert_code: z.ZodOptional<z.ZodEnum<["AGENDAMENTO_INFORMADO_NAO_REGISTRADO", "AGENDAMENTO_DIVERGENTE", "AGENDAMENTO_SOBREPOSTO", "CONTRADICAO_PREMISSA_ANTERIOR", "ORIENTACAO_CLINICA_INDEVIDA", "POLITICA_VIOLADA", "ULTIMA_MENSAGEM_SEM_RESPOSTA", "PERGUNTA_NAO_RESPONDIDA", "PROMESSA_NAO_CUMPRIDA", "IDENTIDADE_ERRADA", "DADO_JA_INFORMADO_RECOLETADO", "DADO_OBRIGATORIO_NAO_COLETADO", "FLUXO_VENDA_NAO_SEGUIDO", "MOTIVO_ENCERRAMENTO_INCOMPATIVEL", "SLA_RESPOSTA_ALTO", "LEAD_QUENTE_SEM_FOLLOWUP", "LEAD_ORIGEM_INCONSISTENTE", "LEAD_QUALIFICACAO_INCONSISTENTE", "AUTOMACAO_CONFLITANTE", "DADO_SENSIVEL_SOLICITADO", "URGENCIA_NAO_ENCAMINHADA", "NF_NAO_ENVIADA", "COBRANCA_NAO_ENVIADA"]>>;
|
|
10046
10092
|
note: z.ZodOptional<z.ZodString>;
|
|
10093
|
+
appointment_id: z.ZodOptional<z.ZodString>;
|
|
10094
|
+
calendar_id: z.ZodOptional<z.ZodString>;
|
|
10047
10095
|
}, "strip", z.ZodTypeAny, {
|
|
10048
10096
|
result: "match" | "inconclusive" | "mismatch" | "missing";
|
|
10049
10097
|
expected: string;
|
|
10050
10098
|
claim_type: "promise" | "appointment_informed" | "data_collected" | "required_data" | "outcome" | "question_requires_answer" | "first_concrete_offer" | "patient_status" | "price_informed";
|
|
10051
10099
|
found: string | null;
|
|
10052
10100
|
note?: string | undefined;
|
|
10101
|
+
calendar_id?: string | undefined;
|
|
10102
|
+
appointment_id?: string | undefined;
|
|
10053
10103
|
alert_code?: "AGENDAMENTO_INFORMADO_NAO_REGISTRADO" | "AGENDAMENTO_DIVERGENTE" | "AGENDAMENTO_SOBREPOSTO" | "CONTRADICAO_PREMISSA_ANTERIOR" | "ORIENTACAO_CLINICA_INDEVIDA" | "POLITICA_VIOLADA" | "ULTIMA_MENSAGEM_SEM_RESPOSTA" | "PERGUNTA_NAO_RESPONDIDA" | "PROMESSA_NAO_CUMPRIDA" | "IDENTIDADE_ERRADA" | "DADO_JA_INFORMADO_RECOLETADO" | "DADO_OBRIGATORIO_NAO_COLETADO" | "FLUXO_VENDA_NAO_SEGUIDO" | "MOTIVO_ENCERRAMENTO_INCOMPATIVEL" | "SLA_RESPOSTA_ALTO" | "LEAD_QUENTE_SEM_FOLLOWUP" | "LEAD_ORIGEM_INCONSISTENTE" | "LEAD_QUALIFICACAO_INCONSISTENTE" | "AUTOMACAO_CONFLITANTE" | "DADO_SENSIVEL_SOLICITADO" | "URGENCIA_NAO_ENCAMINHADA" | "NF_NAO_ENVIADA" | "COBRANCA_NAO_ENVIADA" | undefined;
|
|
10054
10104
|
}, {
|
|
10055
10105
|
result: "match" | "inconclusive" | "mismatch" | "missing";
|
|
@@ -10057,6 +10107,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
10057
10107
|
claim_type: "promise" | "appointment_informed" | "data_collected" | "required_data" | "outcome" | "question_requires_answer" | "first_concrete_offer" | "patient_status" | "price_informed";
|
|
10058
10108
|
found: string | null;
|
|
10059
10109
|
note?: string | undefined;
|
|
10110
|
+
calendar_id?: string | undefined;
|
|
10111
|
+
appointment_id?: string | undefined;
|
|
10060
10112
|
alert_code?: "AGENDAMENTO_INFORMADO_NAO_REGISTRADO" | "AGENDAMENTO_DIVERGENTE" | "AGENDAMENTO_SOBREPOSTO" | "CONTRADICAO_PREMISSA_ANTERIOR" | "ORIENTACAO_CLINICA_INDEVIDA" | "POLITICA_VIOLADA" | "ULTIMA_MENSAGEM_SEM_RESPOSTA" | "PERGUNTA_NAO_RESPONDIDA" | "PROMESSA_NAO_CUMPRIDA" | "IDENTIDADE_ERRADA" | "DADO_JA_INFORMADO_RECOLETADO" | "DADO_OBRIGATORIO_NAO_COLETADO" | "FLUXO_VENDA_NAO_SEGUIDO" | "MOTIVO_ENCERRAMENTO_INCOMPATIVEL" | "SLA_RESPOSTA_ALTO" | "LEAD_QUENTE_SEM_FOLLOWUP" | "LEAD_ORIGEM_INCONSISTENTE" | "LEAD_QUALIFICACAO_INCONSISTENTE" | "AUTOMACAO_CONFLITANTE" | "DADO_SENSIVEL_SOLICITADO" | "URGENCIA_NAO_ENCAMINHADA" | "NF_NAO_ENVIADA" | "COBRANCA_NAO_ENVIADA" | undefined;
|
|
10061
10113
|
}>, "many">;
|
|
10062
10114
|
criteria: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
@@ -10211,6 +10263,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
10211
10263
|
verification: z.ZodOptional<z.ZodEnum<["pending", "confirmed_ok", "confirmed", "inconclusive"]>>;
|
|
10212
10264
|
recheck_after: z.ZodOptional<z.ZodEffects<z.ZodDate, Date, unknown>>;
|
|
10213
10265
|
resolved_in_ticket: z.ZodOptional<z.ZodString>;
|
|
10266
|
+
appointment_id: z.ZodOptional<z.ZodString>;
|
|
10267
|
+
calendar_id: z.ZodOptional<z.ZodString>;
|
|
10214
10268
|
first_seen_ticket_id: z.ZodString;
|
|
10215
10269
|
created_at: z.ZodEffects<z.ZodDate, Date, unknown>;
|
|
10216
10270
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -10230,6 +10284,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
10230
10284
|
}[];
|
|
10231
10285
|
first_seen_ticket_id: string;
|
|
10232
10286
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
10287
|
+
calendar_id?: string | undefined;
|
|
10288
|
+
appointment_id?: string | undefined;
|
|
10233
10289
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
10234
10290
|
suggested_action?: string | undefined;
|
|
10235
10291
|
recheck_after?: Date | undefined;
|
|
@@ -10251,6 +10307,8 @@ export declare const zCsqLeadReportSchema: z.ZodObject<{
|
|
|
10251
10307
|
first_seen_ticket_id: string;
|
|
10252
10308
|
created_at?: unknown;
|
|
10253
10309
|
verification?: "confirmed" | "pending" | "confirmed_ok" | "inconclusive" | undefined;
|
|
10310
|
+
calendar_id?: string | undefined;
|
|
10311
|
+
appointment_id?: string | undefined;
|
|
10254
10312
|
subtype?: "valor" | "parcelamento" | "convenio" | "dia_horario" | "procedimento" | "modalidade" | "objecao_sem_argumento" | "sem_oferta_concreta" | "preco_antes_da_queixa" | undefined;
|
|
10255
10313
|
suggested_action?: string | undefined;
|
|
10256
10314
|
recheck_after?: unknown;
|
|
@@ -121,6 +121,8 @@ exports.zCsqAlertSchema = zod_1.z.object({
|
|
|
121
121
|
verification: exports.zCsqVerificationStateSchema.optional(),
|
|
122
122
|
recheck_after: zod_schemas_1.zFirestoreDateSchema.optional(),
|
|
123
123
|
resolved_in_ticket: zod_1.z.string().optional(),
|
|
124
|
+
appointment_id: zod_1.z.string().optional(),
|
|
125
|
+
calendar_id: zod_1.z.string().optional(),
|
|
124
126
|
first_seen_ticket_id: zod_1.z.string(),
|
|
125
127
|
created_at: zod_schemas_1.zFirestoreDateSchema,
|
|
126
128
|
});
|
|
@@ -267,6 +269,8 @@ exports.zCsqCrossCheckSchema = zod_1.z.object({
|
|
|
267
269
|
found: zod_1.z.string().nullable(),
|
|
268
270
|
alert_code: exports.zCsqAlertCodeSchema.optional(),
|
|
269
271
|
note: zod_1.z.string().optional(),
|
|
272
|
+
appointment_id: zod_1.z.string().optional(),
|
|
273
|
+
calendar_id: zod_1.z.string().optional(),
|
|
270
274
|
});
|
|
271
275
|
// ───────── Avaliacao (report-spec §4) ─────────
|
|
272
276
|
exports.zCsqCriterionScoreSchema = zod_1.z.object({
|
|
@@ -139,6 +139,8 @@ export const zCsqAlertSchema = z.object({
|
|
|
139
139
|
verification: zCsqVerificationStateSchema.optional(),
|
|
140
140
|
recheck_after: zFirestoreDateSchema.optional(),
|
|
141
141
|
resolved_in_ticket: z.string().optional(),
|
|
142
|
+
appointment_id: z.string().optional(),
|
|
143
|
+
calendar_id: z.string().optional(),
|
|
142
144
|
first_seen_ticket_id: z.string(),
|
|
143
145
|
created_at: zFirestoreDateSchema,
|
|
144
146
|
});
|
|
@@ -306,6 +308,8 @@ export const zCsqCrossCheckSchema = z.object({
|
|
|
306
308
|
found: z.string().nullable(),
|
|
307
309
|
alert_code: zCsqAlertCodeSchema.optional(),
|
|
308
310
|
note: z.string().optional(),
|
|
311
|
+
appointment_id: z.string().optional(),
|
|
312
|
+
calendar_id: z.string().optional(),
|
|
309
313
|
});
|
|
310
314
|
|
|
311
315
|
// ───────── Avaliacao (report-spec §4) ─────────
|
|
@@ -132,5 +132,32 @@ export interface ILead extends IProfile {
|
|
|
132
132
|
} | null;
|
|
133
133
|
acquisition_sources?: ILeadReferral[] | null;
|
|
134
134
|
reactivation?: ILeadReactivation | null;
|
|
135
|
+
/**
|
|
136
|
+
* Provider que originou o lead: `chatbee`, `hub-waba`, `hub-instagram`,
|
|
137
|
+
* `waba-history`, `campaign`... Escrito desde sempre pelos dois criadores de
|
|
138
|
+
* lead do chat; só agora declarado (a index signature já o cobria em runtime).
|
|
139
|
+
*/
|
|
140
|
+
origin?: string | null;
|
|
141
|
+
/**
|
|
142
|
+
* feat-157 — CANAL por onde o contato entrou (o número de WhatsApp / conta IG),
|
|
143
|
+
* não o provider. First-touch-wins: gravado uma única vez, na criação do lead, e
|
|
144
|
+
* nunca reescrito por um inbound posterior em outro canal.
|
|
145
|
+
*
|
|
146
|
+
* `contact.channel_ids` NÃO substitui isto: é array e acumula (31% dos contatos
|
|
147
|
+
* de um tenant de dois números já falaram nos dois).
|
|
148
|
+
*
|
|
149
|
+
* No espaço de id do `evo-chat/channels` quando o lead nasce no hub-omni; no id
|
|
150
|
+
* numérico do Chatbee quando nasce no pipeline legado. Filtre por
|
|
151
|
+
* `origin_channel_name`, que é coerente entre as duas eras.
|
|
152
|
+
*/
|
|
153
|
+
origin_channel_id?: string | null;
|
|
154
|
+
origin_channel_name?: string | null;
|
|
155
|
+
/**
|
|
156
|
+
* feat-157 — último departamento que atendeu o lead, denormalizado do ticket na
|
|
157
|
+
* criação e na transferência (id do espaço `evo-people`). Alimenta o
|
|
158
|
+
* `ultimo_setor` do prompt da HubIA e a faceta de departamento da listagem.
|
|
159
|
+
*/
|
|
160
|
+
last_department_id?: string | null;
|
|
161
|
+
last_department_name?: string | null;
|
|
135
162
|
[key: string]: unknown;
|
|
136
163
|
}
|
|
@@ -178,5 +178,32 @@ export interface ILead extends IProfile {
|
|
|
178
178
|
acquisition_sources?: ILeadReferral[] | null;
|
|
179
179
|
// Régua de reativação (feat-037) — mantida pelo subscriber ticket_closed + task lead_reactivation.
|
|
180
180
|
reactivation?: ILeadReactivation | null;
|
|
181
|
+
/**
|
|
182
|
+
* Provider que originou o lead: `chatbee`, `hub-waba`, `hub-instagram`,
|
|
183
|
+
* `waba-history`, `campaign`... Escrito desde sempre pelos dois criadores de
|
|
184
|
+
* lead do chat; só agora declarado (a index signature já o cobria em runtime).
|
|
185
|
+
*/
|
|
186
|
+
origin?: string | null;
|
|
187
|
+
/**
|
|
188
|
+
* feat-157 — CANAL por onde o contato entrou (o número de WhatsApp / conta IG),
|
|
189
|
+
* não o provider. First-touch-wins: gravado uma única vez, na criação do lead, e
|
|
190
|
+
* nunca reescrito por um inbound posterior em outro canal.
|
|
191
|
+
*
|
|
192
|
+
* `contact.channel_ids` NÃO substitui isto: é array e acumula (31% dos contatos
|
|
193
|
+
* de um tenant de dois números já falaram nos dois).
|
|
194
|
+
*
|
|
195
|
+
* No espaço de id do `evo-chat/channels` quando o lead nasce no hub-omni; no id
|
|
196
|
+
* numérico do Chatbee quando nasce no pipeline legado. Filtre por
|
|
197
|
+
* `origin_channel_name`, que é coerente entre as duas eras.
|
|
198
|
+
*/
|
|
199
|
+
origin_channel_id?: string | null;
|
|
200
|
+
origin_channel_name?: string | null;
|
|
201
|
+
/**
|
|
202
|
+
* feat-157 — último departamento que atendeu o lead, denormalizado do ticket na
|
|
203
|
+
* criação e na transferência (id do espaço `evo-people`). Alimenta o
|
|
204
|
+
* `ultimo_setor` do prompt da HubIA e a faceta de departamento da listagem.
|
|
205
|
+
*/
|
|
206
|
+
last_department_id?: string | null;
|
|
207
|
+
last_department_name?: string | null;
|
|
181
208
|
[key: string]: unknown; // index signature
|
|
182
209
|
}
|
|
@@ -132,6 +132,10 @@ export interface ICsqAlert {
|
|
|
132
132
|
recheck_after?: Date;
|
|
133
133
|
/** Ticket em que o alerta foi constatado como resolvido. */
|
|
134
134
|
resolved_in_ticket?: string;
|
|
135
|
+
/** So em alertas de agenda: agendamento com que o claim foi cruzado, para o
|
|
136
|
+
* Nexus linkar `/{tenant}/evo-med/calendar/{calendar_id}/appointment/{appointment_id}`. */
|
|
137
|
+
appointment_id?: string;
|
|
138
|
+
calendar_id?: string;
|
|
135
139
|
/** Ticket em que o alerta apareceu pela primeira vez (herdado x novo). */
|
|
136
140
|
first_seen_ticket_id: string;
|
|
137
141
|
created_at: Date;
|
|
@@ -305,6 +309,9 @@ export interface ICsqCrossCheck {
|
|
|
305
309
|
/** Alerta gerado por esta verificacao, quando houve. */
|
|
306
310
|
alert_code?: CsqAlertCode;
|
|
307
311
|
note?: string;
|
|
312
|
+
/** So em cruzamentos de agenda: agendamento encontrado (link no Nexus). */
|
|
313
|
+
appointment_id?: string;
|
|
314
|
+
calendar_id?: string;
|
|
308
315
|
}
|
|
309
316
|
/** Nota de um criterio. Todo criterio < 100 exige evidencia valida; sem ela o
|
|
310
317
|
* codigo zera para `null` e tira do denominador. */
|
|
@@ -314,6 +314,10 @@ export interface ICsqAlert {
|
|
|
314
314
|
recheck_after?: Date;
|
|
315
315
|
/** Ticket em que o alerta foi constatado como resolvido. */
|
|
316
316
|
resolved_in_ticket?: string;
|
|
317
|
+
/** So em alertas de agenda: agendamento com que o claim foi cruzado, para o
|
|
318
|
+
* Nexus linkar `/{tenant}/evo-med/calendar/{calendar_id}/appointment/{appointment_id}`. */
|
|
319
|
+
appointment_id?: string;
|
|
320
|
+
calendar_id?: string;
|
|
317
321
|
/** Ticket em que o alerta apareceu pela primeira vez (herdado x novo). */
|
|
318
322
|
first_seen_ticket_id: string;
|
|
319
323
|
created_at: Date;
|
|
@@ -519,6 +523,9 @@ export interface ICsqCrossCheck {
|
|
|
519
523
|
/** Alerta gerado por esta verificacao, quando houve. */
|
|
520
524
|
alert_code?: CsqAlertCode;
|
|
521
525
|
note?: string;
|
|
526
|
+
/** So em cruzamentos de agenda: agendamento encontrado (link no Nexus). */
|
|
527
|
+
appointment_id?: string;
|
|
528
|
+
calendar_id?: string;
|
|
522
529
|
}
|
|
523
530
|
|
|
524
531
|
// ───────── Avaliacao (report-spec §4) ─────────
|