❔ How to properly handle exceptions between API controller and service layer?
I'm creating an API and I'm having trouble figuring out how to properly catch errors between my service layer and controller. Could someone take a look at my current code and give me some advice? Useful docs or tutorials are also greatly appreciated.
To better understand the controller, this the controller route:
This is my current controller:
https://pastebin.com/Cg4CJ0QE
My service:
https://pastebin.com/KVaN3nYR
To better understand the controller, this the controller route:
/api/v1/identity-users/{userRefId:guid}/risksThis is my current controller:
https://pastebin.com/Cg4CJ0QE
My service:
https://pastebin.com/KVaN3nYR