sesion-clinic-workflow-platform

Implements appointment scheduling, WhatsApp automation, AFIP invoicing, and video consultations for psychology clinics.

4|Updated May 16, 2026
One-click install
npx skills add https://github.com/reason-machines/devtools-skills --skill sesion-clinic-workflow-platform-reason-machines
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: sesion-clinic-workflow-platform
Source: https://github.com/reason-machines/devtools-skills/tree/main/skills/sesion-clinic-workflow-platform
Command: npx skills add https://github.com/reason-machines/devtools-skills --skill sesion-clinic-workflow-platform-reason-machines

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Psychology clinics and independent practitioners in Argentina need to coordinate appointment scheduling, patient communication, tax-compliant invoicing, and telehealth sessions across disconnected tools, which creates manual overhead and missed reminders. ## Core Features & Use Cases - Agenda Management: NestJS appointment service with Prisma/PostgreSQL that detects practitioner and room conflicts, assigns session durations by type, and emits events for downstream workflows. - WhatsApp Automation: Baileys-based messaging that sends appointment reminders in Spanish, parses confirmation replies, delivers PDF invoices, and flags crisis keywords to alert practitioners. - AFIP Electronic Invoicing: Generates CAE-authorized invoices via the AFIP SDK with correct invoice types, IVA 21% calculations, and monthly fiscal summaries. - Video Consultations: LiveKit integration issuing JWT access tokens with practitioner admin grants, plus a Svelte video component with mute, camera, and end-call controls. - Use Case: A clinic books a virtual session, the patient receives a WhatsApp reminder 24 hours before, joins a LiveKit video room, and automatically receives an AFIP-compliant invoice after the session ends. ## Quick Start Set up the Sesión clinic platform by cloning the repository, configuring the environment variables for PostgreSQL, Redis, LiveKit, WhatsApp, and AFIP, then running the Prisma migrations and starting the NestJS backend and SvelteKit frontend.

Frequently Asked Questions about sesion-clinic-workflow-platform

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I send WhatsApp appointment reminders with Baileys in NestJS?▼

Initialize a Baileys socket with useMultiFileAuthState, then listen for the appointment.created event to schedule reminders. Use date-fns with the Spanish locale to format dates and sendMessage to deliver reminder texts to patient phone numbers.

How to generate AFIP electronic invoices in Node.js?▼

Use the @afipsdk/afip.js library with your CUIT, certificate, and key files. Call ElectronicBilling.getLastVoucher to get the next invoice number, then createVoucher with amounts, IVA breakdown, and document type to receive a CAE authorization code.

How do I detect appointment scheduling conflicts with Prisma?▼

Query appointments where the practitioner or room has overlapping startTime and endTime ranges, excluding cancelled and no-show statuses. Throw a ConflictException if any overlapping records exist before creating the new appointment.

Does LiveKit support practitioner-only controls in video sessions?▼

Yes, LiveKit AccessToken grants can be scoped per user type. Practitioners receive roomAdmin and roomRecord grants while patients get standard roomJoin, canPublish, and canSubscribe permissions, with tokens set to expire after two hours.

Why does the Baileys WhatsApp connection keep disconnecting?▼

Baileys connections close when the session is logged out or network errors occur. Check the DisconnectReason in connection.update events and reinitialize the socket unless the status code indicates a loggedOut state requiring re-authentication.

What are the limitations of WhatsApp Web automation with Baileys?▼

Baileys uses the unofficial WhatsApp Web API, so sessions can be revoked and accounts risk bans under heavy automated use. It requires persistent credential storage and reconnection logic, unlike the official WhatsApp Business API.