Posts tagged with facebook-graph-api

I am facing issue about creating facebook ad via api, My code was working and I am using v17 of meta apis, After that when I try to create the ad I get this error too

{   "error": {     "message": "Invalid parameter",     "type": "OAuthException",     "code": 100,     "error_subcode": 2490446,     "is_transient": false,     "error_user_title": "Creative status is WITH_ISSUES",     "error_user_msg": "Creating ad using ad creative with WITH_ISSUES status is not allowed. The ad creative is in WITH_ISSUES status with error code 2643026 and error message: ‎خطأ أثناء معالجة الإعلان: نواجه مشكلة في معالجة طلبك. لحل المشكلة، يرجى محاولة النشر مرة أخرى. إذا كنت لا تزال تواجه مشكلات، يرجى التواصل مع فريق الدعم. نعتذر عن أي إزعاج.‎ Please fix the ad creative, try use recreate ad creative or another ad creative to proceed.",     "fbtrace_id": "AWGR_J-QxQNRI6skOhmUuV2"   } } 

I need to troubleshooting how can I find what's wrong with the creatives that I create

I'm having an issue that when I try to use the debug_token?input_token={} endpoint for meta graph api, I get a permissions error if I use a System-User access token to try to debug that very same token.

{   "error": {     "message": "(#100) You must provide an app access token, or a user access token that is an owner or developer of the app",     "type": "OAuthException",     "code": 100,     "fbtrace_id": "XYZ123DOREMI"   } } 

I have an app where I ask the user to generate a System User Token and I can't seem to use that token with the debug endpoint to actually see the specifications of the token/ ensure it was generated properly and know when it will expire. I am able to get the debug endpoint to work only if I use a different access token such as a user access token. Is there anyway to fix this? Maybe it is missing permissions on the system user token?

I'm encountering a problem with the transition from Facebook's Handover Protocol to the new Conversation Routing system. Previously, under the Handover Protocol, once the primary app (e.g., a chatbot) responded to a user query, the conversation would automatically move to the 'Done' directory. However, with the recent shift to Conversation Routing, this behaviour has changed. All conversations remain in the Main directory even though the default app has already replied to the user. This is causing difficulties for real agents using the Meta Business Inbox feature, as it's not clear whether a conversation is actively being handled by the bot or has been transferred to the Inbox app.

Current configuration: In my facebook page > Settings > Page Setup > Messenger Conversation Routing> Default App is set to my chatbot app In Page Setup > Advanced Messaging, I've tried both leaving the 'Primary Receiver for Handover Protocol' field empty and setting my app as the primary receiver I also noted that once you setup a default app for Conversation Routing, you can't remove it anymore.

Question: How can I ensure that conversations handled by the bot are marked as 'Done' once responded to, to maintain clarity for the agents in the Meta Inbox? Any advice or solutions would be greatly appreciated.

I'm facing an issue with the Facebook Conversation Routing as described in their documentation. According to the documentation, if a page agent responds to a message in a conversation not currently controlled by the inbox, the inbox should take control of the conversation. However, this is not happening in my case. documentation

Note: Although it doesn't work for Facebook conversation, it does work for Instagram conversations (i.e. the instagram conversation is assigned to the Inbox if replied through the Inbox app)

Current configuration: In my facebook page > Settings > Page Setup > Messenger Conversation Routing> Default App is set to my chatbot app In Page Setup > Advanced Messaging, I've tried both leaving the 'Primary Receiver for Handover Protocol' field empty and setting my app as the primary receiver

Steps to reproduce the issue:

A user sends a message to our Facebook page. The chatbot, which initially controls the conversation, receives and responds the message. I then respond to the message directly through the Inbox (https://business.facebook.com/latest/inbox/). Expected behaviour: According to the documentation, once I respond through the Inbox, control of the conversation should transfer from the chatbot app to the Inbox.

Actual behaviour: Despite responding through the Inbox, the conversation remains assigned to the chatbot app. Therefore if the user responds my chatbot is triggered. I also confirmed this by calling the thread_owner endpoint, which still shows the chatbot as the owner.

Troubleshooting steps taken:

Double-checked the app and page settings to ensure they align with the expected routing behaviour. I can confirm since Conversation Routing is enabled, I do not receive message_handover webhooks once the conversation is closed. I believe this is expected behaviour as also noted in the documentation documentation

Question: Has anyone else encountered this issue? Are there specific settings or conditions that might prevent the expected transfer of conversation control from the chatbot to the Inbox? Any insights or suggestions on how to resolve this would be greatly appreciated.

I'm currently working on an automated system that gathers Instagram profile insight data and sends it to an endpoint. However, I'm facing a challenge due to the large number of Instagram accounts I need to manage—more than 100 in total.

As a beginner in this area, I understand that utilizing the Instagram Graph API would be the most efficient approach. However, manually setting up access for each of the accounts seems like a time-consuming task.

Could anyone provide guidance on how to streamline this process? I'm looking for a clear explanation or a step-by-step guide on how to automate access to the Instagram Graph API for multiple accounts.

Any help or insights would be greatly appreciated!