Home » Community » Proposal » Specifications » OpenSearch » Extensions » Commerce » 1.0 » Draft 1
Contents |
[edit] Notice
This is a draft document for public review.
[edit] Introduction
The OpenSearch Commerce Extension allows search engines to include information about previewing and purchasing digital commerce items in search results.
Example of a search result that includes commerce elements:
<feed xmlns="http://www.w3.org/2005/Atom"
xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/"
xmlns:advertisement="http://a9.com/-/opensearch/extensions/advertisement/1.0/">
<!-- ... -->
<entry>
<!-- ... -->
<com:adultContent>false<com:adultContent>
<com:partnerId>1234567</com:partnerId>
<com:rating>5.0</com:rating>
<com:price value="2" unit="GBP" terms="unlimited"/>
<com:attribution>
<com:label atom:type="TEXT">By Example.com</com:label>
<atom:link href="http://example.com"/>
</com:attribution>
</entry>
<!-- ... -->
</feed>
[edit] Namespace
The XML namespace of the OpenSearch Commmerce Extension is:
-
http://a9.com/-/opensearch/extensions/commerce/1.0/
This namespace and a corresponding namespace prefix must be included when the extension is used in an OpenSearch response.
[edit] Elements
The OpenSearch Advertisement extension introduces the following elements.
[edit] The "adultContent" element
The adultContent element specifies whether the item contains age-restricted content. The definition of "age-restricted content" is defined within locales and out of scope of this document.
- Restrictions: The element value is boolean (true or false). A true value indicates that the item contains age-restricted content.
- Requirements: This element may appear zero or one time.
Examples of adultContent elements:
<com:adultContent>false<com:adultContent>
<com:adultContent>true<com:adultContent>
[edit] The "attribution" element
The attribution element specifies a contractually-obligated attribution to be displayed with the digital commerce item.
- Requirements: This element may appear zero or one time.
| Sub-element Name | Required? | Sub-element Value |
| label | Yes | An atom:text construct that specifies the label to display alongsite the digital commerce item. |
| link | Yes | An Atom Link element that is the link target of the attribution label. |
Examples of attribution elements:
<com:attribution> <com:label atom:type="TEXT">By Example.com</com:label> <atom:link href="http://example.com"/> </com:attribution>
<com:attribution> <com:label atom:type="TEXT">Movies by Example.com</com:label> <atom:link href="http://example.com"/> </com:attribution>
[edit] The "partnerId" element
The partnerId element is used to specify a unique identifier of a browsable or consumable digital commerce item in a partner content catalog.
- Restrictions: The element value is a String identifier of the item in a partner content catalog.
- Requirements: This element may appear zero or one time.
Examples of partnerId elements:
<com:partnerId>1234567</com:partnerId>
[edit] The "price" element
The price element specifies the purchase terms, price and currency for a consumable digital commerce item.
- Restrictions: The element value is undefined.
- Requirements: This element may appear zero or more times.
| Attribute Name | Attribute Value |
| value | A float indicating the value of the consumable item. |
| unit | The currency unit of the price. |
| terms | The terms of use for purchasing the product at this price. |
| expiration | Expiration information for the purchase. |
Examples of price elements:
<com:price value="1.99" unit="USD" terms="Trial" expiration="10 days"/>
<com:price value="2" unit="GBP" terms="unlimited"/>
[edit] The "rating" element
The rating element specifies a numeric rating for a content item. Rating semantics for digital commerce items are out of scope for this specification.
- Restrictions: The element value is a float rating value between 0.0 and 5.0, inclusive.
- Requirements: This element may appear zero or one time.
Examples of rating elements:
<com:rating>1.5</com:rating>
<com:rating>5.0</com:rating>
[edit] Authors
Gail Rahn Frederick, Damon Lanphear and Michael "Luni" Libes <opensearch@medio.com> (Medio Systems)
[edit] License
This document is made available by Medio Systems subject to the terms of the Creative Commons Attribution-ShareAlike 3.0 License.