Skip to content

Looking for sample that modifies a response #270

Answered by Tratcher
brian2github asked this question in General
Discussion options

You must be logged in to vote

What aspect of the response?

Preview2 added support for modifying response headers:
https://microsoft.github.io/reverse-proxy/articles/transforms.html#response-headers-and-trailers

Modifying the response body is not a feature we plan first class support for in the proxy, it's very content dependent. However, it is possible to do this via your own middleware. Here's one example:
https://github.com/dotnet/aspnetcore/blob/04ecd5539f7476ea91c504fea7aa765d7df66e6b/src/Middleware/ResponseCompression/src/ResponseCompressionMiddleware.cs

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by samsp-msft
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #270 on July 02, 2020 18:46.