eBay Merchandising APIVersion 1.5.0

getMostWatchedItems

Retrieves data for items with the highest watch counts for the entire site or for a specific category. The top 20 most watched items, if any, are returned unless maxResults is used to specify a smaller or larger result set. The top items are determined by the watch count totals from the preceding day. Ranking of the most watched items is calculated with the latest watch count information.

Note: Before January 2015, the response returned only auction items that had one or more bids. Now due to an eBay platform change, auction items with and without bids are returned.



Input

The box below lists all fields that could be included in the call request. To learn more about an individual field or its type, click its name in the box (or scroll down to find it in the table below the box).

See also Samples.

<?xml version="1.0" encoding="utf-8"?>
<getMostWatchedItemsRequest xmlns="http://www.ebay.com/marketplace/services">
  <!-- Call-specific Input Fields -->
  <categoryId> string </categoryId>
  <!-- Standard Input Fields -->
  <affiliate> Affiliate
    <customId> string </customId>
    <networkId> string </networkId>
    <trackingId> string </trackingId>
  </affiliate>
  <maxResults> int </maxResults>
</getMostWatchedItemsRequest>
Argument Type Occurrence Meaning
Call-specific Input Fields [Jump to standard fields]
categoryId string Optional Specifies the category from which to retrieve item listings. This field takes the same category ID data as used with other eBay APIs.

Category IDs are site-specific. If the specified category ID doesn't match an existing category for the site, an invalid-category error message is returned. To determine valid categories, you can use either the Shopping API or the Trading API. In the Shopping API, use the FindItemsAdvanced call with the CategoryHistogram value in the IncludeSelector field to retrieve matching category information. In the Trading API, use calls like GetCategories and GetCategoryFeatures to determine valid values for the site.
Max length: 10.

See FindItemsAdvanced documentation for information on retrieving a categories, their details and a category histogram..

Standard Input Fields  
affiliate Affiliate Optional Container for affiliate details. eBay uses the specified affiliate details to build a View Item URL and Product URL string in the response that includes your affiliate tracking information in the correct format. When a user clicks through these URLs to eBay and performs certain tasks, you may get an affiliate commission.

See the eBay Partner Network for information about commissions.
affiliate.customId string Optional Need not be specified. You can define an AffiliateUserID (up to 256 characters) if you want to leverage it to better monitor your marketing efforts. If you are using the eBay Partner Network, and you provide an AffiliateUserID, the tracking URL returned by eBay Partner Network will contain the AffiliateUserID, but it will be referred to as a "customid".
affiliate.networkId string Optional Specifies your tracking partner for affiliate commissions. Affiliates earn money from eBay for driving traffic to eBay. Required if you specify a TrackingID. Depending on your tracking partner, specify one of the following values. Not all partners are valid for all sites. For PlaceOffer, only eBay Partner Network and Mediaplex are valid:
2 = Be Free
3 = Affilinet
4 = TradeDoubler
5 = Mediaplex
6 = DoubleClick
7 = Allyes
8 = BJMT
9 = eBay Partner Network For information about commissions, see the eBay Partner Network.
affiliate.trackingId string Optional The value you specify is obtained from your tracking partner. For eBay Partner Network, the TrackingID is the Campaign ID ("campid") provided by eBay Partner Network. A Campaign ID is a 10-digit, unique number to be used for associating traffic. A Campaign ID is valid across all programs to which you have been accepted. Another example is the Affiliate ID given to you by TradeDoubler.
maxResults int Optional Specifies the maximum number of entries to return in a single call. If the number of entries that can be returned is less than the value you specify, the lower number is returned. Values less than 1 or greater than 50 (or 20 in the case of getTopSellingProducts) will be ignored.
Min: 1. Max: 50. Default: 20.



Output

The box below lists all fields that might be returned in the response. To learn more about an individual field or its type, click its name in the box (or scroll down to find it in the table below the box).

See also Samples.

