ApplyProductPartitionActions 服务操作 - 市场活动管理

将添加、更新或删除操作应用于每个指定的 BiddableAdGroupCriterionNegativeAdGroupCriterion,每个操作都包含 一个 ProductPartition

提示

有关Microsoft购物市场活动的概述和详细信息,请参阅 产品广告智能购物市场活动 技术指南。

请注意以下验证规则。

  • 至少必须为产品分区组树结构指定根节点。 产品分区组的根 BiddableAdGroupCriterion 必须将其条件 操作数 设置为“All”, 并将“属性” 设置为 null。 如果对目录中所有产品进行平均竞价,请将 PartitionType 设置为 Unit。 如果要根据更具体的产品条件对出价进行分区,请将 PartitionType 设置为 Subdivision,将 ParentCriterionId 设置为 null,并将 Id 设置为负值。 将负值用作任何子节点的 ParentCriterionId

  • 根节点被视为级别 0,树最多可以有 7 个级别深的分支。

  • 每次调用最多可以指定 5,000 个 AdGroupCriterionAction 对象。 通过多个调用创建的整个树最多可以有 20,000 个节点。

  • 每个 AdGroupCriterionAction 对象必须具有相同的 AdGroupId,否则调用将失败。

  • 若要更新 ConditionAttribute 属性,必须删除现有的产品分区树节点,并添加新的产品分区树节点,该节点将获取新的标识符。 同样,若要从 BiddableAdGroupCriterion 更新为 NegativeAdGroupCriterion 或反之亦然,必须删除现有的产品分区树节点,并添加一个新的产品分区树节点,该节点将获取新标识符。

  • 如果任何操作失败,则可能已成功的所有剩余操作也将失败。

  • 一次调用中的所有操作都必须生成完整的树结构。 如果需要为每个广告组应用超过 5,000 个操作,则必须进行多次调用。 从第一次调用中获取父广告组条件标识符,然后在后续调用中根据需要添加更多子级。

  • 从根节点到分支末尾的每个路径都必须以一个叶节点 (ProductPartitionType=Unit) 终止。 每个单位都必须有出价,除非节点是 NegativeAdGroupCriterion

  • 每个细分必须至少有一个叶节点,该节点对细分条件的其余部分进行出价,即使用与其同级单位相同的操作数 () ,并将其 属性 设置为 null

  • 只能在其父节点之后指定子节点。

  • 如果要添加具有多个级别的分区,其中父级或子级尚不存在,请使用负 int 值作为引用来标识父级。 例如,将父级的 Id 和子级的 ParentCriterionId 元素都设置为相同的负值。 负 ID 仅在调用期间有效。 响应消息中返回每个成功添加的广告组条件的唯一系统标识符。

  • 对于细分分区节点,将忽略 BiddableAdGroupCriterionCriterionBidDestinationUrl 元素。 这些元素仅与 单元 (叶) 分区节点相关。

  • 对于产品分区条件,始终忽略 AdGroupCriterionStatus 元素。 若要添加、更新或删除产品分区,请设置相应 AdGroupCriterionActionAction 元素。

  • 若要暂停任何产品分区,必须通过调用 UpdateAdGroups 来暂停整个广告组。 可以调用 UpdateCampaigns 来暂停整个市场活动。

  • AdGroupCriterionEditorialStatus 元素对产品分区标准没有显著意义。 产品目录的编辑验证在 Microsoft 商家中心商店中完成。

  • 对于 Delete 操作,只需在 AdGroupCriterion 中指定 IdAdGroupId

  • 如果删除父产品分区,也会删除其所有子级和子级。

  • 不能在分支中指定重复的产品条件。

请求元素

ApplyProductPartitionActionsRequest 对象定义服务操作请求的正文标头元素。 元素的顺序必须与 请求 SOAP 中所示的顺序相同。

注意

除非下面另有说明,否则需要所有请求元素。

请求正文元素

