shopping24 documentation

s is for shopping

API product details

To retrieve full details of a product, request it from the following url:

GET /v3/:appid/product/:productid

Products on detail pages, search result and in category browsing are rendered as follows. The fields are self explanatory:

<ns2:product id="123974288">
  <!-- product's title and description -->
  <title>Samsung SyncMaster T22B350EW 22" (54,6 cm) LED</title>
  <description>
    Der neue HDTV LED-Monitor ...
  </description>
  <!-- product's GTIN-14 -->
  <gtin>04974374230744</gtin>
  
  <!-- the internal shop keeping unit. For debugging purposes only -->
  <sku>686373658</sku>
  
  <!-- the shops offering this product (see below) -->
  <shops count="1">...</shops>
  
  <!-- this product's brand (details see below) -->
  <brand id="10067">...</brand>
  
  <!-- attributes attached to this product. These are all filterable on the full product list. -->
  <attributes>
    <attribute name="tuner" label="Tuner">
      <value id="74761">DVB-C</value>
    </attribute>
    <attribute name="anschluss" label="Anschluss">...</attribute>
    <attribute name="color" label="Farbe">...</attribute>
  </attributes>
  
  <!-- The deepest category this product is included in -->
  <category id="16048">
    <name>Samsung Fernseher</name>
  </category>
  
  <!-- The path from root to the categories this product is included in -->
  <parentcategories>
    <category id="2929">
      <name>discount24 baum 14_06_2011</name>
      <children>
        <category id="3160">
          <name>TV, Audio, Konsolen</name>
          <children>..</children>
        </category>
      </children>
    </category>
  </parentcategories>
  
  <!-- a product image element -->
  <productImage extension="jpg" base="//media02.s24.com" id="212450427">...</productImage>
</ns2:product>

Shop element

The shop element contains the url to make a clickout to. It’s encapsulated in a link tag with the rel clickout. The shop group ID is only relevant for internal structuring.

<shop shopproductid="38002071" id="1722" shopgroupid="15">
  <name>HOH</name>
  
  <!-- product price and shipping. CPC has to be whitelisted, see FAQ -->
  <costs currencyCode="EUR" currencySymbol="€">
    <price cents="14950">149,50</price>
    <shipping cents="0">0,00</shipping>
    <earnings cents="24">0,24</earnings>
    <earningsMobile cents="15">0,15</earningsMobile>
  </costs>
  
  <!-- direct link to shop website -->
  <link href="http://www.hoh.de" rel="url"/>
  
  
  <!-- clickout link for this product -->
  <link href="https://philae.s24.com/v3/clickout/fjv6i1xe/2386/343..." rel="clickout"/>
  
  <!-- shop logo image resource -->
  <imageResource type="logo" base="//media02.s24.com/resource/" id="8a11..">...</imageResource>
</shop>

Brand element

The brand element holds information on the extracted product brand, if any.

<brand id="10067">
  <name>Samsung</name>
  <link href="http://api.s24.com/v3/1yy0uawc/products?brand=10067" rel="products"/>
  <imageResource type="logo" base="//media01.s24.com/resource/" id="8a11..">...</imageResource>
</brand>

Product images

Products contain a productImage element. It encapsulates some pre-defined image sizes as marked in the rel attribute.

image-original
The original image as provided by the shop
image-transparent
(optional) A transparent version of the image above
<productImage extension="jpg" base="//media01.s24.com/" id="87405550">
  <link href="//media02.s24.com/original/87405550.jpg" rel="image-original"/>
  <link href="//media03.s24.com/55x40/87405550.jpg" rel="image-productdetails-small"/>
  <link href="//media04.s24.com/300x220/87405550.jpg" rel="image-productdetails-big"/>
  <link href="//media01.s24.com/transparent/87405550.png" rel="image-transparent"/>
</productImage>

If those sizes do not fit your needs, you’re free to include images in the size of your need. Combine the attributes base, id and your desired image size in the format {width}x{height} to an image url to retrieve a scaled version of the original image:

<img src="//media03.s24.com/100x100/87405550.jpg" />

Multiple image id candidates? If the prefix and/or suffix used to compose an image url contains digit combinations, that are more than 6 digits long, the resizer might get confused, which id to pick as an image id. To be super safe, surround the image id with brackets. {.alert .alert-success}

SEO optimizations

For SEO purposes, you can add prefixes and suffixes to the image url, as long the id and .jpg file extension are included and the size is given in the format {width}x{height}. This produces a prettier and easier to read image urls:

<img src="//media03.s24.com/100x100/some-t-shirt-by-esprit-87405550.jpg" />
<img src="//media03.s24.com/t-shirts/blue/esprit/87405550-some-crazy-tshirt_100x100.jpg" />

Resource images

Shops and brands may carry images as well. Those image resources represent the type stated in the type attribute. The snippet below represents a logo type:

<imageResource type="logo" base="//media02.s24.com/resource/" id="8a118a8a">
  <link href="//media02.s24.com/resource/8a118a8a" rel="self"/>
</imageResource>

You can access the image using the full stated href element in the enclosed link element. The SEO optimizations above apply to these type of images as well.

<img src="//media02.s24.com/resource/8a118a8a" />