<?xml version="1.0" encoding="utf-8"?>
<getMostWatchedItemsResponse xmlns="http://www.ebay.com/marketplace/services">
  <!-- Call-specific Output Fields -->
  <itemRecommendations> ItemRecommendations
    <item> Item
      <bidCount> int </bidCount>
      <buyItNowPrice currencyId="string"> Amount (double) </buyItNowPrice>
      <country> string </country>
      <currentPrice currencyId="string"> Amount (double) </currentPrice>
      <discountPriceInfo> DiscountPriceInfo
        <originalRetailPrice currencyId="string"> Amount (double) </originalRetailPrice>
        <pricingTreatment> PriceTreatmentEnum </pricingTreatment>
        <soldOffEbay> boolean </soldOffEbay>
        <soldOnEbay> boolean </soldOnEbay>
      </discountPriceInfo>
      <globalId> string </globalId>
      <imageURL> anyURI </imageURL>
      <itemId> string </itemId>
      <originalPrice currencyId="string"> Amount (double) </originalPrice>
      <primaryCategoryId> string </primaryCategoryId>
      <primaryCategoryName> string </primaryCategoryName>
      <shippingCost currencyId="string"> Amount (double) </shippingCost>
      <shippingType> string </shippingType>
      <subtitle> string </subtitle>
      <timeLeft> duration </timeLeft>
      <title> string </title>
      <viewItemURL> anyURI </viewItemURL>
      <watchCount> int </watchCount>
    </item>
    <!-- ... more item nodes allowed here ... -->
  </itemRecommendations>
  <!-- Standard Output Fields -->
  <ack> AckValue </ack>
  <errorMessage> ErrorMessage
    <error> ErrorData
      <category> ErrorCategory </category>
      <domain> string </domain>
      <errorId> long </errorId>
      <exceptionId> token </exceptionId>
      <message> string </message>
      <parameter name="string"> ErrorParameter (string) </parameter>
      <!-- ... more parameter nodes allowed here ... -->
      <severity> ErrorSeverity </severity>
      <subdomain> string </subdomain>
    </error>
    <!-- ... more error nodes allowed here ... -->
  </errorMessage>
  <timestamp> dateTime </timestamp>
  <version> string </version>
</getMostWatchedItemsResponse>
Return Value Type Occurrence Meaning
Call-specific Output Fields [Jump to standard fields]
itemRecommendations ItemRecommendations Always A list of items matching the given criteria. Item sort order is different for each call. Returned when there are items that match the search criteria.
itemRecommendations.item Item Conditionally,
repeatable: [0..*]
Contains details for a single recommended item. Returned when there is at least one item that matches the search criteria.
itemRecommendations.item
  .bidCount
int Conditionally The number of bids that have been placed on the item.
itemRecommendations.item
  .buyItNowPrice
Amount (double) Conditionally The Buy It Now Price of the item (if any), in the currency of the site on which the item was listed.

For Chinese auctions (Quantity=1, competitive bidding online auctions), Buy It Now lets a user purchase the item at a fixed price and end the auction immediately. On most sites, after a Chinese auction has bids, the listing is no longer eligible for Buy It Now. However, calls can still return the Buy It Now Price that the seller set for the listing. Use the item.bidCount field to determine whether an auction with Buy It Now has bids or not.

Some eBay sites also support Buy It Now for Dutch auctions (multi- quantity, competitive bidding), where you can buy multiple items from the same listing at a fixed price, instead of bidding. On some sites, the Buy It Now option remains available for Dutch auctions even after there are bids.

For fixed-price (FixedPriceItem) and Store Inventory listings (StoresFixedPrice), see currentPrice instead.

Only returned if an item was listed with Buy It Now.
itemRecommendations.item
  .buyItNowPrice
  [ attribute currencyId ]
string Always The Buy It Now Price of the item (if any), in the currency of the site on which the item was listed.

For Chinese auctions (Quantity=1, competitive bidding online auctions), Buy It Now lets a user purchase the item at a fixed price and end the auction immediately. On most sites, after a Chinese auction has bids, the listing is no longer eligible for Buy It Now. However, calls can still return the Buy It Now Price that the seller set for the listing. Use the item.bidCount field to determine whether an auction with Buy It Now has bids or not.

