I'm trying to handle a 307 redirect response in Ktor, but I'm struggling to intercept the response correctly. I found a solution on StackOverflow suggesting the implementation of a redirect delegate and reattaching the header values. However, I'm not sure how to apply this in Ktor.
I found this solution on stackoverflow
https://stackoverflow.com/questions/55024711/401-response-when-calling-a-307-redirect-server
How can I implement a redirect delegate in Ktor to intercept a 307 response and reattach header values to the request? Any code examples or guidance would be greatly appreciated.