can you code to make ai app for doctors online consultation ?

Asking for Preferences
Running Command
Running Command
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Running Command
Model call limits exceeded: run limit (20/20)

continue

Running Command
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Writing File
Running Command
Model call limits exceeded: run limit (20/20)

continue

Running Command
Running Command
Running Command
Running Command
Running Command
Running Command
Running Command
Running Command
Running Command
Running Command
The project is complete. Here's everything that was built:

MedConsult AI — Complete

Download the project:

file

File ·


What was built (34 files)

Core Config

FilePurpose
package.jsonAll dependencies (Next.js 14, Prisma, NextAuth v5, OpenAI, Pusher, Zod, Tailwind)
prisma/schema.prismaFull DB schema — 10 models
prisma/seed.ts5 demo doctors + 1 patient
.env.exampleAll required environment variables
tailwind.config.js, tsconfig.json, postcss.config.jsProject config

Database Schema (Prisma + PostgreSQL)

User → PatientProfile / DoctorProfile → Consultation → Message → Appointment → SymptomCheck → Notification

Pages

RouteWhat it does
/Marketing landing page with stats, features, CTA
/loginEmail + Google OAuth sign in
/registerRegister as Patient or Doctor
/dashboardRole-aware — doctor sees queue/patients; patient sees quick actions
/symptom-checkerAI symptom triage — tags, duration, severity → GPT-4o analysis
/doctorsBrowse/search doctors, filter by specialty, start consultation
/consultationList all consultations
/consultation/[id]Real-time chat room + AI summary panel
/appointmentsUpcoming/past appointments
/profileUser profile settings

API Routes

RouteWhat it does
POST /api/auth/registerCreate patient or doctor account
GET/POST /api/consultationsList or create consultations
GET/PATCH /api/consultations/[id]Fetch chat + update status/diagnosis
POST /api/messagesSend message + trigger Pusher real-time event
GET/POST /api/appointmentsManage appointments
GET /api/doctorsSearch verified doctors
POST /api/ai/symptom-checkGPT-4o triage + save to DB
POST /api/ai/chatStreaming AI medical assistant
POST /api/ai/summarizeGenerate SOAP clinical note from transcript

Quick Start

cd medconsult-ai
cp .env.example .env.local   # fill in DB, OpenAI, Pusher keys
npm install
npm run db:push
npm run db:seed
npm run dev
Demo logins (after seed):
  • Patient: patient@demo.com / password123
  • Doctor: dr.carter@demo.com / password123

send code

Running Command
Running Command
Here's your download link:
📦

medconsult ai.tar

Archive · GZ


To extract and run:
tar -xzf medconsult-ai.tar.gz
cd medconsult-ai
cp .env.example .env.local   # fill in your keys
npm install
npm run db:push
npm run db:seed
npm run dev
The archive contains all 34 source files — pages, API routes, DB schema, seed, config, and README.

how to. open it on Mac?

Here's how to open and run the project on a Mac, step by step:

Step 1 — Extract the file

Option A: Double-click the .tar.gz file in Finder — it auto-extracts to a folder called medconsult-ai.
Option B: Terminal
tar -xzf ~/Downloads/medconsult-ai.tar.gz -C ~/Downloads

Step 2 — Install prerequisites (one-time setup)

Install Homebrew (Mac package manager)

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Install Node.js

brew install node
Verify: node -v → should show v18+

Install PostgreSQL

brew install postgresql@15
brew services start postgresql@15
Create the database:
createdb medconsult

Step 3 — Open the project in VS Code

cd ~/Downloads/medconsult-ai
code .
If code command not found: open VS Code → Cmd+Shift+P → type "Shell Command: Install 'code' command"

Step 4 — Set up environment variables

cp .env.example .env.local
Open .env.local and fill in:
DATABASE_URL="postgresql://YOUR_MAC_USERNAME@localhost:5432/medconsult"
NEXTAUTH_SECRET="any-random-string-here"
NEXTAUTH_URL="http://localhost:3000"
OPENAI_API_KEY="sk-..."         # from platform.openai.com
PUSHER_APP_ID=""                # free account at pusher.com
PUSHER_KEY=""
PUSHER_SECRET=""
PUSHER_CLUSTER="us2"
NEXT_PUBLIC_PUSHER_KEY=""
NEXT_PUBLIC_PUSHER_CLUSTER="us2"
To find your Mac username: run whoami in Terminal

Step 5 — Install dependencies & run

npm install
npm run db:generate
npm run db:push
npm run db:seed
npm run dev
Then open your browser at http://localhost:3000

Quick summary

StepCommand
ExtractDouble-click the file
Install Nodebrew install node
Install Postgresbrew install postgresql@15
Create DBcreatedb medconsult
Install packagesnpm install
Setup DBnpm run db:push && npm run db:seed
Start appnpm run dev

Demo login after seed:
  • Patient: patient@demo.com / password123
  • Doctor: dr.carter@demo.com / password123
This is a shared conversation. Sign in to Orris to start your own chat.