An AI-powered legal case management system designed for modern law firms to streamline case management, enhance productivity, and provide AI-assisted legal insights.
Our application combines AI-powered legal research with efficient scheduling and document management, making legal tasks more accessible and efficient.
| Frontend | Backend | Database | Auth & Security | Testing |
|---|---|---|---|---|
| Next.js 15 | Node.js | PostgreSQL | NextAuth.js | Pytest |
| React | Next.js API Routes | Prisma ORM | CSRF Protection | Playwright |
| TypeScript | Server Actions | JSON | JWT | Requests |
| Tailwind CSS | Bcrypt |
git clone https://github.com/your-username/advocate-diary-app.git
cd advocate-diary-appnpm install
# or
pnpm installcp .env.example .env
# Edit .env file with your database and authentication settingsnpx prisma migrate dev
npx prisma db seed
# (quick and handy way to reset)
npx prisma migrate resetnpm run dev
# or
pnpm devAccess the application
The app will be available at http://localhost:3000
Create a Python virtual environment for testing:
python -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
pip install pytest requests playwright pytest-playwright
playwright install chromium # Setup playwright for e2e testingThe application includes several test suites:
# Test user operations (create/delete users)
python -m pytest tests/test_user_operations.py
# Test case operations (create/delete cases)
python -m pytest tests/test_case_operations.py
# Test authentication API
python -m pytest tests/test_api_login.py# Auth unit tests
python -m pytest tests/test_auth_unit.py
# Form validation tests
python -m pytest tests/test_form_validation.py# Run end-to-end login tests
python -m pytest tests/test_login_e2e.pypython -m pytestRunning pytest automates testing process and generates
report.html
View the latest automated test report: https://kshg9.github.io/advocate-diary-app/report.html
![]() |
![]() |
| Cases Dashboard | AI Assistant |
User Profile & Personal Information
The application provides RESTful API endpoints for cases and users:
GET /api/cases: Get all cases (filtered by user
role)POST /api/cases: Create a new caseGET /api/cases/:id: Get a specific casePUT /api/cases/:id: Update a caseDELETE /api/cases/:id: Delete a caseGET /api/admin/users: Get all users (admin only)POST /api/admin/users: Create a new user (admin
only)GET /api/admin/users/:id: Get a specific user (admin
only)DELETE /api/admin/users/:id: Delete a user (admin
only)This project is currently Unlicenced - will be changed later.
Visit our project website for more information and documentation: https://kshg9.github.io/advocate-diary-app/