Closed jonnybazookatone closed 8 years ago
Does the API overrides user defined content-types in certain cases? For example:
curl -v "http://localhost/query2svg/<ID>" < HTTP/1.0 200 OK < Content-Type: image/svg+html < Content-Length: 741 < Server: Werkzeug/0.11.2 Python/2.7.6 < Date: Mon, 16 Nov 2015 19:59:42 GMT <
as expected: https://github.com/adsabs/myads/blob/master/myads_service/views/query_as_monument.py#L33
But via the API:
curl -v "http://localhost/v1/vault/query2svg/<ID>" * HTTP 1.0, assume close after body < HTTP/1.0 200 OK < Content-Type: text/html; charset=utf-8 < Content-Length: 741 ... ... < Server: Werkzeug/0.10.4 Python/2.7.6 < Date: Mon, 16 Nov 2015 20:23:18 GMT <
This returns the correct Content-Type when is a single service, but when a part of the API it is returned as 'text/html'.
and also the 502 and 500 return text/html
i think we should always stick to application/json UNLESS the microservice specified a different return header
Related to #89.
v1.0.1
Does the API overrides user defined content-types in certain cases? For example:
as expected: https://github.com/adsabs/myads/blob/master/myads_service/views/query_as_monument.py#L33
But via the API:
This returns the correct Content-Type when is a single service, but when a part of the API it is returned as 'text/html'.