A high-performance, enterprise-grade e-commerce application tailored specifically for the Indian market. Built with Laravel 13, Livewire 3, Tailwind CSS v4, Razorpay Payment Gateway, and Pest PHP.
- Live URL: https://eshop.mkdigit.in
- GitHub Repository: https://github.com/kmtech183/ecommerce-store
-
Storefront & Catalog:
- Contemporary, luxury UI design with category pill filtering, responsive grid layouts, and product search.
- Multi-variant selection (Size, Color, Edition) with real-time price updates.
- Image galleries with high-resolution photography.
-
Cart & Dynamic Checkout:
- Interactive Livewire Cart with sliding drawer and real-time quantity adjustments.
- Seamless guest-to-authenticated cart merging (cookie token tracking).
- Indian Address Book supporting 10-digit mobile validation, 6-digit PIN codes, and 28 States + 8 UTs.
-
Razorpay Integration (Indian Payments):
- 2-Phase payment protocol (server-side order creation in paise minor units).
- Cryptographic HMAC-SHA256 signature verification.
- Public, CSRF-exempt webhook endpoint (
/razorpay/webhook) for asynchronous payment reconciliation. - Supports UPI (GPay, PhonePe, Paytm), Credit/Debit Cards, NetBanking, and Wallets.
-
Taxation & Invoicing:
- Rule 46 CGST Compliant Indian Tax Invoice generation.
- Automatic tax splitting: CGST (9%) + SGST (9%) for intra-state (Gujarat) or IGST (18%) for inter-state orders.
- Optional B2B GSTIN input validation.
- Direct browser-based Print / PDF invoice generation.
-
Asynchronous Processing:
- Background queued order confirmation emails with responsive HTML templates using the database queue driver.
-
Headless REST API:
- RESTful v1 endpoints for categories and products with High-Scale Cursor Pagination (
$O(1)$ performance). - Sanctum Bearer Token Authentication (
/api/v1/login,/api/v1/me,/api/v1/logout). - Rate limiting (
throttle:60,1) and encapsulated JSON Resources preventing N+1 queries.
- RESTful v1 endpoints for categories and products with High-Scale Cursor Pagination (
-
Security & Authorization:
- Granular Model Policies (
ProductPolicy,OrderPolicy) preventing Insecure Direct Object References (IDOR). - Two-tier security with custom
EnsureUserHasRolemiddleware (adminvscustomer). - Strict developer-mode constraints (
preventLazyLoading(),preventSilentlyDiscardingAttributes()).
- Granular Model Policies (
-
Comprehensive Pest Test Suite:
- Unit tests for financial decimal precision and GST calculations.
- Feature tests for storefront catalog, product variants, and API token authentication.
- Policy tests verifying IDOR defense and role-based permissions.
| Layer | Technology |
|---|---|
| Framework | Laravel 13 (PHP 8.3 / 8.4) |
| Frontend | Livewire 3 + Alpine.js + Tailwind CSS v4 + Vite |
| Authentication | Laravel Breeze (Livewire/Volt stack) + Laravel Sanctum |
| Database | MySQL (with InnoDB transactions & decimal precision) |
| Payment Gateway | Razorpay PHP SDK |
| Testing | Pest PHP |
| Queue & Cache | Database / Redis drivers |
When running seeders in local/staging environments:
- Admin Account:
- Email:
[email protected] - Password:
password - Role:
admin
- Email:
- Customer Account:
- Email:
[email protected] - Password:
password - Role:
customer
- Email:
# 1. Clone repository
git clone https://github.com/kmtech183/ecommerce-store.git
cd ecommerce-store
# 2. Install PHP and Node dependencies
composer install
npm install
# 3. Environment configuration
cp .env.example .env
php artisan key:generate
# 4. Configure MySQL credentials in .env
# DB_DATABASE=ecommerce_store
# DB_USERNAME=root
# DB_PASSWORD=
# 5. Run migrations & seed data
php artisan migrate:fresh --seed
# 6. Build assets & create storage link
npm run build
php artisan storage:link
# 7. Start local server
php artisan serveExecute the comprehensive Pest test suite:
php artisan test- Subdomain:
https://eshop.mkdigit.in - Web Root: Points to the
/publicdirectory. - Configuration Optimization:
php artisan config:cache php artisan route:cache php artisan view:cache
Open-sourced software licensed under the MIT license.