Skip to content

Commit

Permalink
Improving docs for setting response headers like content-type
Browse files Browse the repository at this point in the history
[I ran into a gotcha](PostgREST/postgrest#2138). Improving docs so that others can avoid this.

My first PR in this project, and I haven't tested the generated docs. Feel free to discard if it's not appropriate or not done correctly.
  • Loading branch information
nileshtrivedi authored Jan 25, 2022
1 parent 0824139 commit 6bb9f8a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2509,7 +2509,7 @@ Notice that the variable should be set to an *array* of single-key objects rathe

.. note::

PostgREST provided headers such as ``Content-Type``, ``Location``, etc. can be overriden this way.
PostgREST provided headers such as ``Content-Type``, ``Location``, etc. can be overriden this way. Note that irrespective of overridden ``Content-Type`` response header, the content will still be converted to JSON, unless you also set :ref:`raw_media_types` to something like ``text/html``.

.. _pre_req_headers:

Expand Down

0 comments on commit 6bb9f8a

Please sign in to comment.