📃 About | 💻 Technologies | ✨ Features | 🚀 Getting Started | 👨💻 Usage | 🗺️ Roadmap | 👤 Author
B2C (business to consumer) E-commerce API is a Golang project featuring GraphQL with gqlgen and Gin for Web Framework.
The project adopts a well-organized controller-service-repository structure and supports various functionalities, including user registration, Google authentication, cart management, order creation, payment processing, and more. Additionally, it integrates Asaas for enhanced functionality.
One standout feature is its multitenant design. This means the project is crafted to effortlessly support various databases with different structures. This flexibility allows it to adapt and scale based on the specific needs or preferences of users and businesses.
- Authentication and Authorization: User registration with standard credentials or Google authentication.
- Cart Management: Users can add products, create orders, and track payment status.
- Product Management: Admins can add and categorize products for an enhanced shopping experience.
- Order Processing: Creation of orders and secure payment processing with detailed status tracking.
- Payment Integration: Seamless integration with Asaas for efficient and reliable payment processing.
- User Lifecycle Enhancements: Password recovery, email verification, and more to enhance user experience.
- Multitenancy: Designed for seamless scalability, the project supports multiple databases with varying structures.
- Go
- Docker
- make
-
Clone the repository:
git clone https://github.com/lucasshuan/b2c-ecommerce-api.git cd b2c-ecommerce-api
-
Install dependencies:
make deps
-
Start containers:
make docker-up
-
Stop containers:
make docker-down
The project utilizes a configuration file named config.yml
to manage environment-specific settings.
env: dev
dev:
port: 3000
tenants:
tenant1: scheme://user:password@host:port/db
tenant2: ...
To start the development server, run the following command:
make server
- Testing Suite: Integrate a comprehensive testing suite for robust code validation.
- Expanded Database Support: Extend database support beyond PostgreSQL and MySQL to include additional databases.
- Enhanced Security: Implement advanced security measures, such as JWT for user authentication and authorization.
- Notification System: Integrate a notification system to keep users informed about order updates and promotions.
- Order Tracking: Integrate a user-friendly order tracking system, providing real-time updates on order status and location.