How do I list Audiences with Microsoft Advertising API?

Héctor Urbina 0 Reputation points
2023-03-30T16:50:42.5133333+00:00

Hi!

GetAudiencesByIds' Documentation says parameter AudienceIds is optional, and that if it's sent empty or null I should receive all available audiences. However, I'm receiving an empty list.

This is the soap body that I'm trying out:

<soapenv:Body>
      <v13:GetAudiencesByIdsRequest>
         <v13:Type>RemarketingList</v13:Type>
         <v13:ReturnAdditionalFields xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
      </v13:GetAudiencesByIdsRequest>
   </soapenv:Body>

When I request for a specific audience with its id, I get it included in the response correctly.

   <soapenv:Body>
      <v13:GetAudiencesByIdsRequest>
         <v13:AudienceIds>
             <arr:long>817341276</arr:long>
        </v13:AudienceIds>
         <v13:Type>RemarketingList</v13:Type>
         <v13:ReturnAdditionalFields xsi:nil="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/>
      </v13:GetAudiencesByIdsRequest>
   </soapenv:Body>

What is the correct way to request all the audiences?

Microsoft Advertising API
Microsoft Advertising API
A Microsoft API that provides programmatic access to Microsoft Advertising to manage large campaigns or to integrate your marketing with other in-house systems.
440 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.