Realtime facebook webhook lead retrieval - facebook doesnt send webhook

43 views Asked by At

Im trying to retrieve leads from instant lead form facebook in real time using webhook. I have server with node.js post request for facebook webhook. I have created developer app for marketing API and webhook module, i have subscribed my url to my developer app and have tested my leadgen webhook - and its ok, my server getting this test leadgen. But when my AD company is active and user filled facebook form - nothing happened. Facebook doesn't send on my server any webhook.

code for getting webhooks simple and working on test hooks.

app.post('/fbtest', (req, res) => {
  try {
    logStream.write(`[${new Date().toUTCString()}] Request body: ${JSON.stringify(req.body)}\n`);

    res.send("OK");
} catch (error) {
   const errorLog = {
     timestamp: new Date().toUTCString(),
     message: 'Error occurred',
     error: error.message,
     stack: error.stack,
    };
   logStream.write(JSON.stringify(errorLog) + '\n');
   res.status(500).send('Internal Server Error'); 
  } 
});

I have checked my subscription, it looks like ok. In Ad company i have added tracking to my app. Please help me, might be i have missed something.

enter image description here

enter image description here

enter image description here

0

There are 0 answers