Jan '24 (edited) • 💡 Help
Help with error code WhatsApp API
I double checked for restrictions on whether it is allowed or not for this to be sort of like a stack overflow and I noticed there isn't, if there is, I apologize in advance and beg not to be banned from this community;
I am implementing a chatbot for my own financial consulting company and whenever I send a message from my own personal WhatsApp number to the chatbot (with the test phone number) it does receive the webhook but I get an error:
INFO:run:Full incoming data: {'object': 'whatsapp_business_account', 'entry': [{'id': 'xxxxxxx', 'changes': [{'value': {'messaging_product': 'whatsapp', 'metadata': {'display_phone_number': '15551284645', 'phone_number_id': 'xxxxxx'}, 'contacts': [{'profile': {'name': 'S'}, 'wa_id': 'xxxxxx'}], 'messages': [{'from': 'xxxxx', 'id': 'wamid.HBgNNTIxNTUxNzAxNTczNhUCABIYFDNBMUIxMDUyQzgwRjM0RjM3NjVCAA==', 'timestamp': '1705533477', 'text': {'body': 'hello'}, 'type': 'text'}]}, 'field': 'messages'}]}]}
INFO:run:Full incoming data: {'object': 'whatsapp_business_account', 'entry': [{'id': 'xxxxxx', 'changes': [{'value': {'messaging_product': 'whatsapp', 'metadata': {'display_phone_number': 'xxxxx', 'phone_number_id': 'xxxxx'}, 'contacts': [{'profile': {'name': 'S'}, 'wa_id': 'xxxxxx'}], 'messages': [{'from': 'xxxxxx', 'id': 'wamid.HBgNNTIxNTUxNzAxNTczNhUCABIYFDNBMUIxMDUyQzgwRjM0RjM3NjVCAA==', 'timestamp': '1705533477', 'text': {'body': 'hello'}, 'type': 'text'}]}, 'field': 'messages'}]}]}
Main issue
|
v
INFO:httpx:HTTP Request: POST https://api.openai.com/v1/chat/completions "HTTP/1.1 200 OK"
INFO:app.services.openai_service:WhatsApp API Response: 400, b'{"error":{"message":"(#131030) Recipient phone number not in allowed list","type":"OAuthException","code":131030,"error_data":{"messaging_product":"whatsapp","details":"The phone number is not on the authorized recipient list: Add the phone number of the recipient to the list of recipients and try again."},"fbtrace_id":"A-wdQVYs5Eflbgblj5x41Ha"}}'. I already implemented the openai api section but I'm only missing this to figure out. I am still in development/sandbox stage so i'm not sure if this could be the problem.
I am really sorry if this community is not for this purpose so I understand if its deleted, ive already made this question on stack overflow but haven't gotten an answer.
My experience is close to null so I could imagine if the solution is quite straightforward.
5
4 comments
Santiago Beristain
2
Help with error code WhatsApp API
Data Alchemy
skool.com/data-alchemy
Your Community to Master the Fundamentals of Working with Data and AI — by Datalumina®
Leaderboard (30-day)
Powered by