Hi, I'm developing a HttpException filter to catch exceptions when we make request to 3rd party services. The problem is when the exception arrives to the filter, it works correctly but I don't have the request information. For example, we have a controller where we receive the user request, with that request, we make a call to a 3rd party server, that call fails, it throws an exception but I don't have the information of the request made to the 3rd party service.
How can I get for example the URL of the 3rd party service?
#HttpException filter for Axios requests
6 messages · Page 1 of 1 (latest)
Why cant you just log the URL before you make the 3rd party request?
Because I want to retry the request inside the ExceptionFilter
Use a try catch block around the original request and on catch retry
Or throw a custom exception with the url as parameter
Ok, thanks you very much!