AddItem
Creates and publishes a new item listing on an eBay site.
Stored Procedure-Specific Information
When an item listing is successfully created, the response includes the item Id and the estimated listing fees. After adding an item, you can use the ItemListing table to update, delete, and query.To add an item, the following inputs are required: Country, Currency, ListingDuration, and StartPrice. Title, Description, and CategoryId are required only if ProductReferenceId or a pair of Brand and BrandMPN is not specified.
Additional inputs are also required depending on your shipping type (Flat or Calculated). See the "Shipping Type" section for details.
Before Adding an Item
You can follow the procedure below to obtain the required values and add an item through SQL:- Use the CategoryTree view to browse the category hierarchy and find a leaf CategoryId for your item. A leaf category Id is required to add an item.
- Use the ShippingServices view to select a shipping service. The value of the ValidForSellingFlow column must be true; otherwise, that particular shipping service option is no longer valid and cannot be offered to buyers through a listing.
Shipping Type
The following inputs are required for the Flat shipping type: ShippingType, ShippingService, ShippingServicePriority, and ShippingServiceCost.The Calculated shipping type requires additional information related to package stats. The following inputs are required for this shipping type: ShippingType, WeightMajor, WeightMinor, OriginatingPostalCode, ShippingService, and ShippingServicePriority.
The following example uses Flat shipping.
Note: Additional inputs may be required depending on your listing type and payment method.
EXEC AddItem Title = 'testingSP_2', Description = 'Test Description', CategoryId = '853', StartPrice = '10.00', ConditionId = '1000', Currency = 'USD', Country = 'US', ListingDuration = 'Days_10', ListingType = 'FixedPriceItem', Location = 'Atlanta', PostalCode = '30301', Quantity = '1', DispatchTimeMax = '3', PaymentMethod = 'PayPal', PayPalEmailAddress = '[email protected]', ReturnsAcceptedOption = 'ReturnsAccepted', ShippingType = 'Flat', ShippingService = 'UPSGround', ShippingServicePriority = '1', ShippingServiceCost = '5.00', ItemSpecificsAggregate = '[{"Name":"Format","Value":"Yes"},{"Name":"Release Title","Value":"No"},{"Name":"Artist","Value":"Maybe"}]', PictureUrl = '[{"Url":"https://example.com/a.jpg"},{"Url":"https://example.com/b.jpg"}]'
Input
| Name | Type | Required | Description |
| Title | String | False | The name of the item as it appears in the listing or search results. |
| Description | String | False | The description of the item by the seller. In listing requests, you can use CDATA tags to submit your description if you want to use HTML or XML-reserved characters in the description. |
| CategoryId | String | False | The category Id for the first (or only) category in which the item is listed, or in which the item is listed if the item is new. |
| StartPrice | String | True | The original price of the item at listing or relisting time. If this value changes when the item is revised, the new value becomes the original price. |
| ConditionId | String | False | An identifier for the condition of the item. For example, 1000 for New or 3000 for Used. |
| Country | String | True | The 2-letter ISO 3166 country code for the item's location. |
| Currency | String | True | The 3-letter ISO 4217 currency code associated with the price information of the item. |
| DispatchTimeMax | String | False | Specifies the maximum number of business days the seller commits to for preparing an item to be shipped after receiving a cleared payment. This time does not include the shipping time (the transit time of the carrier). Including this field fulfills the Handling time input requirement. |
| ListingDuration | String | True | The number of days the seller wants the listing to be active and available for bidding or buying. |
| ListingType | String | False | The format of the listing the seller wants to use, such as Chinese auction or fixed price. |
| Location | String | False | The geographical location of the item, used together with the Country input. When you revise a listing, you can add or change this value only if the listing has no bids or no items have sold, and the listing does not end within 12 hours. |
| ReturnsAcceptedOption | String | False | Indicates whether the seller allows the buyer to return the item. One of the following values: ReturnsAccepted or ReturnsNotAccepted. If you specify ReturnsNotAccepted, the View Item page indicates that returns are not accepted instead. |
| SubTitle | String | False | The subtitle to use in addition to the title. |
| Quantity | String | False | The Quantity value for auction listings must always be 1. For a fixed-price listing, the Quantity value indicates the number of identical items the seller has available for sale in the listing. |
| Sku | String | False | The seller-defined Stock Keeping Unit (SKU) identifier for the product. |
| UUID | String | False | A universally unique constraint tag. Use the UUID to ensure that you list a particular item only once, particularly when you are listing many items at once. |
| ScheduleTime | String | False | Specifies the time at which the listing becomes active on eBay. |
| PaymentMethod | String | False | Identifies the payment method, such as PayPal, that the seller accepts when the buyer pays for the item. |
| PayPalEmailAddress | String | False | The PayPal email address of the seller. |
| LiveAuction | String | False | Indicates whether the listing is part of a Live Auction. Must be included and set to true if the listing is part of a Live Auction. This Boolean field is returned as true in the ItemList table if the listing is part of a Live Auction. See the eBay Live Auctions home page for more information about Live Auctions on eBay.com. |
| LotSize | String | False | The number of items in the lot. A lot is a set of two or more similar items included in a single listing that must be purchased together in a single order line item. This field is required if two or more items are included in one listing. |
| PostalCode | String | False | Postal code of the place where the item is located. This value is used for proximity searches. |
| TaxCategory | String | False | The tax exception category code for the item. |
| UseTaxTable | String | False | Indicates whether the seller's tax table is used when applying and calculating sales tax for an order line item. |
| VIN | String | False | The Vehicle Identification Number (VIN), which is a unique serial number for a motor vehicle. |
| VRM | String | False | The Vehicle Registration Mark (VRM), which is a unique identifier for a motor vehicle in the United Kingdom (UK). |
| CategoryMappingAllowed | String | False | Indicates whether eBay uses a new Id for the listing when the category no longer exists in the current category structure. If true, eBay uses the new Id for the listing. If false, an error is returned. |
| UseRecommendedProduct | String | False | Indicates whether the matching product from the eBay catalog is used to list the item. If true, and the item details in the request match a product in the eBay catalog, the matching product is used to list the item. |
| ShippingType | String | False | The shipping cost model offered by the seller. |
| ShippingService | String | False | A shipping service option offered by the seller to ship an item to a buyer. For a list of valid ShippingService values, query the ShippingServices view. The ShippingService returned must have a value of true in the ValidForSellingFlow column. |
| ShippingServicePriority | String | False | The integer value that controls the order, relative to other shipping services, in which the corresponding ShippingService appears on the View Item and Checkout page. Sellers can specify up to four domestic shipping services. |
| ShippingServiceCost | String | False | The base cost of shipping the item using the shipping service specified in the ShippingService field, if one is specified. This column includes the packaging and handling cost for flat and calculated shipping. For calculated shipping on a listing that has not yet ended, the cost cannot be determined until the listing has ended and the buyer has specified a postal code. This value reflects savings from a promotional shipping service option. Also applicable to Half.com. |
| ShippingServiceAdditionalCost | String | False | The cost of shipping each additional item when the same buyer purchases multiple quantities of the same line item. If less than ShippingServiceCost, this column gives the buyer a shipping discount. This field is required when creating a multiple-quantity fixed-price listing. This field is not applicable for single-quantity listings. |
| FreeShipping | String | False | Indicates whether the seller wants to offer free shipping. This applies only to the first specified domestic shipping service and is ignored if set for any other shipping service. |
| ShippingPackage | String | False | The nature of the package used to ship the item or items. This field is required for calculated shipping only. |
| ShippingIrregular | String | False | Indicates whether a package is irregular and therefore cannot go through the stamping machine at the shipping service office, and thus requires special or fragile handling. |
| MeasurementUnit | String | False | Specifies the unit type of the weight and dimensions of a shipping package. If MeasurementUnit is used, it overrides the system specified by MeasurementSystem. If MeasurementUnit and MeasurementSystem are not specified, the following defaults are used: English (US); Metric (CA, CAFR, AU). |
| MeasurementSystem | String | False | System of Measurement for PackageDepth, PackageLength, PackageWidth, WeightMajor, and WeightMinor (English or Metric). |
| PackageDepth | String | False | Depth of the package needed to ship the item. |
| PackageDepthUnit | String | False | Unit of measurement for PackageDepth (e.g., in, cm). |
| PackageLength | String | False | Length of the package needed to ship the item. |
| PackageLengthUnit | String | False | Unit of measurement for PackageLength (e.g., in, cm). |
| PackageWidth | String | False | Width of the package needed to ship the item. |
| PackageWidthUnit | String | False | Unit of measurement for PackageWidth (e.g., in, cm). |
| WeightMajor | String | False | The major unit used to specify the weight of a shipping package, such as lbs. |
| WeightMajorUnit | String | False | Unit of measurement for WeightMajor. |
| WeightMinor | String | False | The minor unit used to specify the weight of a shipping package, such as oz. |
| WeightMinorUnit | String | False | Unit of measurement for WeightMinor. |
| BestOfferEnabled | String | False | Indicates whether the Best Offer feature is enabled for this item. |
| ShipToRegistrationCountry | String | False | Indicates whether the seller blocks bidders who reside in countries on the ship-to exclusion list. The seller sets this field to true to block bidders whose eBay primary shipping address is in an excluded country. |
| StoreCategoryId | String | False | Unique identifier of a primary custom category in which to list the item. |
| StoreCategoryName | String | False | Category name of a primary custom category in which to list the item. |
| StoreCategoryId2 | String | False | Unique identifier for the secondary custom category in which to list the item. |
| StoreCategoryName2 | String | False | Name of the secondary custom category in which to list the item. |
| DaysToFullPayment | String | False | The integer value that indicates the number of days a buyer has, after committing to buy, to make full payment to the seller and close the remaining balance on a motor vehicle. Valid values are 3, 7 (default), 10, and 14. |
| Brand | String | False | The brand of the product. eBay searches against the names that are publicly available in its product catalogs, so you can specify the well-known brand name that an average user would recognize. Both Brand and MPN must be specified if the BrandMPN column is used. |
| BrandMPN | String | False | The manufacturer part number of the product. Use the value specified by the manufacturer. |
| EAN | String | False | Applicable for listing use cases only, not buy-side searching. The European Article Number (EAN) is a unique 8 or 13 digit identifier that many industries, such as book publishers, use to identify products. |
| IncludeeBayProductDetails | String | False | Indicates whether an eBay catalog product is used to help create or revise an item listing. |
| IncludeStockPhotoURL | String | False | Indicates whether the item listing includes the stock photo. |
| ISBN | String | False | Applicable for listing use cases only, not buy-side searching. The International Standard Book Number (ISBN) is a unique identifier for books. Specify a 10 or 13 character ISBN. |
| ProductReferenceId | String | False | The short global reference Id for a catalog product. |
| UPC | String | False | Applicable for listing use cases only, not buy-side searching. The Universal Product Code (UPC) is a unique, 12-character identifier that many industries use to identify products. |
| UseStockPhotoURLAsGallery | String | False | Indicates whether the stock photo for an item, if available, is used as the gallery thumbnail. IncludeStockPhotoURL must also be true. |
| PaymentProfileId | String | False | The unique identifier of a Business Policies payment profile. A PaymentProfileId or PaymentProfileName can be specified. |
| PaymentProfileName | String | False | The name of a Business Policies payment profile. A PaymentProfileId or PaymentProfileName can be specified. |
| ReturnProfileId | String | False | The unique identifier of a Business Policies return policy profile. A ReturnProfileId or ReturnProfileName can be specified. |
| ReturnProfileName | String | False | The name of a Business Policies return policy profile. A ReturnProfileId or ReturnProfileName can be specified. |
| ShippingProfileId | String | False | The unique identifier of a Business Policies shipping policy profile. A ShippingProfileId or ShippingProfileName can be specified. |
| ShippingProfileName | String | False | The name of a Business Policies shipping policy profile. A ShippingProfileId or ShippingProfileName can be specified. |
| BusinessSeller | String | False | Indicates whether the seller is a business user and intends to use listing features offered to business users only. |
| RestrictedToBusiness | String | False | Indicates whether the seller elects to offer the item exclusively to business users. If true, the seller elects to offer the item exclusively to business users. If false or not specified, the seller elects to offer the item to all users. |
| VATPercent | String | False | VAT rate for the item, if any. |
| PhotoDisplay | String | False | Specifies the type of image display used in a listing. Some options are only available if images are hosted through eBay Picture Services (EPS). |
| PictureUrl | String | False | The source of the picture. Accepts a single URL, a JSON or XML aggregate of {Url} rows, or a #TEMP table reference. Examples: 'a.jpg' | '[{Url:a.jpg},{Url:b.jpg}]' | 'Pics#TEMP'. |
| GalleryURL | String | False | This field is used internally only. The gallery image is always the first PictureURL passed in, and this field is set to that value. |
| ItemSpecificName | String | False | The name of a single Item Specific, such as 'Release Title'. Pair with ItemSpecificValue. For multiple specifics, use ItemSpecificsAggregate instead. |
| ItemSpecificValue | String | False | The value of a single Item Specific, paired with ItemSpecificName. For multiple specifics, use ItemSpecificsAggregate instead. |
| ItemSpecificsAggregate | String | False | Multiple Item Specifics as a JSON or XML aggregate, or a #TEMP table reference. Each row is {Name, Value}, where Value may be a scalar, a JSON primitive array, multiple XML Value siblings, or a #TEMP reference. Example: '[{Name:Size,Value:[L,M]},{Name:Color,Value:Red}]'. When this is set, the singular ItemSpecificName and ItemSpecificValue inputs are ignored. |
| ProductCompliancePolicyId | String | False | This field is used if the seller wants to apply one or more seller-created global product compliance policies to a listing. |
| ProductCountryPolicy | String | False | Defines the 2-letter country code set. |
| ProductCountryPolicyId | String | False | The policy Id specifying product compliance policy information. |
| TakeBackCountryPolicy | String | False | Defines the 2-letter country code set. |
| TakeBackCountryPolicyId | String | False | The policy Id specifying take-back policy information. |
| TakeBackPolicyId | String | False | This field is used if the seller wants to apply a global take-back policy to the listing. |
| ConditionAdditionalInfo | String | False | The additional information about a condition descriptor. |
| ConditionName | String | False | The numeric Id that maps to the name of a condition descriptor. |
| ConditionValue | String | False | The numeric Id that maps to the value associated with a condition descriptor name. |
Result Set Columns
| Name | Type | Description |
| ItemId | String | The unique identifier of the created item. |
| StartTime | String | The starting date and time for the new listing. |
| EndTime | String | The date and time when the new listing is scheduled to end, based on the start time and the listing duration value set in the ListingDuration field at listing time. |
| FeesAggregate | String | An array of fees associated with the creation of the listing. |
| DiscountReason | String | One or more listing fee or upgrade discount types offered by eBay to the seller. Applicable values: CustomCode, Promotion, SpecialOffer. |