https://github.com/adnanayaz1/messengerprisma
A real-time messaging app that lets users chat one-on-one or in groups—simple, fast, and built for seamless communication.
https://github.com/adnanayaz1/messengerprisma
authjs cloudinary mongodb-atlas next15 prisma-orm shadcn-ui typescript
Last synced: 4 months ago
JSON representation
A real-time messaging app that lets users chat one-on-one or in groups—simple, fast, and built for seamless communication.
- Host: GitHub
- URL: https://github.com/adnanayaz1/messengerprisma
- Owner: AdnanAyaz1
- Created: 2025-04-11T17:38:01.000Z (6 months ago)
- Default Branch: main
- Last Pushed: 2025-04-13T09:15:53.000Z (6 months ago)
- Last Synced: 2025-05-18T22:13:22.571Z (5 months ago)
- Topics: authjs, cloudinary, mongodb-atlas, next15, prisma-orm, shadcn-ui, typescript
- Language: TypeScript
- Homepage: https://messenger-prisma.vercel.app
- Size: 152 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Real-Time Messenger Application
A full-stack real-time messenger application built with modern web technologies.
## Tech Stack
### Frontend
- **Framework**: Next.js 15.2.0 with App Router
- **UI Components**:
- Custom components built with Radix UI primitives
- Shadcn UI components
- Tailwind CSS for styling
- **Authentication**: NextAuth.js v5 with multiple providers (Google, GitHub, Credentials)
- **Form Management**:
- React Hook Form
- Zod for form validation
- **State Management**: React Hooks
- **Real-time Updates**: Pusher.js
- **Image Uploads**: Cloudinary
- **HTTP Client**: Axios### Backend
- **Runtime**: Node.js with Next.js API Routes
- **Database**: MongoDB with Prisma ORM
- **Authentication**: NextAuth.js with JWT
- **Real-time Server**: Pusher
- **Password Hashing**: bcryptjs### Validation & Type Safety
- **Runtime Validation**: Zod schemas
- **Static Type Checking**: TypeScript
- **API Response Handling**: Custom utility functions
- **Database Types**: Prisma generated types### Key Features
- Real-time messaging using Pusher
- Group chat functionality
- User presence detection
- Image sharing in conversations
- Message read receipts
- User profile customization
- Responsive design for all devices
- Social authentication (Google, GitHub)
- Email/Password authentication
- Username availability checking
- Form validation with error messages## Getting Started
1. Clone the repository
2. Install dependencies:
```bash
npm install
```3. Create a `.env` file with the following variables:
```env
DATABASE_URL=
NEXTAUTH_SECRET=
NEXT_PUBLIC_PUSHER_APP_KEY=
PUSHER_APP_ID=
PUSHER_SECRET=
NEXT_PUBLIC_CLOUDINARY_CLOUD_NAME=
GITHUB_ID=
GITHUB_SECRET=
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
```4. Setup the database:
```bash
npx prisma generate
npx prisma db push
```5. Run the development server:
```bash
npm run dev
```## Project Structure
```
├── actions/ # Server actions
├── app/ # Next.js app router pages
├── components/ # Reusable UI components
├── hooks/ # Custom React hooks
├── lib/ # Utility functions and configurations
├── prisma/ # Database schema and client
├── public/ # Static assets
└── types/ # TypeScript type definitions
```## Contributing
1. Fork the repository
2. Create a new branch
3. Make your changes
4. Submit a pull request## License
MIT License