title: Azure Functions HttpClient No such host is known on Request
body: <p>I'm trying to see if an API is up but when I publish the code to Azure, the HttpClient fails to get anything because when it tries to .SendAsync(); the error message I get from Azure is &quot;No Such Host is Known&quot; but the code does work unaltered on my local environment.</p>
  <p>Any idea from this what might be missing or would be the cause for the HttpClient Get to be failing?</p>
  <pre><code>public class ConnectionTester
      {
          [FunctionName(&quot;ConnectionTester&quot;)]
          public static async Task Run([TimerTrigger(&quot;* */30 * * * *&quot;)] TimerInfo connectionTimer, ILogger log)
          {
              log.LogInformation($&quot;C# Timer trigger function executed at: {DateTime.Now}&quot;);
              
              var client = new HttpClient();
              client.DefaultRequestHeaders.Add(&quot;Authorization&quot;, strAuth);
              HttpRequestMessage newRequest = new HttpRequestMessage(HttpMethod.Get, strLink);
              var response = await client.SendAsync(newRequest);
              
              if (response.IsSuccessStatusCode)
              {
                  log.LogInformation(&quot;Success&quot;);
              }
              else
              {
                  log.LogError(&quot;Error&quot;);
              }
          }
      }
  </code></pre>