When using Facebook Messenger to send a chat message to my Chatbot, I don't get a reply. Checking the server logs show that I am receiving a GET request whereas it should be a POST request.
This is weird because the chatbot works when tested by running the file locally, whereas upon deploying it on Digital Ocean Droplet, it receives it as a GET request.
The deployed version works if i explicitly send a POST request via Postman (while simulating a facebook messaging request body)
Is there any reason Facebook is sending / I am receiving it as a GET request instead of a POST?
I tried to test the file locally and it works, and through simulating requests with Postman. It just doesn't work if the request is sent via a message on Facebook Messenger
Made a mistake before, it was indeed related to the redirections as stated by CBroe.
POST Endpoint was made for url with a trailing slash whereas the callback set on facebook developers was set to handle no trailing slash. Just had to fix that and redirection issue was resolved!
Facebook API is sending a GET request instead of a POST to my Chatbot