CarePulse: Reimagining Healthcare Scheduling
Healthcare shouldn't feel like navigating a maze. CarePulse is a modern patient management platform that transforms the appointment booking experience from frustrating phone calls and paperwork into a seamless digital journey.
The Challenge
Every day, healthcare teams lose countless hours to:
- Manual data entry across disconnected spreadsheets
- Phone tag with patients trying to book appointments
- Security risks from sending sensitive information via email
- No-shows from poor communication and reminder systems
I built CarePulse to solve these pain points with a modern tech stack that prioritizes both patient experience and administrative efficiency.
The Solution
For Patients:
- π― Frictionless onboarding β Simple landing page captures essentials, then guides users through a multi-step registration wizard
- π Smart document handling β Secure upload and storage of identity documents and medical records
- π± Real-time updates β Instant SMS notifications via Twilio for appointment confirmations and changes
- π Privacy-first β Built-in consent management and HIPAA-conscious data handling
For Healthcare Staff:
- π Unified dashboard β Review all appointment requests, patient profiles, and scheduling metrics in one place
- β‘ One-click actions β Approve, reschedule, or cancel appointments with instant patient notification
- π Performance monitoring β Sentry integration tracks errors and bottlenecks in production
- π Zero backend maintenance β Appwrite handles auth, database, and storage infrastructure
Technical Architecture
The Next.js App Router organizes the experience into three core flows:
1. Patient Intake Flow
The landing page renders a clean PatientForm that captures essential information. When submitted, the createUser server action provisions an Appwrite user account, gracefully handling duplicate email or phone collisions before redirecting to the registration wizard.
2. Profile Registration
The registration page hydrates with Appwrite data server-side. If the user already has a patient document, we skip ahead to appointment booking. Otherwise, we render the RegisterForm with prefilled data and secure file upload handling backed by Appwrite storage.
3. Scheduling & Admin Operations
Patients submit pending appointment requests through createAppointment, while admins can confirm or cancel via updateAppointment. Both actions live in a centralized module and trigger path revalidation to keep the admin dashboard instantly updated.
All business logic lives in server actionsβno API routes needed. This keeps code co-located with UI components while maintaining type safety end-to-end.
Code Highlights
Server actions keep form submissions clean and type-safe. Here's the appointment creator:
// lib/actions/appointment.actions.ts
export const createAppointment = async (
appointment: CreateAppointmentParams
) => {
const cleanAppointment = {
userId: appointment.userId,
client: appointment.patient,
schedule: appointment.schedule,
reason: appointment.reason,
status: appointment.status,
note: appointment.note || '',
company: appointment.company || 'Unknown',
}
const newAppointment = await databases.createDocument(
DATABASE_ID!,
APPOINTMENT_COLLECTION_ID!,
ID.unique(),
cleanAppointment
)
revalidatePath('/admin')
return parseStringify(newAppointment)
}
The appointment form intelligently handles creation, scheduling, and cancellation with a single component:
// components/forms/AppointmentForm.tsx
const onSubmit = async (values: z.infer<typeof AppointmentFormValidation>) => {
const status =
type === 'schedule'
? 'scheduled'
: type === 'cancel'
? 'cancelled'
: 'pending'
if (type === 'create' && patientId) {
const appointment = {
userId,
patient: patientId,
schedule: new Date(values.schedule),
reason: values.reason!,
status: status as Status,
note: values.note || '',
}
const newAppointment = await createAppointment(appointment)
if (newAppointment) {
form.reset()
router.push(
`/patients/${userId}/new-appointment/success?appointmentId=${newAppointment.$id}`
)
}
} else {
await updateAppointment({
userId,
appointmentId: appointment?.$id!,
timeZone: Intl.DateTimeFormat().resolvedOptions().timeZone,
appointment: {
schedule: new Date(values.schedule),
status: status as Status,
cancellationReason: values.cancellationReason,
},
type,
})
}
}
Demo
Impact & Key Learnings
What This Project Demonstrates:
CarePulse proves that modern healthcare software doesn't require massive infrastructure investments. By orchestrating Next.js 14, Appwrite, and Twilio, we built a production-ready patient management system that:
β
Eliminates backend complexity β Server actions replace traditional API routes
β
Scales effortlessly β Appwrite handles auth, database, and storage without DevOps overhead
β
Maintains type safety β End-to-end TypeScript from forms to database
β
Delivers real-time UX β Path revalidation keeps admin dashboards instantly updated
Key Takeaways:
- Server actions are game-changers for form-heavy applicationsβno API boilerplate needed
- Managed backends like Appwrite let you ship faster without sacrificing control
- SMS notifications dramatically reduce no-shows and improve patient satisfaction
- Modular form architecture makes adding new workflows trivial
This architecture pattern transfers directly to any intake-driven workflow: legal consultations, service bookings, educational enrollment, or customer onboarding.