# Telegram Staff Notifications

The optional `telegram_notifications` module sends privacy-minimized exam-request cards to verified staff and records acknowledgement. It does not support chat, clinical decisions, reports, patient messaging, or critical-result escalation.

## Production setup

1. Create a hospital-governed Telegram bot and enable the module in **Administration → Module Control**.
2. Open **Administration → Telegram Notifications**, save the encrypted bot token and bot username, then test the connection.
3. Expose the RIS through approved public HTTPS and register the webhook. Telegram calls the webhook with a secret-token header that RIS validates.
4. Run a persistent Laravel queue worker (`php artisan queue:work`) under the production process supervisor.
5. Each staff member opens **My Profile**, generates a 15-minute code, and sends `/start CODE` to the approved bot.
6. Requesters select one or more verified staff when submitting an exam request, or notify them from the submitted request page.

## Data boundary

Telegram receives only request number, priority, modality/examination, requesting department, preferred date, mobile-exam flag, and a permission-protected RIS link. Patient identifiers, clinical indication/history, safety information, reports and results remain inside RIS.

Delivery, failures, linking, revocation and acknowledgement are audited. Disabling the module blocks its staff/admin routes and prevents delivery while retaining records.
