title: In Azure function with proxy, get original URL
body: <p>I am setting up an Azure function app where I'm proxying all requests for a subdomain to one specific function.  My <code>proxies.json</code> looks like this:</p>
  
  <pre><code>{
    "$schema": "http://json.schemastore.org/proxies",
    "proxies": {
      "Root URI to Trigger Function": {
        "matchCondition": {
          "route": "/{*path}",
          "methods": [
            "GET",
            "POST"
          ]
        },
        "backendUri": "http://example.com/api/myfunc"
      }
    }
  }
  </code></pre>
  
  <p>Inside my <code>myfunc</code> function, I'm trying to access the URL of the original request using <code>req.originalUrl</code> - however it's always set to <code>http://example.com/api/myfunc</code>.</p>
  
  <p>I tried adding request override to add an extra header, something like this:</p>
  
  <pre><code>"requestOverrides": {
    "backend.request.headers.X-Original-URL": "{request.originalUrl}"
  }
  </code></pre>
  
  <p>Yet, this doesn't work and the <code>X-Original-Url</code> header contains <code>\n\u000fx-forwarded-for\u0012\texample.com</code> value</p>
  
  <p>How can I reliably get the original URL that my function app received?</p>