Http-request redirect to backend host?

I would like incoming queries in haproxy example: http://haproxy/test are redirected to one of the backends in a 301 redirection:

http://server-a/test or
http://server-b/test or
http://server-c/test or

my backend:

backend cluster_redirect
   http mode
   random balance
   server server-a:80
   server server-b:80
   server server-c:80

my frontend:

front-end www
    http-request redirect code 301 location http://%bi%[capture.req.uri]
    use_backend cluster_redirect

%bi is not interpreted!. URL for redirect is : “location: http:///test”

If i use a set-header for debug: http-response set-header X-Debug http://%bi%[capture.req.uri]
the header is : X-Debug: is the IP for haproxy.

Thank you