Werk #13049: RESTAPI: require accept header
Component | REST API | ||
Title | RESTAPI: require accept header | ||
Date | Oct 5, 2021 | ||
Level | Trivial Change | ||
Class | New Feature | ||
Compatibility | Incompatible - Manual interaction might be required | ||
Checkmk versions & editions |
|
In previous version the accept header of the HTTP-request was completely ignored.
With this werk the accept header is obligatory. If no or a wrong accept header is provided an error with a 406 status code will be returned.
For most requests this means you have to provide the follwing header line:
Accept: application/json
For some other requests different accept headers may be required. All headers are documented in the official rest-api documentation.
For example when downloading the agent binary the following header is required:
Accept: application/octet-stream