title: Facebook Webhook Messenger get Page ID
body: <p>I'm using Facebook's messenger webhook and listening API which also sometimes might respond (bot).
  It is important to determine which page ID the webhook is coming from (because it will be used by some pages). From my understanding I've tried to search the params, headers and body.</p>
  <p>Am I supposed to decrypt the <strong>X-Hub-Signature</strong> to determine data which might light to the page ID?</p>
  <p>Here are the headers:</p>
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>{
     "Host":"**xxxx-xxxx-xxxx-xx-x-xxxx-xxxx-xxxx-xxxx.ngrok.io**",
     "User-Agent":"facebookexternalua",
     "Content-Length":"308",
     "Accept":"\/",
     "Accept-Encoding":"deflate, gzip",
     "Content-Type":"application\/json",
     "Facebook-Api-Version":"v12.0",
     "P-Mi-Om":"FgIA",
     "X-Forwarded-For":"**xxxx:xxxx:xxxx:xx::face:b00c**",
     "X-Forwarded-Proto":"https",
     "X-Hub-Signature":"sha1=**xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx**"
  }</code></pre>
  </div>
  </div>
  </p>
  <p>Response:</p>
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>{
     "object":"page",
     "entry":[
        {
           "id":"xxxxxxxxxxxxxxx",
           "time":1636101951119,
           "messaging":[
              {
                 "sender":{
                    "id":"xxxxxxxxxxxxxxx"
                 },
                 "recipient":{
                    "id":"xxxxxxxxxxxxxxx"
                 },
                 "timestamp":1636101950853,
                 "message":{
                    "mid":"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
                    "text":"hey"
                 }
              }
           ]
        }
     ]
  }</code></pre>
  </div>
  </div>
  </p>