@startuml
!include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Component.puml
Container_Boundary(boundary, "Web API") {
together {
Component(userController, "Users Controller", $descr="GET, POST, PATCH")
Component(authorController, "Author Controller", $descr="GET")
Component(materialController, "Materials Controller", $descr="GET, POST, PATCH, DELETE")
Component(cartController, "Carts Controller", $descr="GET, POST, DELETE")
Component(stripeController, "Stripe Controller", $descr="GET, POST")
Component(authController, "Auth Controller", $descr="GET, POST")
}
together {
Component(materialService, "Materials Service", $descr="")
Component(cartService, "Carts Service", $descr="")
Component(userService, "Users Service", $descr="")
Component(stripeService, "Stripe Service", $descr="")
}
Component(commonCartService, "Common Carts Service", $descr="")
Component(consumerService, "Consumers Service", $descr="")
Component(authService, "Auth Service", $descr="")
Component(authorService, "Author Service", $descr="")
Component(imageService, "Image Service", $descr="")
Component(materialFinderService, "Material PriceId Finder Service", $descr="")
}
ContainerDb(database, "Database", "Postgres", $descr="Database for storing material references, users, carts, etc.", $link="https://github.com/davidcode2/teachme")
Container_Ext(stripe, "Stripe API")
cartController --> cartService
materialController --> materialService
materialService --> imageService
materialService -> userService
materialService -> stripeService
userController --> userService
userService --> consumerService
userService --> authorService
cartService --> stripeService
cartService --> userService
cartService --> materialService
cartService --> commonCartService
stripeController --> stripeService
stripeService --> userService
stripeService --> materialFinderService
stripeService --> commonCartService
stripeService -> stripe
authorController --> authorService
authController --> authService
@enduml