Ad Data Object - Campaign Management

Defines the base object of an ad.

Do not try to instantiate an Ad. You can create one or more following objects that derive from it.


<xs:complexType name="Ad" xmlns:xs="">
    <xs:element minOccurs="0" name="AdFormatPreference" nillable="true" type="xs:string" />
    <xs:element minOccurs="0" name="DevicePreference" nillable="true" type="xs:long" />
    <xs:element minOccurs="0" name="EditorialStatus" nillable="true" type="tns:AdEditorialStatus" />
    <xs:element minOccurs="0" name="FinalAppUrls" nillable="true" type="tns:ArrayOfAppUrl" />
    <xs:element minOccurs="0" name="FinalMobileUrls" nillable="true" type="q1:ArrayOfstring" xmlns:q1="" />
    <xs:element minOccurs="0" name="FinalUrls" nillable="true" type="q2:ArrayOfstring" xmlns:q2="" />
    <xs:element minOccurs="0" name="ForwardCompatibilityMap" nillable="true" type="q3:ArrayOfKeyValuePairOfstringstring" xmlns:q3="" />
    <xs:element minOccurs="0" name="Id" nillable="true" type="xs:long" />
    <xs:element minOccurs="0" name="Status" nillable="true" type="tns:AdStatus" />
    <xs:element minOccurs="0" name="TrackingUrlTemplate" nillable="true" type="xs:string" />
    <xs:element minOccurs="0" name="Type" nillable="true" type="tns:AdType" />
    <xs:element minOccurs="0" name="UrlCustomParameters" nillable="true" type="tns:CustomParameters" />


Element Description Data Type
AdFormatPreference The Ad Format Preference is used to indicate whether or not you prefer the ad copy to be shown to users as a search or native ad. Search ads tend to be written as a call to action, whereas intent ads should be written in more of an informational style.

By defining at least one ad that should be used as native, the search ads will only be shown in search results.

Possible values are Native and All. If set to All, the ad will be eligible for both search and native ad formats. If set to Native, the ad will only be eligible for the native ad format.

Ad Format Preference is only supported for ExpandedTextAd and TextAd objects.
DevicePreference Determines the device preference for showing the ad.

Device preference is only supported for AppInstallAd and TextAd objects.
EditorialStatus The editorial review status of the ad, which indicates whether the ad is pending review, has been approved, or has been disapproved. AdEditorialStatus
FinalAppUrls Reserved for future use. AppUrl array
FinalMobileUrls The mobile landing page URL.

Final mobile URLs is only supported for text ads. For more details see TextAd.
string array
FinalUrls The last or final URL where a user is ultimately taken, whether or not the click to final URL path included any redirects.

Final URLs are only supported for AppInstallAd, ExpandedTextAd, and TextAd objects.
string array
ForwardCompatibilityMap The list of key and value strings for forward compatibility to avoid otherwise breaking changes when new elements are added in the current API version.

Forward compatibility changes will be noted here in future releases. There are currently no forward compatibility changes for this object.
KeyValuePairOfstringstring array
Id The unique Bing Ads identifier for the ad. long
Status The status of the ad.

You can set the ad status to Active or Paused.
TrackingUrlTemplate The tracking template to use as a default for all landing page URLs.

Tracking template is only supported for AppInstallAd, DynamicSearchAd, ExpandedTextAd, and TextAd objects. It is not supported for the ProductAd object.
Type The type of the ad. For more information about ad types, see the Remarks. AdType
UrlCustomParameters Your custom collection of key and value parameters for URL tracking.

Custom parameters are only supported for AppInstallAd, DynamicSearchAd, ExpandedTextAd, and TextAd objects. They are not supported for the ProductAd object.


For Java and the .NET languages, do not set the Type element because the value is determined by whether you instantiate an expanded text ad or another type of ad.

If you generate the SOAP manually, use the type attribute of the Ad node as shown in the following example, to specify whether the ad is an expanded text ad or another type of ad.

<Ads xmlns:i="">
  <Ad i:type="ExpandedTextAd">
    <DevicePreference i:nil="true" />
    <EditorialStatus i:nil="true" />
    <ForwardCompatibilityMap i:nil="true" />
    <Id i:nil="true" />
    <Status i:nil="true" />
    <FinalUrls xmlns:a="">
    <Path2>shoe sale</Path2>
    <Text>Find New Customers & Increase Sales! Start Advertising on Contoso Today.</Text>
    <TitlePart2>Fast & Easy Setup</TitlePart2>


Service: CampaignManagementService.svc v12

Used By