I've got a script which firstly creates a custom audience, then populates it with SHA256-hashed emails.
The custom audience exists and I can see / manage it in the Facebook's Business Manager (very same ID).
The error is the following: Unsupported post request. Object with ID 'xxxxxxxxxxxxx' does not exist, cannot be loaded due to missing permissions, or does not support this operation. Please read the Graph API documentation at https://developers.facebook.com/docs/graph-api.
This is the code which is being executed:
private function uploadForConfiguration(...): void {
// ...
Api::init($this->appId, $this->appSecret, $configuration->getAccessToken());
foreach ($customAudienceIds as $audienceId) {
foreach (\array_chunk($emails, 10000) as $emailsChunk) {
$audience = new CustomAudience($audienceId); // $audienceId exists as per Business Manager
// Emails are already SHA256 hashed and lower-case transformed
$audience->addUsers($emailsChunk, CustomAudienceTypes::EMAIL, [], true, false);
}
}
}
Is this the right way to call the API? Or should I call it differently?
Hello!
I've got a script which firstly creates a custom audience, then populates it with SHA256-hashed emails.
The custom audience exists and I can see / manage it in the Facebook's Business Manager (very same ID).
The error is the following:
Unsupported post request. Object with ID 'xxxxxxxxxxxxx' does not exist, cannot be loaded due to missing permissions, or does not support this operation. Please read the Graph API documentation at https://developers.facebook.com/docs/graph-api
.This is the code which is being executed:
Is this the right way to call the API? Or should I call it differently?
Thanks