Open DominikPalo opened 2 years ago
When starting your server you can do so like: try server.start(9080, forceIPv4: true) For me this made the request.address show the IP address of the request i.e. 127.0.0.1. If you combine with request.path you should be able to start to rebuild the request.
I'd like to access the complete URL address inside the route callback. So here is an example code:
but after visiting the registered address (e.g.
http://127.0.0.1:66577/hello-world?test=1
), therequest.path
,request.headers
,request.queryParams
properties are parsed and set correctly, just therequest.address
contains a strange string - something like::c080:d00:60:0
instead of the visited URL (http://127.0.0.1:66577/hello-world?test=1
in my case).Although the
HttpRequest.address
property is not documented, I'm assuming that it should contain the complete URL of the request. Am I right? Or if theHttpRequest.address
is used for something different, how can I get the visited URL?