This repository contains/represents the API endpoints for Bazaar, a location-based marketplace SaaS platform designed specifically for universities. The platform combines an Express.js backend API with a React frontend application (migrated from the previous bazaar-frontend
repository).
Bazaar enables university students to buy, sell, and trade items within their campus community. The platform uses location-based services to connect buyers and sellers in the same university area, creating a safe and localized marketplace experience.
- User authentication and authorization
- Location-based item discovery
- Item listing management (create, read, update, delete)
- Search and filtering capabilities
- University-specific marketplaces
- Real-time item availability updates
- User profiles and ratings
- Secure messaging between buyers and sellers
- Node.js
- Express.js
- MongoDB (database)
- JWT (authentication)
- Passport.js (authorization)
- React.js
- Redux (state management)
- Material-UI (component library)
- Axios (API client)
- React Router (routing)
- Node.js (v14 or higher)
- MongoDB
- npm or yarn
- Clone the repository:
git clone https://github.com/steevejoseph/bazaar-backend.git
cd bazaar-backend
- Install dependencies:
npm install
- Create a
.env
file in the root directory with the following variables:
PORT=3000
MONGODB_URI=your_mongodb_connection_string
JWT_SECRET=your_jwt_secret
NODE_ENV=development
- Start the development server:
npm run dev
The API endpoints are organized around the following resources:
/api/auth
- Authentication endpoints/api/users
- User management/api/items
- Item listings/api/messages
- User messaging/api/universities
- University management
For detailed API documentation, please refer to:
npm test
npm run lint
npm run build
The application can be deployed to any Node.js hosting platform. Make sure to set the appropriate environment variables for production deployment.
npm run start
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Original frontend code from bazaar-frontend
- All contributors who have helped shape and improve this project
For any questions or concerns, please open an issue in the repository.