'LinkedIn AdGroups API returning empty results

I am trying to GET campaign groups that are in an AdAccount using python API.

I have generated access token from LinkedIn UI & it has a validity of 2 months.

This is one of the API that i tried. My AdAccount has ACTIVE campaign groups.

https://api.linkedin.com/v2/adCampaignGroupsV2?q=search&search.status.values[0]=ACTIVE&search.status.values[1]=DRAFT&sort.field=ID&sort.order=DESCENDING

On every API call i am getting an empty result only.

{'paging': {'start': 0, 'count': 10, 'links': [], 'total': 0}, 'elements': []}

Could someone please help me how to retrieve Ads data from LinkedIn



Solution 1:[1]

I've seen your post about this on upwork. I didn't applied there because I have no experience with python or LinkedIn ads. Checking the docs looks like the params are optional so I guess you could do a:

GET https://api.linkedin.com/v2/adCampaignGroupsV2?q=search

And you should be able to see all the campaigns that you have access to. If you still get empty result you should check your permissions. Link here.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Andrei