# Database

### MongoDB Connection

The project uses Mongoose for MongoDB connection. The connection is handled in `lib/db/mongoose.ts` with connection pooling.

### User Model

The User model is defined in `models/User.ts`:

```typescript
interface IUser {
  email: string;
  name: string;
  emailVerified?: boolean;
  image?: string;
  createdAt: Date;
  updatedAt: Date;
}
```