Replies: 1 comment
-
@ecnjava Did you register your URL webhook in Meta Portal ? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi guys!!
I'm using GCF webhook and PyWA....
Throughout GC Logs explorer, I can see the incoming messages accordingly, but my Flask server is not being triggered whenever a message arrives (@wa_ret.on_message(filters.command("start")))..... Could you please advise me???
Here is my source code:
import flask # pip3 install flask
from pywa import WhatsApp, types
flask_app = flask.Flask(name)
async def init_wa():
global wa_ret
if wa_ret is None:
wa_ret = WhatsApp(
phone_id="3",
server=flask_app,
token="1",
verify_token='1',
api_version=21.0,
continue_handling=True)
@https_fn.on_request()
def webhook(request: https_fn.Request) -> https_fn.Response:
if request.method == 'GET':
mode = request.args.get('hub.mode')
token = request.args.get('hub.verify_token')
challenge = request.args.get('hub.challenge')
challenge_200 = challenge, 200
Beta Was this translation helpful? Give feedback.
All reactions