79833965

Date: 2025-11-30 14:35:54
Score: 1
Natty:
Report link

I'll get (PHP) Laravel-framework specific in my response and respond from that specific architectural view point.

"Controller" is what stands between the incoming request to your application and the business-logic operations it performs, while "Service" is what wraps around that same business-logic opeations and is called my the controller.

The following flow might be helpful in wrapping one's head around the concept:
client sends a request -> controller (validation, calling the necessary service to perform business logic and passing the request to it) -> service (computation, db checks, resource mutation, etc) -> response back to controller (formatting, view) -> client receives response.

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Meromah