0๐
โ
Itโs turns out that I was sending POST request with json body to controller mapped to url with suffix โhtmโ. This request cause conflict with mime-mapping โtext/htmlโ and as result server immediately response with code 406.
0๐
I get the response properly when I do it from postman. I believe you have getters and setters.
use the header Accept: application/json
Mark the class as implements serializable.
Source:stackexchange.com