{"id":30176052,"url":"https://github.com/omar-mega-byte/beemo","last_synced_at":"2026-04-12T09:03:00.274Z","repository":{"id":306278292,"uuid":"1000295119","full_name":"Omar-Mega-Byte/Beemo","owner":"Omar-Mega-Byte","description":"Beemo is a modular e-commerce application built using Spring Boot, following a microservices architecture. It includes core services for users, orders, traders, products, and payments, orchestrated through Eureka Discovery and exposed via an API Gateway","archived":false,"fork":false,"pushed_at":"2025-08-04T11:03:30.000Z","size":152,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-04T14:21:36.887Z","etag":null,"topics":["backend-api","ecommerce","java","javadoc","maven","postman","spring-boot","swagger"],"latest_commit_sha":null,"homepage":"","language":"Java","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/Omar-Mega-Byte.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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-06-11T14:57:04.000Z","updated_at":"2025-08-04T11:03:33.000Z","dependencies_parsed_at":"2025-07-24T20:19:27.959Z","dependency_job_id":null,"html_url":"https://github.com/Omar-Mega-Byte/Beemo","commit_stats":null,"previous_names":["omar-mega-byte/beemo"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Omar-Mega-Byte/Beemo","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Omar-Mega-Byte%2FBeemo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Omar-Mega-Byte%2FBeemo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Omar-Mega-Byte%2FBeemo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Omar-Mega-Byte%2FBeemo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Omar-Mega-Byte","download_url":"https://codeload.github.com/Omar-Mega-Byte/Beemo/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Omar-Mega-Byte%2FBeemo/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269987330,"owners_count":24508223,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-12T02:00:09.011Z","response_time":80,"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":["backend-api","ecommerce","java","javadoc","maven","postman","spring-boot","swagger"],"created_at":"2025-08-12T02:19:17.177Z","updated_at":"2026-04-12T09:03:00.245Z","avatar_url":"https://github.com/Omar-Mega-Byte.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# 🐝 Beemo — E-commerce Microservices System\n\nBeemo is a modular e-commerce application built using **Spring Boot**, following a microservices architecture. It includes core services for users, orders, traders, products, and payments, orchestrated through **Eureka Discovery** and exposed via an **API Gateway**.\n\n---\n\n## 🧱 Project Structure\n\n| Folder             | Description                                        |\n|--------------------|----------------------------------------------------|\n| `api-gateway`      | API Gateway using Spring Cloud Gateway             |\n| `eureka-server`    | Service registry using Netflix Eureka              |\n| `user-service`     | Handles registration, login, and user validation   |\n| `trader-service`   | Manages traders and product-related actions        |\n| `order-service`    | Manages customer orders                            |\n| `payment-service`  | Handles payment logic                              |\n| `common-models`    | Shared DTOs/entities across services               |\n| `postman`          | Collection for testing APIs                        |\n\n---\n\n## 🚀 How to Run\n\nMake sure you have Java 17+ and Maven installed.\n\n1. **Start Eureka Server**\n   ```bash\n   cd eureka-server\n   mvn spring-boot:run\n   ```\n\n2. **Start API Gateway**\n   ```bash\n   cd api-gateway\n   mvn spring-boot:run\n   ```\n\n3. **Start Microservices**\n   ```bash\n   cd user-service \u0026\u0026 mvn spring-boot:run\n   cd trader-service \u0026\u0026 mvn spring-boot:run\n   cd order-service \u0026\u0026 mvn spring-boot:run\n   cd payment-service \u0026\u0026 mvn spring-boot:run\n   ```\n\n4. **Import Postman Collection**\n   * Open the `postman/` folder and import the collection into Postman.\n---\n# Beemo API Documentation\n\nThis document provides an overview of the **Beemo** application's APIs, including TraderService, UserService, OrderService, and PaymentService. All endpoints use JSON for request and response bodies where applicable.\n\n## Base URLs\n- **TraderURL**: `http://localhost:9005`\n- **UserURL**: `http://localhost:9005`\n- **GatewayURL**: `http://localhost:9001`\n- **PaymentUrl**: `http://localhost:9004`\n\n## TraderService APIs\n- **POST /products**  \n  Saves a product.  \n  **Body**: `{ \"name\": string, \"description\": string, \"price\": number, \"stock\": number }`  \n  **Example**: `{ \"name\": \"Hihi Cola\", \"description\": \"An amazing drink\", \"price\": 19, \"stock\": 10 }`\n\n- **GET /products**  \n  Retrieves all products, optionally filtered by company.  \n  **Query Param**: `company` (optional, e.g., `Giza`)  \n\n- **GET /products/{id}**  \n  Fetches a product by ID.  \n  **Example**: `/products/6`\n\n- **GET /products/{id}/stock?quantity={n}**  \n  Checks if a product has sufficient stock.  \n  **Query Param**: `quantity` (e.g., `1`)  \n  **Example**: `/products/1/stock?quantity=1`\n\n- **PUT /products/{id}**  \n  Updates a product's details.  \n  **Body**: `{ \"name\": string, \"description\": string, \"price\": number }`  \n  **Example**: `/products/5`, `{ \"name\": \"Alex Cola\", \"description\": \"An amazing drink\", \"price\": 19 }`\n\n- **DELETE /products/{id}**  \n  Deletes a product by ID.  \n  **Example**: `/products/3`\n\n## UserService APIs\n- **POST /register**  \n  Registers a new user.  \n  **Body**: `{ \"username\": string, \"email\": string, \"password\": string }`  \n  **Example**: `{ \"username\": \"testuser\", \"email\": \"test@example.com\", \"password\": \"password123\" }`\n\n- **POST /login**  \n  Authenticates a user.  \n  **Body**: `{ \"username\": string, \"password\": string }`  \n  **Example**: `{ \"username\": \"testuser\", \"password\": \"password123\" }`\n\n- **GET /{id}/validate**  \n  Validates a user by ID.  \n  **Example**: `/1/validate`\n\n## OrderService APIs\n- **POST /orders**  \n  Creates a new order.  \n  **Body**: `{ \"userId\": number, \"productId\": number, \"quantity\": number }`  \n  **Example**: `{ \"userId\": 1, \"productId\": 9, \"quantity\": 2 }`\n\n- **GET /orders/user/{id}**  \n  Retrieves all orders for a user.  \n  **Example**: `/orders/user/1`\n\n- **GET /orders/{id}/status**  \n  Checks the status of an order.  \n  **Example**: `http://localhost:9001/orders/1/status`\n\n## PaymentService APIs\n- **POST /payments**  \n  Processes a payment.  \n  **Body**: `{ \"orderId\": number, \"userId\": number, \"amount\": number, \"currency\": string, \"paymentMethod\": string, \"paypalEmail\": string, \"description\": string }`  \n  **Example**: `{ \"orderId\": 2, \"userId\": 1, \"amount\": 99.99, \"currency\": \"USD\", \"paymentMethod\": \"PAYPAL\", \"paypalEmail\": \"user@example.com\", \"description\": \"Order payment\" }`\n\n- **POST /payments/{id}/refund**  \n  Issues a refund for a payment.  \n  **Body**: Same as POST /payments  \n  **Example**: `http://localhost:9004/payments/103/refund`\n\n- **GET /payments/health**  \n  Checks the health status of the payment service.  \n  **Example**: `http://localhost:9004/payments/health`\n\n- **GET (Order Status)**  \n  Intended to check order status (endpoint incomplete in provided collection).\n\n## Notes\n- All APIs use `noauth` authentication unless specified otherwise.\n- Replace `{{TraderURL}}`, `{{UserURL}}`, `{{GatewayURL}}`, and `{{PaymentUrl}}` with the respective base URLs.\n- Ensure proper JSON formatting for request bodies.\n- The PaymentService uses `http://localhost:9004` for most endpoints, with some hardcoded URLs.\n- For further details, refer to the Postman collection: [Beemo Collection](https://gold-resonance-166177.postman.co/workspace/613b5506-7453-4bfb-82e1-c499336d62d8/collection/43221147-000d6693-beb0-47e7-8137-044526183f06?action=share\u0026source=collection_link\u0026creator=43221147).\n---\n## 🔐 Security\n\nA mock `noauth` HTTP scheme is defined in OpenAPI. You can implement full JWT authentication later.\n\n---\n\n## 📄 .gitignore\n\nCommon `.gitignore` entries:\n* `target/`\n* `.idea/`, `.vscode/`\n* `.env`, `*.log`\n* `*.iml`\n\n---\n\n## 📚 Tech Stack\n\n* Java 17\n* Spring Boot\n* Spring Cloud (Gateway, Eureka)\n* Maven\n* Postman\n* OpenAPI 3.0\n\n---\n\n## 🧪 Future Enhancements\n\n* ✅ Inventory management\n* ✅ Kafka or RabbitMQ for event-driven orders\n\n---\n\n## 🐝 About\n\n**Beemo** was created as a sample e-commerce platform with learning in mind—focused on testing, scalability, and modularity in Spring Boot microservices.\n\n\n## 📎 License\n\nThis project is licensed under the MIT License.\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fomar-mega-byte%2Fbeemo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fomar-mega-byte%2Fbeemo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fomar-mega-byte%2Fbeemo/lists"}