Posts tagged with facebook

{ "name": "ewf", "adset_id": "120215374042820542", "creative": { "creative_id": "1336302651052048" }, "status": "ACTIVE", "leadgen_form_id": "3944213285856717", "access_token": "EAARyZAITtz6QBO86pyaorCyAa5uij334AFiVizvoL5rnw65FBlnqWQJydGUhd1L6fgfIHmxuNyz2lba3xGj6Y8c1jZCvZBkrZA4sVvoImjNpfBdJrELvylBr8lNm5MpBKrzP7dg9FzLULbt9taTUjxge63my0RhvdKxdHS3BZAsUrbMn8AcJmeBePLZAFcZBGfGIwZDZD" }

I'm experiencing an issue with Instagram Direct referral data being passed through the webhook. In some cases, when a user clicks a "Click to Instagram Direct" ad, the webhook includes referral information (e.g., "source": "ADS", "ad_id", etc.). However, for other users who click the very same ad, the webhook payload contains no referral object at all-only the basic message fields. In Meta Business Suite (Ads Manager), I can see that both groups of users did indeed come from the ad. Yet only some of them generate referral data in the webhook. Here are two JSON examples showing the difference: With referral data (includes "referral": { "source": "ADS", "ad_id": Without referral data (no referral field, despite the user coming from the same Instagram ad). have already verified that: My webhook is subscribed to messaging_referrals. The ads are set up using the "Click to IG Direct" objective/format. Everything else in my setup seems consistent. I would be glad to hear any advice on what the problem may be, or if there are any nuances in using Facebook

UPD: I have managed to reproduce this problem, namely if I go to an advertisement in the news feed, click ‘send message’, a modal window appears, after which I do not respond to the message, but close it and go to my account, after which I respond to the welcome message from the advertisement. In this case, we receive a text message via webhook. My pages are subscribed to messages,feed,messaging_postbacks,messaging_referrals

I am trying to create an application that publishes posts to my Facebook Page. Here are the steps I have taken:

  1. Create app via link https://developers.facebook.com/
  2. In section Add use cases I selacted Other
  3. Select an app type -> Buiseness
  4. Then I created app
  5. I didnt add any Add products to your app I directly go to https://developers.facebook.com/tools/explorer/
  6. In permision section I selected pages_read_engagement and pages_manage_posts
  7. Then in User or Pages I selected Get Page Access Token
  8. I selected my page (I created it)
  9. Then I generated access token
  10. I run this query and copy number id from return
  11. Then I run /id/feed POST to publish post:

I get error message that I'm not admin or have incorrect permissions. In my opinion this is correct so issue is somewhere other. Can you please help me find solution for running POST query and publish post on a FB page?

I'm currently working on a workflow to fetch all posts made by my company on social medias. On Facebook, I'm currently using the ads_posts endpoint to fetch both organic and paid posts (was previously using /feed for organic posts and /ads on the business account for paid posts, however the ads endpoint was lacking some posts that were created through dynamic ads).

The current request is like this:

https://graph.facebook.com/v21.0/{FB_PAGE_ID}/ads_posts?fields=id,created_time,updated_time&include_inline_create=true&access_token={PAGE_ACCESS_TOKEN}.  

The problem is, this endpoint only gets me data from within about a month ago. Any try to fetch data older than that using the filters "since" and "until" returns no data, and trying to go there manually through pagination gets me an error of:

Please reduce the amount of data you're asking for, then retry your request

(the "limit" filter doesn't help with this either).

Am I missing something here? Is this a limitation of the ads_posts endpoint? I couldn't find anything related to this on the API reference.

Also, i saw that the posts returned via /ads_posts are sorted by their creation time, while the ads fetched on the /ads are sorted by their update time. Is there any way to change the sorting of the ads_posts entries to their update time as well?

Thanks in advance!

Using https://graph.facebook.com/v21.0/{AD_ACCOUNT_ID}/ads?fields=id,created_time,updated_time,creative{effective_object_story_id}&access_token={USER_ACCESS_TOKEN} i'm able to get ads from 2024-12-01 and before, with their effective_object_story_id that I can access through the post endpoint and check that they in fact exist.

Using the mentioned /ads_posts request, it gets me only posts as old as from 2024-12-06 (3101 posts total). Anything older than this gets me an error or no data at all.

All the posts have been published the same way, and the tokens used have all the needed permission.