Add headers to denote version on API responses

I would mildly disagree with that because advertising the software and version responsible for generating a response helps feature discovery/expectation/detection and third party tools can react accordingly. With that in mind, one might argue that a separate endpoint can be there just to query the capabilities or environment, but that would require the software to advertise such an endpoint (ref: HATEOAS). Additionally, HTTP is an stateless protocol, so the tool will have to keep some sort of session record to relate the successive requests after discovering the meta info, hence a self contained response would be more preferred.

Some tools (apart from those interacting with the JSON API) that might be interested in knowing the version of a web application include crawlers and web archives. For example, web archives later perform some rewriting to make sure pages render properly with relevant assets loaded from the archive from the nearest time frame. As the web progresses, technologies change, so the archive replay system would get great help if some specific tweak is needed to some known mass deployed frameworks/CMSs. I would point out that archives don’t store session information, but they do archive all the request and response headers along with the payload.