How iagobarros211256/volurya works
Volurya is a Go backend and storefront for band merchandise. The main purchase workflow runs from the customer’s cart through checkout, order creation, Stripe payment, and a signed webhook that updates payment/order state. Other product branches cover account authentication, catalog administration and image uploads, and real-time notifications. The README documents the full payment flow; source excerpts confirm selected controller, use-case, repository, and worker interactions. Unsampled subsystem wiring is omitted where evidence is unavailable.
Main entry points: main.go API routing · payment_controller.go Payment handlers · product_controller.go Catalog handlers · cart_controller.go Cart handlers
Components 26
Storefront and HTTP
- Storefront scripts
views/static/js/store.js - Auth client
views/static/js/auth.js - Cart client
views/static/js/cart.js - Admin client
views/static/js/store-admin.js - API routing
cmd/main.go - Auth handlers
controller/auth_controller.go - Catalog handlers
controller/product_controller.go - Cart handlers
controller/cart_controller.go - Payment handlers
controller/payment_controller.go - Notification stream
controller/notification_controller.go
Business workflows
- Authentication rules
usecase/auth_usecase.go - Catalog rules
usecase/product_usecase.go - Cart rules
usecase/cart_usecase.go - Checkout and payment
usecase/payment_usecase.go - Image processing
jobs/image_worker.go - Notification hub
notifications/hub.go
Persistence
- Product repository
repository/product_repository.go - Cart repository
repository/cart_repository.go - Payment repository
repository/payment_repository.go - User repository
repository/user_repository.go - Refresh token repository
repository/refresh_token_repository.go
External services
- PostgreSQL
- Stripe
- Cloudflare R2
storage/r2.go - Email delivery
email/email.go
Other components
- Customer
Connections 31
- Customer → Storefront scripts: uses
README.md - Customer → Auth client: authenticates
README.md - Customer → Cart client: manages cart
README.md - Storefront scripts → API routing: requests catalog
- Auth client → API routing: calls auth API
views/static/js/auth.js - Cart client → API routing: calls cart API
README.md - Admin client → API routing: admin requests
- API routing → Auth handlers: routes auth
cmd/main.go - API routing → Payment handlers: routes webhook
cmd/main.go - API routing → Cart handlers: routes cart
cmd/main.go - API routing → Notification stream: routes events
cmd/main.go - API routing → Catalog handlers: routes catalog
README.md - Auth handlers → Authentication rules: delegates auth
controller/auth_controller.go - Authentication rules → User repository: reads and writes
usecase/auth_usecase.go - Authentication rules → Refresh token repository: rotates tokens
usecase/auth_usecase.go - Catalog handlers → Catalog rules: delegates catalog
controller/product_controller.go - Catalog handlers → Image processing: submits images
- Catalog rules → Product repository: accesses products
- Cart handlers → Cart rules: delegates cart
controller/cart_controller.go - Cart rules → Cart repository: accesses cart
- Cart handlers → Notification hub: publishes events
controller/cart_controller.go - Payment handlers → Checkout and payment: creates order
controller/payment_controller.go - Payment handlers → Stripe: creates intent
controller/payment_controller.go - Payment handlers → Checkout and payment: handles webhook
README.md - Checkout and payment → Payment repository: records payment
- Product repository → PostgreSQL: queries catalog
repository/product_repository.go - Cart repository → PostgreSQL: reads and writes cart
repository/cart_repository.go - Payment repository → PostgreSQL: stores payment
repository/payment_repository.go - Image processing → Cloudflare R2: stores images
- Customer → Stripe: completes payment
README.md - Customer → Notification stream: opens event stream
README.md