{"id":34897183,"url":"https://github.com/hvaezapp/zitro-shop","last_synced_at":"2026-04-16T10:31:33.506Z","repository":{"id":329167323,"uuid":"1117618974","full_name":"hvaezapp/zitro-shop","owner":"hvaezapp","description":"modular e-commerce API built with .NET 9. The project follows a Modular Monolith architecture.","archived":false,"fork":false,"pushed_at":"2025-12-18T09:50:39.000Z","size":158,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-12-21T06:50:32.566Z","etag":null,"topics":["csharp","docker","dotnetcore","fluentvalidation","modular-monolith","rabbitmq","redis","sqlserver"],"latest_commit_sha":null,"homepage":"","language":"C#","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/hvaezapp.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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-12-16T15:13:27.000Z","updated_at":"2025-12-18T09:50:42.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/hvaezapp/zitro-shop","commit_stats":null,"previous_names":["hvaezapp/zitro-shop"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/hvaezapp/zitro-shop","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hvaezapp%2Fzitro-shop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hvaezapp%2Fzitro-shop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hvaezapp%2Fzitro-shop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hvaezapp%2Fzitro-shop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hvaezapp","download_url":"https://codeload.github.com/hvaezapp/zitro-shop/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hvaezapp%2Fzitro-shop/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31881998,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-16T09:23:21.276Z","status":"ssl_error","status_checked_at":"2026-04-16T09:23:15.028Z","response_time":69,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["csharp","docker","dotnetcore","fluentvalidation","modular-monolith","rabbitmq","redis","sqlserver"],"created_at":"2025-12-26T07:38:04.351Z","updated_at":"2026-04-16T10:31:33.499Z","avatar_url":"https://github.com/hvaezapp.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ZitroShop\n\nZitroShop is a modern, modular e-commerce API built with .NET 9. The project follows a **Modular Monolith** architecture, ensuring clear separation of concerns between different business domains such as Products, Basket, and Payments.\n\n## 🚀 Tech Stack\n\n- **Framework:** .NET 9\n- **Database:** SQL Server (EF Core)\n- **Caching \u0026 Locking:** Redis\n- **Message Broker:** RabbitMQ\n- **API Documentation:** Scalar (Modern Swagger alternative)\n- **Validation:** FluentValidation\n\n## 🏗 Project Structure\n\nThe solution is divided into several modules:\n- **ZitroShop.Api:** The entry point and API layer.\n- **ZitroShop.Modules:** Contains independent business modules:\n  - **ProductModule:** Product catalog and management.\n  - **BasketModule:** Shopping basket logic using Redis for persistence and locking.\n  - **PaymentModule:** Payment processing and status tracking.\n- **ZitroShop.Shared:** Shared infrastructure, base classes, and utilities.\n\n## 🛠 Getting Started\n\n### 1. Prerequisites\n- [.NET 9 SDK](https://dotnet.microsoft.com/download/dotnet/9.0)\n- [Docker Desktop](https://www.docker.com/products/docker-desktop)\n- [SQL Server](https://www.microsoft.com/en-us/sql-server/sql-server-downloads)\n\n### 2. Infrastructure Setup\nRun the following command to start Redis and RabbitMQ containers:\n```bash\ndocker compose up -d\n```\n\n### 3. Database Configuration\nUpdate the connection string in `src/ZitroShop.Api/appsettings.Development.json` if your SQL Server instance differs from the default:\n```json\n\"ConnectionStrings\": {\n  \"SvcDbContext\": \"data source=.;initial catalog=ZitroShopDB;TrustServerCertificate=True;Trusted_Connection=True;\"\n}\n```\n\nThen, apply the migrations to create the database:\n```bash\ndotnet ef database update --project src/ZitroShop.Modules --startup-project src/ZitroShop.Api\n```\n\n### 4. Running the Project\n```bash\ndotnet run --project src/ZitroShop.Api\n```\nThe API will be available at `http://localhost:5128`.\n\n### 5. API Documentation\nOnce the app is running, you can explore the interactive API documentation at:\n- **Scalar:** `http://localhost:5128/scalar/v1`\n\n---\n\n## 📡 API Examples\n\n### 📦 Products\n#### Get All Products\nRetrieves a list of all available products.\n- **URL:** `/products`\n- **Method:** `GET`\n- **Example Request:**\n```bash\ncurl -X GET http://localhost:5128/products\n```\n\n### 🛒 Basket\n#### Add Product to Basket\nAdds a specific product to a user's basket.\n- **URL:** `/basket/add`\n- **Method:** `POST`\n- **Payload:**\n```json\n{\n  \"userId\": 1,\n  \"productId\": 1\n}\n```\n- **Example Request:**\n```bash\ncurl -X POST http://localhost:5128/basket/add \\\n-H \"Content-Type: application/json\" \\\n-d '{\"userId\": 1, \"productId\": 1}'\n```\n\n### 💳 Payment\n#### Start Payment Process\nInitiates a payment for the items in the user's basket.\n- **URL:** `/payment/start`\n- **Method:** `POST`\n- **Payload:**\n```json\n{\n  \"userId\": 1\n}\n```\n- **Example Request:**\n```bash\ncurl -X POST http://localhost:5128/payment/start \\\n-H \"Content-Type: application/json\" \\\n-d '{\"userId\": 1}'\n```\n\n#### Check Payment Status\nRetrieves the current status of a payment.\n- **URL:** `/payment/{paymentId}`\n- **Method:** `GET`\n- **Example Request:**\n```bash\ncurl -X GET http://localhost:5128/payment/1\n```\n\n---\n\n![zitro-shop Endpoints](zitro-shop-api.png)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhvaezapp%2Fzitro-shop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhvaezapp%2Fzitro-shop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhvaezapp%2Fzitro-shop/lists"}