• Joined on 2026-08-03
ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:08:12 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:08:12 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Consider using explicit property syntax for clarity: { jefeMecanicoId: jefeMecanicoId }

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:41 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:41 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:41 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

The default parameter db = prisma works because PrismaClient satisfies TransactionClient, but add a comment to clarify this intentional covariance for future maintainers.

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:09 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:09 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Function name 'yaProcesado' suggests it returns true if already processed, but it returns false on successful insert (new message). Consider renaming to 'registrarProcesado' or inverting logic for clarity.

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Header 'x-hub-signature-256' may be undefined; firmaValida should handle missing header explicitly or check here before calling.

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Fire-and-forget with empty catch hides potential issues marking messages as read; at least log the error for observability.

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Catch-all returns 200 to avoid Meta retries, but errors are only logged. Add alerting/monitoring (e.g., Sentry) so failures don't go unnoticed.

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Module-level variable 'ultimaLimpieza' is not reliable in serverless/multi-instance environments; each instance has its own memory and cold starts reset it. Consider a cron job or DB-based cleanup instead.

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Cleanup runs on every POST request adding latency; with the unreliable timer it may run too often or not at all. Move to a scheduled job (e.g., Vercel Cron) or a separate background worker.

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:07:08 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Type assertion without runtime validation; if Meta changes payload structure this will fail silently. Use a schema validator (e.g., zod) to parse and validate the webhook payload.

ai-bot commented on pull request jpbeldomenico/taller_automotriz#4 2026-08-05 12:06:56 -03:00
feat: bot de reservas por WhatsApp (F0) y flujo web jefe -> trabajo

Inline review