Breaking News - November 8, 2012:GoodRelations is the new, official e-commerce core for schema.org
For over a year now, we have been working with the schema.org sponsors, namely Google, Yahoo, Bing, and Yandex, on the integration of GoodRelations into the schema.org core. This will mean that you can use the full expressivity of GoodRelations directly from the schema.org namespace in Microdata syntax. Today, that addition has been officially published on the schema.org servers. This brings the full thrust of having the four biggest search engines behind it to the adoption of GoodRelations for exposing rich e-commerce data directly from shop pages and datasheets.
For more information on why this is important, see the article GoodRelations for Semantic SEO.
On this page, we will provide examples of this usage.
Note: Schema.org will be one additional syntactical form of using GoodRelations for your site. GoodRelations will remain an independent vocabulary, and usable in RDFa and other RDF syntaxes. The original namespace of GoodRelations will remain the primary location. In particular, consumers of GoodRelations data will be able to execute SPARQL queries using the original GoodRelations namespace and identifiers, because the next service release of GoodRelations will include all necessary mappings.
We were looking for a way of making the rich GoodRelations conceptual model be usable as a direct extension of schema.org so that Webmasters would not have to choose between schema.org and GoodRelations but could instead use both the basic schema.org patterns and the advanced GoodRelations patterns from the same namespace.
The basic approach for the integration is as follows:
The following example shows how an entity of type http://schema.org/Offer can be augmented using the granular pricing elements of GoodRelations for indicating shipping charges. It also shows the usage of business functions that define the bundle of rights you will obtain on the product.
div itemscope itemtype="http://schema.org/Offer" itemid="#offer">
<div itemprop="name">Hepp Personal SCSI Controller Card</div>
<div itemprop="description">The Hepp Personal SCSI is a 16-bit add-on card that allows
<div>
attaching up to seven SCSI devices to your computer.</link itemprop="businessFunction"
< href="http://purl.org/goodrelations/v1#Sell" />
<!-- Unit price -->
div itemscope itemprop="priceSpecification"
< itemtype="http://schema.org/UnitPriceSpecification">Price:
meta itemprop="priceCurrency" content="EUR">Euro:
<span itemprop="price">99.99</span>
<time itemprop="validThrough"
< datetime="2012-11-30T23:59:59Z"></time>
div>
</<!-- Shipment fees -->
Delivery costs todiv itemscope itemprop="priceSpecification"
< itemtype="http://schema.org/DeliveryChargeSpecification">
meta itemprop="eligibleRegion" content="DE">Germany:
<meta itemprop="priceCurrency" content="EUR">Euro:
<span itemprop="price">10.00</span>
<link itemprop="appliesToDeliveryMethod"
< href="http://purl.org/goodrelations/v1#UPS" />(via UPS)
div>
</<!-- other offer properties follow here -->
...div> </
Observe the following details:
1. Some property names differ slightly between the GoodRelations namespace and the schema.org namespace:
GoodRelations | schema.org |
---|---|
hasBusinessFunction | businessFunction |
hasCurrency | priceCurrency |
hasCurrencyValue | price |
hasPriceSpecification | priceSpecification |
2. The enumerations, i.e. the instances of the classes like gr:BusinessFunction and gr:DeliveryMethod are used directly from the GoodRelations namespace. Since schema.org does typically not define lists of enumerations, that seems like the favorite way of adding support for those. So instead of http://schema.org/Sell, as one may assume:
div itemscope itemtype="http://schema.org/Offer" itemid="#offer">
<
...link itemprop="businessFunction" href="http://schema.org/Sell" /> <
we use http://purl.org/goodrelations/v1#Sell for such enumerations.
div itemscope itemtype="http://schema.org/Offer" itemid="#offer">
<link itemprop="businessFunction" href="http://purl.org/goodrelations/v1#Sell" /> <
We use http://schema.org/Movie with the business function LeaseOut and the validity of the lease will be encoded using the eligibleDuration property:
<!-- Some copies of that title -->
div itemprop="about" itemscope itemtype="http://schema.org/Movie" itemid="#video">
<link itemprop="type" href="http://schema.org/SomeProducts" />
<h1 itemprop="name">Pirates of the Carribean: On Stranger Tides (2011)</h1>
<span itemprop="description">Jack Sparrow and Barbossa embark on a quest to
<
find the elusive fountain of youth, only to discover that Blackbeard andspan>
his daughter are after it too.</a itemprop "model" href="http://www.imdb.com/title/tt0325980/">
<a>
More information on imdb.com</<!-- The offer to sell a copy of the video -->
div itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<link itemprop="businessFunction" href="http://purl.org/goodrelations/LeaseOut" />
<div itemprop="priceSpecification" itemscope
Price: <itemtype="http://schema.org/UnitPriceSpecification">$
span itemprop="price">3.99</span>
<meta itemprop="priceCurrency" content="USD">
<time itemprop="validThrough"
< datetime="2012-12-31T23:59:59Z"></time>
div>
</link itemprop="availableDeliveryMethod"
Delivery: < href="http://purl.org/goodrelations/v1#DirectDownload" /> Download
div itemprop="eligibleDuration" itemscope
Validity of the lease: <itemtype="http://schema.org/QuantitativeValue">
span itemprop="value">30</span>-
<meta itemprop="unitCode" content="DAY" >days
<div>
</div> </
A special case is
This used to be gr:durationOfWarrantyInMonths in GoodRelations but will be updated to match the new name and range from schema.org shortly.
Links: