Ebay Product Page API

This endpoint will retrieve product data from an Ebay product pages (/itm/) and transform it into usable JSON.

try {
String apiKey = "API_KEY";
String product_id = "PRODUCT_ID";
String country_code = "COUNTRY_CODE";
String tld = "TLD";
String url = "https://api.scraperapi.com/structured/ebay/product?api_key=" + apiKey + "&product_id=" + product_id + "&country_code=" + country_code + "&tld=" + tld;
URL urlForGetRequest = new URL(url);
HttpURLConnection connection = (HttpURLConnection) urlForGetRequest.openConnection();
connection.setRequestMethod("GET");
int responseCode = connection.getResponseCode();
if (responseCode == HttpURLConnection.HTTP_OK) {
BufferedReader in = new BufferedReader(new InputStreamReader(connection.getInputStream()));
StringBuffer response = new StringBuffer();
String readLine;
while ((readLine = in.readLine()) != null) {
response.append(readLine);
}
in.close();
System.out.println(response.toString());
} else {
throw new Exception("Error in API Call");
}
} catch (Exception ex) {
ex.printStackTrace();
}
ParametersDetails

API_KEY (required)

User's normal API Key

PRODUCT_ID (required)

ebay product ID. 12 digits. Example: 166619046796

TLD

Top-level Ebay domain to scrape. This is an optional argument and defaults to “com” (ebay.com). Valid values include:

com (ebay.com)

co.uk (ebay.co.uk)

com.au (ebay.com.au)

de (ebay.de)

ca (ebay.ca)

fr (ebay.fr)

it (ebay.it)

es (ebay.es)

at (ebay.at)

ch (ebay.ch)

com.sg (ebay.com.sg)

com.my (ebay.com.my)

ph (ebay.ph)

ie (ebay.ie)

pl (ebay.pl)

nl (ebay.nl)

COUNTRY

country_code influences the language and the currency of the page. The TLD should be set to ‘com’ if you are using languages that are not used by the TLDs listed above.

