diff --git a/Controllers/GeneralUseHelperFunctions.cs b/Controllers/GeneralUseHelperFunctions.cs index b1dffb3..226bf32 100644 --- a/Controllers/GeneralUseHelperFunctions.cs +++ b/Controllers/GeneralUseHelperFunctions.cs @@ -233,7 +233,12 @@ public class GeneralUseHelpers(ApplicationDbContext db, IConfiguration appsettin else { // Handle the error + JObject error = JObject.Parse(await response.Content.ReadAsStringAsync()); Console.WriteLine($"[QuotifyBE] Error: response status code from API was {response.StatusCode}."); + if (error != null && error["error"] != null && error["error"]!["message"] != null) + { + Console.WriteLine($" Error message: {error["error"]!["message"]}"); + } return null; } }