Skip to content

Latest commit

 

History

4 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

E-Gram Connect

A panchayat (village council) transparency portal: residents can see who their elected members are and what projects are running, and can file grievances; administrators manage the member roster and the project list.

Stack

Layer Built with
Backend TypeScript, Express, Mongoose (MongoDB)
Frontend React, Material UI, React Router, Axios
Auth JWT, split into user and admin middleware

Data model

Five Mongoose models in backend/db.ts:

  • User and Admin — the two account types, authenticated separately.
  • Panchayat Member — name, designation, ward, phone, photo.
  • Project — name, description, budget, timeline, status, links, images.
  • Grievance — a complaint tied to the user who filed it.

API

All routes are mounted under /api/v1.

/user

Route Method Auth
/signup, /signin POST public
/ GET user
/members GET public
/project GET public
/complaint POST, GET user

/admin

Route Method Auth
/signup, /signin POST public
/ GET admin
/member POST admin
/member GET public
/member/:id DELETE admin
/addProject POST admin

Member and project reads are deliberately public — the portal's purpose is that residents can see them without an account. Anything that writes requires the matching token.

Request bodies are validated with schemas under backend/validation/ (signup, signin, memberSchema, project, griveance).

Running it

The backend and frontend are separate packages.

cd backend && npm install && npm run dev     # http://localhost:3000
cd frontend && npm install && npm run dev

The backend expects a MongoDB connection string; see backend/config.ts for the values it reads.

About

Village governance platform: TypeScript/Express API for grievances, projects and member records, with a React front end.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages