Skip to content

Structure

Redirect

Specifies the type of redirect that the client should receive.
struct Redirect

Topics

Instance Properties

  • status
    Associated HTTPStatus for this redirect type.

Type Properties

  • normal
    Forces the redirect to come with a GET, regardless of req method. 303 see other
  • permanent
    A cacheable redirect. Not all user-agents preserve request method and body, so this should only be used for GET or HEAD requests 301 permanent
  • permanentPost
    Redirect where the request method and the body will not be altered. This should be used for POST redirects. 308 Permanent Redirect
  • temporary
    Maintains original request method, ie: PUT will call PUT on redirect. 307 Temporary