0
votes

In this topic https://developers.facebook.com/docs/marketing-api/audiences-api in part "Custom Audiences from CRM Data" mentioned that I can use Page Scoped User IDs to create custom audience. What schema type I must specify to use PSIDs? Is it possible now from API?

1
My guess would be simply FB_USER_ID ... github.com/facebook/facebook-php-ads-sdk/blob/master/src/… doesn’t list anything other fields related to a Facebook id, and I would suppose that Facebook itself is able to figure out whether a passed id is an app- or page-scoped one. - CBroe
@CBroe Hi, thank you, but to use the page scope user id, we need to specify page_id. But the documentation does not describe where in payload specify page_id. - Евгений Чекалов
“but to use the page scope user id, we need to specify page_id” - where does it say that? - CBroe
@CBroe because when you do it through facebook ads manager interface, you need to choose page_ids to select users. - Евгений Чекалов
So what, you are not using the interface here. Have you tried it via API and gotten an error message in that regard? - CBroe

1 Answers

2
votes

It looks like you can use this format when you post the the /user endpoint of a custom audience:

{
    payload: {
        schema: ["PAGEUID"],
        is_raw: true,
        page_ids: ["323209841097806"],
        data: [
            ["10208379178770401"],
            ["10208379178770402"],
            ["10208379178770403"],
            ["10208379178770404"],
            ["10208379178770405"]
        ]
    }
}