Some eBay sites also support Buy It Now for Dutch auctions (multi- quantity, competitive bidding), where you can buy multiple items from the same listing at a fixed price, instead of bidding. On some sites, the Buy It Now option remains available for Dutch auctions even after there are bids.

For fixed-price (FixedPriceItem) and Store Inventory listings (StoresFixedPrice), see currentPrice instead.

Only returned if an item was listed with Buy It Now.
itemRecommendations.item
  .country
string Conditionally Two-letter ISO 3166 country code to indicate the country where the item is located. For English names that correspond to each code (e.g., KY="Cayman Islands"), see the ISO site.
itemRecommendations.item
  .currentPrice
Amount (double) Conditionally For competitive-bidding listings (Chinese and Dutch auctions), current minimum asking price (start price) or the current highest bid for the item if bids have been placed. Shows minimum bid if no bids have been placed on the item. For Basic Fixed-Price, Store Inventory, or Ad type listings, this returns the original price specified when the item was listed/re-listed or the revised price if the item was revised.
itemRecommendations.item
  .currentPrice
  [ attribute currencyId ]
string Always For competitive-bidding listings (Chinese and Dutch auctions), current minimum asking price (start price) or the current highest bid for the item if bids have been placed. Shows minimum bid if no bids have been placed on the item. For Basic Fixed-Price, Store Inventory, or Ad type listings, this returns the original price specified when the item was listed/re-listed or the revised price if the item was revised.
itemRecommendations.item
  .discountPriceInfo
DiscountPriceInfo Conditionally This container provides information for an item that has a Strikethrough Price (STP) or a Minimum Advertised Price (MAP) discount pricing treatment. STP and MAP apply only to fixed-price listings and auction listings with the Buy It Now option. STP is available on the US, UK, and German (DE) sites, while MAP is available only on the US site.

Discount pricing is available to qualified sellers (and their associated developers) who participate in the Discount Pricing Program. Once qualified, sellers receive a "special account flag" (SAF) that allows them to apply Discount Pricing to both single-variation and multi-variation items. Sellers should contact their account manager or Customer Service to see if they qualify for the Strikethrough Pricing program.

As a seller listing Discount Price items, you are required to maintain records of your discount pricing in the event you are called upon to substantiate your item pricing. The following link details your legal obligations when you utilize Discount Pricing to sell items: Strikethrough Pricing Requirements

For AddFixedPriceItem, RelistFixedPriceItem, ReviseFixedPriceItem, and VerifyAddFixedPriceItem: If you are listing variations (MSKU items), use Variation.DiscountPriceInfo for each variation.

See Displaying Discount Pricing Information to Buyers.

itemRecommendations.item
  .discountPriceInfo
  .originalRetailPrice
Amount (double) Conditionally The actual retail price set by the manufacturer (OEM). eBay does not maintain or validate the OriginalRetailPrice supplied by the seller. OriginalRetailPrice should always be more than StartPrice. Compare the StartPrice/BuyItNowPrice to OriginalRetailPrice to determine the amount of savings to the buyer.
itemRecommendations.item
  .discountPriceInfo
  .originalRetailPrice
  [ attribute currencyId ]
string Always The actual retail price set by the manufacturer (OEM). eBay does not maintain or validate the OriginalRetailPrice supplied by the seller. OriginalRetailPrice should always be more than StartPrice. Compare the StartPrice/BuyItNowPrice to OriginalRetailPrice to determine the amount of savings to the buyer.
itemRecommendations.item
  .discountPriceInfo
  .pricingTreatment
PriceTreatmentEnum Conditionally Based on OriginalRetailPrice, MinimumAdvertisedPrice, and StartPrice values, eBay identifies whether the listing falls under MAP or STP (aka OriginalRetailPrice). GetItem returns this for items listed with one of these discount pricing treatments. GetSellerList returns the DiscountPriceInfo container. This field is not applicable for Add/Revise/Relist calls.

Applicable values:

MAP
Indicates that Minimum Advertised Price pricing treatment has been applied.
NONE
Indicates that there has no been any pricing treatment applied.
STP
Indicates that Strike Through Price pricing treatment has been applied.

itemRecommendations.item
  .discountPriceInfo.soldOffEbay
