A full-stack platform that empowers Canadians to hold their elected representatives accountable by visualizing MPs' voting records, conflicts of interest, and parliamentary activity through an intuitive, data-driven interface.
RateMyMP bridges the gap between citizens and Parliament by aggregating and presenting federal political data in an accessible format. Search for your MP, explore their voting history, track parliamentary motions, and stay informed about how your representatives vote on issues that matter to you.
-
MP Search & Discovery
- Search by MP name or postal code
- View comprehensive MP profiles with party affiliation and constituency
-
Parliamentary Motion Tracking
- Browse recent parliamentary motions and bills
- Filter by category and voting outcome
- View detailed vote breakdowns by party
-
Voting Records Visualization
- Interactive charts showing voting patterns
- Party-by-party vote breakdowns
- Historical voting trends
-
MP Report Cards
- Detailed voting history analysis
- Conflicts of interest visualization
- Parliamentary activity tracking
-
High-Performance Architecture
- React + TypeScript frontend with Tailwind CSS
- Express.js backend with PostgreSQL database
- React Query for efficient data caching
- Sub-100ms API response times
Frontend:
- React 18 with TypeScript
- Tailwind CSS for styling
- React Query for state management and caching
- React Router for navigation
- Recharts for data visualization
Backend:
- Node.js with Express.js
- PostgreSQL database
- REST API architecture
- Automated data validation
DevOps:
- Docker containerization
- CI/CD pipeline (GitHub Actions)
This project integrates data from trusted Canadian parliamentary sources:
- Our Commons - Official House of Commons data
- OpenParliament - Parliamentary voting records and debates
- Parliament of Canada Open Data - Official government APIs
- Node.js 18+
- PostgreSQL 14+
- npm or yarn
- Clone the repository
git clone https://github.com/yourusername/ratemymp.git
cd ratemymp- Install dependencies
# Install frontend dependencies
cd client
npm install
# Install backend dependencies
cd ../server
npm install- Set up environment variables
# In server directory
cp .env.example .env
# Edit .env with your PostgreSQL credentials- Initialize database
cd server
npm run db:migrate
npm run db:seed- Run the application
# Terminal 1 - Backend
cd server
npm run dev
# Terminal 2 - Frontend
cd client
npm run devThe app will be available at http://localhost:5173
docker-compose upratemymp/
├── client/ # React frontend
│ ├── src/
│ │ ├── components/ # Reusable UI components
│ │ ├── pages/ # Page components
│ │ ├── services/ # API service layer
│ │ └── hooks/ # Custom React hooks
│ └── package.json
├── server/ # Express backend
│ ├── src/
│ │ ├── routes/ # API routes
│ │ ├── controllers/ # Request handlers
│ │ ├── models/ # Database models
│ │ └── services/ # Business logic
│ └── package.json
└── docker-compose.yml
Each MP has a dedicated profile showing:
- Biographical information
- Current committee memberships
- Recent votes and positions
- Contact information
Browse and filter parliamentary motions with:
- Category-based filtering
- Vote outcome visualization
- Party breakdown charts
- Historical motion archives
Find your representative quickly:
- Search by name (autocomplete)
- Lookup by postal code
- Filter by party or province
- All data is sourced from public government records
- No user data is collected or stored
- Open-source and transparent
Contributions are welcome! Please read our Contributing Guidelines before submitting PRs.
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request