元素 说明 数据类型
CriterionActions 最多 5,000 个 AdGroupCriterionAction 对象的列表,每个对象都包含 一个 Action 元素和 一个 BiddableAdGroupCriterionNegativeAdGroupCriterion

所有广告组条件操作都必须针对同一广告组。 有关详细信息,包括验证规则,请参阅 使用市场活动管理服务创建Microsoft购物市场活动
AdGroupCriterionAction 数组

请求标头元素

元素 说明 数据类型
AuthenticationToken OAuth 访问令牌,表示有权Microsoft广告帐户的用户的凭据。

有关详细信息,请参阅 使用 OAuth 进行身份验证
string
CustomerAccountId 拥有或与请求中的实体关联的广告帐户的标识符。 如果需要这两个元素,此标头元素必须与 AccountId 正文元素具有相同的值。 此元素是大多数服务操作所必需的,作为最佳做法,应始终设置它。

有关详细信息,请参阅 获取帐户和客户 ID
string
CustomerId 用户正在访问或操作的客户) 经理帐户 (标识符。 用户可以访问多个经理帐户。 此元素是大多数服务操作所必需的,作为最佳做法,应始终设置它。

有关详细信息,请参阅 获取帐户和客户 ID
string
DeveloperToken 用于访问必应广告 API 的开发人员令牌。

有关详细信息,请参阅 获取开发人员令牌
string
Password 此元素保留供内部使用,将从 API 的未来版本中删除。 必须使用 AuthenticationToken 元素来设置用户凭据。 string
UserName 此元素保留供内部使用,将从 API 的未来版本中删除。 必须使用 AuthenticationToken 元素来设置用户凭据。 string

响应元素

ApplyProductPartitionActionsResponse 对象定义服务操作响应的正文标头元素。 元素的返回顺序与 响应 SOAP 中所示的顺序相同。

响应正文元素

元素 说明 数据类型
AdGroupCriterionIds 标识已应用操作的条件的标识符列表。 标识符列表直接对应于请求中的条件列表。

如果任何条件操作失败,则所有剩余的条件操作都将失败,并且此列表中的所有元素都将为 null。
long 数组
PartialErrors BatchError 对象的数组,其中包含未成功的任何请求项的详细信息。

错误列表与请求中的项列表不直接对应。 如果没有错误,列表可以为空,也可以包含与请求中每个不成功的列表项对应的一个或多个错误对象。

对于由于用户错误而失败的条件,将返回可操作的错误代码。

如果任何条件操作失败,则所有剩余的条件操作都将失败,并且此列表中的任何元素都不会为 null。 对于本来可能成功的条件,将返回一个通用错误,说明相关实体失败。
BatchError 数组

响应标头元素

元素 说明 数据类型
跟踪 ID 包含 API 调用详细信息的日志条目的标识符。 string

请求 SOAP

此模板由一个工具生成,用于显示 SOAP 请求的正文标头元素的顺序。 有关可用于此服务操作的支持类型,请参阅上面的 请求正文元素 参考。

<s:Envelope xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
  <s:Header xmlns="https://bingads.microsoft.com/CampaignManagement/v13">
    <Action mustUnderstand="1">ApplyProductPartitionActions</Action>
    <AuthenticationToken i:nil="false">ValueHere</AuthenticationToken>
    <CustomerAccountId i:nil="false">ValueHere</CustomerAccountId>
    <CustomerId i:nil="false">ValueHere</CustomerId>
    <DeveloperToken i:nil="false">ValueHere</DeveloperToken>
  </s:Header>
  <s:Body>
    <ApplyProductPartitionActionsRequest xmlns="https://bingads.microsoft.com/CampaignManagement/v13">
      <CriterionActions i:nil="false">
        <AdGroupCriterionAction>
          <Action>ValueHere</Action>
          <AdGroupCriterion i:nil="false" i:type="-- derived type specified here with the appropriate prefix --">
            <AdGroupId>ValueHere</AdGroupId>
            <Criterion i:nil="false" i:type="-- derived type specified here with the appropriate prefix --">
              <Type i:nil="false">ValueHere</Type>
              <!--These fields are applicable if the derived type attribute is set to ProductPartition-->
              <Condition i:nil="false">
                <Attribute i:nil="false">ValueHere</Attribute>
                <Operand i:nil="false">ValueHere</Operand>
                <Operator i:nil="false">ValueHere</Operator>
              </Condition>
              <ParentCriterionId i:nil="false">ValueHere</ParentCriterionId>
              <PartitionType>ValueHere</PartitionType>
              <!--These fields are applicable if the derived type attribute is set to HotelGroup-->
              <Listing i:nil="false">
                <Attribute i:nil="false">ValueHere</Attribute>
                <Operand i:nil="false">ValueHere</Operand>
              </Listing>
              <ListingType>ValueHere</ListingType>
              <ParentCriterionId i:nil="false">ValueHere</ParentCriterionId>
              <!--These fields are applicable if the derived type attribute is set to HotelAdvanceBookingWindowCriterion-->
              <MaxDays i:nil="false">ValueHere</MaxDays>
              <MinDays i:nil="false">ValueHere</MinDays>
              <!--These fields are applicable if the derived type attribute is set to HotelCheckInDateCriterion-->
              <EndDate i:nil="false">ValueHere</EndDate>
              <StartDate i:nil="false">ValueHere</StartDate>
              <!--This field is applicable if the derived type attribute is set to HotelCheckInDayCriterion-->
              <CheckInDay i:nil="false">ValueHere</CheckInDay>
              <!--This field is applicable if the derived type attribute is set to HotelDateSelectionTypeCriterion-->
              <HotelDateSelectionType i:nil="false">ValueHere</HotelDateSelectionType>
              <!--These fields are applicable if the derived type attribute is set to HotelLengthOfStayCriterion-->
              <MaxNights i:nil="false">ValueHere</MaxNights>
              <MinNights i:nil="false">ValueHere</MinNights>
              <!--This field is applicable if the derived type attribute is set to ProductScope-->
              <Conditions i:nil="false">
                <ProductCondition>
                  <Attribute i:nil="false">ValueHere</Attribute>
                  <Operand i:nil="false">ValueHere</Operand>
                  <Operator i:nil="false">ValueHere</Operator>
                </ProductCondition>
              </Conditions>
              <!--This field is applicable if the derived type attribute is set to Webpage-->
              <Parameter i:nil="false">
                <Conditions i:nil="false">
                  <WebpageCondition>
                    <Argument i:nil="false">ValueHere</Argument>
                    <Operand>ValueHere</Operand>
                    <Operator i:nil="false">ValueHere</Operator>
                  </WebpageCondition>
                </Conditions>
                <CriterionName i:nil="false">ValueHere</CriterionName>
              </Parameter>
              <!--This field is applicable if the derived type attribute is set to AgeCriterion-->
              <AgeRange i:nil="false">ValueHere</AgeRange>
              <!--These fields are applicable if the derived type attribute is set to DeviceCriterion-->
              <DeviceName i:nil="false">ValueHere</DeviceName>
              <OSName i:nil="false">ValueHere</OSName>
              <!--These fields are applicable if the derived type attribute is set to DayTimeCriterion-->
              <Day i:nil="false">ValueHere</Day>
              <FromHour i:nil="false">ValueHere</FromHour>
              <FromMinute i:nil="false">ValueHere</FromMinute>
              <ToHour i:nil="false">ValueHere</ToHour>
              <ToMinute i:nil="false">ValueHere</ToMinute>
              <!--This field is applicable if the derived type attribute is set to GenderCriterion-->
              <GenderType i:nil="false">ValueHere</GenderType>
              <!--These fields are applicable if the derived type attribute is set to RadiusCriterion-->
              <LatitudeDegrees i:nil="false">ValueHere</LatitudeDegrees>
              <LongitudeDegrees i:nil="false">ValueHere</LongitudeDegrees>
              <Name i:nil="false">ValueHere</Name>
              <Radius i:nil="false">ValueHere</Radius>
              <RadiusUnit i:nil="false">ValueHere</RadiusUnit>
              <!--These fields are applicable if the derived type attribute is set to LocationCriterion-->
              <DisplayName i:nil="false">ValueHere</DisplayName>
              <EnclosedLocationIds i:nil="false" xmlns:a1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
                <a1:long>ValueHere</a1:long>
              </EnclosedLocationIds>
              <LocationId i:nil="false">ValueHere</LocationId>
              <LocationType i:nil="false">ValueHere</LocationType>
              <!--This field is applicable if the derived type attribute is set to LocationIntentCriterion-->
              <IntentOption i:nil="false">ValueHere</IntentOption>
              <!--These fields are applicable if the derived type attribute is set to AudienceCriterion-->
              <AudienceId i:nil="false">ValueHere</AudienceId>
              <AudienceType i:nil="false">ValueHere</AudienceType>
              <!--These fields are applicable if the derived type attribute is set to ProfileCriterion-->
              <ProfileId>ValueHere</ProfileId>
              <ProfileType>ValueHere</ProfileType>
              <!--This field is applicable if the derived type attribute is set to StoreCriterion-->
              <StoreId i:nil="false">ValueHere</StoreId>
              <!--This field is applicable if the derived type attribute is set to DealCriterion-->
              <DealId>ValueHere</DealId>
              <!--This field is applicable if the derived type attribute is set to GenreCriterion-->
              <GenreId>ValueHere</GenreId>
              <!--These fields are applicable if the derived type attribute is set to PlacementCriterion-->
              <PlacementId>ValueHere</PlacementId>
              <PlacementName i:nil="false">ValueHere</PlacementName>
            </Criterion>
            <Id i:nil="false">ValueHere</Id>
            <Status i:nil="false">ValueHere</Status>
            <Type i:nil="false">ValueHere</Type>
            <!--These fields are applicable if the derived type attribute is set to BiddableAdGroupCriterion-->
            <CriterionBid i:nil="false" i:type="-- derived type specified here with the appropriate prefix --">
              <Type i:nil="false">ValueHere</Type>
              <!--This field is applicable if the derived type attribute is set to RateBid-->
              <RateAmount i:nil="false">
                <Amount i:nil="false">ValueHere</Amount>
              </RateAmount>
              <!--This field is applicable if the derived type attribute is set to FixedBid-->
              <Amount>ValueHere</Amount>
              <!--This field is applicable if the derived type attribute is set to BidMultiplier-->
              <Multiplier>ValueHere</Multiplier>
            </CriterionBid>
            <DestinationUrl i:nil="false">ValueHere</DestinationUrl>
            <EditorialStatus i:nil="false">ValueHere</EditorialStatus>
            <FinalAppUrls i:nil="false">
              <AppUrl>
                <OsType i:nil="false">ValueHere</OsType>
                <Url i:nil="false">ValueHere</Url>
              </AppUrl>
            </FinalAppUrls>
            <FinalMobileUrls i:nil="false" xmlns:a1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
              <a1:string>ValueHere</a1:string>
            </FinalMobileUrls>
            <FinalUrlSuffix i:nil="false">ValueHere</FinalUrlSuffix>
            <FinalUrls i:nil="false" xmlns:a1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
              <a1:string>ValueHere</a1:string>
            </FinalUrls>
            <TrackingUrlTemplate i:nil="false">ValueHere</TrackingUrlTemplate>
            <UrlCustomParameters i:nil="false">
              <Parameters i:nil="false">
                <CustomParameter>
                  <Key i:nil="false">ValueHere</Key>
                  <Value i:nil="false">ValueHere</Value>
                </CustomParameter>
              </Parameters>
            </UrlCustomParameters>
            <CriterionCashback i:nil="false" i:type="-- derived type specified here with the appropriate prefix --">
              <Type i:nil="false">ValueHere</Type>
              <!--This field is applicable if the derived type attribute is set to CashbackAdjustment-->
              <CashbackPercent i:nil="false">ValueHere</CashbackPercent>
            </CriterionCashback>
            <!--No additional fields are applicable if the derived type attribute is set to NegativeAdGroupCriterion-->
          </AdGroupCriterion>
        </AdGroupCriterionAction>
      </CriterionActions>
    </ApplyProductPartitionActionsRequest>
  </s:Body>
</s:Envelope>

响应 SOAP

此模板由一个工具生成,用于显示 SOAP 响应的 正文标头 元素的顺序。

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
  <s:Header xmlns="https://bingads.microsoft.com/CampaignManagement/v13">
    <TrackingId d3p1:nil="false" xmlns:d3p1="http://www.w3.org/2001/XMLSchema-instance">ValueHere</TrackingId>
  </s:Header>
  <s:Body>
    <ApplyProductPartitionActionsResponse xmlns="https://bingads.microsoft.com/CampaignManagement/v13">
      <AdGroupCriterionIds d4p1:nil="false" xmlns:a1="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns:d4p1="http://www.w3.org/2001/XMLSchema-instance">
        <a1:long>ValueHere</a1:long>
      </AdGroupCriterionIds>
      <PartialErrors d4p1:nil="false" xmlns:d4p1="http://www.w3.org/2001/XMLSchema-instance">
        <BatchError d4p1:type="-- derived type specified here with the appropriate prefix --">
          <Code>ValueHere</Code>
          <Details d4p1:nil="false">ValueHere</Details>
          <ErrorCode d4p1:nil="false">ValueHere</ErrorCode>
          <FieldPath d4p1:nil="false">ValueHere</FieldPath>
          <ForwardCompatibilityMap xmlns:e291="http://schemas.datacontract.org/2004/07/System.Collections.Generic" d4p1:nil="false">
            <e291:KeyValuePairOfstringstring>
              <e291:key d4p1:nil="false">ValueHere</e291:key>
              <e291:value d4p1:nil="false">ValueHere</e291:value>
            </e291:KeyValuePairOfstringstring>
          </ForwardCompatibilityMap>
          <Index>ValueHere</Index>
          <Message d4p1:nil="false">ValueHere</Message>
          <Type d4p1:nil="false">ValueHere</Type>
          <!--These fields are applicable if the derived type attribute is set to EditorialError-->
          <Appealable d4p1:nil="false">ValueHere</Appealable>
          <DisapprovedText d4p1:nil="false">ValueHere</DisapprovedText>
          <Location d4p1:nil="false">ValueHere</Location>
          <PublisherCountry d4p1:nil="false">ValueHere</PublisherCountry>
          <ReasonCode>ValueHere</ReasonCode>
        </BatchError>
      </PartialErrors>
    </ApplyProductPartitionActionsResponse>
  </s:Body>
</s:Envelope>

代码语法

示例语法可用于 必应广告 SDK。 有关更多示例,请参阅 必应广告 API 代码示例

public async Task<ApplyProductPartitionActionsResponse> ApplyProductPartitionActionsAsync(
	IList<AdGroupCriterionAction> criterionActions)
{
	var request = new ApplyProductPartitionActionsRequest
	{
		CriterionActions = criterionActions
	};

	return (await CampaignManagementService.CallAsync((s, r) => s.ApplyProductPartitionActionsAsync(r), request));
}
static ApplyProductPartitionActionsResponse applyProductPartitionActions(
	ArrayOfAdGroupCriterionAction criterionActions) throws RemoteException, Exception
{
	ApplyProductPartitionActionsRequest request = new ApplyProductPartitionActionsRequest();

	request.setCriterionActions(criterionActions);

	return CampaignManagementService.getService().applyProductPartitionActions(request);
}
static function ApplyProductPartitionActions(
	$criterionActions)
{

	$GLOBALS['Proxy'] = $GLOBALS['CampaignManagementProxy'];

	$request = new ApplyProductPartitionActionsRequest();

	$request->CriterionActions = $criterionActions;

	return $GLOBALS['CampaignManagementProxy']->GetService()->ApplyProductPartitionActions($request);
}
response=campaignmanagement_service.ApplyProductPartitionActions(
	CriterionActions=CriterionActions)

要求

服务: CampaignManagementService.svc v13
命名空间: https://bingads.microsoft.com/CampaignManagement/v13

请求 URL

https://campaign.api.bingads.microsoft.com/CampaignManagement/v13/ProductPartitionActions/Apply

请求元素

ApplyProductPartitionActionsRequest 对象定义服务操作请求的正文标头元素。

注意

除非下面另有说明,否则需要所有请求元素。

请求正文元素

元素 说明 数据类型
CriterionActions 最多 5,000 个 AdGroupCriterionAction 对象的列表,每个对象都包含 一个 Action 元素和 一个 BiddableAdGroupCriterionNegativeAdGroupCriterion

所有广告组条件操作都必须针对同一广告组。 有关详细信息,包括验证规则,请参阅 使用市场活动管理服务创建Microsoft购物市场活动
AdGroupCriterionAction 数组

请求标头元素

元素 说明 数据类型
Authorization OAuth 访问令牌,表示有权Microsoft广告帐户的用户的凭据。 请确保令牌的前缀为“持有者”,这是正确身份验证所必需的。

有关详细信息,请参阅 使用 OAuth 进行身份验证
string
CustomerAccountId 拥有或与请求中的实体关联的广告帐户的标识符。 如果需要这两个元素,此标头元素必须与 AccountId 正文元素具有相同的值。 此元素是大多数服务操作所必需的,作为最佳做法,应始终设置它。

有关详细信息,请参阅 获取帐户和客户 ID
string
CustomerId 用户正在访问或操作的客户) 经理帐户 (标识符。 用户可以访问多个经理帐户。 此元素是大多数服务操作所必需的,作为最佳做法,应始终设置它。

有关详细信息,请参阅 获取帐户和客户 ID
string
DeveloperToken 用于访问必应广告 API 的开发人员令牌。

有关详细信息,请参阅 获取开发人员令牌
string
Password 此元素保留供内部使用,将从 API 的未来版本中删除。 必须使用 AuthenticationToken 元素来设置用户凭据。 string
UserName 此元素保留供内部使用,将从 API 的未来版本中删除。 必须使用 AuthenticationToken 元素来设置用户凭据。 string

响应元素

ApplyProductPartitionActionsResponse 对象定义服务操作响应的正文标头元素。 元素的返回顺序与 响应 JSON 中所示的顺序相同。

响应正文元素

元素 说明 数据类型
AdGroupCriterionIds 标识已应用操作的条件的标识符列表。 标识符列表直接对应于请求中的条件列表。

如果任何条件操作失败,则所有剩余的条件操作都将失败,并且此列表中的所有元素都将为 null。
long 数组
PartialErrors BatchError 对象的数组,其中包含未成功的任何请求项的详细信息。

错误列表与请求中的项列表不直接对应。 如果没有错误,列表可以为空,也可以包含与请求中每个不成功的列表项对应的一个或多个错误对象。

对于由于用户错误而失败的条件,将返回可操作的错误代码。

如果任何条件操作失败,则所有剩余的条件操作都将失败,并且此列表中的任何元素都不会为 null。 对于本来可能成功的条件,将返回一个通用错误,说明相关实体失败。
BatchError 数组

响应标头元素

元素 说明 数据类型
跟踪 ID 包含 API 调用详细信息的日志条目的标识符。 string

请求 JSON

此模板由显示 JSON 请求的 正文标头 元素的工具生成。 有关可用于此服务操作的支持类型,请参阅上面的 请求正文元素 参考。

下面是一个示例,如果 AdGroupCriterion 的类型为 BiddableAdGroupCriterion,CriterionAgeCriterion,CriterionBidBidMultiplier,CriterionCashbackCashbackAdjustment,则适用。

{
  "CriterionActions": [
    {
      "Action": "ValueHere",
      "AdGroupCriterion": {
        "AdGroupId": "LongValueHere",
        "Criterion": {
          "Type": "AgeCriterion",
          "AgeRange": "ValueHere"
        },
        "Id": "LongValueHere",
        "Status": "ValueHere",
        "Type": "BiddableAdGroupCriterion",
        "CriterionBid": {
          "Type": "BidMultiplier",
          "Multiplier": DoubleValueHere
        },
        "CriterionCashback": {
          "Type": "CashbackAdjustment",
          "CashbackPercent": DoubleValueHere
        },
        "DestinationUrl": "ValueHere",
        "EditorialStatus": "ValueHere",
        "FinalAppUrls": [
          {
            "OsType": "ValueHere",
            "Url": "ValueHere"
          }
        ],
        "FinalMobileUrls": [
          "ValueHere"
        ],
        "FinalUrls": [
          "ValueHere"
        ],
        "FinalUrlSuffix": "ValueHere",
        "TrackingUrlTemplate": "ValueHere",
        "UrlCustomParameters": {
          "Parameters": [
            {
              "Key": "ValueHere",
              "Value": "ValueHere"
            }
          ]
        }
      }
    }
  ]
}

响应 JSON

此模板由一个工具生成,用于显示 JSON 响应的 正文标头 元素。

以下示例适用于 BatchError 的类型为 EditorialError

{
  "AdGroupCriterionIds": [
    "LongValueHere"
  ],
  "PartialErrors": [
    {
      "Code": IntValueHere,
      "Details": "ValueHere",
      "ErrorCode": "ValueHere",
      "FieldPath": "ValueHere",
      "ForwardCompatibilityMap": [
        {
          "key": "ValueHere",
          "value": "ValueHere"
        }
      ],
      "Index": IntValueHere,
      "Message": "ValueHere",
      "Type": "EditorialError",
      "Appealable": "ValueHere",
      "DisapprovedText": "ValueHere",
      "Location": "ValueHere",
      "PublisherCountry": "ValueHere",
      "ReasonCode": IntValueHere
    }
  ]
}

代码语法

若要通过 SDK 调用 REST API,需要将 SDK 升级到特定版本并配置系统参数。示例语法可用于 必应广告 SDK。 有关更多示例,请参阅 必应广告 API 代码示例

public async Task<ApplyProductPartitionActionsResponse> ApplyProductPartitionActionsAsync(
	IList<AdGroupCriterionAction> criterionActions)
{
	var request = new ApplyProductPartitionActionsRequest
	{
		CriterionActions = criterionActions
	};

	return (await CampaignManagementService.CallAsync((s, r) => s.ApplyProductPartitionActionsAsync(r), request));
}
static ApplyProductPartitionActionsResponse applyProductPartitionActions(
	ArrayOfAdGroupCriterionAction criterionActions) throws RemoteException, Exception
{
	ApplyProductPartitionActionsRequest request = new ApplyProductPartitionActionsRequest();

	request.setCriterionActions(criterionActions);

	return CampaignManagementService.getService().applyProductPartitionActions(request);
}
static function ApplyProductPartitionActions(
	$criterionActions)
{

	$GLOBALS['Proxy'] = $GLOBALS['CampaignManagementProxy'];

	$request = new ApplyProductPartitionActionsRequest();

	$request->CriterionActions = $criterionActions;

	return $GLOBALS['CampaignManagementProxy']->GetService()->ApplyProductPartitionActions($request);
}
response=campaignmanagement_service.ApplyProductPartitionActions(
	CriterionActions=CriterionActions)