boolean Conditionally Used by the eBay UK and eBay Germany (DE) sites, this flag indicates that the discount price (specified as StartPrice) is the price for which the seller offered the same (or similar) item for sale on a Web site or offline store other than eBay in the previous 30 days. The discount price is always in reference to the seller's own price for the item.

If this field is set to 'true', eBay displays 'Was*' in the UK and 'Ursprunglich*' in Germany, next to the discounted price of the item. In the event both SoldOffeBay and SoldOneBay fields are set, SoldOneBay takes precedence.
itemRecommendations.item
  .discountPriceInfo.soldOnEbay
boolean Conditionally Used by the eBay UK and eBay Germany (DE) sites, this flag indicates that the discount price (specified as StartPrice) is the price for which the seller offered the same (or similar) item for sale on a Web site or offline store other than eBay in the previous 30 days. The discount price is always in reference to the seller's own price for the item.

If this field is set to 'true', eBay displays 'Was*' in the UK and 'Ursprunglich*' in Germany, next to the discounted price of the item. In the event both SoldOffeBay and SoldOneBay fields are set, SoldOneBay takes precedence.
itemRecommendations.item
  .globalId
string Conditionally The site upon which the item is listed. Returns a Global ID, which is a unique identifier for combinations of site, language, and territory.

For a list of possible enumeration values and how they map to eBay sites, see Global ID Values.
itemRecommendations.item
  .imageURL
anyURI Conditionally URL for a picture used as the Gallery thumbnail, if any. The image uses one of the following graphics formats: JPEG, BMP, TIF, or GIF. Only returned if the seller chose to show a gallery image.
itemRecommendations.item
  .itemId
string Always The ID that uniquely identifies the item listing. The ID is generated by eBay after an item is listed. You cannot choose or revise this value.
Max length: 19.
itemRecommendations.item
  .originalPrice
Amount (double) Conditionally Original price of an item whose price a seller has reduced with the Promotional Price Display feature. Only returned if the price has been revised.
itemRecommendations.item
  .originalPrice
  [ attribute currencyId ]
string Always Original price of an item whose price a seller has reduced with the Promotional Price Display feature. Only returned if the price has been revised.
itemRecommendations.item
  .primaryCategoryId
string Conditionally Numeric ID of the first (or only) category in which the item is listed. (Listings can appear in more than one category.)
Note: Currently, the Merchandising API calls do not return a listing's secondary category, if any.
Max length: 10.
itemRecommendations.item
  .primaryCategoryName
string Conditionally Display name of the first (or only) category in which the item is listed. This is a fully qualified category breadcrumb (e.g., Computers & Networking:Laptops, Notebooks).
Max length: 30.
itemRecommendations.item
  .shippingCost
Amount (double) Conditionally The shipping cost associated with the first shipping service. Only returned when shipping type is flat.
itemRecommendations.item
  .shippingCost
  [ attribute currencyId ]
string Always The shipping cost associated with the first shipping service. Only returned when shipping type is flat.
itemRecommendations.item
  .shippingType
string Conditionally The shipping cost model offered by the seller.

Applicable values:
Calculated
Calculated shipping model: the cost of shipping is determined in large part by the seller-offered and buyer-selected shipping service. The seller might assess an additional fee via PackagingHandlingCosts.
CalculatedDomesticFlatInternational
The seller specified one or more calculated domestic shipping services and one or more flat international shipping services.
Flat
Flat shipping model: the seller establishes the cost of shipping and cost of shipping insurance, regardless of what any buyer-selected shipping service might charge the seller.
FlatDomesticCalculatedInternational
The seller specified one or more flat domestic shipping services and one or more calculated international shipping services.
Free
Free shipping: Seller has specified free shipping for the item. The cost of shipping is zero for the first domestic shipping service (for flat or calculated shipping).
Freight
Freight shipping model: The cost of shipping is determined by a third party, FreightQuote.com, based on the item location (zip code).
NotSpecified
The seller did not specify the shipping type.
itemRecommendations.item
  .subtitle
string Conditionally Subtitle of the item. Only returned if the seller included a subtitle for the listing.

