title: Cloud Front : The request could not be satisfied
body: <p>I am coming across this problem, i have a chat server which needs to communicate to the lambda service hosted in aws , but cloud front throws the following error.</p>
  
  <pre><code>BODY: &lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"&gt;
  &lt;HTML&gt;&lt;HEAD&gt;&lt;META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1"&gt;
  &lt;TITLE&gt;ERROR: The request could not be satisfied&lt;/TITLE&gt;
  &lt;/HEAD&gt;&lt;BODY&gt;
  &lt;H1&gt;ERROR&lt;/H1&gt;
  &lt;H2&gt;The request could not be satisfied.&lt;/H2&gt;
  &lt;HR noshade size="1px"&gt;
  Bad request.
  &lt;BR clear="all"&gt;
  &lt;HR noshade size="1px"&gt;
  &lt;PRE&gt;
  Generated by cloudfront (CloudFront)
  Request ID: h5kPdVnMXwh-P7e7mxQ5LL1gj9fAupp_MNAPxmxufI74W4WhE_MByw==
  &lt;/PRE&gt;
  &lt;ADDRESS&gt;
  &lt;/ADDRESS&gt;
  &lt;/BODY&gt;&lt;/HTML&gt;
  </code></pre>
  
  <p>This is how my request goes in application.</p>
  
  <pre><code>const options = {
      hostname: 'xxx.uat.com',
      port : '443',        
      path: '/qa/addMessage',
      method: 'POST'
  };
  const req = http.request(options, (res) =&gt; {
  }
  </code></pre>
  
  <p>the chat server.js is hosted in ec2. what is the issue here? </p>