AnsweredAssumed Answered

How to access request header values for host for use in {{}}

Question asked by eschumac on Mar 1, 2016
Latest reply on Mar 2, 2016 by eschumac

I'm finding the docs and search difficult at best for this most basic need.

 

I have responses with callback URI's to other signatures on the service. Since I will never really know the host and port of the VSE I have a need to get these at RUNTIME. I am OK with deploying the service and then finding its port and host name for the initial request, but all responses should be dynamic.

 

I poked around and found a lot of dead ends only to arrive at this for host and port: {{LISA_HOST}}:{{lisa.vse.port.number}}

 

Looks funny, right? Why couldn't I do like this? {{lisa.vse.host.name}}:{{lisa.vse.port.number}} Well, if you do that Host name is UNKNOWN.

 

But I really want to get Host from the header without a lot of trouble. So, how to get things like header values from known keys in the header?

 

Shouldn't I be able to do like this? {{=request.header("Host")}}. Doesn't everyone need to do this kind of thing?

Outcomes