Whenever possible, you should handle errors directly in the call chain. However, it is also good to have a global error handler installed so that no implementation details get leaked to the public.
In this video, we will create a basic Minimal API with a broken endpoint. Then, we will create a global error handler to address the error, in case we do not catch it in the specific endpoint where it happens.
Full Training Courses:
Source Code:
Mailing List:
Watch video Global Error Handling in C# Minimal APIs online, duration 13 minute 59 second in high hd quality that is uploaded to the channel IAmTimCorey 25 March 2024. Share the link to the video on social media so that your subscribers and friends will also watch this video. This video clip has been viewed 16 thousand times and liked it 535 visitors.