{"id":28479001,"url":"https://github.com/pankaj085/lotuslynx","last_synced_at":"2026-05-01T16:32:17.201Z","repository":{"id":295414879,"uuid":"985690248","full_name":"pankaj085/lotuslynx","owner":"pankaj085","description":"LotusLynx is a modern e-commerce backend built with FastAPI, SQLAlchemy, and Pydantic. It features robust user authentication, JWT-based authorization, product and order management, and a clean, modular codebase.","archived":false,"fork":false,"pushed_at":"2025-06-03T09:42:57.000Z","size":106,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-07-03T09:41:39.758Z","etag":null,"topics":["ecommerce-application","fastapi","postgresql","python","sqlalchemy"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pankaj085.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-05-18T10:17:57.000Z","updated_at":"2025-06-03T09:42:59.000Z","dependencies_parsed_at":"2025-07-03T09:42:08.192Z","dependency_job_id":null,"html_url":"https://github.com/pankaj085/lotuslynx","commit_stats":null,"previous_names":["pankaj085/lotuslynx"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/pankaj085/lotuslynx","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pankaj085%2Flotuslynx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pankaj085%2Flotuslynx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pankaj085%2Flotuslynx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pankaj085%2Flotuslynx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pankaj085","download_url":"https://codeload.github.com/pankaj085/lotuslynx/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pankaj085%2Flotuslynx/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32505073,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"online","status_checked_at":"2026-05-01T02:00:05.856Z","response_time":64,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ecommerce-application","fastapi","postgresql","python","sqlalchemy"],"created_at":"2025-06-07T18:07:43.120Z","updated_at":"2026-05-01T16:32:17.190Z","avatar_url":"https://github.com/pankaj085.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LotusLynx E-commerce Platform\n\n\u003c!-- Replace this with your actual logo once created --\u003e\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"docs/imgs/lotuslynx_logo.png\" alt=\"LotusLynx Logo\" width=\"408\" height=\"117\"/\u003e\n\u003c/p\u003e\n\n\u003e 🚧 **Project Status: Under Active Development** \n\n## Tech Stack\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://fastapi.tiangolo.com/img/logo-margin/logo-teal.png\" alt=\"FastAPI\" height=\"40\"/\u003e\n  \u003cimg src=\"https://www.postgresql.org/media/img/about/press/elephant.png\" alt=\"PostgreSQL\" height=\"40\"/\u003e\n  \u003cimg src=\"https://res.cloudinary.com/cloudinary/image/upload/v1/logo/for_white_bg/cloudinary_logo_for_white_bg.png\" alt=\"Cloudinary\" height=\"40\"/\u003e\n  \u003cimg src=\"https://freelogopng.com/images/all_img/1685814267stripe-logo-png.png\" alt=\"Stripe\" height=\"40\"/\u003e\n\u003c/p\u003e\n\n\n## Project Overview\n\nA backend-focused e-commerce platform built with FastAPI, emphasizing robust API development, secure authentication, and modern backend practices. While the project includes basic templates for administrative interfaces, the primary focus is on building a solid, production-ready backend API.\n\n### Key Focus Areas\n- **Backend Development**: Comprehensive FastAPI implementation\n- **API Design**: RESTful API with detailed documentation\n- **Security**: JWT authentication, role-based access control\n- **Payment Integration**: Stripe payment processing\n- **File Management**: Cloudinary integration for image storage\n- **Database**: PostgreSQL with SQLAlchemy ORM\n- **Testing**: Comprehensive test coverage with pytest\n\n### Frontend Note\nThe project uses simple Jinja2 templates for administrative interfaces. The primary goal is to create a robust API that can be consumed by any frontend technology in the future.\n\n## Current Progress\n\n- ✅ Backend API setup with FastAPI\n- ✅ Database models and schemas\n- ✅ User authentication with JWT (access/refresh tokens)\n- ✅ Product management with image upload\n- ✅ Stripe payment integration\n- ✅ Role-based access control\n- 🔄 Cart and Order system (In Progress)\n- ⏳ Frontend development (Planned)\n\n## Technology Stack\n\n### Backend\n- **FastAPI**: Modern Python web framework\n- **SQLAlchemy**: SQL toolkit and ORM\n- **Pydantic**: Data validation\n- **PostgreSQL**: Primary database\n- **JWT**: Authentication tokens\n- **Alembic**: Database migrations\n\n### External Services\n- **Stripe**: Payment processing\n- **Cloudinary**: Image storage and optimization\n\n### Development Tools\n- **Python 3.10+**\n- **Poetry/pip**: Dependency management\n- **pytest**: Testing framework\n- **uvicorn**: ASGI server\n\n## Project Structure\n\n```\nlotuslynx/\n│\n├── .env                       # Environment variables\n├── .gitignore                 # Standard Python + frontend ignores\n├── requirements.txt           # With dev dependencies separated\n├── Dockerfile                 # Multi-stage build\n├── docker-compose.yml         # App + DB + Redis + Frontend\n├── alembic.ini                # Migration config\n│\n├── backend/\n│   ├── __init__.py            # Package marker\n│   ├── main.py                # FastAPI app (lifespan setup)\n│   ├── database.py            # SQLAlchemy async/sync setup\n│   ├── utils.py               # Miscellaneous helpers\n│   │\n│   ├── core/                  # Critical utilities\n│   │   ├── __init__.py        # Exports config, auth\n│   │   ├── auth.py            # JWT logic (access/refresh)\n│   │   ├── config.py          # Pydantic settings\n│   │   └── security.py        # OAuth2 schemes\n│   │\n│   ├── dependencies/          # Reusable FastAPI deps\n│   │   ├── __init__.py        # Clean exports\n│   │   ├── auth.py            # get_current_user\n│   │   ├── roles.py           # require_admin/require_editor\n│   │   ├── payments.py        # stripe_payment\n│   │   └── database.py        # get_db (session)\n│   │\n│   ├── models/                # SQLAlchemy ORM\n│   │   ├── __init__.py        # Exposes models\n│   │   ├── user.py            # User, roles\n│   │   ├── product.py         # Product, categories\n│   │   ├── cart.py            # Cart, CartItem\n│   │   └── order.py           # Order, OrderItem\n│   │\n│   ├── schemas/               # Pydantic models\n│   │   ├── __init__.py        # Exposes schemas\n│   │   ├── user.py            # UserCreate, UserResponse\n│   │   ├── product.py         # Product CRUD schemas\n│   │   ├── cart.py            # Cart operations\n│   │   └── order.py           # Order workflows\n│   │\n│   ├── routers/               # API endpoints\n│   │   ├── __init__.py        # Router aggregation\n│   │   ├── auth_router.py     # /auth/*\n│   │   ├── products_router.py # /products/* (with Cloudinary)\n│   │   ├── cart_router.py     # /cart/*\n│   │   └── orders_router.py   # /orders/*\n│   │\n│   ├── services/              # External integrations\n│   │   ├── __init__.py\n│   │   ├── payment.py         # Stripe/PayPal\n│   │   ├── email.py           # SMTP templates\n│   │   └── cloudinary.py      # Image upload helpers\n│   │\n│   └── tests/                 # Pytest\n│       ├── __init__.py\n│       ├── conftest.py        # Fixtures\n│       ├── test_auth.py\n│       └── test_products.py\n│\n├── frontend/                  # Static files\n│   ├── static/                # Built assets (Vite/Webpack)\n│   │   ├── css/\n│   │   ├── js/\n│   │   └── img/\n│   │\n│   └── templates/             # Jinja2 templates\n│       ├── base.html          # Layout\n│       ├── auth/\n│       │   ├── login.html\n│       │   └── register.html\n│       └── admin/\n│           ├── dashboard.html\n│           └── products.html\n│\n├── alembic/                   # Migrations\n│   ├── versions/\n│   ├── env.py\n│   └── script.py.mako\n│\n└── scripts/                   # Deployment/DB\n    ├── seed_db.py             # Test data\n    └── backup_db.sh           # PostgreSQL dumps\n\n```\n\n## Features\n\n### Implemented\n- JWT Authentication with refresh tokens\n- Role-based access control (Admin/Editor/User)\n- Product management with image upload\n- Secure payment processing with Stripe\n- Cloudinary integration for image storage\n\n### Planned\n- Shopping cart functionality\n- Order management\n- User profiles\n- Admin dashboard\n- Email notifications\n- React frontend\n- Docker containerization\n\n## Getting Started\n\n1. Clone the repository:\n```bash\ngit clone https://github.com/yourusername/lotuslynx.git\ncd lotuslynx\n```\n\n2. Set up environment:\n```bash\npython -m venv .venv\nsource .venv/bin/activate\npip install -r requirements.txt\n```\n\n3. Configure environment variables:\n```bash\ncp .env.example .env\n# Edit .env with your credentials\n```\n\n4. Run development server:\n```bash\nuvicorn backend.main:app --reload\n```\n\n## Development Roadmap\n\n1. **Phase 1** (Current)\n   - Complete core backend functionality\n   - Implement comprehensive testing\n   - Document API endpoints\n\n2. **Phase 2**\n   - Develop React frontend\n   - Add shopping cart\n   - Implement order system\n\n3. **Phase 3**\n   - Add admin dashboard\n   - Email integration\n   - Performance optimization\n\n4. **Phase 4**\n   - Docker containerization\n   - CI/CD setup\n   - Production deployment\n\n## API Documentation\n\nOnce the server is running, visit:\n- Swagger UI: `http://localhost:8000/docs`\n- ReDoc: `http://localhost:8000/redoc`\n\n## Environment Variables\n\nRequired environment variables in your `.env` file:\n\n```ini\n# Database\nDATABASE_URL=postgresql://user:password@localhost/dbname\n\n# Authentication\nSECRET_KEY=your-secret-key\nALGORITHM=HS256\nACCESS_TOKEN_EXPIRES_MINUTES=30\nREFRESH_TOKEN_EXPIRES_DAYS=7\n\n# Cloudinary\nCLOUDINARY_CLOUD_NAME=your-cloud-name\nCLOUDINARY_API_KEY=your-api-key\nCLOUDINARY_API_SECRET=your-api-secret\n\n# Stripe\nSTRIPE_SECRET_KEY=your-stripe-secret-key\nSTRIPE_WEBHOOK_SECRET=your-webhook-secret\nSTRIPE_CURRENCY=usd\n```\n\n## API Endpoints\n\n### Auth Routes\n- `POST /auth/register` - Register new user\n- `POST /auth/login` - Login user\n- `POST /auth/refresh` - Refresh access token\n\n### Product Routes\n- `GET /products` - List all products\n- `POST /products` - Create product (Admin only)\n- `GET /products/{id}` - Get product details\n- `PUT /products/{id}` - Update product (Admin only)\n- `DELETE /products/{id}` - Delete product (Admin only)\n\n### Additional routes documentation in progress...\n\n\n## Development Guidelines\n\n- Follow PEP 8 style guide\n- Write docstrings for all functions/classes\n- Include type hints\n- Write tests for new features\n- Keep the codebase modular and clean\n\n## Support \u0026 Contact\n\nFor support, mail [pankaj085k@gmail.com](mailto:pankaj085k@gmail.com \"Send an E-mail\") or create an issue in the repository.\n\n## Acknowledgments\n\n- FastAPI Documentation\n- SQLAlchemy Documentation\n- Stripe API Documentation\n- Cloudinary Documentation\n\n## Contributing\n\nCurrently, this is a personal project in development. Contributions might be welcome in the future.\n\n## License\n\nThis project is licensed under the [MIT License](LICENSE) - see the [LICENSE](LICENSE) file for details.\n\n## Author\n\nPankaj Kushwaha - [GitHub](https://github.com/pankaj085 \"Follow me on GitHub\") | [LinkedIn](https://www.linkedin.com/in/py--dev/ \"Follow me on LinkedIn\")\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpankaj085%2Flotuslynx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpankaj085%2Flotuslynx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpankaj085%2Flotuslynx/lists"}