Note: Due to an eBay platform change in January 2015, this field is no longer supported for the getSimilarItems and getMostWatchedItems calls. It is returned in the response but will always be blank.

Max length: 55.
itemRecommendations.item
  .timeLeft
duration Conditionally Time left before the item listing ends. The duration is represented in the ISO 8601 duration format (PnDTnHnMnS). For ended listings, the time left is P0DT0H0M0S (zero days, zero hours, zero minutes, and zero seconds).
itemRecommendations.item.title string Always Name of the item as it appears in the listing or search results.
Max length: 55.
itemRecommendations.item
  .viewItemURL
anyURI Always The URL of the web page where a user can view the listing. On the US site, this is called the "View Item" page. If you enabled affiliate tracking in the call, viewItemURL contains a string that includes affiliate tracking information (see the eBay Partner Network).
itemRecommendations.item
  .watchCount
int Always The number of watches placed on this item from buyers' My eBay accounts.
Standard Output Fields  
ack AckValue Always Indicates whether there are any errors or warnings associated with the processing of the request.

Applicable values:

Failure
Errors occurred that prevented the request from being processed successfully.
PartialFailure
Reserved for future use.
Success
The request was processed successfully without errors or warnings.
Warning
The request was processed successfully, but some warnings were returned.

errorMessage ErrorMessage Conditionally Information for an error or warning that occurred when eBay processed the request. Not returned when responseStatus is Success. See Errors by Number for a list of errors and warnings that can be returned by Merchandising API calls.
errorMessage.error ErrorData Conditionally,
repeatable: [0..*]
Details about a single error.
errorMessage.error.category ErrorCategory Conditionally There are three categories of errors: request errors, application errors, and system errors.

Applicable values:

Application
An error occurred due to a problem with the request, such as missing or invalid fields. The problem must be corrected before the request can be made again. If the problem is due to something in the application (such as a missing required field), the application must be changed. Once the problem in the application or data is resolved, resend the corrected request to eBay.
Request
An error occurred due to a problem with the request, such as invalid or missing data. The problem must be corrected before the request can be made again. If the problem is a result of end-user data, the application must alert the end-user to the problem and provide the means for the end-user to correct the data. Once the problem in the data is resolved, resend the request to eBay with the corrected data.
System
Indicates that an error has occurred on the eBay system side, such as a database or server down. An application can retry the request as-is a reasonable number of times (eBay recommends twice). If the error persists, contact Developer Technical Support. Once the problem has been resolved, the request may be resent in its original form.

errorMessage.error.domain string Conditionally Name of the domain upon which the error occurred.

Domains include:

Marketplace
A business or validation error occurred for the Merchandising Service.
SOA
An exception occurred in the framework.
errorMessage.error.errorId long Conditionally A unique code that identifies the particular error condition that occurred. Your application can use error codes as identifiers in your customized error-handling algorithms.
errorMessage.error.exceptionId token Conditionally Unique identifier for an exception associated with an error.
errorMessage.error.message string Conditionally A detailed description of the condition that resulted in the error.
errorMessage.error.parameter ErrorParameter (string) Conditionally,
repeatable: [0..*]
Some warning and error messages return one or more variables that contain contextual information about the error. This is often the field or value that triggered the error.
errorMessage.error.parameter
  [ attribute name ]
string Conditionally Some warning and error messages return one or more variables that contain contextual information about the error. This is often the field or value that triggered the error.
errorMessage.error.severity ErrorSeverity Conditionally Indicates whether the error caused the request to fail (Error) or not (Warning).

If the request fails and the source of the problem is within the application (such as a missing required element), please change the application before you retry the request. If the problem is due to end- user input data, please alert the end-user to the problem and provide the means for them to correct the data. Once the problem in the application or data is resolved, you can attempt to re- send the request to eBay.

If the source of the problem is on eBay's side, you can retry the request as-is a reasonable number of times (eBay recommends twice). If the error persists, contact Developer Technical Support. Once the problem has been resolved, the request may be resent in its original form.

