Information about response format and withFormat in Grails - ppazos/cabolabs-ehrserver GitHub Wiki
It seems withFormat is not working as expected when the Accept header is set to a mime type (if it has app/json it doesn't match json in withFormat), but it always work if the format param is present on the request.
https://onekilo79.wordpress.com/2014/02/11/angularjs-and-grails-withformat-and-json/