Accept Header
Learn Accept Header (Content Negotiation, Spring MVC) with worked examples, diagrams and interview questions. Free on JavaSchoolLab.
Fresher Notes Accept header is a request header where the client lists the media types it can handle, for example Accept: application/json . Spring behavior : HeaderContentNegotiationStrategy reads it and the handler mapping matches it against produces ; this is the default strategy. Result : a match gives the body in that type; no match gives 406 Not Acceptable .