When a warning occurs, the error is returned in addition to the business data. In this case, you do not need to retry the request (as the original request was successful). However, depending on the cause or nature of the warning, you might need to contact either the end user or eBay to effect a long term solution to the problem to prevent it from reoccurring in the future.

Applicable values:

Error
The request that triggered the error was not processed successfully. When a serious application-level error occurs, the error is returned instead of the business data.
Warning
The request was processed successfully, but something occurred that may affect your application or the user. For example, eBay may have changed a value the user sent in. In this case, eBay returns a normal, successful response and also returns the warning.

errorMessage.error.subdomain string Conditionally Name of the subdomain upon which the error occurred.

Subdomains include:

Merchandising
The error is specific to the Merchandising service.
MarketplaceCommon
The error is common to all Marketplace services.
timestamp dateTime Always This value represents the date and time when eBay processed the request. The time zone of this value is GMT and the format is the ISO 8601 date and time format (YYYY-MM-DDTHH:MM:SS.SSSZ). See the "dateTime" type for information about this time format and converting to and from the GMT time zone.
version string Always The version of the response payload schema. Indicates the version of the schema that eBay used to process the request. Developer Technical Support may ask you for the version value when you work with them to troubleshoot issues.



Samples

New to making API calls? Please see Making an API Call.

Note: Some item IDs, user IDs, or other data in these samples might no longer be active on eBay. If necessary, you can substitute current eBay data in your requests.

Available samples:

Sample: Basic Call

Retrieves items that have the highest watch counts.

Description

The user braggybuyer is browsing for gift ideas, and wants to see what interests other eBay buyers. This call sample retrieves the items on eBay with the highest watch counts.

Input

There are no required input fields for this sample. This sample sets maxResults to 3 to limit the size of the response.

URL format. See also the non-wrapped version of this URL. For results in a format other than XML, 
specify a different value for responseencoding.
http://svcs.ebay.com/MerchandisingService?
   OPERATION-NAME=getMostWatchedItems&
   SERVICE-NAME=MerchandisingService&
   SERVICE-VERSION=1.1.0&
   CONSUMER-ID=YourAppID&
   RESPONSE-DATA-FORMAT=XML&
   REST-PAYLOAD&
   maxResults=3

   Here is the same input in XML format. Note that this does not include standard values.

XML format. Also available is the .txt version of this XML.

<?xml version="1.0" encoding="UTF-8"?>
<getMostWatchedItems xmlns="http://www.ebay.com/marketplace/services">
  <maxResults>3</maxResults>
</getMostWatchedItems>

Output

The response contains a list of recommended items from which braggybuyer can choose. The current price and shipping costs are returned for each item, along with basic information about the listing, such as itemId, title, and time left. The viewItemURL links to the View Item page.

