messenger-bot-tutorial icon indicating copy to clipboard operation
messenger-bot-tutorial copied to clipboard

not able to register in facebook webhook

Open rcchit opened this issue 8 years ago • 16 comments

Trying to register facebook webhook and keep getting error listed below .BTW I changed in index.js from FB_PAGE_ACCESS_TOKEN to PAGE_ACCESS_TOKEN

"The URL couldn't be validated. Response does not match challenge, expected value="492837124", received="hello world i am a..."

I created these config on heroku PAGE_ACCESS_TOKEN VERIFY_TOKEN

rcchit avatar Feb 05 '17 01:02 rcchit

@rcchit what is the URL you are using?

kostimarko avatar Feb 08 '17 23:02 kostimarko

I had the same issue. You need to paste in the url with /webhook.

https://this-app-68903.herokuapp.com/webhook/

Since this is the sub-dir in the code for FB verification

app.get('/webhook/', function (req, res) {

Komsomol avatar Feb 09 '17 11:02 Komsomol

@Komsomol I had the same issue. After adding /webhook/ everything worked.

kostimarko avatar Feb 09 '17 17:02 kostimarko

I am getting the below error, when trying to setup the webhook. How do we add configurations to heroku? I do not have any prior knowledge in cloud deployment. Please help.

The URL couldn't be validated. Callback verification failed with the following errors: HTTP Status Code = 503; HTTP Message = Service Unavailable

codename-47 avatar Feb 15 '17 11:02 codename-47

I get a similar error Adding /webhook/ doesn't really help either

I've tried even changing the Procfile to a different version (mentioned in another issue) and it fails still

sunnyMiglani avatar Feb 23 '17 00:02 sunnyMiglani

@sunnyMiglani are you getting a 503 error?

kostimarko avatar Feb 23 '17 05:02 kostimarko

@sunnyMiglani We need to provide start script to "start": "node index.js" in package.json file. Hope that works. dfbcaf46-f47c-11e6-8965-f59e44954f3b

codename-47 avatar Feb 23 '17 06:02 codename-47

@kostimarko I'm getting a 502 "bad gateway" error

@codename-47 I've tried adding that, still receive the same error

sunnyMiglani avatar Feb 24 '17 23:02 sunnyMiglani

@sunnyMiglani have you tried running it with out a heroku config?

kostimarko avatar Mar 01 '17 01:03 kostimarko

@codename-47 on adding configurations

Generate a token from this site and save the token somewhere: screen shot 2017-05-31 at 17 55 56

To add configurations to heroku, type this command into the terminal while in your working directory. heroku config:set FB_PAGE_ACCESS_TOKEN=fake-access-token-dhsa09uji4mlkasdfsd

You can then access the token in your index.js file as follows: screen shot 2017-05-31 at 17 51 24

dchege711 avatar May 31 '17 15:05 dchege711

I am facing given problem

The URL couldn't be validated. Response does not match challenge, expected value="182436379", received="Invalid verify token"

any solution for this https://github.com/netguru/messenger-ruby/issues/54

dinshawr avatar Jul 31 '17 09:07 dinshawr

I am facing similar problem here is my issue,

The URL couldn't be validated. Response does not match challenge, expected value="1060150785", received=""1060150785""

F-Makhokha avatar Sep 06 '17 09:09 F-Makhokha

@F-Makhokha check for index.js and add https://YOUR-APP.herokuapp.com/webhook/ your token would be: my_voice_is_my_password_verify_me as mentioned in index.js

abhilashrao avatar Oct 12 '17 00:10 abhilashrao

Hello, any updates about that issue ? Thanks in advance

nicocouz avatar Feb 05 '19 10:02 nicocouz

Deploy the Heroku app first using git and then you should register the facebook webhook.

Poseidon4006 avatar May 26 '19 23:05 Poseidon4006

Had the same issue, but turns out I was using the wrong URL. Use the URL that comes out in the build logs

chitalian avatar Oct 12 '20 05:10 chitalian