The URL to redirect to
The HTTP redirect status (3xx) to send - by default this is HTTPStatus.found
import vibe.http.router; void request_handler(HTTPServerRequest req, HTTPServerResponse res) { res.redirect("http://example.org/some_other_url"); } void test() { auto router = new URLRouter; router.get("/old_url", &request_handler); listenHTTP(new HTTPServerSettings, router); }
Sends a redirect request to the client.