XML format.
<?xml version="1.0" encoding="UTF-8"?>
<getMostWatchedItemsResponse xmlns="http://www.ebay.com/marketplace/services" xmlns:sct="http://www.ebay.com/soaframework/common/types">
  <ack>Success</ack>
  <version>1.1.0</version>
  <timestamp>2008-08-15T15:13:32.994-07:00</timestamp>
  <itemRecommendations>
    <item>
      <itemId>200220313166</itemId>
      <title>Meet & Greet with Elton John in Las Vegas! + 2 Tickets</title>
      <viewItemURL>
        http://cgi.ebay.com/ws/eBayISAPI.dll?ViewItem&item=200220313166&ih=010&category
        =16071&_trksid=m8&_trkparms=algo%3DMW%26app%3DYourAppID%26itu%3DUCC%26otn%3D3%
        26po%3DOp1%26ps%3D50
      </viewItemURL>
      <currentPrice currencyId="USD">22101.79</currentPrice>
      <globalId>EBAY-US</globalId>
      <timeLeft>P2DT1H54M34S</timeLeft>
      <primaryCategoryId>1305</primaryCategoryId>
      <primaryCategoryName>Tickets</primaryCategoryName>
      <subtitle></subtitle>
      <bidCount>89</bidCount>
      <country>US</country>
      <imageURL>http://thumbs.ebaystatic.com/pict/200220313166_1.jpg</imageURL>
      <shippingCost currencyId="USD">0.0</shippingCost>
      <shippingType>Flat</shippingType>
      <watchCount>936</watchCount>
    </item>
    <item>
      <itemId>200220861011</itemId>
      <title>2 Tickets to the Star Trek Movie World Premiere in LA!</title>
      <viewItemURL>
        http://cgi.ebay.com/ws/eBayISAPI.dll?ViewItem&item=200220861011&ih=010&category
        =16071&_trksid=m8&_trkparms=algo%3DMW%26app%3DYourAppID%26itu%3DUCC%26otn%3D3%
        26po%3DOp1%26ps%3D50
      </viewItemURL>
      <currentPrice currencyId="USD">6000.0</currentPrice>
      <globalId>EBAY-US</globalId>
      <timeLeft>P2DT1H54M34S</timeLeft>
      <primaryCategoryId>1305</primaryCategoryId>
      <primaryCategoryName>Tickets</primaryCategoryName>
      <subtitle></subtitle>
      <bidCount>39</bidCount>
      <country>US</country>
      <imageURL>http://thumbs.ebaystatic.com/pict/200220861011_1.jpg</imageURL>
      <shippingCost currencyId="USD">0.0</shippingCost>
      <shippingType>Flat</shippingType>
      <watchCount>663</watchCount>
    </item>
    <item>
      <itemId>5594177231</itemId>
      <title>eBay's #1 DiET PiLL -LiPOREXiN - $153? NOW $12.99 EBKY3</title>
      <viewItemURL>
        http://cgi.ebay.com/ws/eBayISAPI.dll?ViewItem&item=5594177231&ih=011&category=1
        1781&_trksid=m8&_trkparms=algo%3DMW%26app%3DYourAppID%26itu%3DUCC%26otn%3D3%26
        po%3DOp1%26ps%3D50
      </viewItemURL>
      <globalId>EBAY-US</globalId>
      <timeLeft>P4DT20H33M39S</timeLeft>
      <primaryCategoryId>26395</primaryCategoryId>
      <primaryCategoryName>Health & Beauty</primaryCategoryName>
      <subtitle></subtitle>
      <buyItNowPrice currencyId="USD">11.99</buyItNowPrice>
      <country>US</country>
      <imageURL>http://thumbs.ebaystatic.com/pict/5594177231_2.jpg</imageURL>
      <shippingCost currencyId="USD">6.0</shippingCost>
      <shippingType>Flat</shippingType>
      <watchCount>527</watchCount>
    </item>
  </itemRecommendations>
</getMostWatchedItemsResponse>


Back to list of samples

Sample: Get Most Watched Items in a Category

Retrieves items that have the highest watch counts within a specific category.

Description

The user braggybuyer is browsing for gift ideas for a friend that likes to read, and wants to see what books interest other eBay buyers. This call sample retrieves the items within the books category (category ID 267) on eBay with the highest watch counts.

Input

The categoryId field specifies that most watched items be retrieved from the books category ().

URL format. See also the non-wrapped version of this URL. For results in a format other than XML, 
specify a different value for responseencoding.
http://svcs.ebay.com/MerchandisingService?
   OPERATION-NAME=getMostWatchedItems&
   SERVICE-NAME=MerchandisingService&
   SERVICE-VERSION=1.1.0&
   CONSUMER-ID=YourAppID&
   RESPONSE-DATA-FORMAT=XML&
   REST-PAYLOAD&
   maxResults=3&
   categoryId=267

   Here is the same input in XML format. Note that this does not include standard values.

XML format. Also available is the .txt version of this XML.

<?xml version="1.0" encoding="UTF-8"?>
<getMostWatchedItems xmlns="http://www.ebay.com/marketplace/services">
  <maxResults>3</maxResults>
  <categoryId>267</categoryId>
</getMostWatchedItems>

Output

The response contains a list of recommended items from which braggybuyer can choose. The current price and shipping costs are returned for each item, along with basic information about the listing, such as itemId, title, and time left. The viewItemURL links to the View Item page.

