Category "symfony-http-client"

Why can't I access the response content when the Symfony HTTP Client encounters an error, and an exception is thrown instead?

I want to make a request to retrieve user info from OAUTH server with Symfony HttpClient but I can't fetch fetch the response directly when encountering an erro

Cannot retrieve error message using Symfony HttpClient if the response is not "ok"

I use Symfony HttpClient to call an external API. When the status code is 200 I can use getContent() method to retrieve the API response. If the API response is