6

I have created a Ads and campaigns in Facebook Ads Manager. But they are not yet published

I have tried the following API call to get a list of all the campaigns I have created,

/v3.2/act_XXXX/campaigns

But I am getting an empty response,

{
  "data": [
  ]
}

Is there any other way to list all the campaigns created irrespective of they are published or not

r123
  • 578
  • 8
  • 26
  • 1
    Did you manage to resolve this issue? The suggestion below doesn't seem to work for me. – Alon Granot Sep 06 '20 at 06:06
  • Does this answer your question? [How to access all draft campaigns with the Facebook marketing API?](https://stackoverflow.com/questions/70058289/how-to-access-all-draft-campaigns-with-the-facebook-marketing-api) – Oleksii Tambovtsev Dec 07 '21 at 13:32

1 Answers1

0

The default filter is ACTIVE campaign, if you want to retrieve for different state you can use the filter options, as example:

act_XXXX/campaigns?filtering=[{'field':'effective_status','operator':'IN','value':["ACTIVE","PAUSED","PENDING_REVIEW"]}]&fields=name,effective_status

And add in the list the status you need, from the doc:

effective_status enum {ACTIVE, PAUSED, DELETED, PENDING_REVIEW, DISAPPROVED, PREAPPROVED, PENDING_BILLING_INFO, CAMPAIGN_PAUSED, ARCHIVED, ADSET_PAUSED, WITH_ISSUES}

Facebook doc here

Matteo
  • 37,680
  • 11
  • 100
  • 115
  • 1
    I am still getting an empty response after using the above given parameters – r123 Mar 14 '19 at 12:31
  • hi @r123 have tried using ALL the possible state listed in the answer? Are you able to use the campaign id in order to retrieve it and check for the status? – Matteo Mar 14 '19 at 12:56
  • 1
    yes, I have tried all possible states. Also, I am not able to use the campaign id in order to retrieve it – r123 Mar 15 '19 at 04:15
  • I think there is a difference between the ```effective_status``` variable and whether a campaign is in draft or published mode. I also struggle to retrieve draft campaigns. – Tea Tree Nov 21 '21 at 02:34
  • @TeaTree try filtering by `status` instead of `effective_status` – Matteo Nov 21 '21 at 20:30
  • I don't think that'll work: from the [documentation](https://developers.facebook.com/docs/marketing-api/reference/ad-campaign-group), ```configured_status``` takes one of these values: ACTIVE, PAUSED, DELETED, ARCHIVED. ```effective_status``` takes ACTIVE, PAUSED, DELETED, ARCHIVED, IN_PROCESS, WITH_ISSUES. ```status``` takes ACTIVE, PAUSED, DELETED, ARCHIVED. The draft status of a campaign is different though and not listed anywhere here. – Tea Tree Nov 21 '21 at 21:04