Sample Response

  "product_id_epid": "166619046796",
  "title": "Apple AirPods Pro 2nd Generation 2023 A2968 Magsafe USB-C Charging - Excellent",
  "seller": {
    "name": "Amazing Wireless",
    "seller_url": "https://www.ebay.com/str/amazingwireless",
    "seller_reviews_count": 141910,
    "seller_review": "99.4% positive",
    "top_rated": true
  },
  "price": {
    "value": 149.99,
    "currency": "USD"
  },
  "images": [
    "https://i.ebayimg.com/images/g/rm4AAOSwPtJljzDc/s-l1600.webp",
    "https://i.ebayimg.com/images/g/WDgAAOSwr3ZljzDb/s-l140.webp",
    "https://i.ebayimg.com/images/g/RfwAAOSwaj5ljzDb/s-l140.webp",
    "https://i.ebayimg.com/images/g/n5wAAOSwIHNmM9iK/s-l140.webp",
    "https://i.ebayimg.com/images/g/BREAAOSw8XxmM9iK/s-l140.webp",
    "https://i.ebayimg.com/images/g/i~kAAOSw9vRmM9iK/s-l140.webp",
    "https://i.ebayimg.com/images/g/d-IAAOSwrrtmM9iK/s-l140.webp",
    "https://i.ebayimg.com/images/g/F9oAAOSwc79mM9iJ/s-l140.webp",
    "https://i.ebayimg.com/images/g/I2QAAOSwCz5mM9iK/s-l140.webp",
    "https://i.ebayimg.com/images/g/w7EAAOSwu~hiKndx/s-l140.webp"
  ],
  "available_quantity": "More than 10 available",
  "sold_items": "1,866 sold",
  "shipping_costs": {
    "value": 0
  },
  "shipping_notes": "Free 2-3 day shipping",
  "return_policy": "60 days returns. Seller pays for return shipping.",
  "condition": "Excellent - Refurbished",
  "year_manufactured": "2023",
  "brand": "Apple",
  "color": "White",
  "model": "Apple AirPods Pro (2nd generation)",
  "item_specifics": [
    {
      "label": "Seller Notes",
      "value": "“85%+ battery life. The Device is in Excellent Cosmetics. Have been Tested, 100% Functionality. Comes with Accessories.” Read Lessabout the seller notes "
    },
    {
      "label": "UPC",
      "value": "0195949052484"
    },
    {
      "label": "Form Factor",
      "value": "In-Ear Only"
    },
    {
      "label": "Type",
      "value": "Canal Earbud (In Ear Canal)"
    },
    {
      "label": "Number of Earpieces",
      "value": "Double"
    },
    {
      "label": "Wireless Technology",
      "value": "Bluetooth"
    },
    {
      "label": "Connectivity",
      "value": "Bluetooth"
    },
    {
      "label": "MPN",
      "value": "MTJV3AM/A"
    },
    {
      "label": "Features",
      "value": "Active Noise Cancellation, Water-Resistant, Sweat-Proof"
    },
    {
      "label": "Microphone Type",
      "value": "Built-In"
    }
  ],
  "item_description_from_seller_url": "https://vi.vipr.ebaydesc.com/itmdesc/166619046796?t=0&category=80077&seller=amazing-wireless&excSoj=1&ver=0&excTrk=1&lsite=0&ittenable=true&domain=ebay.com&descgauge=1&cspheader=1&oneClk=2&secureDesc=1",
  "rating": 4.4,
  "review_count": 71,
  "rating_count_5stars": 55,
  "rating_count_4stars": 2,
  "rating_count_3stars": 6,
  "rating_count_2stars": 2,
  "rating_count_1star": 6,
  "easy_to_use": 84,
  "well_designed": 84,
  "good_value": 76,
  "reviews": [
    {
      "stars": 5,
      "author": " by luczama66",
      "review_date": "May 29, 2024",
      "title": "First time being an eBay buyer and was super sus about buying an airpod replacement on here. Glad i did tho because the airpod works just fine. You ca",
      "content": "First time being an eBay buyer and was super sus about buying an airpod replacement on here. Glad i did tho because the airpod works just fine. You can obviously tell it’s used bc it has small scratches but it isn’t a big deal for me. I liked how it came with written instructions on how to reset it even for different airpod generations! Worth the price too. ",
      "attrs": [
        {
          "label": "Verified purchase",
          "value": "Yes"
        },
        {
          "label": "Condition",
          "value": "Pre-Owned"
        },
        {
          "label": "Sold by",
          "value": "pezzs_inc"
        }
      ]
    },
    {
      "stars": 3,
      "author": " by kz9f424",
      "review_date": "May 05, 2024",
      "title": "They are definitely clones of AirPods Pros 2nd Gen as I noticed a few features are either missing or disabled. That and the name they have when first ",
      "content": "They are definitely clones of AirPods Pros 2nd Gen as I noticed a few features are either missing or disabled. That and the name they have when first pairing is literally “Not Your AirPod Pros”. They do sound good though and I can live without conversation awareness and the inability to turn off charging case sounds for the money I saved buying these instead of shelling out money to buy directly from Apple. ",
      "attrs": [
        {
          "label": "Verified purchase",
          "value": "Yes"
        },
        {
          "label": "Condition",
          "value": "Pre-Owned"
        },
        {
          "label": "Sold by",
          "value": "thunder-6325"
        }
      ]
    },
    {
      "stars": 5,
      "author": " by morr.wayn",
      "review_date": "Apr 29, 2024",
      "title": "Apple AirPods Pro (2nd Generation) Wireless Ear Buds USB-C Charging MTJV3AM/A ",
      "content": "Connect and install on my I Phone was as simple as a couple of clicks, so straight foreword. They fit my ears perfectly out of the box, extra tips are included. The sound is far soupier to the other three brands I have tried. It was nice while waiting at the dentist office, listing to music, seated under the TV that was on, the TV was not noticeable as in blocked completely, very nice. These are also less massive that the Sony buds that died on me. Yes I am pleased.",
      "attrs": [
        {
          "label": "Verified purchase",
          "value": "Yes"
        },
        {
          "label": "Condition",
          "value": "New"
        },
        {
          "label": "Sold by",
          "value": "amazing-wireless"
        }
      ]
    },
    {
      "stars": 5,
      "author": " by rambo-lambo65",
      "review_date": "Mar 08, 2024",
      "title": "Lightweight with great features",
      "content": "A little too expensive but they are fantastic",
      "attrs": [
        {
          "label": "Verified purchase",
          "value": "Yes"
        },
        {
          "label": "Sold by",
          "value": "goldstar_tech"
        }
      ]
    },
    {
      "stars": 5,
      "author": " by rolandk51",
      "review_date": "Mar 03, 2024",
      "title": "Great sounding, great fit, quality build. A good choice ",
      "content": "Great sounding earbuds. Fit very nice charge really well in the case. The Case charges well when resting on charging plate. Highly recommend these sound great.",
      "attrs": [
        {
          "label": "Verified purchase",
          "value": "Yes"
        },
        {
          "label": "Condition",
          "value": "New"
        }
      ]
    }
  ],
  "similar_items": [
    {
      "title": "Apple AirPods Pro 2nd Generation with MagSafe Wireless Charging Case (USB‑C)...",
      "url": "https://www.ebay.com/itm/387434387384",
      "image_url": "https://i.ebayimg.com/thumbs/images/g/yFkAAOSwW5Zm-fel/s-l500.jpg",
      "price": {
        "value": 85,
        "currency": "USD"
      },
      "condition": "Pre-owned",
      "shipping_cost": {
        "value": 7.71,
        "currency": "USD"
      },
      "seller_feedback": "Seller with 100% positive feedback"
    },
    {
      "title": "Apple AirPods Pro 2nd Generation 2023 A2968 Magsafe USB-C Charging - SEALED",
      "url": "https://www.ebay.com/itm/176602653143",
      "image_url": "https://i.ebayimg.com/thumbs/images/g/OCUAAOSwh7Bm-clk/s-l500.jpg",
      "price": {
        "value": 174,
        "currency": "USD"
      },
      "condition": "New",
      "shipping_cost": {
        "value": 0
      },
      "watchers": 5
    },
    {
      "title": "Apple AirPods Pro 2nd Generation with MagSafe Wireless Charging Case (USB‑C)...",
      "url": "https://www.ebay.com/itm/395738824335",
      "image_url": "https://i.ebayimg.com/thumbs/images/g/pBMAAOSwWQ1m-NeG/s-l500.jpg",
      "price": {
        "value": 64.14,
        "currency": "USD"
      },
      "condition": "Pre-owned",
      "shipping_cost": {
        "value": 7.71,
        "currency": "USD"
      },
      "watchers": 11
    },
    {
      "title": "Apple AirPods Pro 2nd Generation 2023 A2968 Magsafe USB-C Charging",
      "url": "https://www.ebay.com/itm/335592547939",
      "image_url": "https://i.ebayimg.com/thumbs/images/g/MvIAAOSwJxxm9Eog/s-l500.jpg",
      "price": {
        "value": 119.99,
        "currency": "USD"
      },
      "condition": "New",
      "shipping_cost": {
        "value": 10.6,
        "currency": "USD"
      },
      "seller_feedback": "Seller with 100% positive feedback"
    }
  ]
}

Last updated