Vim Connect App SDK
Build applications that integrate directly into EHR provider workflows
The Vim Connect App SDK lets you build applications that run inside Electronic Health Record (EHR) systems. Your app appears as a sidebar within the provider's EHR, with real-time access to patient data, encounters, referrals, and orders.
How It Works
Vim Connect uses a Chrome extension that injects the Vim Hub — an application hub overlay — into web-based EHR systems. Your application loads inside this hub and communicates with the extension through the SDK.
EHR (browser tab)
├── Vim Connect Extension
│ ├── Detects EHR context (patient, encounter, etc.)
│ ├── Extracts data from the page
│ └── Injects the Vim Hub sidebar
│ └── Your Application
│ └── @vimconnect/app-sdk
│ ├── Workflow Events (chart opened, encounter started)
│ ├── Context (real-time entity data)
│ ├── Entity API (read patient, encounter, order data)
│ ├── Writeback (update EHR fields)
│ └── Hub Controls (badges, notifications, status)What You Can Build
- Clinical decision support — Surface care gaps, drug interactions, or quality measures when a patient chart opens
- Documentation assistants — Pre-fill encounter notes, assessment fields, or referral details
- Prior authorization — Automate auth workflows when orders or referrals are created
- Care coordination — Display care team info, schedule follow-ups, or track referrals
- Population health — Show risk scores, wellness reminders, or preventive care alerts
SDK Capabilities
| Capability | Description |
|---|---|
| Workflow Events | Get notified when the provider opens a chart, starts an encounter, creates a referral, or places an order |
| Context Tracking | Subscribe to real-time entity data changes as the provider navigates the EHR |
| Entity API | Read patient demographics, problems, medications, insurance, encounter details, and more |
| Writeback | Update encounter notes, diagnoses, orders, and referrals — with permission controls for disruptive operations |
| Hub Controls | Set your app icon status, show notification badges, display push notifications, and control visibility |
| Type Safety | Full TypeScript types and Zod schemas for all entities, events, and API methods |
Quick Example
import { initVimSDK } from '@vimconnect/app-sdk';
import type { Patient } from '@vimconnect/app-sdk';
// Initialize the SDK (runs inside the Vim Hub sidebar)
const sdk = await initVimSDK();
// Tell the hub your app is ready
sdk.hub.setActivationStatus('ENABLED');
// React to workflow events
sdk.ehr.workflow.on('chart_open', (event) => {
const patient = event.entities.patient; // fully typed
console.log('Chart opened for patient:', patient.id);
});
// Track real-time context changes
sdk.ehr.context.onChange('encounter_open:encounter', (prev, curr) => {
if (curr) {
console.log('Active encounter:', curr.fields.cc);
}
});
// Read additional data of the current patient context
const result = await sdk.ehr.api.patient.getPatient();
// Write back to the EHR (with permission handling)
const cap = sdk.ehr.context.encounter.getCapability('update');
if (cap.available && sdk.ehr.context.encounter.hasPermission('update')) {
await sdk.ehr.context.encounter.update({
assessment: { findings: 'Normal exam' },
});
}Start Here
Two shortcuts that save the most time on day one:
- Start from the Demo App — fork a working Vim app with the OAuth flow already wired and an explorer that drives every capability your manifest declares against live EHR context.
- Build with an AI Agent —
@vimconnect/app-sdkships a Claude Code skill,vim-app-sdk-docs, that makes your agent look up real entity fields, event ids, and method signatures instead of inventing them. Onecpto install.
Next Steps
- Quick Start — Build your first Vim app in 5 minutes
- Authentication — Implement OAuth 2.0 for your application
- EHR Connectivity — Work with events, context, and APIs
- Vim Hub — Control your app's presence in the hub
- API Reference — Full type reference for entities, events, and methods