XML format.
<?xml version="1.0" encoding="UTF-8"?>
<getMostWatchedItemsResponse xmlns:sct="http://www.ebay.com/soaframework/common/types" xmlns="http://www.ebay.com/marketplace/services">
  <ack>Success</ack>
  <version>1.1.0</version>
  <timestamp>2008-08-15T15:13:32.994-07:00</timestamp>
  <itemRecommendations>
    <item>
      <itemId>260236631895</itemId>
      <title>Piccolomini LA SFERA MONDO 1579 STAR ATLAS Woodcut Maps</title>
      <viewItemURL>
        http://cgi.ebay.com/ws/eBayISAPI.dll?ViewItem&item=260236631895&ih=016&category
        =29223&_trksid=m8&_trkparms=algo%3DMW%26app%3DYourAppID%26its%3DC%26itu%3DUCC%
        26otn%3D3%26po%3DOp1%26ps%3D50
      </viewItemURL>
      <currentPrice currencyId="USD">1025.99</currentPrice>
      <globalId>EBAY-US</globalId>
      <timeLeft>P2DT22H54M23S</timeLeft>
      <primaryCategoryId>267</primaryCategoryId>
      <primaryCategoryName>Books</primaryCategoryName>
      <subtitle></subtitle>
      <bidCount>13</bidCount>
      <country>US</country>
      <imageURL>http://thumbs.ebaystatic.com/pict/260236631895_1.jpg</imageURL>
      <shippingCost currencyId="USD">0.0</shippingCost>
      <shippingType>Flat</shippingType>
      <watchCount>99</watchCount>
    </item>
    <item>
      <itemId>270234121868</itemId>
      <title>Teaching Textbooks Pre-Algebra Sonlight Homeschool</title>
      <viewItemURL>
        http://cgi.ebay.com/ws/eBayISAPI.dll?ViewItem&item=270234121868&ih=017&category
        =2228&_trksid=m8&_trkparms=algo%3DMW%26app%3DYourAppID%26its%3DC%26itu%3DUCC%2
        6otn%3D3%26po%3DOp1%26ps%3D50
      </viewItemURL>
      <currentPrice currencyId="USD">150.0</currentPrice>
      <globalId>EBAY-US</globalId>
      <timeLeft>P2DT16H43M1S</timeLeft>
      <primaryCategoryId>267</primaryCategoryId>
      <primaryCategoryName>Books</primaryCategoryName>
      <bidCount>19</bidCount>
      <country>US</country>
      <imageURL>http://thumbs.ebaystatic.com/pict/270234121868_1.jpg</imageURL>
      <shippingCost currencyId="USD">12.99</shippingCost>
      <shippingType>Flat</shippingType>
      <watchCount>83</watchCount>
    </item>
    <item>
      <itemId>6978359568</itemId>
      <title>Basic Animatronic How-to Do it Yourself Book!</title>
      <viewItemURL>
        http://cgi.ebay.com/ws/eBayISAPI.dll?ViewItem&item=6978359568&ih=007&category=2
        228&_trksid=m8&_trkparms=algo%3DMW%26app%3DYourAppID%26its%3DC%26itu%3DUCC%26o
        tn%3D3%26po%3DOp1%26ps%3D50
      </viewItemURL>
      <globalId>EBAY-US</globalId>
      <timeLeft>P24DT5H1M37S</timeLeft>
      <primaryCategoryId>267</primaryCategoryId>
      <primaryCategoryName>Books</primaryCategoryName>
      <subtitle></subtitle>
      <buyItNowPrice currencyId="USD">35.0</buyItNowPrice>
      <country>US</country>
      <imageURL>http://thumbs.ebaystatic.com/pict/6978359568_4.jpg</imageURL>
      <shippingCost currencyId="USD">4.0</shippingCost>
      <shippingType>Flat</shippingType>
      <watchCount>74</watchCount>
    </item>
  </itemRecommendations>
</getMostWatchedItemsResponse>


Back to list of samples



Change History

Change Date Description
1.4.0
2010-03-03
  • maxResults (modified): Increased maximum allowed results from 20 to 50.
1.1.0
2008-08-12
  • version (added): The version of the schema eBay used to process the request.
  • timestamp (added): The date and time when eBay processed the request.
1.0.0
2008-06-11
  • (added) New call