# generated by fastapi-codegen:
# filename: openapi.yaml
# timestamp: 2025-06-07T15:11:49+00:00
from __future__ import annotations
from typing import List, Optional
from pydantic import BaseModel, Field
class AdIds(BaseModel):
adIds: Optional[List[str]] = Field(
None,
description='A list of ad IDs. Only one ad can be deleted per operation and only one adId value will be returned.',
)
class AdReference(BaseModel):
adId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for an ad. This ID is generated when an ad is created.',
)
href: Optional[str] = Field(
None,
description='The getAd URI of an ad. You can use this URI to retrieve the ad.',
)
class AdReferences(BaseModel):
ads: Optional[List[AdReference]] = Field(
None,
description='A list of ad IDs. An ad ID is generated for each successfully created ad. Only one ad can be created per operation.',
)
class AdditionalInfoData(BaseModel):
metricKey: Optional[str] = Field(
None,
description="The metric used to provide additional information for the suggested keyword.<br /><br /><strong>Valid Values:</strong> <ul><li><code>ACTIVE_SELLER_COUNT</code></li><li><code>SEARCH_VOLUME</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:MetricEnum'>eBay API documentation</a>",
)
value: Optional[str] = Field(
None,
description='The data provided for the specified metric.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> All metric data is compiled for the marketplace associated with the specified campaign ID.</span>',
)
class AlertDimension(BaseModel):
key: Optional[str] = Field(
None,
description="The key field of the applied dimension. For example, the marketplace Id. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:DimensionKeyEnum'>eBay API documentation</a>",
)
value: Optional[str] = Field(
None,
description="The value field of the applied dimension. For example, if the key is a <code>MARKETPLACE_ID</code>, the value would be from <a href='/api-docs/sell/marketing/types/ba:MarketplaceIdEnum'>MarketplaceIdEnum</a>.",
)
class Amount(BaseModel):
currency: Optional[str] = Field(
None,
description='The base currency applied to the <b>value</b> field to establish a monetary amount. <br><br>The currency is represented as a 3-letter <a href="https://www.iso.org/iso-4217-currency-codes.html " title="https://www.iso.org " target="_blank">ISO 4217</a> currency code. For example, the code for the Canadian Dollar is <code>CAD</code>. <br><br><b>Default:</b> The default currency of the eBay marketplace that hosts the listing. For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/ba:CurrencyCodeEnum\'>eBay API documentation</a>',
)
value: Optional[str] = Field(
None,
description='The monetary amount in the specified <b>currency</b>. <br><br><i>Required in</i> the <b>amount</b> type.',
)
class Aspect(BaseModel):
key: Optional[str] = Field(
None,
description="The type of the aspect. For example, <code>MINIMUM_REQUIRED</code>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:AspectKeyEnum'>eBay API documentation</a>",
)
value: Optional[str] = Field(
None,
description="The value of the aspect. For example, if the aspect is a percentage, a value of '2.0' would equal 2%.",
)
class Budget(BaseModel):
amount: Optional[Amount] = Field(
None,
description='The allocated budget amount for a CPC Promoted Listings campaign.',
)
budgetStatus: Optional[str] = Field(
None,
description="The budget status for a CPC Promoted Listings campaign. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:BudgetStatusEnum'>eBay API documentation</a>",
)
class BudgetRequest(BaseModel):
amount: Optional[Amount] = Field(
None,
description='The allocated budget amount for a CPC Promoted Listings campaign.',
)
class CampaignBudget(BaseModel):
daily: Optional[Budget] = Field(
None,
description="The daily budget limit for the Cost Per Click (CPC) Promoted Listings campaign.<br /><br /><i>Required if</i> the campaign's funding model is CPC.<br /><br />This will be a dollar value. All clicks using the keywords defined for the campaign will go towards expending the daily budget. Once the daily budget is exceeded for the campaign, all Promoted Listings under the campaign will be turned off until the next day.<br /><br /><b>Valid Values</b>:<ul><li><code>50.00</code></li><li><code>100.00</code></li></ul>",
)
class CampaignBudgetRequest(BaseModel):
daily: Optional[BudgetRequest] = Field(
None, description='The daily budget limit for a CPC Promoted Listings campaign.'
)
class CouponConfiguration(BaseModel):
couponCode: Optional[str] = Field(
None,
description='A unique code that buyers can use during checkout to receive a discount. The code must be unique across eBay. <br><br>The code must be from 8-15 alphanumeric characters and can contain no more than two dashes ( - ).<br><br>This is required when the promotion type is CODED_COUPON.',
)
couponType: Optional[str] = Field(
None,
description="This indicates the type of Coded Coupon promotion, and is required when the promotion type is <b>CODED_COUPON</b>.<br><br>Supported types:<ul><li><b>PRIVATE_SINGLE_SELLER_COUPON:</b> Anyone can use and share the coupon code, but it isn't posted on eBay.</li><li><b>PUBLIC_SINGLE_SELLER_COUPON:</b> Anyone can find the coupon code on eBay and use it.</li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:CouponTypeEnum'>eBay API documentation</a>",
)
maxCouponRedemptionPerUser: Optional[int] = Field(
None,
description='This sets the limit on the number of times a buyer can use this coupon. The range of values is 1-10. If no value is provided, a buyer can use the coupon an unlimited number of times.',
)
class CreateAdGroupRequest(BaseModel):
defaultBid: Optional[Amount] = Field(
None,
description='A bid amount that applies to all of the keywords in an ad group that do not have individual bids.',
)
name: Optional[str] = Field(
None, description='The seller-defined name of the ad group.'
)
class CreateAdRequest(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for an ad group in a campaign that uses the Cost Per Click (CPC) funding model. <p><i>Required if</i> the campaign\'s funding model is Cost Per Click (CPC).</p><p>Create an ad group using the <a href="/api-docs/sell/marketing/resources/adgroup/methods/createAdGroup">createAdGroup</a> method.</p><p>Specify the campaign to associate the ad group with using the <b>campaign_id</b> path parameter. </p><span class="tablenote"><b>Note:</b> You can call the <a href="/api-docs/sell/marketing/resources/adgroup/methods/getAdGroups">getAdGroups</a> method to retrieve the ad group IDs for a seller.</span>',
)
bidPercentage: Optional[str] = Field(
None,
description="The user-defined <b>bid percentage</b> (also known as the <i>ad rate</i>) sets the level that eBay increases the visibility in search results for the associated listing. The higher the <b>bidPercentage</b> value, the more eBay promotes the listing.<br><br><i>Required if</i> the campaign's funding model is Cost Per Sale (CPS). <br><br>The value specified here is also used to calculate the Promoted Listings fee. This percentage value is multiplied by the final sales price to determine the fee. <br><br>The Promoted Listings fee is determined at the time the transaction completes and the seller is assessed the fee only when an item sells through a Promoted Listings ad campaign. <br><br>The <b>bidPercentage</b> is a single precision value that is guided by the following rules: <ul><li>These values are <b>valid</b>:<br> <code>4.1</code>, <code>5.0</code>, <code>5.5</code>, ...</li> <li>These values are <b>not valid</b>:<br /> <code>0.01</code>, <code>10.75</code>, <code>99.99</code>,<br /> and so on.</li></ul>This is default bid percentage for the campaigns using the Cost Per Sale (CPS) funding model, and this value will be overridden by any ads in the campaign that have their own set bid percentages.<br /><br />If a bid percentage is not provided for an ad, eBay uses the default bid percentage of the associated campaign.<br /><br /><b>Minimum value:</b> 2.0 <br><b>Maximum value:</b> 100.0",
)
listingId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a listing that is generated when the listing is created. <p class="tablenote"><b>Note:</b> This field accepts listing IDs, as generated by the Inventory API, and item IDs, as used in the eBay Traditional API set (e.g., the Trading and Finding APIs).</p>',
)
class CreateAdsByInventoryReferenceRequest(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='<span class="tablenote"><b>Note:</b> This field is not currently in use. Ad groups are only applicable to Promoted Listings Advanced (PLA) ad campaigns that use the Cost Per Click (CPC) funding model. See <a href="/api-docs/sell/static/marketing/pl-overview.html#funding-model">Funding Models</a> in the <i>Promoted Listings Playbook</i> for more information.</span>',
)
bidPercentage: Optional[str] = Field(
None,
description="The user-defined <b>bid percentage</b> (also known as the <i>ad rate</i>) sets the level that eBay increases the visibility in search results for the associated listing. The higher the <b>bidPercentage</b> value, the more eBay promotes the listing.<br /><br /><i>Required if</i> the campaign's funding model is Cost Per Sale (CPS).<br /><br />The value specified here is also used to calculate the Promoted Listings fee. This percentage value is multiplied by the final sales price to determine the fee.<br /><br />The Promoted Listings fee is determined at the time the transaction completes and the seller is assessed the fee only when an item sells through a Promoted Listings ad campaign.<br /><br />The <b>bidPercentage</b> is a single precision value that is guided by the following rules: <ul><li>These values are <b>valid</b>:<br> <code>4.1</code>, <code>5.0</code>, <code>5.5</code>, ...</li> <li>These values are <b>not valid</b>:<br /> <code>0.01</code>, <code>10.75</code>, <code>99.99</code>,<br /> and so on.</li></ul>This is default bid percentage for the campaigns using the Cost Per Sale (CPS) funding model, and this value will be overridden by any ads in the campaign that have their own set bid percentages.<br /><br />If a bid percentage is not provided for an ad, eBay uses the default bid percentage of the associated campaign.<br /><br /><b>Minimum value:</b> 2.0 <br><b>Maximum value:</b> 100.0",
)
inventoryReferenceId: Optional[str] = Field(
None,
description='An ID that identifies a single-item listing or multiple-variation listing that is managed with the <a href="/api-docs/sell/inventory/resources/methods" title="Inventory API Reference">Inventory API</a>. <p>The <i>inventory reference ID</i> is a seller-defined value that can be either an <b>SKU</b> for a single-item listing or an <b>inventoryItemGroupKey</b> for a multiple-value listing.</p> <p>An <i>inventoryItemGroupKey</i> is a value that the seller defines to indicate a listing that\'s the parent of an inventory item group (a multiple-variation listing, such as a listing for a shirt that\'s available in multiple sizes and colors).</p> <p>You must always specify both an <b>inventoryReferenceId</b> and an <b>inventoryReferenceType</b> to indicate an item that\'s managed with the Inventory API.</p>',
)
inventoryReferenceType: Optional[str] = Field(
None,
description="Indicates the type of item the <b>inventoryReferenceId</b> references. The item can be either an <code>INVENTORY_ITEM</code> or <code>INVENTORY_ITEM_GROUP</code>. <p>You must always pair an <b>inventoryReferenceId</b> with and <b>inventoryReferenceType</b>.</p> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:InventoryReferenceTypeEnum'>eBay API documentation</a>",
)
class CreateKeywordRequest(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='This adGroupId is created when an ad group is first created and associated with a campaign. This is the ad group that the corresponding keyword will be added to. This ad group must be a part of the campaign that is specified in the call URI.<br /><br /><span class="tablenote"><b>Note:</b> You can call the <a href="/api-docs/sell/marketing/resources/adgroup/methods/getAdGroups">getAdGroups</a> method to retrieve the ad group IDs for a seller, and <a href="/api-docs/sell/marketing/resources/keywords/methods/getKeywords">getKeywords</a> to retrieve the keyword IDs for a seller\'s keywords.</span>',
)
bid: Optional[Amount] = Field(
None,
description='This container is used to set the bid for the keyword. Each time a listing is retrieved in search results using this keyword and clicked on, the seller will be charged this amount. Each click goes toward the daily budget set up for the CPC campaign. If the bid is not provided, then the default bid associated with the ad group is used.<br /><br /><span class="tablenote"><b>Note:</b> You can call the <a href="/api-docs/sell/marketing/resources/adgroup/methods/suggestBids">suggestBids</a> method to retrieve the suggested bids for keywords.</span>',
)
keywordText: Optional[str] = Field(
None, description='Input the keyword into this field.'
)
matchType: Optional[str] = Field(
None,
description="A field that defines the match type for the keyword.<br /><br /><b>Valid Values:</b><ul><li><code>BROAD</code></li><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:MatchTypeEnum'>eBay API documentation</a>",
)
class CreateNegativeKeywordRequest(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='This adGroupId is created when an ad group is first created and associated with a campaign. This is the ad group to which the corresponding negative keyword will be added.<br /><br /><span class="tablenote"><b>Note:</b> You can call the <a href="/api-docs/sell/marketing/resources/adgroup/methods/getAdGroups">getAdGroups</a> method to retrieve the ad group IDs for a seller.</span><br /><br /><i>Required if</i> the negative keyword is being created at the ad group level.',
)
campaignId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a campaign. This ID is generated when a campaign is created.<br /><br /><i>Required if</i> the negative keyword is being created at the ad group level.',
)
negativeKeywordMatchType: Optional[str] = Field(
None,
description='A field that defines the match type for the negative keyword.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> Broad matching of negative keywords is not currently supported.</span><br /><b>Valid Values:</b><ul><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/pls:NegativeKeywordMatchTypeEnum\'>eBay API documentation</a>',
)
negativeKeywordText: Optional[str] = Field(
None, description='The negative keyword text.'
)
class DeleteAdRequest(BaseModel):
listingId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a listing that is generated when the listing is created. <p class="tablenote"><b>Note:</b> This request accepts both listing IDs, as generated by the Inventory API, and an item IDs, as used in the eBay Traditional API set (e.g., the Trading and Finding APIs).</p>',
)
class DeleteAdsByInventoryReferenceRequest(BaseModel):
inventoryReferenceId: Optional[str] = Field(
None,
description='The inventory reference ID is a seller-defined SKU value for a single-item listing, or a seller-defined identifier for an inventory item group. Both of these values are defined when using the Inventory API, and an inventory item group is used to create a multiple-variation listing.',
)
inventoryReferenceType: Optional[str] = Field(
None,
description="The enumeration value passed into this field indicates the type of value used for the corresponding <b>inventoryReferenceId</b> value. The enumeration value used here will either be <code>INVENTORY_ITEM</code> (to delete the ad for a single SKU listing) or <code>INVENTORY_ITEM_GROUP</code> (to delete the ad for a multiple-variation listing). For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:InventoryReferenceTypeEnum'>eBay API documentation</a>",
)
class Dimension(BaseModel):
annotationKeys: Optional[List[str]] = Field(
None,
description='A list of annotations associated with the dimension of the report.',
)
dimensionKey: Optional[str] = Field(
None,
description='The name of the dimension on which the report is based. <p>A dimension is an attribute to which the report data applies.</p>',
)
class DimensionKeyAnnotation(BaseModel):
annotationKey: Optional[str] = Field(
None, description='An annotation key associated with the dimension.'
)
dataType: Optional[str] = Field(
None,
description="The data type of the annotation key value. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/plr:DataTypeEnum'>eBay API documentation</a>",
)
class DimensionMetadata(BaseModel):
dataType: Optional[str] = Field(
None,
description="The data type of the dimension value used to create the report. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/plr:DataTypeEnum'>eBay API documentation</a>",
)
dimensionKey: Optional[str] = Field(
None, description='The name of the dimension used to create the report.'
)
dimensionKeyAnnotations: Optional[List[DimensionKeyAnnotation]] = Field(
None,
description='An list of annotation keys associated with the specified dimension of the report.',
)
class DiscountBenefit(BaseModel):
amountOffItem: Optional[Amount] = Field(
None,
description='The monetary amount that is discounted off an item (or items) when the promotion criteria is met. <br><br>For <b>threshold promotions</b>, where the buyer triggers the discount, the valid values for this field are: <br><code> 5, 6, 7, 8, 9, 10, 15, 20, 25, <br> 30, 35, 40, 45, 50, 55, 60, 65, <br> 70, 75, 80, 85, 90, 95, 100, 110, <br> 120, 125, 150, 200, 250</code> <br><br>For <b>markdown</b> promotions, the range is greater, as outlined below and detailed more precisely <a href="/api-docs/sell/static/marketing/pm-amountoffitems-values.html" target="_blank">here</a>: <ul><li>$1 increments from $5 to $100</li><li>$5 increments from $105 to $1,000</li><li>$100 increments from $1,100 to $15,000</li></ul>',
)
amountOffOrder: Optional[Amount] = Field(
None,
description="Used for threshold promotions, this is the monetary amount that is discounted off an order when the promotion criteria is met. Because this field is valid only for orders, it's not a valid combination to use with markdown promotions. <br><br><b>Valid values</b> for the associated <code>amountOffOrder.</code><b>value</b> field: <br><code> 5, 6, 7, 8, 9, 10, 15, 20, 25, <br> 30, 35, 40, 45, 50, 55, 60, 65, <br> 70, 75, 80, 85, 90, 95, 100, 110, <br> 120, 125, 150, 200, 250</code>",
)
percentageOffItem: Optional[str] = Field(
None,
description='The percentage applied to the sales price that is discounted off the promoted item (or items) when the promotion criteria is met. <br><br>Valid integer values for percentage off: <b>Min:</b> <code>5</code> <b>Max:</b> <code>80</code>',
)
percentageOffOrder: Optional[str] = Field(
None,
description='Used for threshold promotions, this is the percentage of the order price that is discounted off the order when the promotion criteria is met. This field is not value for markdown promotions. <br><br>Valid integer values for ORDER_DISCOUNT promotions: <b>Min:</b> <code>5</code> <b>Max:</b> <code>80</code> <br><br>For VOLUME_DISCOUNT promotions: Must be set to <code>0</code> for the first discount rule.',
)
class DiscountSpecification(BaseModel):
forEachAmount: Optional[Amount] = Field(
None,
description='The monetary amount that must be spent on promoted items before the promotional discount is applied. <br><br><b>Valid values</b> for the associated <code>forEachAmount.</code><b>value</b> field: <br><code> 5, 10, 15, 20, 25, 30, 35, 40, 45, 49, <br> 50, 55, 59, 60, 65, 69, 70, 75, 79, 80, <br> 85, 89, 90, 95, 99, 100, 110, 120, 125, <br> 149, 150, 175, 199, 200, 249, 250, 299, <br> 300, 350, 399, 400, 450, 499, 500</code>',
)
forEachQuantity: Optional[int] = Field(
None,
description='The number of items that must be purchased in order to qualify for the discount. <br><br><b>Valid values:</b> <br><code> 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, <br> 12, 13, 14, 15, 16, 17, 18, 19 <br> 20, 25, 50, 75, 100</code>',
)
minAmount: Optional[Amount] = Field(
None,
description='Known as the "threshold amount", the minimum dollar amount that needs to be spent on promoted items in order to qualify for the promotion\'s discount. <br><br><b>Valid values</b> for the associated <code>minAmount.</code><b>value</b> field: <br><code> 5, 10, 15, 20, 25, 30, 35, 40, 45, 49, <br> 50, 55, 59, 60, 65, 69, 70, 75, 79, 80, <br> 85, 89, 90, 95, 99, 100, 110, 120, <br> 125, 149, 150, 175, 199, 200, 249, 250, 299, <br> 300, 350, 399, 400, 450, 499, 500</code>',
)
minQuantity: Optional[int] = Field(
None,
description="The minimum quantity of promoted items that needs to be bought in order to qualify for the promotion's discount. <br><br><b>Valid values:</b> <br><code> 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, <br> 12, 13, 14, 15, 16, 17, 18, 19 <br> 20, 25, 50, 75, 100</code>",
)
numberOfDiscountedItems: Optional[int] = Field(
None,
description='Use this field to configure "Buy One Get One" (or <b>BOGO</b>) promotions. <br><br>You must couple this field with <b>forEachQuantity</b> and an <b>amountOffItem</b> or <b>percentOffItem</b> field to configure your BOGO promotion. This field is not valid with order-based promotions. <br><br>The value of this field represents the number of items to be discounted when other promotion criteria is met. For example, when the buyer adds the number of items identified by the <b>forEachQuantity</b> value to their cart, they are then eligible to receive the stated discount from an additional number of like items (the number of which is identified by this field) when they add those items to their cart. To receive the discount, the buyer must purchase the number of items indicated by <b>forEachQuantity</b> <i>plus</i> the number indicated by this field. <br><br><b>Valid values:</b> <br><code> 1, 2, 3, 4, 5, 6, 7, 8, 9, 10</code>',
)
class DynamicAdRatePreference(BaseModel):
adRateAdjustmentPercent: Optional[str] = Field(
None,
description='The percentage above or below (-) the eBay suggested ad rate that a seller is willing to pay.<br /><br />This specifies the maximum and minimum values to which an ad rate can be dynamically adjusted.',
)
adRateCapPercent: Optional[str] = Field(
None,
description='The maximum value (specified as a percentage) to which the eBay suggested ad rate can be adjusted. The adjusted ad rate will never exceed this percentage.',
)
class ErrorParameter(BaseModel):
name: Optional[str] = Field(
None, description='Name of the entity that threw the error.'
)
value: Optional[str] = Field(None, description='A description of the error.')
class FundingStrategy(BaseModel):
adRateStrategy: Optional[str] = Field(
None,
description="The ad rate strategy that shall be applied to the campaign. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:AdRateStrategyEnum'>eBay API documentation</a>",
)
bidPercentage: Optional[str] = Field(
None,
description='The user-defined <b>bid percentage</b> (also known as the <i>ad rate</i>) sets the level that eBay increases the visibility in search results for the associated listing. The higher the <b>bidPercentage</b> value, the more eBay promotes the listing. <br><br>The value specified here is also used to calculate the Promoted Listings fee. This percentage value is multiplied by the final sales price to determine the fee. <br><br>The Promoted Listings fee is determined at the time the transaction completes and the seller is assessed the fee only when an item sells through a Promoted Listings ad campaign. <br><br>The <b>bidPercentage</b> is a single precision value that is guided by the following rules: <ul><li>These values are <b>valid</b>:<br> <code>4.1</code>, <code>5.0</code>, <code>5.5</code>, ...</li> <li>These values are <b>not valid</b>:<br /> <code>0.01</code>, <code>10.75</code>, <code>99.99</code>,<br /> and so on.</li></ul>This is the default bid percentage for the campaigns using the Cost Per Sale (CPS) funding model, and this value will be overridden by any ads in the campaign that have their own set bid percentages.<br /><br />If a bid percentage is not provided for an ad, eBay uses the default bid percentage of the associated campaign.<br /><br /><span class="tablenote"><b>Note:</b>This field is only relevant for campaigns that use the CPS funding model. It is not used for campaigns that use the Cost Per Click (CPC) funding model.</span><br /><b>Minimum value:</b> 2.0 <br><b>Maximum value:</b> 100.0',
)
dynamicAdRatePreferences: Optional[List[DynamicAdRatePreference]] = Field(
None,
description='A field that indicates whether a single, user-defined bid percentage (also known as the <i>ad rate</i>) should be used, or whether eBay should automatically adjust listings to maintain the daily suggested bid percentage.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> Dynamic adjustment is only applicable when the <b>adRateStrategy</b> is set to <code>DYNAMIC</code>.</span><br /><b>Default:</b> <code>FIXED</code>',
)
fundingModel: Optional[str] = Field(
None,
description="Indicates the model that eBay uses to calculate the Promoted Listings fee. <p>For a description of the funding model types, refer to <b>FundingModelTypeEnum</b>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:FundingModelEnum'>eBay API documentation</a>",
)
class InventoryItem(BaseModel):
inventoryReferenceId: Optional[str] = Field(
None,
description='The seller\'s inventory reference ID for a listing. Also known as the "SKU" or "custom label," an inventory reference ID is either the ID of the listing or, if the listing has variations (such as a shirt that\'s available in multiple sizes and colors), the ID of the parent listing.',
)
class InventoryReference(BaseModel):
inventoryReferenceId: Optional[str] = Field(
None,
description="The seller's inventory reference ID for an item that is managed with the Inventory API. <br><br>An inventory reference is either the ID of a single listing or the ID of the parent of an item group listing (a multi-variation listing, such as a shirt that is available in multiple sizes and colors). <br><br><i>Required if </i> if you supply an <b>inventoryReferenceType</b>.",
)
inventoryReferenceType: Optional[str] = Field(
None,
description="Indicates the type of item indicated by the <b>inventoryReferenceId</b>. <br><br>This value can be set to either <code>INVENTORY_ITEM</code> or <code>INVENTORY_ITEM_GROUP</code> (if the ID points to a multi-variation listing). <br><br><i>Required if </i> if you supply an <b>inventoryReferenceId</b>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:InventoryReferenceTypeEnum'>eBay API documentation</a>",
)
class ItemBasis(BaseModel):
estimatedValue: Optional[int] = Field(
None,
description='The estimated value of the search impressions for items based on the provided dimensions. <br /><br /><b>Duration:</b> 17 days<br /><br /><b>Total slots:</b> 200 <br /><br /><b>Channel:</b> Dweb, Mweb, Native',
)
metric: Optional[str] = Field(
None,
description="The basis of the statistics. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:TargetingMetricsEnum'>eBay API documentation</a>",
)
class ItemMarkdownStatus(BaseModel):
listingMarkdownStatus: Optional[str] = Field(
None,
description="Indicates the state assigned to the markdown promotion using one of the <b>status</b> values. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:ItemMarkdownStatusEnum'>eBay API documentation</a>",
)
statusChangedDate: Optional[str] = Field(
None,
description='Identifies the date the last time the state of the promotion changed. Both both markdown and markup events can trigger a status change.',
)
statusMessage: Optional[str] = Field(
None,
description='An eBay-assigned text string that describes the status of the promotion.',
)
class Keyword(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='This field identifies the ad group that the keyword is associated with.',
)
bid: Optional[Amount] = Field(
None,
description='The bid associated with the keyword. This container will not be returned if the keyword does not have a defined bid value.',
)
keywordId: Optional[str] = Field(
None, description='The unique identifier of a keyword.'
)
keywordStatus: Optional[str] = Field(
None,
description="The status of the keyword.<br /><br /><b>Valid Values:</b><ul><li><code>ACTIVE</code></li><li><code>PAUSED</code></li><li><code>ARCHIVED</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:KeywordStatusEnum'>eBay API documentation</a>",
)
keywordText: Optional[str] = Field(None, description='The text of the keyword.')
matchType: Optional[str] = Field(
None,
description="A field that defines the match type for the keyword.<br /><br /><b>Valid Values:</b><ul><li><code>BROAD</code></li><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:MatchTypeEnum'>eBay API documentation</a>",
)
class KeywordPagedCollectionResponse(BaseModel):
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
keywords: Optional[List[Keyword]] = Field(
None,
description='This array contains all of the keywords that match the request criteria. Keywords will be sorted by adGroupId, regardless of whether you searched for keywords across the entire campaign, or if you searched for keywords within one or specific ad groups.',
)
limit: Optional[int] = Field(
None,
description='The number of keywords returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.',
)
next: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the next page in the result set. This value is returned only if there is an additional page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first returned result. This value can be set in the request with the <b>offset</b> query parameter. <p class="tablenote"><strong>Note: </strong>The items in a paginated result set use a zero-based list where the first item in the list has an offset of <code>0</code>.</p>',
)
prev: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the previous page in the result set. Basically, all of the request parameters will remain the same except the offset value, which will be decreased to retrieve the previous page of results. <br><br><b>Max length</b>: 2048',
)
total: Optional[int] = Field(
None,
description='The total number of keywords retrieved in the result set. <br><br>If no keywords are found, this field is returned with a value of <code>0</code>.',
)
class KeywordRequest(BaseModel):
keywordText: Optional[str] = Field(
None,
description='The text of the keyword. Keywords are not case sensitive and compound words can be used without additional encoding (for example, tennis ball).<br /><br /><b>Maximum number of characters: </b>100 <br /><br /><b>Maximum number of words: </b>10 ',
)
matchType: Optional[str] = Field(
None,
description="A field that defines the match type for the keyword.<br /><br /><b>Valid Values:</b><ul><li><code>BROAD</code></li><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:MatchTypeEnum'>eBay API documentation</a>",
)
class ListingDetail(BaseModel):
currentPrice: Optional[Amount] = Field(
None, description='The container that returns the current price of the listing.'
)
freeShipping: Optional[bool] = Field(
None,
description='If set to <code>true</code>, the seller pays for the shipping (or that the item is marked for local pickup only) In this case, the listing does not have an associated shipping cost for the first listed domestic-shipping option (even if the first domestic-shipping option specifies a flat-rate or calculated shipping option). If <code>false</code>, the buyer is required to pay for a flat-rate or calculated cost shipping service.',
)
inventoryReferenceId: Optional[str] = Field(
None,
description='The seller\'s inventory reference ID for a listing. Also known as the "SKU" or "custom label," an inventory reference ID is either the ID of the listing or, if the listing has variations (such as a shirt that\'s available in multiple sizes and colors), the ID of the parent listing.',
)
inventoryReferenceType: Optional[str] = Field(
None,
description='Indicates the type of the <b>inventoryReferenceId</b>, which can be either a single-SKU or a multi-SKU listing (<code>INVENTORY_ITEM</code> and <code>INVENTORY_ITEM_GROUP</code>, respectively). <br><br><b>Note:</b> This value is not currently returned in the response.',
)
listingCategoryId: Optional[str] = Field(
None,
description='The ID of the category that listing belongs to. The ID is a numeric and unique identifier for the category that is assigned by eBay.',
)
listingCondition: Optional[str] = Field(
None,
description='An eBay-assigned value that indicates condition of the associated item. For more information, see <a href="/api-docs/sell/static/metadata/condition-id-values.html">Item condition ID and name values</a>.',
)
listingConditionId: Optional[str] = Field(
None,
description='The ID of the condition associated with the item. For more information, see <a href="/api-docs/sell/static/metadata/condition-id-values.html">Item condition ID and name values</a>.<br /><br /><span class="tablenote"><b>Note: </b> This value is not currently returned in the response.</span>',
)
listingId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID that is generated when the item is listed.',
)
listingPromotionStatuses: Optional[List[ItemMarkdownStatus]] = Field(
None,
description='A list of the status values assigned to the item and the date that each new status was assigned.',
)
quantity: Optional[int] = Field(
None, description='The number of items being sold in the listing.'
)
storeCategoryId: Optional[str] = Field(
None,
description='Store CategoryId (if any) that to which the listing belongs. This field is blank if there is no seller Store category ID.',
)
title: Optional[str] = Field(
None,
description='The seller-defined title of the listing that a seller can use to identify the item. This label is not displayed in end-user flows.',
)
class MetricMetadata(BaseModel):
dataType: Optional[str] = Field(
None,
description="The data type of the returned metric value. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/plr:DataTypeEnum'>eBay API documentation</a>",
)
metricKey: Optional[str] = Field(None, description='The name of the metric.')
class NegativeKeyword(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='An ad group ID that is generated when an ad group is first created and associated with a campaign.<br /><br /><span class="tablenote"><b>Note:</b> You can call the <a href="/api-docs/sell/marketing/resources/adgroup/methods/getAdGroups">getAdGroups</a> method to retrieve the ad group IDs for a seller.</span>',
)
campaignId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a campaign. This ID is generated when a campaign is created.',
)
negativeKeywordId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a negative keyword. This keyword ID will be generated for each successfully created negative keyword.',
)
negativeKeywordMatchType: Optional[str] = Field(
None,
description='A field that defines the match type for the negative keyword.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> Broad matching of negative keywords is not currently supported.</span><br /><b>Valid Values:</b><ul><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/pls:NegativeKeywordMatchTypeEnum\'>eBay API documentation</a>',
)
negativeKeywordStatus: Optional[str] = Field(
None,
description="A field that defines the status of the negative keyword. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:NegativeKeywordStatusEnum'>eBay API documentation</a>",
)
negativeKeywordText: Optional[str] = Field(
None, description='The text for the negative keyword.'
)
class NegativeKeywordPagedCollectionResponse(BaseModel):
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
limit: Optional[int] = Field(
None,
description='The number of items returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.',
)
negativeKeywords: Optional[List[NegativeKeyword]] = Field(
None,
description='A list of negative keywords returned in the paginated collection.',
)
next: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the next page in the result set. This value is returned only if there is an additional page of results to display from the result set.',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first returned result. This value can be set in the request with the <b>offset</b> query parameter.<br /><br /><b>Default:</b> <code>0</code><br /><br /><span class="tablenote"><b>Note: </b>The items in a paginated result set use a zero-based list, where the first item in the list has an offset of <code>0</code>.</span>',
)
prev: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the previous page in the result set. Basically, all of the request parameters will remain the same except the offset value, which will be decreased to retrieve the previous page of results.',
)
total: Optional[int] = Field(
None, description='The total number of result sets in the paginated collection.'
)
class PromotionDetail(BaseModel):
couponCode: Optional[str] = Field(
None,
description='A unique code that buyers can use during checkout to receive a discount. The code must be unique across eBay.',
)
description: Optional[str] = Field(
None,
description='This is the seller-defined "tag line" for the offer, such as "Save on designer shoes." Tag lines appear under the "offer-type text" that is generated for a promotion and displayed under the offer tile that is shown on the seller\'s <b>All Offers</b> page and on the promotion\'s event page. <p class="tablenote"><b>Note:</b> Offer-type text is a teaser that\'s presented throughout the buyer\'s journey through the sales flow and is generated by eBay. This text is not editable by the seller—it\'s derived from the settings in the <b>discountRules</b> and <b>discountSpecification</b> fields—and can be, for example, "Extra 20% off when you buy 3+".</p> <br><b>Maximum length:</b> 50 <br><br><i>Required if</i> you are configuring ORDER_DISCOUNT or MARKDOWN_SALE promotions (and not valid for VOLUME_DISCOUNT promotions).',
)
endDate: Optional[str] = Field(
None,
description='The date and time the promotion ends in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller.',
)
marketplaceId: Optional[str] = Field(
None,
description='The eBay marketplace ID of the site where the promotion is hosted. Threshold promotions are supported on a select set of marketplaces while markdown promotions are supported on all eBay marketplaces. <p><b>Valid values for threshold promotions are as follows:</b></p> <ul class="compact"><li><code>EBAY_AU</code> = Australia</li> <li><code>EBAY_DE</code> = Germany</li> <li><code>EBAY_ES</code> = Spain</li> <li><code>EBAY_FR</code> = France</li> <li><code>EBAY_GB</code> = Great Britain</li> <li><code>EBAY_IT</code> = Italy</li> <li><code>EBAY_US</code> = United States</li></ul> For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/ba:MarketplaceIdEnum\'>eBay API documentation</a>',
)
name: Optional[str] = Field(
None,
description='The seller-defined name or "title" of the promotion, such as "Buy 1 Get 1", that the seller can use to identify a promotion. This label is not displayed in end-user flows. <br><br><b>Maximum length:</b> 90',
)
priority: Optional[str] = Field(
None,
description="Applicable for only <b>ORDER_DISCOUNT</b> promotions, this field indicates the precedence of the promotion, which is used to determine the position of a promotion on the seller's <b>All Offers</b> page. If an item is associated with multiple promotions, the promotion with the higher priority takes precedence. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionPriorityEnum'>eBay API documentation</a>",
)
promotionHref: Optional[str] = Field(
None, description='The URI of the promotion details.'
)
promotionId: Optional[str] = Field(
None,
description="A unique eBay-assigned ID for the promotion that's generated when the promotion is created.",
)
promotionImageUrl: Optional[str] = Field(
None,
description="Required for CODED_COUPON, MARKDOWN_SALE, and ORDER_DISCOUNT promotions, and not applicable for <b>VOLUME_DISCOUNT</b> promotions, this field is a URL that points to an image for the promotion. This image is displayed on the seller's <b>All Offers</b> page. The URL must point to either JPEG or PNG image and it must be a minimum of 500x500 pixels in dimension and cannot exceed 12Mb in size.",
)
promotionStatus: Optional[str] = Field(
None,
description="The current status of the promotion. When creating a new promotion, you must set this value to either <code>DRAFT</code> or <code>SCHEDULED</code>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionStatusEnum'>eBay API documentation</a>",
)
promotionType: Optional[str] = Field(
None,
description="Indicates type of the promotion, either <code>CODED_COUPON</code>, <code>MARKDOWN_SALE</code>, <code>ORDER_DISCOUNT</code>, or <code>VOLUME_DISCOUNT</code>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionTypeEnum'>eBay API documentation</a>",
)
startDate: Optional[str] = Field(
None,
description='The date and time the promotion starts in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller.',
)
class PromotionReportDetail(BaseModel):
averageItemDiscount: Optional[Amount] = Field(
None,
description='The <i>average item discount</i> is the average discount that has been applied to each item in a promotion. This value is calculated as follows: <br><br><b>totalDiscount</b> / <b>itemsSoldQuantity</b> = <b>averageItemDiscount</b>',
)
averageItemRevenue: Optional[Amount] = Field(
None,
description='The <i>average item revenue</i> is the average revenue that has been received for each item in a promotion. This value is calculated as follows: <br><br><b>totalSales</b> / <b>itemsSoldQuantity</b> = <b>averageItemRevenue</b>',
)
averageOrderDiscount: Optional[Amount] = Field(
None,
description='The <i>average order discount</i> is the average discount that has been applied to each order in a promotion. This value is calculated as follows: <br><br><b>totalDiscount</b> / <b>numberOfOrdersSold</b> = <b>averageOrderDiscount</b>',
)
averageOrderRevenue: Optional[Amount] = Field(
None,
description='The <i>average order revenue</i> is the average revenue that has been received for each order in a promotion. This value is calculated as follows: <br><br><b>totalSales</b> / <b>numberOfOrdersSold</b> = <b>averageOrderRevenue</b>',
)
averageOrderSize: Optional[str] = Field(
None,
description='The <i>average order size</i> is the average number of items that each order contained in a promotion. This value is calculated as follows: <br><br><b>itemsSoldQuantity</b> / <b>numberOfOrdersSold</b> = <b>averageOrderSize</b> ',
)
baseSale: Optional[Amount] = Field(
None,
description='This is the monetary amount of items purchased in a promotion where the threshold <i>wasn\'t met</i>, so the discount was not applied. <br><br>For example, suppose you\'re running a "Buy 1, get 1 at 50%" promotion on $5 socks. One buyer purchased only one pair of socks, so they pay the full price of $5. Here, your <b>baseSale</b> amount would be $5.',
)
itemsSoldQuantity: Optional[int] = Field(
None,
description='This is the quantity of items purchased in a threshold promotion where the threshold <i>has been met</i> and the discount was applied. <br><br>For example, suppose you\'re running a "Buy 1, get 1 at 50%" promotion on $5 socks. One buyer purchases two pairs of socks, so they pay $7.50 for both pairs (rather than the full price of $10). Your number of items sold (<b>itemsSoldQuantity</b>) would be 2 and you number of orders sold (<b>numberOfOrdersSold</b>) would be 1.',
)
numberOfOrdersSold: Optional[int] = Field(
None,
description='This is the number of orders sold in a threshold promotion where the threshold <i>has been met</i> and the discount was applied. <br><br>For example, suppose you\'re running a "Buy 1, get 1 at 50%" promotion on $5 socks. One buyer purchases two pairs of socks, so they pay $7.50 for both pairs (rather than the full price of $10). Your <b>numberOfOrdersSold</b> would be 1 and your <b>itemsSoldQuantity</b> would be 2.',
)
percentageSalesLift: Optional[str] = Field(
None,
description='The <i>percentage sales lift</i> is the total dollar amount gained due to promotions. This value is calculated as follows: <br><br> <b>promotionSale</b> / <b>totalSale</b> = <b>percentageSalesLift</b> ',
)
promotionHref: Optional[str] = Field(
None, description='The URI of the promotion report.'
)
promotionId: Optional[str] = Field(
None,
description="A unique eBay-assigned ID for the promotion that's generated when the promotion is created.",
)
promotionReportId: Optional[str] = Field(
None,
description='The unique eBay-assigned ID of the promotion report that is generated when the report is created.',
)
promotionSale: Optional[Amount] = Field(
None,
description='This is the monetary amount of the items sold in a threshold promotion where the threshold <i>has been met</i> and the discount was applied. <br><br>For example, suppose you\'re running a "Buy 1, get 1 at 50%" promotion on $5 socks. One buyer purchases two pairs of socks, so they pay $7.50 for both pairs (rather than the full price of $10). Your <b>promotionSale</b> amount would be $7.50.',
)
promotionType: Optional[str] = Field(
None,
description="Indicates the type of the promotion, either <code>CODED_COUPON</code>, <code>MARKDOWN_SALE</code>, <code>ORDER_DISCOUNT</code>, or <code>VOLUME_DISCOUNT</code>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionTypeEnum'>eBay API documentation</a>",
)
totalDiscount: Optional[Amount] = Field(
None,
description='This is the monetary discount amount applied to the sale of items in a threshold promotion where the threshold <i>has been met</i> and the discount was applied. <br><br>For example, suppose you\'re running a "Buy 1, get 1 at 50%" promotion on $5 socks. One buyer purchases two pairs of socks, so they pay $7.50 for both pairs (rather than the full price of $10). Your <b>totalDiscount</b> amount would be $2.50.',
)
totalSale: Optional[Amount] = Field(
None,
description='This is the total monetary sales amount of all items sold in a promotion. <br><br>For example, suppose you\'re running a "Buy 1, get 1 at 50%" promotion on $5 socks. You make one sale where the buyer purchases only one pair of socks and they pay the full price of $5 (<b>baseSale</b>). You make a second sale where the buyer purchases two pairs of socks and they pay $7.50, for both pairs (<b>promotionSale</b>). Your <b>totalSale</b> would be $12.50. This value is calculated as follows: <br><br><b>baseSale</b> + <b>promotionSale</b> = <b>totalSale</b>',
)
class PromotionsPagedCollection(BaseModel):
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
limit: Optional[int] = Field(
None,
description='The number of items returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.',
)
next: Optional[str] = Field(
None,
description='The URI for the following page of results. This value is returned only if there is an additional page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first returned result. This value can be set in the request with the <b>offset</b> query parameter. <p class="tablenote"><strong>Note: </strong>The items in a paginated result set use a zero-based list where the first item in the list has an offset of <code>0</code>.</p>',
)
prev: Optional[str] = Field(
None,
description='The URI for the preceding page of results. This value is returned only if there is a previous page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
promotions: Optional[List[PromotionDetail]] = Field(
None,
description='A list containing the details of each returned promotion. This includes all the information about the promotions except for the listings that are part of the promotions.',
)
total: Optional[int] = Field(
None,
description='The total number of items retrieved in the result set. <br><br>If no items are found, this field is returned with a value of <code>0</code>.',
)
class PromotionsReportPagedCollection(BaseModel):
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
limit: Optional[int] = Field(
None,
description='The number of items returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.',
)
next: Optional[str] = Field(
None,
description='The URI for the following page of results. This value is returned only if there is an additional page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first returned result. This value can be set in the request with the <b>offset</b> query parameter. <p class="tablenote"><strong>Note: </strong>The items in a paginated result set use a zero-based list where the first item in the list has an offset of <code>0</code>.</p>',
)
prev: Optional[str] = Field(
None,
description='The URI for the preceding page of results. This value is returned only if there is a previous page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
promotionReports: Optional[List[PromotionReportDetail]] = Field(
None,
description='A list of <b>promotionReports</b> contained in the paginated result set.',
)
total: Optional[int] = Field(
None,
description='The total number of items retrieved in the result set. <br><br>If no items are found, this field is returned with a value of <code>0</code>.',
)
class ProposedBid(BaseModel):
currency: Optional[str] = Field(
None,
description='The base currency applied to the <b>value</b> field to establish a monetary amount. <br><br>The currency is represented as a 3-letter <a href="https://www.iso.org/iso-4217-currency-codes.html " title="https://www.iso.org " target="_blank">ISO 4217</a> currency code. For example, the code for the Canadian Dollar is <code>CAD</code>. <br><br><b>Default:</b> The default currency of the eBay marketplace that hosts the listing. For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/ba:CurrencyCodeEnum\'>eBay API documentation</a>',
)
rangeEnd: Optional[str] = Field(
None, description='The end of the range specified for the bid.'
)
rangeStart: Optional[str] = Field(
None, description='The start of the range specified for the bid.'
)
value: Optional[str] = Field(None, description='The value of the proposed bid.')
class ReportMetadata(BaseModel):
dimensionMetadata: Optional[List[DimensionMetadata]] = Field(
None,
description='A list containing the metadata for the dimension used in the report.',
)
maxNumberOfDimensionsToRequest: Optional[int] = Field(
None,
description='The maximum number of dimensions that can be requested for the specified report type.',
)
maxNumberOfMetricsToRequest: Optional[int] = Field(
None,
description='The maximum number of metrics that can be requested for the specified report type.',
)
metricMetadata: Optional[List[MetricMetadata]] = Field(
None,
description='A list containing the metadata for the metrics in the report.',
)
reportType: Optional[str] = Field(
None,
description='The <b>report_type</b>, as specified in the request to create the report task.<br/><br/><span class="tablenote"><b>Note:</b> INVENTORY_PERFORMANCE_REPORT is not currently available; availability date is pending.</span> For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/plr:ReportTypeEnum\'>eBay API documentation</a>',
)
class ReportMetadatas(BaseModel):
reportMetadata: Optional[List[ReportMetadata]] = Field(
None, description='A list of the metadata for the associated report type.'
)
class ReportTask(BaseModel):
campaignIds: Optional[List[str]] = Field(
None,
description="A list of IDs for the campaigns that are included in the report. A campaign ID is a unique eBay-assigned identifier of the campaign that's generated when the campaign is created.<br /><br />Call <b>getCampaigns</b> to return the current campaign IDs for a seller.",
)
dateFrom: Optional[str] = Field(
None,
description='The date defining the start of the timespan covered by the report, formatted as an <a href="https://www.iso.org/iso-8601-date-and-time-format.html " title="https://www.iso.org " target="_blank">ISO 8601</a> timestamp.',
)
dateTo: Optional[str] = Field(
None,
description='The date defining the end of the timespan covered by the report, formatted as an <a href="https://www.iso.org/iso-8601-date-and-time-format.html " title="https://www.iso.org " target="_blank">ISO 8601</a> timestamp.',
)
dimensions: Optional[List[Dimension]] = Field(
None, description='A list containing the dimension in the report.'
)
fundingModels: Optional[List[str]] = Field(
None,
description='The funding model for the campaign that shall be included in the report.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> The default funding model for Promoted Listings reports is <code>COST_PER_SALE</code>.</span><br /><br /><b>Valid Values:</b><ul><li><code>COST_PER_SALE</code></li><li><code>COST_PER_CLICK</code></li></ul>',
)
inventoryReferences: Optional[List[InventoryReference]] = Field(
None,
description='If supplied in the request, this field returns a list of the seller\'s inventory reference IDs included in the report. <p>Each item is referenced by a pair of <b>inventoryRefernceID</b> and <b>inventoryReferenceType</b> values, where an inventory reference ID can be either a seller-defined <b>SKU</b> value or an <b>inventoryItemGroupKey</b>. An <b>inventoryItemGroupKey</b> is seller-defined ID for an inventory item group (a multiple-variation listing), and is created and used by the <a href="/api-docs/sell/inventory/resources/methods">Inventory API</a>.</p>',
)
listingIds: Optional[List[str]] = Field(
None,
description="If supplied in the request, this field returns a list of the listing IDs included in the report. A listing ID is an eBay-assigned ID that's generated when a listing is created.",
)
marketplaceId: Optional[str] = Field(
None,
description="The ID of the eBay marketplace used by the report task. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/ba:MarketplaceIdEnum'>eBay API documentation</a>",
)
metricKeys: Optional[List[str]] = Field(
None, description='A list of metrics for the report task.'
)
reportExpirationDate: Optional[str] = Field(
None,
description='The date after which the report is no longer be available. Reports are available for 30 days and you cannot download a report after it has expired. <br><br><b>Format (UTC): </b> yyyy-MM-ddThh:mm:ss.sssZ',
)
reportFormat: Optional[str] = Field(
None,
description="Indicates the format of the report. Currently, only <code>TSV_GZIP</code> is supported. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/plr:ReportFormatEnum'>eBay API documentation</a>",
)
reportHref: Optional[str] = Field(
None,
description='The URL of the generated report, which can be used to download the report once it has been generated.',
)
reportId: Optional[str] = Field(
None, description='A unique eBay-assigned ID for the report.'
)
reportName: Optional[str] = Field(
None,
description="An eBay-assigned name for the report that's created by the <b>createReportTask</b> call. This name is unique for the seller.",
)
reportTaskCompletionDate: Optional[str] = Field(
None,
description='The date the report task completed the report generation. <br><br><b>Format (UTC): </b> yyyy-MM-ddThh:mm:ss.sssZ',
)
reportTaskCreationDate: Optional[str] = Field(
None,
description='The date the report task was created. <br><br><b>Format (UTC): </b> yyyy-MM-ddThh:mm:ss.sssZ',
)
reportTaskExpectedCompletionDate: Optional[str] = Field(
None,
description='The date the report task is expected to complete the report generation. <br><br><b>Format (UTC): </b> yyyy-MM-ddThh:mm:ss.sssZ',
)
reportTaskId: Optional[str] = Field(
None,
description='The unique eBay-assigned ID of the report task. This value is generated when the report task is created with a call to <b>createReportTask</b>.',
)
reportTaskStatus: Optional[str] = Field(
None,
description="Indicates the current state of the report task. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/plr:TaskStatusEnum'>eBay API documentation</a>",
)
reportTaskStatusMessage: Optional[str] = Field(
None,
description='A status message with additional information about the report task.',
)
reportType: Optional[str] = Field(
None,
description='Indicates type of report associated with the report task.<br/><br/><span class="tablenote"><b>Note:</b> INVENTORY_PERFORMANCE_REPORT is not currently available; availability date is pending.</span> For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/plr:ReportTypeEnum\'>eBay API documentation</a>',
)
class ReportTaskPagedCollection(BaseModel):
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
limit: Optional[int] = Field(
None,
description='The number of items returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.',
)
next: Optional[str] = Field(
None,
description='The URI for the following page of results. This value is returned only if there is an additional page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first returned result. This value can be set in the request with the <b>offset</b> query parameter.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> The items in a paginated result set use a zero-based list where the first item in the list has an offset of <code>0</code>.</span>',
)
prev: Optional[str] = Field(
None,
description='The URI for the preceding page of results. This value is returned only if there is a previous page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
reportTasks: Optional[List[ReportTask]] = Field(
None,
description='A list of report tasks contained on this page from the paginated response.',
)
total: Optional[int] = Field(
None,
description='The total number of items retrieved in the result set. <br><br>If no items are found, this field is returned with a value of <code>0</code>.',
)
class SelectionRule(BaseModel):
brands: Optional[List[str]] = Field(
None,
description="An array of product brands used as an inclusion filter. A product's brand is defined in a listing's item specifics. This array will be returned if one or more product brands were used as a filter.",
)
categoryIds: Optional[List[str]] = Field(
None,
description='A list of category IDs associated with the listings to be included in the campaign. Ads are created for all the seller\'s items listed in the specified categories, up to a maximum of 50,000 items. The IDs can be either a list of eBay category IDs (from the site where the item is hosted), or a list of category IDs defined and used by the seller\'s store. <p><b>eBay Marketplace category IDs</b> <br>To get a list of marketplace category IDs, do one of the following:</p> <ul><li>Get a list of category IDs for a marketplace by adding <code>/sch/allcategories/all-categories</code> to the marketplace URL when browsing the site. <br>For example: <code> http://www.ebay.com.au/sch/allcategories/all-categories</code> </li><li>Navigate to the desired category on the host site and copy the category ID from the URL.</li> <li>These options are also available for the US marketplace: <ul><li>See <a href="http://pages.ebay.com/sellerinformation/news/categorychanges.html " target="_blank">Category Changes</a> for the latest list of category IDs.</li><li>Retrieve a list of category IDs using the <a href="/api-docs/commerce/taxonomy/resources/methods">Taxonomy API</a>.</li></ul></li></ul><p><b>Seller store category IDs</b> <br>Because store category IDs are uniquely defined and maintained by each seller, this service cannot provide a list of a seller\'s IDs. However, sellers can retrieve their store category IDs as follows:</p><ol><li>Go to <b>Seller Hub</b> > <b>Marketing</b>.</li> <li>Click <b>Manage store categories</b>. <br> A list of your store categories displays.</li> <li>Click the <b>All categories</b> link displayed at the bottom of the list. <br>A complete list of your store categories and their associated store category IDs displays.</li></ol>',
)
categoryScope: Optional[str] = Field(
None,
description="The enumeration values returned in this field indicate if the category IDs in the corresponding categoryIds array are identifiers for eBay categories or for a seller's eBay store categories. This field is always returned if one or more category IDs are used as a filter. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:CategoryScopeEnum'>eBay API documentation</a>",
)
listingConditionIds: Optional[List[str]] = Field(
None,
description='A comma-separated list of unique identifiers for the conditions of listings to be included in the campaign. Up to four IDs can be specified.<br /><br />This array is only returned if one or more item condition values are used as a filter.<br /><br /><span class="tablenote"><strong>Note:</strong> Multiple listing condition IDs are mapped to the four valid values listed below. Refer to <a href="/api-docs/sell/static/marketing/pl-campaign-flow-pls.html#add-by-rule" target="_blank">Promoted Listings Standard campaign flow</a> for more details.</span><br /><br /><strong>Valid Values:</strong><ul><li><code>1000</code> = New</li><li><code>2000</code> = Certified Refurbished</li><li><code>2500</code> = Seller Refurbished</li><li><code>3000</code> = Used</li></ul>',
)
maxPrice: Optional[Amount] = Field(
None,
description="Use this container to set a maximum price threshold. Any listings that have a 'Buy it Now' price above this price will not be considered for or added to this campaign.",
)
minPrice: Optional[Amount] = Field(
None,
description="Use this container to set a minimum price threshold. Any listings that have a 'Buy it Now' price below this price will not be considered for or added to this campaign.",
)
class SuggestedBids(BaseModel):
keywordText: Optional[str] = Field(None, description='The text for the keyword.')
matchType: Optional[str] = Field(
None,
description="A field that defines the match type for the keyword.<br /><br /><b>Valid Values:</b><ul><li><code>BROAD</code></li><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:MatchTypeEnum'>eBay API documentation</a>",
)
proposedBid: Optional[ProposedBid] = Field(
None, description='The suggested bid associated with the keyword. '
)
class SummaryReportResponse(BaseModel):
baseSale: Optional[Amount] = Field(
None,
description='The total revenue from all the purchased items that were part of a promotion but <i>did not trigger</i> a discount during the promotion period.',
)
lastUpdated: Optional[str] = Field(
None, description='The date the report was generated.'
)
percentageSalesLift: Optional[str] = Field(
None,
description='The percentage of the total dollar amount gained due to promotions. This value is calculated as follows: <br><br><b>precentageSalesLift</b> = <b>promotionSale</b> / (<b>baseSale</b> + <b>promotionSale</b>)',
)
promotionSale: Optional[Amount] = Field(
None,
description='The total revenue from all the purchased items that were part of a promotion and their purchase <i>did trigger</i> a discount during the promotion period.',
)
totalSale: Optional[Amount] = Field(
None,
description="Total dollar sales amount of all the seller's listings, current to the date the report was generated.",
)
class TargetedBidRequest(BaseModel):
keywords: Optional[List[KeywordRequest]] = Field(
None,
description='A list of keywords in the paginated collection. <br /><br /><b>Maximum number of keywords: </b>500',
)
class TargetedBidsPagedCollection(BaseModel):
suggestedBids: Optional[List[SuggestedBids]] = Field(
None, description='A list of bids in the paginated collection.'
)
class TargetedKeywordRequest(BaseModel):
additionalInfo: Optional[List[str]] = Field(
None,
description='A field used to indicate whether additional information and insight data shall be provided for suggested keywords.<br /><br /><strong>Valid Value:</strong> <code>KEYWORD_INSIGHTS</code>',
)
exclusions: Optional[List[str]] = Field(
None,
description='A field used to indicate that the keywords already selected by sellers for the specified listing IDs should be filtered out of the response, and only new and unique keyword recommendations shall be returned.<br /><br /><strong>Valid Value:</strong> <code>ADOPTED_KEYWORDS</code>',
)
listingIds: Optional[List[str]] = Field(
None,
description='A set of comma-separated listing IDs in the paginated collection. <br /><br /><b>Maximum number of listings requested: </b>300',
)
matchType: Optional[str] = Field(
None,
description="A field that defines the match type for the keyword.<br /><br /><b>Valid Values:</b><ul><li><code>BROAD</code></li><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:MatchTypeEnum'>eBay API documentation</a>",
)
class TargetingItems(BaseModel):
bases: Optional[List[ItemBasis]] = Field(
None, description='The metrics and additional information for the items.'
)
listingId: Optional[str] = Field(
None, description='The listing ID of the targeted item.'
)
class UpdateAdGroupRequest(BaseModel):
adGroupStatus: Optional[str] = Field(
None,
description="An enumeration value representing the current status of the ad group.<p>If the status of the ad is currently <code>ACTIVE</code>, you can change status to <code>PAUSED</code> or <code>ARCHIVED</code>. If ad group is currently in <code>PAUSED</code> status, you can change the status back to <code>ACTIVE</code>. Ads that are currently in <code>ARCHIVED</code> status cannot be made <code>ACTIVE</code> again.<br /><br /><b>Valid Values:</b><ul><li><code>ACTIVE</code></li><li><code>PAUSED</code></li><li><code>ARCHIVED</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:AdGroupStatusEnum'>eBay API documentation</a>",
)
defaultBid: Optional[Amount] = Field(
None,
description='A bid amount that applies to all of the keywords in an ad group that do not have individual bids.',
)
name: Optional[str] = Field(
None, description='The updated name for the specified ad group.'
)
class UpdateAdStatusByListingIdRequest(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for an ad group in a campaign that uses the Cost Per Click (CPC) funding model.<br /><br /><span class="tablenote"><b>Note:</b> You can call the <a href="/api-docs/sell/marketing/resources/adgroup/methods/getAdGroups">getAdGroups</a> method to retrieve the ad group IDs for a seller.</span>',
)
adStatus: Optional[str] = Field(
None,
description="An enumeration value representing the current status of the ad.<br /><br /><b>Valid Values:</b><ul><li><code>ACTIVE</code></li><li><code>PAUSED</code></li><li><code>ARCHIVED</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:AdStatusEnum'>eBay API documentation</a>",
)
listingId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a listing that is generated when the listing is created.<br /><br /><span class="tablenote"><b>Note:</b> This field accepts both listing IDs (as generated by the Inventory API), and item IDs (as used in the eBay Traditional API set, such as the Trading and Finding APIs).</span>',
)
class UpdateAdStatusRequest(BaseModel):
adId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID that is generated when the ad is created.',
)
adStatus: Optional[str] = Field(
None,
description="An enumeration value representing the current status of the ad.<br /><br /><b>Valid Values:</b><ul><li><code>ACTIVE</code></li><li><code>PAUSED</code></li><li><code>ARCHIVED</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:AdStatusEnum'>eBay API documentation</a>",
)
class UpdateAdrateStrategyRequest(BaseModel):
adRateStrategy: Optional[str] = Field(
None,
description="The ad rate strategy that shall be applied to the campaign. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:AdRateStrategyEnum'>eBay API documentation</a>",
)
bidPercentage: Optional[str] = Field(
None,
description='The user-defined <b>bid percentage</b> (also known as the <i>ad rate</i>) sets the level that eBay increases the visibility in search results for the associated listing. The higher the <b>bidPercentage</b> value, the more eBay promotes the listing. <br><br>The value specified here is also used to calculate the Promoted Listings fee. This percentage value is multiplied by the final sales price to determine the fee. <br><br>The Promoted Listings fee is determined at the time the transaction completes and the seller is assessed the fee only when an item sells through a Promoted Listings ad campaign. <br><br>The <b>bidPercentage</b> is a single precision value that is guided by the following rules: <ul><li>These values are <b>valid</b>:<br> <code>4.1</code>, <code>5.0</code>, <code>5.5</code>, ...</li> <li>These values are <b>not valid</b>:<br /> <code>0.01</code>, <code>10.75</code>, <code>99.99</code>,<br /> and so on.</li></ul>This is the default bid percentage for the campaigns using the Cost Per Sale (CPS) funding model, and this value will be overridden by any ads in the campaign that have their own set bid percentages.<br /><br />If a bid percentage is not provided for an ad, eBay uses the default bid percentage of the associated campaign.<br /><br /><b>Minimum value:</b> 2.0 <br><b>Maximum value:</b> 100.0',
)
dynamicAdRatePreferences: Optional[List[DynamicAdRatePreference]] = Field(
None,
description='A field that indicates whether a single, user-defined bid percentage (also known as the <i>ad rate</i>) should be used, or whether eBay should automatically adjust listings to maintain the daily suggested bid percentage.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> Dynamic adjustment is only applicable when the <b>adRateStrategy</b> is set to <code>DYNAMIC</code>.</span><br /><b>Default:</b> <code>FIXED</code>',
)
class UpdateBidPercentageRequest(BaseModel):
bidPercentage: Optional[str] = Field(
None,
description='The user-defined <b>bid percentage</b> (also known as the <i>ad rate</i>) sets the level that eBay increases the visibility in search results for the associated listing. The higher the <b>bidPercentage</b> value, the more eBay promotes the listing. <br><br>The value specified here is also used to calculate the Promoted Listings fee. This percentage value is multiplied by the final sales price to determine the fee. <br><br>The Promoted Listings fee is determined at the time the transaction completes and the seller is assessed the fee only when an item sells through a Promoted Listings ad campaign. <br><br>The <b>bidPercentage</b> is a single precision value that is guided by the following rules: <ul><li>These values are <b>valid</b>:<br> <code>4.1</code>, <code>5.0</code>, <code>5.5</code>, ...</li> <li>These values are <b>not valid</b>:<br /> <code>0.01</code>, <code>10.75</code>, <code>99.99</code>,<br /> and so on.</li></ul>This is default bid percentage for the campaigns using the Cost Per Sale (CPS) funding model, and this value will be overridden by any ads in the campaign that have their own set bid percentages.<br /><br />If a bid percentage is not provided for an ad, eBay uses the default bid percentage of the associated campaign.<br /><br /><b>Minimum value:</b> 2.0 <br><b>Maximum value:</b> 100.0',
)
class UpdateCampaignBudgetRequest(BaseModel):
daily: Optional[BudgetRequest] = Field(
None,
description='The daily budget limit for the Cost Per Click (CPC) Promoted Listings campaign. This will be a dollar value. All clicks using the keywords defined for the campaign will go towards expending the daily budget. Once the daily budget is exceeded for the campaign, all Promoted Listings under the campaign will be turned off until the next day.<br /><br /><b>Valid Values</b>:<ul><li><code>50.00</code></li><li><code>100.00</code></li></ul>',
)
class UpdateCampaignIdentificationRequest(BaseModel):
campaignName: Optional[str] = Field(
None,
description="The new seller-defined name for the campaign. This value must be unique for the seller. <p>If you don't want to change the name of the campaign, specify the current campaign name in this field.<p>You can use any alphanumeric characters in the name, except the less than (<) or greater than (>) characters.</p><b>Max length: </b>80 characters.",
)
endDate: Optional[str] = Field(
None,
description='The date and time the campaign ends, in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). If this field is omitted, the campaign will have no defined end date, and will not end until the seller makes a decision to end the campaign with an <a href="/api-docs/sell/marketing/resources/campaign/methods/endCampaign">endCampaign</a> call, or if they update the campaign at a later time with an end date.<p>If you want to change only the end date of the campaign, specify the current campaign name and set <b>startDate</b> to the current date (you cannot use a start date that is in the past), and set the <b>endDate</b> as desired. Note that if you do not set a new end date in this call, any current endDate value will be set to null. To preserve the currently-set end date, you must specify the value again in your request.</p>',
)
startDate: Optional[str] = Field(
None,
description='The new start date for the campaign, in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). <p>If the campaign is currently <code>RUNNING</code> or <code>PAUSED</code>, enter the current date in this field because you cannot submit past or future date for these campaigns.</p> <p>On the date specified, the service derives the keywords for each listing in the campaign, creates an ad for each listing, and associates each new ad with the campaign. The campaign starts after this process is completed. The amount of time it takes the service to start the campaign depends on the number of listings in the campaign.</p> <p>Call <a href="/api-docs/sell/marketing/resources/campaign/methods/getCampaigns">getCampaigns</a> to retrieve the <b>campaign_id</b> and the campaign status (<code>RUNNING</code>, <code>PAUSED</code>, <code>ENDED</code>, and so on) for all the seller\'s campaigns.</p>',
)
class UpdateKeywordByKeywordIdRequest(BaseModel):
bid: Optional[Amount] = Field(
None,
description='This container is used to set or change the bid percentage for the keyword. Each time a listing is retrieved in search results using this keyword and clicked on, the seller will be charged this amount. Each click goes toward the daily budget set up for the Cost Per Click (CPC) campaign.',
)
keywordId: Optional[str] = Field(
None,
description='This field is used to identify the keyword to be updated. The <a href="/api-docs/sell/marketing/resources/keyword/methods/getKeyword">getKeyword</a> method can be used to retrieve keywordId values.',
)
keywordStatus: Optional[str] = Field(
None,
description='Include this field if you wish to change the status of the keyword. The status value specified here must be different than the keyword\'s current status. To confirm the current status of a keyword, you can use the <a href="/api-docs/sell/marketing/resources/keyword/methods/getKeyword">getKeyword</a> method.</p><p>If the status of the ad is currently <code>ACTIVE</code>, you can change status to <code>PAUSED</code> or <code>ARCHIVED</code>. If ad group is currently in <code>PAUSED</code> status, you can change the status back to <code>ACTIVE</code>. Ads that are currently in <code>ARCHIVED</code> status cannot be made <code>ACTIVE</code> again. For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/pls:KeywordStatusEnum\'>eBay API documentation</a>',
)
class UpdateKeywordRequest(BaseModel):
bid: Optional[Amount] = Field(
None,
description='This container is used to set or change the bid for the keyword. Each time a listing is retrieved in search results using this keyword and clicked on, the seller will be charged this amount. Each click goes toward the daily budget set up for the CPC campaign. If the bid is not provided, then the default bid associated with the ad group is used.',
)
keywordStatus: Optional[str] = Field(
None,
description='Include this field if you wish to change the status of the keyword. The status value specified here must be different than the keyword\'s current status. To confirm the current status of a keyword, you can use the <a href="/api-docs/sell/marketing/resources/keyword/methods/getKeyword">getKeyword</a> method.</p><p>If the status of the ad is currently <code>ACTIVE</code>, you can change status to <code>PAUSED</code> or <code>ARCHIVED</code>. If ad group is currently in <code>PAUSED</code> status, you can change the status back to <code>ACTIVE</code>. Ads that are currently in <code>ARCHIVED</code> status cannot be made <code>ACTIVE</code> again. For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/pls:KeywordStatusEnum\'>eBay API documentation</a>',
)
class UpdateNegativeKeywordIdRequest(BaseModel):
negativeKeywordId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a negative keyword. This keyword ID will be generated for each successfully created negative keyword.',
)
negativeKeywordStatus: Optional[str] = Field(
None,
description="A field that defines the status of the negative keyword. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:NegativeKeywordStatusEnum'>eBay API documentation</a>",
)
class UpdateNegativeKeywordRequest(BaseModel):
negativeKeywordStatus: Optional[str] = Field(
None,
description="A field that defines the status of the negative keyword. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:NegativeKeywordStatusEnum'>eBay API documentation</a>",
)
class AdCampaignPostResponse(BaseModel):
pass
class AdCampaignCampaignIdAdPostResponse(BaseModel):
pass
class AdCampaignCampaignIdAdGroupPostResponse(BaseModel):
pass
class AdCampaignCampaignIdClonePostResponse(BaseModel):
pass
class AdCampaignCampaignIdKeywordPostResponse(BaseModel):
pass
class AdReportReportIdGetResponse(BaseModel):
pass
class ItemPriceMarkdownPostResponse(BaseModel):
pass
class ItemPriceMarkdownPromotionIdPutResponse(BaseModel):
pass
class NegativeKeywordPostResponse(BaseModel):
pass
class AdGroup(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for an ad group in a campaign that uses the Cost Per Click (CPC) funding model.',
)
adGroupStatus: Optional[str] = Field(
None,
description="An enumeration value representing the current status of the ad group.<br /><br /><b>Valid Values:</b><ul><li><code>ACTIVE</code></li><li><code>PAUSED</code></li><li><code>ARCHIVED</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:AdGroupStatusEnum'>eBay API documentation</a>",
)
defaultBid: Optional[Amount] = Field(
None,
description='A bid amount that applies to all of the keywords in an ad group that do not have individual bids. For all keywords without individual bids, the default bid is the amount that the seller will pay per click for the listings in the ad group in the promoted listings campaign.<br><br><b>Valid Values</b>: 0.5, 0.75',
)
name: Optional[str] = Field(
None, description='The seller-defined name of the ad group.'
)
class AdGroupPagedCollectionResponse(BaseModel):
adGroups: Optional[List[AdGroup]] = Field(
None,
description='The details of existing ad groups, such as the name, ID, and status of the ad groups.',
)
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
limit: Optional[int] = Field(
None,
description='The number of items returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.',
)
next: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the next page in the result set. This value is returned only if there is an additional page of results to display from the result set.',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first returned result. This value can be set in the request with the <b>offset</b> query parameter. <p><b>Default:</b> 0</p><br><span class="tablenote"><b>Note: </b>The items in a paginated result set use a zero-based list, where the first item in the list has an offset of <code>0</code>.</span>',
)
prev: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the previous page in the result set. Basically, all of the request parameters will remain the same except the offset value, which will be decreased to retrieve the previous page of results.',
)
total: Optional[int] = Field(
None,
description='The total number of items retrieved in the result set.<br /><br /><span class="tablenote"><b>Note: </b>If no items are found, this field is returned with a value of <code>0</code>.</span>',
)
class AdditionalInfo(BaseModel):
infoType: Optional[str] = Field(
None,
description="The type of additional information provided for the suggested keyword.<br /><br /><strong>Valid Value:</strong> <code>KEYWORD_INSIGHTS</code> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:AdditionalInfoEnum'>eBay API documentation</a>",
)
metrics: Optional[List[AdditionalInfoData]] = Field(
None,
description='A list of additional data provided for the suggested keyword.',
)
class AlertDetails(BaseModel):
aspect: Optional[Aspect] = Field(
None,
description='The aspect information of the alert including keys and values.',
)
dimension: Optional[AlertDimension] = Field(
None,
description='The dimension information of the alert including keys and values.',
)
class BulkCreateAdRequest(BaseModel):
requests: Optional[List[CreateAdRequest]] = Field(
None,
description='An array of listing IDs and their associated bid percentages, which the request uses to create ads in bulk. This request accepts both listing IDs, as generated by the Inventory API, and an item IDs, as used in the eBay Traditional API set (e.g., the Trading and Finding APIs). <br><br><b>Maximum: </b> 500 IDs per call',
)
class BulkCreateAdsByInventoryReferenceRequest(BaseModel):
requests: Optional[List[CreateAdsByInventoryReferenceRequest]] = Field(
None,
description='A list of inventory reference ID and inventory reference type pairs, and the bid percentage, which the call uses to create ads in bulk.',
)
class BulkCreateKeywordRequest(BaseModel):
requests: Optional[List[CreateKeywordRequest]] = Field(
None,
description='This array is used to pass in multiple keywords for one or more ad groups that belong to a campaign that uses the Cost Per Click (CPC) funding model. Up to {max value} keywords can be created with one call.',
)
class BulkCreateNegativeKeywordRequest(BaseModel):
requests: Optional[List[CreateNegativeKeywordRequest]] = Field(
None,
description='This array is used to pass in multiple negative keywords for one or more ad groups that belong to a campaign that uses the Cost Per Click (CPC) funding model.',
)
class BulkDeleteAdRequest(BaseModel):
requests: Optional[List[DeleteAdRequest]] = Field(
None, description='An array of the listing IDs that identify the ads to remove.'
)
class BulkDeleteAdsByInventoryReferenceRequest(BaseModel):
requests: Optional[List[DeleteAdsByInventoryReferenceRequest]] = Field(
None,
description='A list of inventory referenceID and inventory reference type pairs that specify the set of ads to remove in bulk.',
)
class BulkUpdateAdStatusByListingIdRequest(BaseModel):
requests: Optional[List[UpdateAdStatusByListingIdRequest]] = Field(
None, description='An array of listing IDs and bid percentages.'
)
class BulkUpdateAdStatusRequest(BaseModel):
requests: Optional[List[UpdateAdStatusRequest]] = Field(
None, description='An array of listing IDs and bid percentages.'
)
class BulkUpdateKeywordRequest(BaseModel):
requests: Optional[List[UpdateKeywordByKeywordIdRequest]] = Field(
None,
description='Use this array to update the bid values and/or statuses of one or more existing keywords.',
)
class BulkUpdateNegativeKeywordRequest(BaseModel):
requests: Optional[List[UpdateNegativeKeywordIdRequest]] = Field(
None,
description='An array to update the statuses of one or more existing negative keywords.',
)
class CampaignCriterion(BaseModel):
autoSelectFutureInventory: Optional[bool] = Field(
None,
description="A field used to indicate whether listings shall be automatically added to, or removed from, a Promoted Listings campaign based on the rules that have been configured for the campaign.<br /><br />If set to <code>true</code>, eBay adds all listings matching the campaign criterion to the campaign, including any new listings created from the items in a seller's inventory.<br /><br /><b>Default:</b> <code>false</code>",
)
criterionType: Optional[str] = Field(
None,
description="This enum defines the criterion (selection rule) types. Currently, the only criterion type supported is <code>INVENTORY_PARTITION</code>, and you must specify this value if you manage your items with the Inventory API and you want to include items based on their inventory reference IDs. <br><br>Do not include this field if you manage your listings with Trading API/legacy model. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:CriterionTypeEnum'>eBay API documentation</a>",
)
selectionRules: Optional[List[SelectionRule]] = Field(
None,
description='This container shows all of the rules/inclusion filters used to add listings to the campaign.',
)
class CloneCampaignRequest(BaseModel):
campaignName: Optional[str] = Field(
None,
description='A seller-defined name for the newly-cloned campaign. This value must be unique for the seller. <p>You can use any alphanumeric characters in the name, except the less than (<) or greater than (>) characters.</p><b>Max length: </b>80 characters',
)
endDate: Optional[str] = Field(
None,
description='The date and time the campaign ends, in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). If this field is omitted, the campaign will have no defined end date, and will not end until the seller makes a decision to end the campaign with an <a href="/api-docs/sell/marketing/resources/campaign/methods/endCampaign">endCampaign</a> call, or if they update the campaign at a later time with an end date.',
)
fundingStrategy: Optional[FundingStrategy] = Field(
None,
description='This container is used to set the funding model and default bid percentage for the campaign to be cloned.',
)
startDate: Optional[str] = Field(
None,
description='The date and time the cloned campaign starts, in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller. <p>On the date specified, the service derives the keywords for each listing in the campaign, creates an ad for each listing, and associates each new ad with the campaign. The campaign starts after this process is completed. The amount of time it takes the service to start the campaign depends on the number of listings in the campaign. Call <b>getCampaign</b> to check the status of the campaign.</p>',
)
class CreateCampaignRequest(BaseModel):
budget: Optional[CampaignBudgetRequest] = Field(
None,
description='The allocated daily budget for the Cost Per Click (CPC) Promoted Listings campaign.<br /><br /><i>Required if</i> the campaign funding model is CPC.',
)
campaignCriterion: Optional[CampaignCriterion] = Field(
None,
description='This container is used if the seller wishes to create one or more rules for a rules-based campaign. If you populate the <b>campaignCriterion</b> object in your <b>createCampaign</b> request, ads for the campaign are created by rule for the listings that meet the criteria you specify, and these ads are associated with the campaign to be created.',
)
campaignName: Optional[str] = Field(
None,
description='A seller-defined name for the campaign. This value must be unique for the seller. <p>You can use any alphanumeric characters in the name, except the less than (<) or greater than (>) characters.</p><b>Max length: </b>80 characters',
)
endDate: Optional[str] = Field(
None,
description='The date and time the campaign ends, in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). If this field is omitted, the campaign will have no defined end date, and will not end until the seller makes a decision to end the campaign with an <a href="/api-docs/sell/marketing/resources/campaign/methods/endCampaign">endCampaign</a> call, or if they update the campaign at a later time with an end date.',
)
fundingStrategy: Optional[FundingStrategy] = Field(
None,
description='This container is used to set the funding model and default bid percentage for a Cost Per Sale (CPS) campaign.',
)
marketplaceId: Optional[str] = Field(
None,
description="The ID of the eBay marketplace where the campaign is hosted. See the <b>MarketplaceIdEnum</b> type to get the appropriate enumeration value for the listing marketplace. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/ba:MarketplaceIdEnum'>eBay API documentation</a>",
)
startDate: Optional[str] = Field(
None,
description='The date and time the campaign starts, in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller. <p>On the date specified, the service derives the keywords for each listing in the campaign, creates an ad for each listing, and associates each new ad with the campaign. The campaign starts after this process is completed. The amount of time it takes the service to start the campaign depends on the number of listings in the campaign. Call <b>getCampaign</b> to check the status of the campaign.</p>',
)
class CreateReportTask(BaseModel):
additionalRecords: Optional[List[str]] = Field(
None,
description='A list of additional records that shall be included in the report, such as non-performing data.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> Additional records are only applicable to Promoted Listings Advanced (PLA) campaigns that use the Cost Per Click (CPC) funding model.</span><br /><b>Valid Value:</b> <code>NON_PERFORMING_DATA</code>',
)
campaignIds: Optional[List[str]] = Field(
None,
description='A list of campaign IDs to be included in the report task. Call <b>getCampaigns</b> to get a list of the current campaign IDs for a seller.<br /><br />For Promoted Listings Standard (PLS) sellers, this field is required if the <b>reportType</b> is set to <code>CAMPAIGN_PERFORMANCE_REPORT</code> or <code>CAMPAIGN_PERFORMANCE_SUMMARY_REPORT</code>.<br /><br />For Promoted Listings Advanced (PLA) sellers, leave this request field blank to retrieve the details for all campaigns associated with your account, or specify the campaign IDs for which you would like to retrieve the campaign-specific details.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> There is a maximum data limit that cannot be exceeded when generating reports. If this threshold is exceeded, the report will fail. Refer to <a href="/api-docs/sell/static/marketing/pl-reports.html#creation">Promoted Listings reporting</a> in the Selling Integration Guide for details.</span><br /><br /><b>Maximum:</b><ul><li>25 IDs for PLS</li><li>1,000 IDs for PLA</li></ul>',
)
dateFrom: Optional[str] = Field(
None,
description='The date defining the start of the timespan covered by the report.<br /><br />Format the timestamp as an <a href="https://www.iso.org/iso-8601-date-and-time-format.html" title="https://www.iso.org" target="_blank">ISO 8601</a> string, which is based on the 24-hour Coordinated Universal Time (UTC) clock with local offset.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> The date specified cannot be a future date.</span><br /><br /><b>Format:</b> <code>[YYYY]-[MM]-[DD]T[hh]:[mm]:[ss].[sss]Z</code><br /><br /><b>Example:</b> <code>2021-03-15T13:00:00-07:00</code>',
)
dateTo: Optional[str] = Field(
None,
description='The date defining the end of the timespan covered by the report.<br /><br />As with the <b>dateFrom</b> field, format the timestamp as an <a href="https://www.iso.org/iso-8601-date-and-time-format.html" title="https://www.iso.org" target="_blank">ISO 8601</a> string.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> The date specified cannot be a future date. Additionally, the time specified must be a later time than that specified in the <b>dateFrom</b> field.</span><br /><br /><b>Format:</b> <code>[YYYY]-[MM]-[DD]T[hh]:[mm]:[ss].[sss]Z</code><br /><br /><b>Example:</b> <code>2021-03-17T13:00:00-07:00</code>',
)
dimensions: Optional[List[Dimension]] = Field(
None,
description='The list of the dimensions applied to the report. <p>A dimension is an attribute to which the report data applies. For example, if you set <b>dimensionKey</b> to <code>campaign_id</code> in a Campaign Performance Report, the data will apply to the entire ad campaign. For information on the dimensions and how to specify them, see <a href="/api-docs/sell/static/marketing/pl-reports.html">Promoted Listings reporting</a>.</p>',
)
fundingModels: Optional[List[str]] = Field(
None,
description='The funding model for the campaign that shall be included in the report.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> The default funding model for Promoted Listings reports is <code>COST_PER_SALE</code>.</span><br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> Multiple value support for the <b>fundingModels</b> array has been deprecated. See <a href ="/develop/apis/api-deprecation-status ">API Deprecation Status</a> for information.</span><br /><br /><b>Valid Values:</b><ul><li><code>COST_PER_SALE</code></li><li><code>COST_PER_CLICK</code></li></ul><i>Required if</i> the campaign funding model is Cost Per Click (CPC).',
)
inventoryReferences: Optional[List[InventoryReference]] = Field(
None,
description='You can use this field to supply an array of items to include in the report if you manage your inventory with the <a href="/api-docs/sell/inventory/resources/methods">Inventory API</a>. <br><br>This field is mutually exclusive with the <b>listingIds</b> field; if you populate this field, <i>do not</i> populate the <b>listingIds</b> field. <br><br>An inventory reference identifies an item in your inventory using a pair of values, where the <b>inventoryReferenceId</b> can be either a seller-defined <b>SKU</b> value or an <b>inventoryItemGroupKey</b>, where an <b>inventoryItemGroupKey</b> is seller-defined ID for an inventory item group (a multiple-variation listing). <br><br>Couple the <b>inventoryReferenceId</b> with an <b>inventoryReferenceType</b> identifier to fully identify an item in your inventory. <br><br><b>Maximum: </b> 500 items <br><br><i>Required if </i> you do not supply an array of <b>listingId</b> values or if you set <b>reportType</b> to <code>INVENTORY_PERFORMANCE_REPORT</code>.',
)
listingIds: Optional[List[str]] = Field(
None,
description='Use this field to supply an array of listing IDs you want to include in the report.<br><br>A listing ID is the eBay listing identifier that is generated when the listing is created. This field accepts listing ID values generated with both the Inventory API and the eBay Traditional APIs, such as the Trading and Finding APIs.<br><br><span class="tablenote"><span style="color:#FF0000"><strong>Important:</strong></span> This field is mutually exclusive with the <b>inventoryReferences</b> field; if you populate this field, <i>do not</i> populate the <b>inventoryReferences</b> field.</span><br /><br />For Promoted Listings Standard (PLS) sellers, this field is required if you do not supply an array of <b>inventoryReferences</b> values or if you set the <b>reportType</b> to <code>LISTING_PERFORMANCE_REPORT</code>.<br /><br />For Promoted Listings Advanced (PLA) sellers, leave this field blank to retrieve the details for all listings associated with the specified campaign IDs (or all campaigns associated with your account, if no campaign IDs are specified), or specify the listing IDs for which you would like to retrieve the listing-specific details.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> There is a maximum data limit that cannot be exceeded when generating reports. If this threshold is exceeded, the report will fail. Refer to <a href="/api-docs/sell/static/marketing/pl-reports.html#creation">Promoted Listings reporting</a> in the Selling Integration Guide for details.</span><br /><br /><b>Maximum:</b> 500 listings',
)
marketplaceId: Optional[str] = Field(
None,
description="The ID for the eBay marketplace on which the report is based.<br /><br /><b>Maximum: </b> 1 For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/ba:MarketplaceIdEnum'>eBay API documentation</a>",
)
metricKeys: Optional[List[str]] = Field(
None,
description='The list of metrics to be included in the report. <p>Metrics are the quantitative measurements compiled into the report and the data returned is based on the specified dimension of the report. For example, if the dimension is <code>campaign</code>, the metrics for <b>number of sales</b> would be the number of sales in the campaign. However, if the dimension is <code>listing</code>, the <b>number of sales</b> represents the number of items sold in that listing.</p> <p>For information on metric keys and how to set them, see <a href="/api-docs/sell/static/marketing/pl-reports.html">Promoted Listings reporting</a>.</p><b>Minimum: </b> 1',
)
reportFormat: Optional[str] = Field(
None,
description="The file format of the report. Currently, the only supported format is <code>TSV_GZIP</code>, which is a gzip file with tab separated values. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/plr:ReportFormatEnum'>eBay API documentation</a>",
)
reportType: Optional[str] = Field(
None,
description='The type of report to be generated, such as <code>ACCOUNT_PERFORMANCE_REPORT</code> or <code>CAMPAIGN_PERFORMANCE_REPORT</code>.<br/><br/><span class="tablenote"><b>Note:</b> INVENTORY_PERFORMANCE_REPORT is not currently available; availability date is pending.</span><br /><br /><b>Maximum:</b> 1 For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/plr:ReportTypeEnum\'>eBay API documentation</a>',
)
class DiscountRule(BaseModel):
discountBenefit: Optional[DiscountBenefit] = Field(
None,
description='This container defines the promotional discount as either a monetary amount or a percentage of the sales price. <p><b>Note:</b> When configuring promotion benefits, populate just one of the following fields in the <b>discountBenefit</b> container:</p> <ul><li><b>amountOffItem</b></li> <li><b>amountOffOrder</b></li> <li><b>percentageOffItem</b></li> <li><b>percentageOffOrder</b></li></ul> <p>For volume pricing, only <b>percentageOffOrder</b> is applicable as a <b>discountBenefit</b>. Also, the first <b>discountBenefit</b> container in a volume pricing configuration must set <b>percentageOffOrder</b> to <code>0</code>.</p> <p class="tablenote"><b>Tip:</b> Refer to <a href="/api-docs/sell/static/marketing/pm-specifying-discounts.html">Configuring discounts for threshold promotions</a> for information and examples on how to combine <b>discountBenefit</b> and <b>discountSpecification</b> to create different types of promotions.</p>',
)
discountSpecification: Optional[DiscountSpecification] = Field(
None,
description='This container defines the criteria for when the discounts of a promotion trigger, such as the minimum quantity that the buyer must purchase before the promotion kicks in. The promotional discount is applied each time the criteria defined by this container is met. <p>When configuring the rules that govern when the discounts are applied, populate just one of the following fields in the <b>discountSpecification</b> container:</p> <ul><li><b>minAmount</b></li> <li><b>minQuantity</b></li> <li><b>forEachQuantity</b></li> <li><b>forEachAmount</b></li></ul> <p class="tablenote"><b>Important:</b> When configuring <i>volume pricing promotions</i>, only <b>minQuantity</b> is applicable as a <b>discountSpecification</b>. Also, the configuration for <b>minQuantity</b> in a volume pricing configuration is specific. In the first <b>discountSpecification</b> container, set <b>minQuantity</b> to <code>1</code>, and in the second, set <b>minQuantity</b> to <code>2</code>. If you include a third <b>discountRules</b> pair, <b>minQuantity</b> must be set to <code>3</code>, and in a fourth, it must be set to <code>4</code>. Also, you must set a <b>ruleOrder</b> value in each <b>discountRules</b> container. In the first container, <b>discountRules</b> must be set to <code>1</code>, and in each subsequent container, the value be be incremented by 1. For more, see <a href="/api-docs/sell/static/marketing/pm-volume-discounts.html" target="_blank">Configuring volume pricing discounts</a>.</p> <p class="tablenote"><b>Tip:</b> see <a href="/api-docs/sell/static/marketing/pm-specifying-discounts.html" target="_blank">Configuring discounts for threshold promotions</a> for information and examples on how to combine <b>discountBenefit</b> and <b>discountSpecification</b> to create different types of promotions.</p>',
)
maxDiscountAmount: Optional[Amount] = Field(
None,
description='The limit on how much a buyer can save using a <code>CODED_COUPON</code> promotion type. Permitted values are 1-1000. Supported currency codes include USD, GBP, EUR, and AUD. <p class="tablenote"><b>Note:</b> The Currency Code for \'maxDiscountAmount\' must be the same as the Currency Code for \'budget\'.</p>',
)
ruleOrder: Optional[int] = Field(
None,
description='This field indicates the order in which the <b>discountRules</b> are presented. The value specified for this field must equal the associated <b>minQuantity</b> value. <br><br><i>Required if </i> you are creating a volume pricing promotion.',
)
class Error(BaseModel):
category: Optional[str] = Field(
None,
description='The category type for this error or warning. It takes an ErrorCategory object which can have one of three values:<ul><li><code>Application</code>: Indicates an exception or error occurred in the application code or at runtime. Examples include catching an exception in a service\'s business logic, system failures, or request errors from a dependency.</li><li><code>Business</code>: Used when your service or a dependent service refused to continue processing on the resource because of a business rule violation such as "Seller does not ship item to Antarctica" or "Buyer ineligible to purchase an alcoholic item". Business errors are not syntactical input errors.</li><li><code>Request</code>: Used when there is anything wrong with the request, such as authentication, syntactical errors, rate limiting or missing headers, bad HTTP header values, and so on.</li></ul>',
)
domain: Optional[str] = Field(
None, description='Name of the domain containing the service or application.'
)
errorId: Optional[int] = Field(
None,
description='A positive integer that uniquely identifies the specific error condition that occurred. Your application can use error codes as identifiers in your customized error-handling algorithms.',
)
inputRefIds: Optional[List[str]] = Field(
None,
description="Identifies specific request elements associated with the error, if any. inputRefId's response is format specific. For JSON, use <i>JSONPath</i> notation.",
)
longMessage: Optional[str] = Field(
None,
description='An expanded version of message that should be around 100-200 characters long, but is not required to be such.',
)
message: Optional[str] = Field(
None,
description="An end user and app developer friendly device agnostic message. It explains what the error or warning is, and how to fix it (in a general sense). Its value is at most 50 characters long. If applicable, the value is localized in the end user's requested locale.",
)
outputRefIds: Optional[List[str]] = Field(
None,
description='Identifies specific response elements associated with the error, if any. Path format is the same as <code>inputRefId</code>.',
)
parameters: Optional[List[ErrorParameter]] = Field(
None,
description='This optional complex field type contains a list of one or more context-specific <code>ErrorParameter</code> objects, with each item in the list entry being a parameter (or input field name) that caused an error condition. Each <code>ErrorParameter</code> object consists of two fields, a <code>name</code> and a <code>value</code>.',
)
subdomain: Optional[str] = Field(
None,
description="Name of the domain's subsystem or subdivision. For example, checkout is a subdomain in the buying domain.",
)
class ItemsPagedCollection(BaseModel):
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
limit: Optional[int] = Field(
None,
description='The number of items returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.',
)
listings: Optional[List[ListingDetail]] = Field(
None, description='An array of the listings associated with a promotion.'
)
next: Optional[str] = Field(
None,
description='The URI for the following page of results. This value is returned only if there is an additional page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first returned result. This value can be set in the request with the <b>offset</b> query parameter. <p class="tablenote"><strong>Note: </strong>The items in a paginated result set use a zero-based list where the first item in the list has an offset of <code>0</code>.</p>',
)
prev: Optional[str] = Field(
None,
description='The URI for the preceding page of results. This value is returned only if there is a previous page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
total: Optional[int] = Field(
None,
description='The total number of items retrieved in the result set. <br><br>If no items are found, this field is returned with a value of <code>0</code>.',
)
warnings: Optional[List[Error]] = Field(
None,
description='A list of warnings that were generated by the request. Warning do not stop processing, but should be checked to ensure that the response contains the correct information.',
)
class KeywordResponse(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='The identifier of the ad group that the keyword was added to.',
)
errors: Optional[List[Error]] = Field(
None,
description='This container will be returned if there is an issue creating the corresponding keyword and/or adding that keyword to the corresponding ad group.',
)
href: Optional[str] = Field(
None,
description='The getKeyword URI for the keyword, which is used to retrieve the keyword. This URI will be returned for each successfully created keyword.',
)
keywordId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a keyword that is generated for an ad group. This keyword ID will be generated for each successfully created keyword.',
)
keywordText: Optional[str] = Field(None, description='The text of the keyword.')
matchType: Optional[str] = Field(
None,
description="A field that defines the match type for the keyword.<br /><br /><b>Valid Values:</b><ul><li><code>BROAD</code></li><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:MatchTypeEnum'>eBay API documentation</a>",
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code is returned for each keyword to indicate the success or failure of adding that keyword to the ad group.',
)
class NegativeKeywordResponse(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='A unique identifier for an ad group that is generated when an ad group is first created and associated with a campaign.',
)
campaignId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a campaign. This ID is generated when a campaign is created.',
)
errors: Optional[List[Error]] = Field(
None,
description='This container will be returned if there is an issue creating the corresponding negative keyword.',
)
href: Optional[str] = Field(
None,
description='The URI for the negative keyword, which is used to retrieve the negative keyword. This URI will be returned for each successfully created negative keyword.',
)
negativeKeywordId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a negative keyword. This negative keyword ID will be generated for each successfully created negative keyword.',
)
negativeKeywordMatchType: Optional[str] = Field(
None,
description='The match type for the negative keyword.<br /><br /><span class="tablenote"><span style="color:#004680"><strong>Note:</strong></span> Broad matching of negative keywords is not currently supported.</span><br /><b>Valid Values:</b><ul><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/pls:NegativeKeywordMatchTypeEnum\'>eBay API documentation</a>',
)
negativeKeywordText: Optional[str] = Field(
None, description='The text for the negative keyword.'
)
statusCode: Optional[int] = Field(
None,
description='The status of the request to create a negative keyword. This field indicates whether the process was successful or not.',
)
class RuleCriteria(BaseModel):
excludeInventoryItems: Optional[List[InventoryItem]] = Field(
None,
description='A list of seller inventory reference IDs to exclude from the promotion. <br><br><p class="tablenote"><b>Note:</b> The request can have either <b>excludeInventoryItems</b> or <b>excludeListingIds</b> but not both.</p> <b>Maximum:</b> 100 parent items <br><b>Maximum SKU or custom label length:</b> 50 characters',
)
excludeListingIds: Optional[List[str]] = Field(
None,
description='A list of eBay listing IDs to exclude from the promotion. <br><br><p class="tablenote"><b>Note:</b> The request can have either <b>excludeInventoryItems</b> or <b>excludeListingIds</b> but not both.</p> <b>Maximum:</b> 100 parent items <br><b>Maximum SKU or custom label length:</b> 50 characters',
)
markupInventoryItems: Optional[List[InventoryItem]] = Field(
None,
description="A list of SKUs to remove from a markdown promotion. The listed SKUs are 'marked up' to their standard price after being part of the markdown promotion.",
)
markupListingIds: Optional[List[str]] = Field(
None,
description="A list of listing IDs to remove from a markdown promotion. The listed items are 'marked up' to their standard price after being part of the markdown promotion.",
)
selectionRules: Optional[List[SelectionRule]] = Field(
None,
description='The container for the rules that select the items to include in a promotion. <br><br><i>Required if </i> <b>inventoryCriterionType</b> is set to <code>INVENTORY_BY_RULE</code>.',
)
class SuggestedKeywords(BaseModel):
additionalInfo: Optional[List[AdditionalInfo]] = Field(
None,
description='A container for the additional information and compiled insight data for suggested keywords. ',
)
keywordText: Optional[str] = Field(None, description='The text for the keyword.')
matchType: Optional[str] = Field(
None,
description="A field that defines the match type for the keyword.<br /><br /><b>Valid Values:</b><ul><li><code>BROAD</code></li><li><code>EXACT</code></li><li><code>PHRASE</code></li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:MatchTypeEnum'>eBay API documentation</a>",
)
class TargetedAdsPagedCollection(BaseModel):
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
limit: Optional[int] = Field(
None,
description='The number of items returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.',
)
next: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the next page in the result set. This value is returned only if there is an additional page of results to display from the result set.',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first returned result. This value can be set in the request with the <b>offset</b> query parameter. <p><b>Default:</b> 0</p><br><span class="tablenote"><b>Note: </b>The items in a paginated result set use a zero-based list, where the first item in the list has an offset of <code>0</code>.</span>',
)
prev: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the previous page in the result set. Basically, all of the request parameters will remain the same except the offset value, which will be decreased to retrieve the previous page of results.',
)
suggestedItems: Optional[List[TargetingItems]] = Field(
None, description='A list of suggested items in the paginated collection.'
)
total: Optional[int] = Field(
None,
description='The total number of items retrieved in the result set.<br /><br /><span class="tablenote"><b>Note: </b>If no items are found, this field is returned with a value of <code>0</code>.</span>',
)
class TargetedKeywordsPagedCollection(BaseModel):
suggestedKeywords: Optional[List[SuggestedKeywords]] = Field(
None,
description='A list of suggested keywords in the paged collection. <p> <span class="tablenote"><strong>Note:</strong> A relevancy check with items already present in the ad-group is performed even if item IDs associated with the ad-group are not explicitly passed in the request.</span></p> ',
)
class UpdateAdsByInventoryReferenceResponse(BaseModel):
ads: Optional[List[AdReference]] = Field(
None, description='A list of ad IDs and links to retrieve them.'
)
errors: Optional[List[Error]] = Field(
None,
description='A container for all of the errors associated with the specified inventory reference ID.',
)
inventoryReferenceId: Optional[str] = Field(
None,
description='The reference ID associated with the ad. The reference ID could be a SKU number or Inventory Item Group, depending on value of <code>inventoryReferenceType</code>.',
)
inventoryReferenceType: Optional[str] = Field(
None,
description="The inventory reference type associated with the ad. The inventory reference type could be a SKU number or Inventory Item Group. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:InventoryReferenceTypeEnum'>eBay API documentation</a>",
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code that indicates whether or not the CPS ad was successfully updated.',
)
class UpdateKeywordResponse(BaseModel):
errors: Optional[List[Error]] = Field(
None,
description='This container will be returned if there are one or more issues associated with modifying the corresponding keyword.',
)
keywordId: Optional[str] = Field(
None,
description='This field identifies the keyword that the seller updated, or attempted to update.',
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code is returned for each keyword to indicate the success or failure of updating that keyword.',
)
class UpdateNegativeKeywordResponse(BaseModel):
errors: Optional[List[Error]] = Field(
None,
description='A container that will be returned if there are one or more issues associated with modifying the corresponding negative keyword.',
)
negativeKeywordId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a negative keyword. This keyword ID will be generated for each successfully created negative keyword.',
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code that indicates the success or failure of updating that negative keyword.',
)
class AdResponse(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for an ad group in a Promoted Listings Advanced (PLA) campaign that uses the Cost Per Click (CPC) funding model.<span class="tablenote"><b>Note:</b> This field will always be returned for campaigns that use the CPC funding model. It will not be returned for campaigns that use the Cost Per Sale (CPS) funding model.</span>',
)
adId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for an ad. This ID is generated when an ad is created.<span class="tablenote"><b>Note:</b>This field is only returned when an ad is successfully created for the corresponding listing.</span>',
)
errors: Optional[List[Error]] = Field(
None, description='An array of errors associated with the request.'
)
href: Optional[str] = Field(
None,
description='The getAd URI that points to the ad.<span class="tablenote"><b>Note:</b>This field is only returned when an ad is successfully created for the corresponding listing.</span>',
)
listingId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a listing that is generated when the listing is created.',
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code indicating if the corresponding ad was successfully created or not. <code>200 Successful</code> should be returned for successfully created ads.<span class="tablenote"><b>Note:</b>A status code is returned for each ad that the seller creates, or attempts to create.</span>',
)
class AdUpdateResponse(BaseModel):
adId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID that is generated when the ad is created.',
)
errors: Optional[List[Error]] = Field(
None, description='A list of errors associated with the specified listing ID.'
)
href: Optional[str] = Field(
None, description='The URI for the ad, which can be used to retrieve the ad.'
)
listingId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID that is generated when the listing is created.',
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code that indicates the response-status of the request.',
)
class AdUpdateStatusByListingIdResponse(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for an ad group in a campaign that uses the Cost Per Click (CPC) funding model.',
)
errors: Optional[List[Error]] = Field(
None, description='A list of errors associated with the specified listing ID.'
)
href: Optional[str] = Field(
None, description='The URI for the ad, which can be used to retrieve the ad.'
)
listingId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID that is generated when the listing is created.',
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code that indicates the response-status of the request.',
)
class AdUpdateStatusResponse(BaseModel):
adId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID that is generated when the ad is created.',
)
errors: Optional[List[Error]] = Field(
None, description='A list of errors associated with the specified listing ID.'
)
href: Optional[str] = Field(
None, description='The URI for the ad, which can be used to retrieve the ad.'
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code that indicates the response-status of the request.',
)
class Alert(BaseModel):
alertType: Optional[str] = Field(
None,
description="The type of alert message. For example, an invalid bid percentage. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:AlertTypeEnum'>eBay API documentation</a>",
)
details: Optional[List[AlertDetails]] = Field(
None, description='A description of the alert including dimensions and aspects.'
)
class BaseResponse(BaseModel):
warnings: Optional[List[Error]] = Field(
None,
description='The container for any warning error messages generated by the request. Warnings are not fatal in that they do not prevent the call from running and returning a response, but they should be reviewed to ensure your requests are returning the responses you expect.',
)
class BulkAdResponse(BaseModel):
responses: Optional[List[AdResponse]] = Field(
None,
description='This array displays the list of ads that were successfully created. For any ads that were not created successfully, the errors array may provide more detail about why creation of one or more ads failed.',
)
class BulkAdUpdateResponse(BaseModel):
responses: Optional[List[AdUpdateResponse]] = Field(
None, description='A set of ad listings processed by the call.'
)
class BulkAdUpdateStatusByListingIdResponse(BaseModel):
responses: Optional[List[AdUpdateStatusByListingIdResponse]] = Field(
None, description='An array of processed ad listings in bulk.'
)
class BulkAdUpdateStatusResponse(BaseModel):
responses: Optional[List[AdUpdateStatusResponse]] = Field(
None, description='An array of processed ad listings in bulk.'
)
class BulkCreateKeywordResponse(BaseModel):
responses: Optional[List[KeywordResponse]] = Field(
None, description='A list of keywords that have been processed by the request.'
)
class BulkCreateNegativeKeywordResponse(BaseModel):
responses: Optional[List[NegativeKeywordResponse]] = Field(
None,
description='A list of negative keywords that have been processed by the request.',
)
class BulkUpdateAdsByInventoryReferenceResponse(BaseModel):
responses: Optional[List[UpdateAdsByInventoryReferenceResponse]] = Field(
None,
description='A list of inventory references that were processed from the request.',
)
class BulkUpdateKeywordResponse(BaseModel):
responses: Optional[List[UpdateKeywordResponse]] = Field(
None,
description='A list of keywords that have been processed from the bulk request.',
)
class BulkUpdateNegativeKeywordResponse(BaseModel):
responses: Optional[List[UpdateNegativeKeywordResponse]] = Field(
None,
description='A list of negative keywords that have been processed from the bulk request.',
)
class Campaign(BaseModel):
alerts: Optional[List[Alert]] = Field(
None, description='This array contains alert messages for the campaign.'
)
budget: Optional[CampaignBudget] = Field(
None,
description='The allocated budget for the Cost Per Click (CPC) Promoted Listings campaign.<span class="tablenote"><b>Note:</b> This field will only be returned for campaigns using the CPC funding model; it does not apply to the Cost Per Sale (CPS) funding model.</span>',
)
campaignCriterion: Optional[CampaignCriterion] = Field(
None,
description='The selection rules (criterion) used to select the listings for a campaign. If you populate the <b>campaignCriterion</b> object in your <b>createCampaign</b> request, ads for the campaign are created by rule for the listings that meet the criteria you specify, and these ads are associated with the campaign.<span class="tablenote"><b>Note:</b> This container is only returned for rules-based campaigns using the Cost Per Sale (CPS) funding model.</span>',
)
campaignId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a campaign. This ID is generated when a campaign is created.',
)
campaignName: Optional[str] = Field(
None,
description='A seller-defined name for the campaign. This value must be unique for the seller. <p>You can use any alphanumeric characters in the name, except the less than (<) or greater than (>) characters.</p><b>Max length: </b>80 characters',
)
campaignStatus: Optional[str] = Field(
None,
description="Indicates the status of the campaign, such as <code>RUNNING</code>, <code>PAUSED</code>, and <code>ENDED</code>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:CampaignStatusEnum'>eBay API documentation</a>",
)
endDate: Optional[str] = Field(
None,
description='The date and time the campaign ends, in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). If this field is omitted, the campaign will have no defined end date, and will not end until the seller makes a decision to end the campaign with an <a href="/api-docs/sell/marketing/resources/campaign/methods/endCampaign">endCampaign</a> call, or if they update the campaign at a later time with an end date.',
)
fundingStrategy: Optional[FundingStrategy] = Field(
None,
description='This container shows the funding model used for the campaign, and the default bid percentage for a campaign that uses the Cost Per Sale (CPS) funding model. <p>Currently, the supported funding models are <code>COST_PER_SALE</code> and <code>COST_PER_CLICK</code>.',
)
marketplaceId: Optional[str] = Field(
None,
description="The ID of the eBay marketplace where the campaign is hosted. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/ba:MarketplaceIdEnum'>eBay API documentation</a>",
)
startDate: Optional[str] = Field(
None,
description='The date and time the campaign starts, in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller. <p>On the date specified, the service derives the keywords for each listing in the campaign, creates an ad for each listing, and associates each new ad with the campaign. The campaign starts after this process is completed. The amount of time it takes the service to start the campaign depends on the number of listings in the campaign. Call <a href="/api-docs/sell/marketing/resources/campaign/methods/getCampaign">getCampaign</a> to check the status of the campaign.</p>',
)
class CampaignPagedCollectionResponse(BaseModel):
campaigns: Optional[List[Campaign]] = Field(
None,
description="This array contains all of the seller's campaign that match the request criteria.",
)
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
limit: Optional[int] = Field(
None,
description='The number of items returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.',
)
next: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the next page in the result set. This value is returned only if there is an additional page of results to display from the result set. <br><br><b>Max length</b>: 2048',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first returned result. This value can be set in the request with the <b>offset</b> query parameter. <p class="tablenote"><strong>Note: </strong>The items in a paginated result set use a zero-based list where the first item in the list has an offset of <code>0</code>.</p>',
)
prev: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the previous page in the result set. Basically, all of the request parameters will remain the same except the offset value, which will be decreased to retrieve the previous page of results. <br><br><b>Max length</b>: 2048',
)
total: Optional[int] = Field(
None,
description='The total number of campaigns retrieved in the result set. <br><br>If no campaigns are found, this field is returned with a value of <code>0</code>.',
)
class Campaigns(BaseModel):
campaigns: Optional[List[Campaign]] = Field(
None,
description='This is an array of one or campaigns that match the listing or inventory item group specified in the request.',
)
class CreateAdsByInventoryReferenceResponse(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for an ad group in a Promoted Listings Advanced (PLA) campaign that uses the Cost Per Click (CPC) funding model.<span class="tablenote"><b>Note:</b> This field will always be returned for campaigns that use the CPC funding model. It will not be returned for campaigns that use the Cost Per Sale (CPS) funding model.</span>',
)
ads: Optional[List[AdReference]] = Field(
None,
description='A list of ad IDs. An ad ID is generated for each successfully created ad.',
)
errors: Optional[List[Error]] = Field(
None,
description='An array of errors or warnings associated with the create-ads request.',
)
inventoryReferenceId: Optional[str] = Field(
None,
description='An ID that identifies a single-item listing or multiple-variation listing that is managed with the <a href="/api-docs/sell/inventory/resources/methods" title="Inventory API Reference">Inventory API</a>. <p>The <i>inventory reference ID</i> is a seller-defined value that can be either an <b>SKU</b> for a single-item listing or an <b>inventoryItemGroupKey</b> for a multiple-value listing.</p>',
)
inventoryReferenceType: Optional[str] = Field(
None,
description="Indicates the type of item the <b>inventoryReferenceId</b> references. The item can be either an <code>INVENTORY_ITEM</code> or <code>INVENTORY_ITEM_GROUP</code>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:InventoryReferenceTypeEnum'>eBay API documentation</a>",
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code that indicates the response-status of the request. Check this code to see if the ads were successfuly created.',
)
class DeleteAdResponse(BaseModel):
adId: Optional[str] = Field(
None,
description='The unique identifier of the ad that was deleted, or the ad that the seller attempted to delete.',
)
errors: Optional[List[Error]] = Field(
None,
description='An array of the errors or warnings associated with the request.',
)
listingId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for a listing that is generated when the listing is created.',
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code that indicates the response-status of the request. Check this code to see if the ad was successfully deleted.<span class="tablenote"><b>Note:</b>A status code is returned for each ad that the seller deletes, or attempts to delete.</span>',
)
class DeleteAdsByInventoryReferenceResponse(BaseModel):
adIds: Optional[List[str]] = Field(
None,
description='The unique identifier of the ad that was deleted, or the ad that the seller attempted to delete.<span class="tablenote"><b>Note:</b>Although the field name is plural and it is an array, only one ad ID will be returned here since there can be only one ad per listing.</span>',
)
errors: Optional[List[Error]] = Field(
None, description='The container for the errors associated with the request.'
)
inventoryReferenceId: Optional[str] = Field(
None,
description='The inventory reference ID is a seller-defined SKU value for a single-item listing, or a seller-defined identifier for an inventory item group. Both of these values are defined when using the Inventory API, and an inventory item group is used to create a multiple-variation listing.',
)
inventoryReferenceType: Optional[str] = Field(
None,
description="The enumeration value returned here indicates if the ad was for a single-variation listing or a multiple-variation listing. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:InventoryReferenceTypeEnum'>eBay API documentation</a>",
)
statusCode: Optional[int] = Field(
None,
description='An HTTP status code indicating if the corresponding ad was successfully deleted or not. <code>200 Successful</code> should be returned for successfully deleted ads. <span class="tablenote"><b>Note:</b>A status code is returned for each ad that the seller deletes, or attempts to delete.</span>',
)
class InventoryCriterion(BaseModel):
inventoryCriterionType: Optional[str] = Field(
None,
description="Indicates how the items to include in the promotion are selected. You can include inventory by ID, using rules, or globally include all your inventory. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:InventoryCriterionEnum'>eBay API documentation</a>",
)
inventoryItems: Optional[List[InventoryItem]] = Field(
None,
description='An array of containers for the seller\'s inventory reference IDs (also known as an "SKU" or "custom label") to be added to the promotion. <p class="tablenote"><b>Note:</b> The request can have either <b>inventoryItems</b> or <b>listingIds</b>, but not both.</p> <br><br><b>Required:</b> All listings in a promotion must offer an electronic payment method. <br><b>Maximum:</b> 500 parent items <br><b>Maximum SKU or custom label length:</b> 50 characters <br><br><i>Required if </i> <b>InventoryCriterionType</b> is set to <code>INVENTORY_BY_VALUE</code>, you must specify either <b>inventoryItems</b> or <b>listingIds</b>.',
)
listingIds: Optional[List[str]] = Field(
None,
description='An array of eBay listing IDs to be added to the promotion. <p class="tablenote"><b>Note:</b> The request can have either <b>inventoryItems</b> or <b>listingIds</b>, but not both.</p> <br><br><b>Required:</b> All listings in a promotion must offer an electronic payment method. <br><b>Maximum:</b> 500 parent items <br><b>Maximum SKU or custom label length:</b> 50 characters <br><br><i>Required if </i> <b>InventoryCriterionType</b> is set to <code>INVENTORY_BY_VALUE</code>, you must specify either <b>inventoryItems</b> or <b>listingIds</b>.',
)
ruleCriteria: Optional[RuleCriteria] = Field(
None,
description='This container defines a set of inventory selection rules for a promotion. <br><br>When defining rule criteria, you must limit item exclusions to 100 IDs when you choose from live inventory. <br><br>Required if <b>InventoryCriterionEnum</b> is set to <code>INVENTORY_BY_RULE</code> or <code>INVENTORY_ANY</code>.',
)
class ItemPromotion(BaseModel):
applyDiscountToSingleItemOnly: Optional[bool] = Field(
None,
description='This flag is relevant in only when <b>promotionType</b> is set to <code>VOLUME_DISCOUNT</code>. For details on volume pricing promotions, see <a href="/api-docs/sell/static/marketing/pm-volume-discounts.html">Configuring volume pricing discounts</a>. <br><br>If set to <code>true</code>, the discount is applied only when the buyer purchases multiple quantities of a single item in the promotion. Otherwise, the promotional discount applies to multiple quantities of any items in the promotion. Different variations of a multi-variation item are considered to be the same item. Note that this flag is not relevant if the <b>inventoryCriterion</b> container identifies a single listing ID for the promotion.',
)
budget: Optional[Amount] = Field(
None,
description='This sets the budget for the <code>CODED_COUPON</code> promotion type. Supported values range from 100-1000000. Supported currency codes include USD, GBP, EUR, and AUD. <p class="tablenote"><b>Note:</b> The budget value for an active or paused promotion can not be decreased.</p> <p class="tablenote"><b>Note:</b> The Currency Code for \'budget\' must be the same as the Currency Code for \'maxDiscountAmount\'.</p>',
)
couponConfiguration: Optional[CouponConfiguration] = Field(
None, description='The configuration of a coded coupon promotion.'
)
description: Optional[str] = Field(
None,
description='This is the seller-defined "tag line" for the offer, such as "Save on designer shoes." <br><br>The tag line appears under the "offer-type text" that is generated for the promotion and is displayed on the offer tile that\'s shown on the seller\'s <b>All Offers</b> page, and on the event page for the promotion. <p class="tablenote"><b>Note:</b> Offer-type text is a teaser that\'s presented throughout the buyer\'s journey through the sales flow and is generated by eBay. The offer-type text is not editable by the seller—it\'s derived from the settings in the <b>discountRules</b> and <b>discountSpecification</b> fields—and can be, for example, "Extra 20% off when you buy 3+".</p> <br><b>Maximum length:</b> 50 <br><br><i>Required if</i> you are configuring CODED_COUPON, ORDER_DISCOUNT, or MARKDOWN_SALE promotions (and not valid for VOLUME_DISCOUNT promotions).',
)
discountRules: Optional[List[DiscountRule]] = Field(
None,
description='This container defines a promotion using the following two required fields: <ul><li><b>discountBenefit</b> – Defines a discount as either a monetary amount or a percentage that is subtracted from the sales price of an item, a set of items, or an order.</li> <li><b>discountSpecification</b> – Defines a set of rules that determine when the promotion is applied.</li></ul> <p class="tablenote"><b>Note:</b> For volume pricing, you must specify at least two and not more than four <b>discountBenefit</b>/<b>discountSpecification</b> pairs. In addition, you must define each set of rules with a <b>ruleOrder</b> value that corresponds with the order of volume discounts you present.</p> <p><b>Tip:</b> Refer to <a href="/api-docs/sell/static/marketing/pm-specifying-discounts.html">Specifying item promotion discounts</a> for information and examples on how to combine <b>discountBenefit</b> and <b>discountSpecification</b> to create different types of promotions.</p>',
)
endDate: Optional[str] = Field(
None,
description='The date and time the promotion ends in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller.',
)
inventoryCriterion: Optional[InventoryCriterion] = Field(
None,
description='A container that defines either the listing IDs or the selection rules that specify the items to include in the promotion. Listing IDs can be either eBay listing IDs or a list of the seller\'s inventory reference IDs (know as SKUs or custom labels). See the <b>selectionRules</b> container for the rule criteria you can use to select inventory. <p class="tablenote"><b>Note:</b> All listings in Promotions Manager promotions must support an electronic payment method.</p>',
)
marketplaceId: Optional[str] = Field(
None,
description="The eBay marketplace ID of the site where the threshold promotion is hosted. Threshold promotions are currently supported on a limited number of eBay marketplaces. <p><b>Valid values:</b></p> <ul><li><code>EBAY_AU</code> = Australia</li> <li><code>EBAY_DE</code> = Germany</li> <li><code>EBAY_ES</code> = Spain</li> <li><code>EBAY_FR</code> = France</li> <li><code>EBAY_GB</code> = Great Britain</li> <li><code>EBAY_IT</code> = Italy</li> <li><code>EBAY_US</code> = United States</li></ul> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/ba:MarketplaceIdEnum'>eBay API documentation</a>",
)
name: Optional[str] = Field(
None,
description='The seller-defined name or "title" of the promotion that the seller can use to identify a promotion. This label is not displayed in end-user flows. <br><br><b>Maximum length:</b> 90',
)
priority: Optional[str] = Field(
None,
description="Applicable for only <b>ORDER_DISCOUNT</b> promotions, this field indicates the precedence of the promotion, which is used to determine the position of a promotion on the seller's <b>All Offers</b> page. If an item is associated with multiple promotions, the promotion with the higher priority takes precedence. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionPriorityEnum'>eBay API documentation</a>",
)
promotionImageUrl: Optional[str] = Field(
None,
description="Required for CODED_COUPON, MARKDOWN_SALE, and ORDER_DISCOUNT promotions, and not valid for VOLUME_DISCOUNT promotions. <br><br>Populate this field with a URL that points to an image to be used with the promotion. This image is displayed on the seller's <b>All Offers</b> page. The URL must point to either JPEG or PNG image and it must be a minimum of 500x500 pixels in dimension and cannot exceed 12Mb in size.",
)
promotionStatus: Optional[str] = Field(
None,
description="The current status of the promotion. When creating a new promotion, this value must be set to either <code>DRAFT</code> or <code>SCHEDULED</code>. <br><br>Note that you must set this value to <code>SCHEDULED</code> when you update a <b>RUNNING</b> promotion. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionStatusEnum'>eBay API documentation</a>",
)
promotionType: Optional[str] = Field(
None,
description='Use this field to specify the type of the promotion you are creating. <p>The supported types are:</p> <ul><li><code>CODED_COUPON</code> – A coupon code promotion set with <b>createItemPromotion</b>.</li> <li><code>MARKDOWN_SALE</code> – A markdown promotion set with <b>createItemPriceMarkdownPromotion</b>.</li> <li><code>ORDER_DISCOUNT</code> – A threshold promotion set with <b>createItemPromotion</b>.</li> <li><code>VOLUME_DISCOUNT</code> – A volume pricing promotion set with <b>createItemPromotion</b>.</li></ul> <p>See the <a href="/api-docs/sell/static/marketing/promotions-manager.html" target="_blank">Promotions Manager</a> documentation for details.</p> <p><i>Required if </i> you are creating a volume pricing promotion (<code>VOLUME_DISCOUNT</code>).</p> For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionTypeEnum\'>eBay API documentation</a>',
)
startDate: Optional[str] = Field(
None,
description='The date and time the promotion starts in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller.',
)
class ItemPromotionResponse(BaseModel):
applyDiscountToSingleItemOnly: Optional[bool] = Field(
None,
description='If set to <code>true</code>, the discount is applied only when the buyer purchases multiple quantities of a single item in the promotion. Otherwise, the promotional discount applies to multiple quantities of any items in the promotion. Different variations of a multi-variation item are considered to be the same item. Note that this flag is not relevant if the <b>inventoryCriterion</b> container identifies a single listing ID for the promotion.',
)
budget: Optional[Amount] = Field(
None,
description='This sets the budget for the <code>CODED_COUPON</code> promotion type. Supported values range from 100-1000000. Supported currency codes include USD, GBP, EUR, and AUD. <p class="tablenote"><b>Note:</b> The budget value for an active or paused promotion can not be decreased.</p> <p class="tablenote"><b>Note:</b> The Currency Code for \'budget\' must be the same as the Currency Code for \'maxDiscountAmount\'.</p>',
)
couponConfiguration: Optional[CouponConfiguration] = Field(
None, description='The configuration of a coded coupon promotion.'
)
description: Optional[str] = Field(
None,
description='Required for CODED_COUPON promotions, this is the seller-defined "tag line" for the offer, such as "Save on designer shoes." The tag line appears under the "offer-type text" that is generated for the promotion and is displayed under the offer tile that is shown on the seller\'s <b>All Offers</b> page and on the event page for the promotion. This tag line is not used with volume pricing promotions. <p class="tablenote"><b>Note:</b> Offer-type text is a teaser that\'s presented throughout the buyer\'s journey through the sales flow and is generated by eBay. This text is not editable by the seller—it\'s derived from the settings in the <b>discountRules</b> and <b>discountSpecification</b> fields—and can be, for example, "Extra 20% off when you buy 3+".</p> <br><b>Maximum length:</b> 50',
)
discountRules: Optional[List[DiscountRule]] = Field(
None,
description='A list containing the promotion benefits (<b>discountRule</b>) and the rules that define when the benefit is applied (<b>discountSpecification</b>).',
)
endDate: Optional[str] = Field(
None,
description='The date and time the promotion ends in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller.',
)
inventoryCriterion: Optional[InventoryCriterion] = Field(
None,
description="Returns either an array of listing IDs or the selection rules used to specify the items included in the promotion. Listing IDs can be either eBay listing IDs or an array of seller's inventory reference IDs (know as SKUs or custom labels). See the <b>selectionRules</b> container for the rule criteria you can use to select inventory.",
)
marketplaceId: Optional[str] = Field(
None,
description='The eBay marketplace ID of the site where the threshold promotion is hosted. Threshold promotions are currently supported on a limited number of eBay marketplaces. <p><b>Valid values:</b></p> <ul class="compact"><li><code>EBAY_AU</code> = Australia</li> <li><code>EBAY_DE</code> = Germany</li> <li><code>EBAY_ES</code> = Spain</li> <li><code>EBAY_FR</code> = France</li> <li><code>EBAY_GB</code> = Great Britain</li> <li><code>EBAY_IT</code> = Italy</li> <li><code>EBAY_US</code> = United States</li></ul> For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/ba:MarketplaceIdEnum\'>eBay API documentation</a>',
)
name: Optional[str] = Field(
None,
description='The seller-defined name or "title" of the promotion that the seller can use to identify a promotion. This label is not displayed in end-user flows. <br><br><b>Maximum length:</b> 90',
)
priority: Optional[str] = Field(
None,
description="Applicable for only <b>ORDER_DISCOUNT</b> promotions, this field indicates the precedence of the promotion, which eBay uses to determine the position of a promotion on the seller's <b>All Offers</b> page. If an item is associated with multiple promotions, the promotion with the higher priority takes precedence. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionPriorityEnum'>eBay API documentation</a>",
)
promotionId: Optional[str] = Field(
None,
description="A unique eBay-assigned ID for the promotion that's generated when the promotion is created.",
)
promotionImageUrl: Optional[str] = Field(
None,
description="Required for CODED_COUPON, MARKDOWN_SALE, and ORDER_DISCOUNT promotions, and not applicable for <b>VOLUME_DISCOUNT</b> promotions, this field is a URL that points to an image for the promotion. This image is displayed on the seller's <b>All Offers</b> page. The URL must point to either JPEG or PNG image and it must be a minimum of 500x500 pixels in dimension and cannot exceed 12Mb in size.",
)
promotionStatus: Optional[str] = Field(
None,
description="The current status of the promotion. When creating a new promotion, this value must be set to either <code>DRAFT</code> or <code>SCHEDULED</code>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionStatusEnum'>eBay API documentation</a>",
)
promotionType: Optional[str] = Field(
None,
description="Indicates the type of the promotion, either <code>CODED_COUPON</code>, <code>MARKDOWN_SALE</code>, <code>ORDER_DISCOUNT</code>, or <code>VOLUME_DISCOUNT</code>. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionTypeEnum'>eBay API documentation</a>",
)
startDate: Optional[str] = Field(
None,
description='The date and time the promotion starts in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller.',
)
class SelectedInventoryDiscount(BaseModel):
discountBenefit: Optional[DiscountBenefit] = Field(
None,
description='This container defines the promotional discount as either a monetary amount or a percentage applied to the sales price.',
)
discountId: Optional[str] = Field(
None,
description='A unique, eBay-generated ID that you can use to identify the discount. This field is ignored in POST and PUT operations.',
)
inventoryCriterion: Optional[InventoryCriterion] = Field(
None,
description='A container that defines either the listing IDs or the selection rules that specify the items to include in the promotion. Listing IDs can be either eBay listing IDs or a list of the seller\'s inventory reference IDs (know as SKUs or custom labels). See the <b>selectionRules</b> container for the rule criteria you can use to select inventory. <p class="tablenote"><b>Note:</b> All listings in Promotions Manager promotions must support an electronic payment method.</p>',
)
ruleOrder: Optional[int] = Field(
None,
description='For markdown promotions, this field is reserved for future use. <!--This field specifies the precedence of this set of inventory criteria, which is taken into account if an item is selected for multiple discounts by different sets of criteria. The criteria with the highest priority (lowest ruleOrder value) takes precedence over criteria with a lower precedence.-->',
)
class Ad(BaseModel):
adGroupId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID for an ad group in a campaign that uses the Cost Per Click (CPC) funding model. This ID is created after a successful <a href="/api-docs/sell/marketing/resources/adgroup/methods/createAdGroup">createAdGroup</a> call, and all ad groups must be associated with a CPC campaign.',
)
adId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID that is generated when the ad is created.',
)
adStatus: Optional[str] = Field(
None,
description='The current status of the CPC ad.<br /><br /><b>Valid Values:</b><ul><li><code>ACTIVE</code></li><li><code>PAUSED</code></li><li><code>ARCHIVED</code></li></ul><span class="tablenote"><b>Note:</b> This type only applies to the Cost Per Click (CPC) funding model; it does not apply to the Cost Per Sale (CPS) funding model.</span> For implementation help, refer to <a href=\'https://developer.ebay.com/api-docs/sell/marketing/types/pls:AdStatusEnum\'>eBay API documentation</a>',
)
alerts: Optional[List[Alert]] = Field(
None, description='An array containing alert messages for the ad.'
)
bidPercentage: Optional[str] = Field(
None,
description='The user-defined <b>bid percentage</b> (also known as the <i>ad rate</i>) sets the level that eBay increases the visibility in search results for the associated listing. The higher the <b>bidPercentage</b> value, the more eBay promotes the listing. <br><br>The value specified here is also used to calculate the Promoted Listings fee. This percentage value is multiplied by the final sales price to determine the fee. <br><br>The Promoted Listings fee is determined at the time the transaction completes and the seller is assessed the fee only when an item sells through a Promoted Listings ad campaign. <br><br>The <b>bidPercentage</b> is a single precision value that is guided by the following rules: <ul><li>These values are <b>valid</b>:<br> <code>4.1</code>, <code>5.0</code>, <code>5.5</code>, ...</li> <li>These values are <b>not valid</b>:<br /> <code>0.01</code>, <code>10.75</code>, <code>99.99</code>,<br /> and so on.</li></ul>This is default bid percentage for the campaigns using the Cost Per Sale (CPS) funding model, and this value will be overridden by any ads in the campaign that have their own set bid percentages.<br /><br />If a bid percentage is not provided for an ad, eBay uses the default bid percentage of the associated campaign.<br /><br /><span class="tablenote"><b>Note:</b>This field will always be returned for campaigns that use the Cost Per Sale (CPS) funding model. It will not be returned for campaigns that use the Cost Per Click (CPC) funding model.</span><br /><b>Minimum value:</b> 2.0 <br><b>Maximum value:</b> 100.0',
)
inventoryReferenceId: Optional[str] = Field(
None,
description='An ID that identifies a single-item listing or multiple-variation listing that is managed with the <a href="/api-docs/sell/inventory/resources/methods" title="Inventory API Reference">Inventory API</a>. <p>The <i>inventory reference ID</i> is a seller-defined value that can be either an <b>SKU</b> for a single-item listing or an <b>inventoryItemGroupKey</b> for a multiple-value listing.</p> <p>An <i>inventoryItemGroupKey</i> is a value that the seller defines to indicate a listing that\'s the parent of an inventory item group (a multiple-variation listing, such as a listing for a shirt that\'s available in multiple sizes and colors).</p><p>This field is only returned if the ad is associated with a SKU or an inventory item group value.</p>',
)
inventoryReferenceType: Optional[str] = Field(
None,
description="The enumeration value returned here indicates the type of listing the inventoryReferenceId references. The value returned here will be <code>INVENTORY_ITEM</code> for a single-variation listing, or <code>INVENTORY_ITEM_GROUP</code> for a multiple-variation listing. <p>This field is only returned if the ad is associated with a SKU or an inventory item group value.</p> For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/pls:InventoryReferenceTypeEnum'>eBay API documentation</a>",
)
listingId: Optional[str] = Field(
None,
description='A unique eBay-assigned ID that is generated when a listing is created.',
)
class AdPagedCollectionResponse(BaseModel):
ads: Optional[List[Ad]] = Field(
None, description='The list of ads that matched the request criteria.'
)
href: Optional[str] = Field(
None, description='The URI of the current page of results from the result set.'
)
limit: Optional[int] = Field(
None,
description='The number of items returned on a single page from the result set. This value can be set in the request with the <b>limit</b> query parameter.<p><b>Default</b>: <code>10</code>',
)
next: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the next page in the result set. Basically, all of the request parameters will remain the same except the offset value, which will be increased to retrieve the next page of results. <br><br><b>Max length</b>: 2048',
)
offset: Optional[int] = Field(
None,
description='The number of results skipped in the result set before listing the first result on the current page. This value can be set in the request with the <b>offset</b> query parameter. If the <b>offset</b> value is not set, it defaults to zero.<p><b>Default</b>: <code>0</code></p><p class="tablenote"><strong>Note: </strong>The items in a paginated result set use a zero-based list where the first item in the list has an offset of <code>0</code>.</p>',
)
prev: Optional[str] = Field(
None,
description='The call URI that can be used to retrieve the previous page in the result set. Basically, all of the request parameters will remain the same except the offset value, which will be decreased to retrieve the previous page of results. <br><br><b>Max length</b>: 2048',
)
total: Optional[int] = Field(
None,
description='The total number of items retrieved in the result set. <br><br>If no items are found, this field is returned with a value of <code>0</code>.',
)
class Ads(BaseModel):
ads: Optional[List[Ad]] = Field(
None,
description='A list of ad IDs. An ad ID is generated for each successfully created ad.',
)
class BulkCreateAdsByInventoryReferenceResponse(BaseModel):
responses: Optional[List[CreateAdsByInventoryReferenceResponse]] = Field(
None,
description='This array displays the list of ads that were successfully created. For any ads that were not created successfully, the errors array may provide more detail about why creation of one or more ads failed.',
)
class BulkDeleteAdResponse(BaseModel):
responses: Optional[List[DeleteAdResponse]] = Field(
None,
description='An array of the ads that were deleted by the <b>bulkDeleteAdsByListingId</b> request, including information associated with each individual delete request.',
)
class BulkDeleteAdsByInventoryReferenceResponse(BaseModel):
responses: Optional[List[DeleteAdsByInventoryReferenceResponse]] = Field(
None,
description='An array of the ads that were deleted by the <b>bulkDeleteAdsByInventoryReference</b> request, including information associated with each individual delete request.',
)
class ItemPriceMarkdown(BaseModel):
applyFreeShipping: Optional[bool] = Field(
None,
description='If set to <code>true</code>, free shipping is applied to the first shipping service specified for the item. The first domestic shipping option is set to "free shipping," regardless if the shipping <b>optionType</b> for that service is set to <code>FLAT_RATE</code>, <code>CALCULATED</code>, or <code>NOT_SPECIFIED</code> (freight). This flag essentially adds free shipping as a promotional bonus. <br><br><b>Default:</b> <code>false</code>',
)
autoSelectFutureInventory: Optional[bool] = Field(
None,
description='If set to <code>true</code>, eBay will automatically add inventory items to the markdown promotion if they meet the <b>selectedInventoryDiscounts</b> criteria specified for the markdown promotion. <br><br><b>Default:</b> <code>false</code>',
)
blockPriceIncreaseInItemRevision: Optional[bool] = Field(
None,
description="If set to <code>true</code>, price increases (including removing the free shipping flag) are blocked and an error message is returned if a seller attempts to adjust the price of an item that's partaking in this markdown promotion. If set to <code>false</code>, an item is dropped from the markdown promotion if the seller adjusts the price. <br><br><b>Default:</b> <code>false</code>",
)
description: Optional[str] = Field(
None,
description='This field is required if you are configuring an MARKDOWN_SALE promotion. <br><br>This is the seller-defined "tag line" for the offer, such as "Save on designer shoes." A tag line appears under the "offer-type text" that is generated for the promotion. The text is displayed on the offer tile that is shown on the seller\'s <b>All Offers</b> page and on the event page for the promotion. <p class="tablenote"><b>Note:</b> Offer-type text is a teaser that\'s presented throughout the buyer\'s journey through the sales flow and is generated by eBay. This text is not editable by the seller—it\'s derived from the settings in the <b>discountRules</b> and <b>discountSpecification</b> fields—and can be, for example, "20% off".</p> <br><b>Maximum length:</b> 50',
)
endDate: Optional[str] = Field(
None,
description='The date and time the promotion ends, in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). The value supplied for <b>endDate</b> must be at least 24 hours after the value supplied for the <b>startDate</b> of the markdown promotion.<br><br>For display purposes, convert this time into the local time of the seller. <br><br><b>Max value:</b><ul><li><code>14</code> days for the AT, CH, DE, ES, FR, IE, IT, and UK, marketplaces.</li> <li><code>45</code> days for all other marketplaces.</li></ul>',
)
marketplaceId: Optional[str] = Field(
None,
description="The eBay marketplace ID of the site where the markdown promotion is hosted. Markdown promotions are supported on all eBay marketplaces. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/ba:MarketplaceIdEnum'>eBay API documentation</a>",
)
name: Optional[str] = Field(
None,
description="The seller-defined name or 'title' of the promotion that the seller can use to identify a promotion. This label is not displayed in end-user flows. <br><br><b>Maximum length:</b> 90",
)
priority: Optional[str] = Field(
None,
description="This field is ignored in markdown promotions. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionPriorityEnum'>eBay API documentation</a>",
)
promotionImageUrl: Optional[str] = Field(
None,
description="Required for CODED_COUPON, MARKDOWN_SALE, and ORDER_DISCOUNT promotions, populate this field with a URL that points to an image to be used with the promotion. This image is displayed on the seller's <b>All Offers</b> page. The URL must point to either JPEG or PNG image and it must be a minimum of 500x500 pixels in dimension and cannot exceed 12Mb in size.",
)
promotionStatus: Optional[str] = Field(
None,
description="The current status of the promotion. When creating a new promotion, you must set this value to either <code>DRAFT</code> or <code>SCHEDULED</code>. <br><br>Note that you must set this value to <code>SCHEDULED</code> when you update a <b>RUNNING</b> promotion. For implementation help, refer to <a href='https://developer.ebay.com/api-docs/sell/marketing/types/sme:PromotionStatusEnum'>eBay API documentation</a>",
)
selectedInventoryDiscounts: Optional[List[SelectedInventoryDiscount]] = Field(
None,
description='A list that defines the sets of selected items for the markdown promotion and the discount specified for promotion.',
)
startDate: Optional[str] = Field(
None,
description='The date and time the promotion starts in UTC format (<code>yyyy-MM-ddThh:mm:ssZ</code>). For display purposes, convert this time into the local time of the seller.',
)