<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type='text/xsl' href='./OpenSocial.xslt' ?>
<?rfc toc="yes"?>
<!DOCTYPE rfc PUBLIC "-//IETF//DTD RFC 2629//EN"
"http://xml.resource.org/authoring/rfc2629.dtd">
<rfc ipr="full3978"
     docName="opensocial-specification-release-notes"
     xmlns:x="http://purl.org/net/xml2rfc/ext">
 <front>
  <title abbrev="OpenSocial Specification Release Notes">OpenSocial
  Specification Release Notes</title>
  <author fullname='OpenSocial and Gadgets Specification Group'>
   <address>
    <email>opensocial-and-gadgets-spec@googlegroups.com</email>
   </address>
  </author>
  <date month="November"
        year="2010" />
  <area>General</area>
  <keyword>OpenSocial</keyword>
  <keyword>social networking</keyword>
  <keyword>REST</keyword>
  <keyword>XML</keyword>
  <keyword>Extensible Markup Language</keyword>
  <keyword>JSON</keyword>
  <keyword>JavaScript Object Notation</keyword>
  <keyword>Atom</keyword>
 </front>
 <middle>
    <section title="Version 1.1">
    <t>Published November 18, 2010</t>
    <t>
    As OpenSocial continues to be adopted, especially in enterprise
    environments, there was a desire by the community to include support for advanced mashup scenarios, specifically, those where gadgets could securely message each other in a loosely coupled manner. OpenSocial 1.1 includes support for this capability, informally known as pub-sub.</t>
     <section title="Major Changes">
        <section title="Inter-Gadget Communication">
            <t>
               Version 1.1 officially
    support an inter-gadget eventing system based upon the <eref target="http://www.openajax.org/member/wiki/OpenAjax_Hub_2.0_Specification">OpenAjax
        Hub</eref>. "The OpenAjax Hub is a set of standard JavaScript functionality
    defined by the OpenAjax Alliance that addresses key interoperability
    and security issues that arise when multiple Ajax libraries and/or
    components are used within the same web page." By incorporating this technology into OpenSocial, gadgets are now able to declare, as part of the module definition, events to which they are able to publish and subscribe. In addition, this specification has reserved several topic namespaces for use by OpenSocial.
    Please refer to the <eref target="./Core-Gadget.xml#interGadgetEventing">Inter-Gadget Eventing</eref> in the Core-Gadget specification for more information.
            </t>
        </section>
     </section>
       <section title="Other Changes">
      <list style="hanging">
        <t hangText="Clarification of language around OAuth">Version 1.0 of the specification contained duplicate language and inconsistencies in the language around the use of OAuth. This version attempts to clean up these and present a more consistent usage model.</t>
      </list>
    </section>
    </section>
 
   <section title="Version 1.0">
     <t>Published March 9, 2010</t>
     <t>With so many different types of websites adopting OpenSocial it has become clear that a "one size fits all" approach isn't appropriate for the OpenSocial spec.  Containers have different types of data they want to make available to clients (sometimes it's social data, sometimes it's not), and some want to expose that data via web services, while others wish to use gadgets.  As such, modularity was a key goal in the OpenSocial 1.0 iteration, allowing implementers to pick and choose the elements of OpenSocial that make sense for their use cases.  OpenSocial 1.0 also defines extension points so containers can add functionality not covered in the spec, but do so in a standard way, making it easier to fold such extensions back into the spec or share extensions across containers.</t>
     <section title="Major Changes">
       <section title="Revised Compliance Section">
     <t>To accommodate the varied use cases of OpenSocial containers, the <eref target="./OpenSocial-Specification.xml#Compliance">Compliance</eref> section has been revised to include four compliance models:</t>
     <list>
       <t><x:highlight>Core API Server</x:highlight> - For containers that wish to expose data in a standard way though web services.</t>
       <t><x:highlight>Core Gadget Server</x:highlight> - For containers that simply want to be able to render gadgets.</t>
       <t><x:highlight>Social API Server</x:highlight> - For containers that wish to expose social data through standard web services that are consistent across containers.</t>
       <t><x:highlight>Social Gadget Server</x:highlight> - For containers that want to render gadgets and provide them access to standard social data.</t>
     </list>
     <t>The spec itself has been reorganized along these lines as well, consolidating all data definitions into the Core-Data.xml and Social-Data.xml files, and creating a separate file for each of the four compliance models.</t>
      </section>
       <section title="Defined how to extend the OpenSocial spec">
         <t>A new <eref target="./OpenSocial-Specification.xml#Extensions">Extensions</eref> section defines how containers can extend OpenSocial in a common way so that extensions can be shared across containers, even if they're not appropriate for the official OpenSocial spec.</t>
       </section>
    </section>
    <section title="Other Changes">
      <list style="hanging">
<t hangText="Gadget Feature Versioning">Features included in a gadget spec should now be versioned.  If no version is specified, the default value is '1.0'.</t>
<t hangText="Complete existing basic groups support">OpenSocial v0.9 defined a groups REST service, so OpenSocial 1.0 adds definitions for the JavaScript API and RPC endpoint.</t>
<t hangText="Deprecated opensocial.* JavaScript API">The opensocial.* namespace has been largely deprecated in favor of the osapi.* API.</t>
<t hangText="Clarify the 'Friend' term">Added text to make it clear the 'friend' may refer to any relationship (e.g. colleague, classmate, etc.).</t>
<t hangText="os:Var variables in templates and data pipelining">Variables may be declared in both inline and custom tag templates with the os:Var tag. This tag may also be used data pipelining to declare global literal variables.</t>
<t hangText="Clarify case sensitivity rules for DataPipeline/ EL variables">The spec now decalres that variable keys are case-sensitive both for Data Pipeline tags and for template parameters.</t>
<t hangText="Define EL access to meta-data about data-pipeline tag response">Added a 'Request' field to the object returned in data pipelining responses so developers can access information about the request that initiated the request.</t>
<t hangText="Clarify escaping behavior of EL">Introduces a "SecurityProfile" feature that gadgets can include to specify if they want EL functions to HTML escape strings or not.</t>
<t hangText="Clarify Custom Tag Template Parameter Behavior">Added language stating that only one value is allowed for a given parameter and define behavior where namespaces are used.</t>
<t hangText="Remove the Background section">The content in this section was split up and distributed to the appropriate sections in the spec.  For example, the overview of data objects like people, activites, and messages now live in Social-Data.xml</t>
<t hangText="Revised Core Gadget Specification">Added documentation for the elements in a gadget XML spec and removed the Metadata and JavaScript Request sections.</t>
<t hangText="REST data 'title' field normalized between Album and MediaItem">MediaItem object now have a 'title' field and the 'caption' field has been deprecated.</t>
<t hangText="Normalize between birthday and DATE_OF_BIRTH">The spec now uses 'birthday' throughout.</t>
<t hangText="Errata in v0.9">Several typos and inaccuracies that we're pointed out since v0.9 was published.</t>
</list>
    </section>
     <section title="Incompatible Changes">
       <t>Several field names have been changed. Containers should continue to support the old values to avoid breaking existing gadgets.  App developers should use the new field names for all new gadgets.</t>
       <texttable align="left">
         <ttcol>Old field name</ttcol>
         <ttcol>New field name</ttcol>
         <c>Account.userid</c><c>Account.userId</c>
         <c>Address.extendedAddress</c><c>Removed. Use Address.streetAddress</c>
         <c>Address.poBox</c><c>Removed. Use Address.streetAddress</c>
         <c>Album.caption</c><c>Album.title</c>
         <c>Name.additionalName</c><c>Name.middleName</c>
         <c>Person.appdata</c><c>Person.appData</c>
         <c>Person.dateOfBirth</c><c>Person.birthday</c>
         <c>Person.languages</c><c>Removed. Use Person.languagesSpoken</c>
       </texttable>
     </section>
   </section>
  <section title="Version 0.9">
   <t>Published April 15, 2009</t>
   <t>The major focus of OpenSocial v0.9 was to make application development,
   testing, and deployment easier and faster, while reducing the learning curve
   for new app developers.</t>
   <section title="Major Changes">
    <section title="Lightweight Javascript APIs">
     <t>OpenSocial v0.9 introduces a new 
     <eref target="./Gadgets-Specification.xml#LightweightJSAPI">Lightweight
     JavaScript API</eref> that makes requesting and parsing data simpler. The
     new API has all the power, flexibility and granularity of the old one, but
     the code speaks for itself:</t>
     <figure>
      <preamble>Requesting the viewer in OpenSocial v0.8</preamble>
      <artwork xml:space="preserve">
var req = opensocial.newDataRequest();
req.add(req.newFetchPersonRequest(opensocial.DataRequest.PersonId.OWNER), "req");
req.send(callback);
</artwork>
     </figure>
     <figure>
      <preamble>Requesting the viewer in OpenSocial v0.9</preamble>
      <artwork xml:space="preserve">
osapi.people.getViewer().execute(callback);
</artwork>
     </figure>
     <t>For backwards compatibility, the new API is available in a separate
     namespace, “osapi” which can be activated with a &lt;Require
     feature="osapi"&gt; directive. All the old APIs are still available via
     &lt;Require feature="opensocial-0.9"&gt;, so existing applications can
     continue working. However, for new application development, the new
     lighter API is the smarter choice. Not only will you save time typing, but
     your JS code will be significantly reduced, improving download times.</t>
    </section>
    <section title="Proxied Content">
     <t>In its first iterations, OpenSocial was limited to running AJAX
     applications inside social networks. However, testing an app that is
     rendered by someone else's server has proven difficult and the heavy
     reliance on JavaScript meant that lots of server-side web programming
     skills were under-utilized.</t>
     <t>Some developers even come up with ways to cram their old way of
     developing web applications into the OpenSocial model – using a
     makeRequest() to download HTML contents from a URL on their servers, and
     then stuff the result into an element’s innerHTML somewhere on the page.
     Clearly these developers were sending us a powerful signal we couldn’t
     ignore.</t>
     <t>
     <eref target="./Gadgets-API-Specification.xml#ProxiedContent">Proxied
     Content</eref> is a formal way for the same use case to be achieved. It
     allows developers to specify a URL for a given &lt;Content&gt; block in
     their gadget spec rather than inline JavaScript and HTML.</t>
     <figure>
      <preamble>An example of proxied content</preamble>
      <artwork xml:space="preserve">
&lt;Content view="home.about" href="http://www.example.com/about.html"&gt;
</artwork>
     </figure>
     <t>When the given view is requested, the container will make a request to
     the URL specified (or fetch the data from cache) and render the HTML
     returned directly in the browser.</t>
     <t>This small code change introduces several advantages:</t>
     <list style="symbols">
      <t>Provides a simpler pathway for converting existing web applications
      into OpenSocial apps.</t>
      <t>Allows containers to sanitize content before rendering, protecting all
      the parties involved.</t>
      <t>Reduces the number of server round-trips required to render an
      application, especially when combined with data pipelining. Fewer round
      trips significantly reduces latency for end users.</t>
     </list>
    </section>
    <section title="Data Pipelining">
     <t>A common pattern in OpenSocial apps to date is for apps to request
     social data from the container when first loaded using a DataRequest, then
     send that data to remote servers using a makeRequest. Using JavaScript to
     perform these operations requires the container to load the app's IFrame
     before any requests are made, leaving the end user staring at a
     'Loading...' message.</t>
     <t>
     <eref target="./OpenSocial-Data-Pipelining.xml">Data
     Pipelining</eref> defines a simple declarative XML language that allows the
     developer to specify what social data their application will need, so the
     container can make that data immediately available by including it in the
     app's IFrame. When used with proxied content, the social data is sent to
     the URL specified in the href attribute of the &lt;Content&gt;
     element.</t>
     <figure>
      <preamble>Using data pipelining and proxied content</preamble>
      <artwork xml:space="preserve">
&lt;Content type="html" href="http://www.example.com/userInfo.php"&gt;&lt;![CDATA[
  &lt;script xmlns:os="http://ns.opensocial.org/2008/markup" type="text/os-data"&gt;
    &lt;os:ViewerRequest key="viewer"/&gt;
  &lt;/script&gt;
]]&gt;&lt;/Content&gt;
</artwork>
     </figure>
     <t>In this example, the container sends the viewer's information to the
     given URL (i.e. http://www.example.com/userInfo.php), where the PHP file
     can access the viewer's ID and return HTML containing the appropriate
     information for that user.</t>
    </section>
    <section title="Templates and OSML">
     <t>Until now, the standard approach to rendering data into OpenSocial apps
     has involved manipulating a DOM element's innerHTML and/or dynamically
     creating DOM elements. These methods for generating UI can be unwieldy,
     difficult to maintain, and aren't easily reusable. For example, imagine
     handing off the following snippet to a HTML/CSS programmer to improve the
     UI design:</t>
     <figure>
      <artwork xml:space="preserve">
var link = document.createElement('a');
link.href = song.url;
document.getElementById('outputDiv').appendChild(link);
var img = document.createElement('img');
img.src = song.albumThumbnail;
link.appendChild(img);
link.appendChild(document.createTextNode(song.title + ' BY ' + song.artist + ' FROM ALBUM ' + song.album));
</artwork>
     </figure>
     <t>
     <eref target="./OpenSocial-Templating.xml">OpenSocial Templates</eref> give
     you a straightforward approach to creating data-driven UI in OpenSocial
     gadgets while separating markup from programming logic. The result is code
     that is cleaner, more streamlined, reusable, and much easier to maintain.
     With OpenSocial Templates, the example above becomes more
     HTML-friendy:</t>
     <figure>
      <artwork xml:space="preserve">
&lt;script type="text/os-template"&gt;
 &lt;a href="${url}"&gt;
 &lt;img src="${albumThumbnail}"/&gt;
 ${title} BY ${artist} FROM ALBUM ${album}
 &lt;/a&gt;
&lt;/script&gt;
</artwork>
     </figure>
     <t>OpenSocial Templates also support looping and conditional display,
     giving developers the flexibility to create elaborate UI elements with
     less code.</t>
     <t>
     <eref target="./OpenSocial-Markup-Language-Tags.xml">OSML Markup</eref> is
     a series of special tags that can be used within templates – these tags
     can be used to accomplish common tasks (such as displaying user Badges
     with proper container “bling”), or to safely perform what would otherwise
     be unsafe operations (for example, including a Flash movie while
     restricting its access or executing JavaScript within the container memory
     space).</t>
     <t>OSML is extensible. All containers must provide a small set of standard
     tags, but each container is free to add its own extension tags (although
     cooperation is encouraged to avoid conflicts). Furthermore, app developers
     can create Custom Tag templates to build up a library of OSML tags to be
     used in their own applications.</t>
    </section>
   </section>
   <section title="Other Changes">
    <list style="hanging">
     <t hangText="Alignment with Portable Contacts">Several changes to ensure
     that the data formats for OpenSocial REST and Portable Contacts are
     compatible.</t>
     <t hangText="Ability to page through activities">Adds support for
     startIndex and count parameters when requesting activities.</t>
     <t hangText="Content Rewriting">Adds support for rewriting the content of
     a gadget and allows developers to control the behavior of the rewriter by
     introducing a new optional feature "content-rewrite". The content-rewrite
     feature defines a set of rewriting operations that a container can perform
     on rendered and proxied content and rules to allow developers to control
     which content the rewriter can operate on.</t>
     <t hangText="Albums and Media Items">Adds support for accessing photos and
     other media items.</t>
     <t hangText="Upload Support">Allows upload of files through REST and
     JSON-RPC calls to the OpenSocial container. This mechanism can be used to
     support many capabilities such as uploading audio/video/image content to
     the container for inclusion in a user's album or creating activity stream
     entries that contain uploaded media item content.</t>
     <t hangText="Logging Support">Exposes JavaScript functions which can be
     used by developers and libraries to output logging information. This
     creates a single place for developers to look when debugging their
     application, smoothing over a barrier to adoption.</t>
     <t hangText="International Formatting">Adds internationalization support
     for currency, date time, and numeric formatting.</t>
     <t hangText="Invalidation">Provides an additional mechanism for gadget
     developers to control the lifecycle of specific HTTP content cached by
     OpenSocial containers beyond what is already available through standard
     HTTP cache control headers. This capability allows developers to
     explicitly invalidate the content the container has fetched on behalf of a
     user (via proxied rendering or authenticated/signed makeRequest calls) and
     static resources such as gadget specs and message bundles</t>
     <t hangText="Messaging Support">Extends the current messaging model to
     support read/write access via JavaScript and REST/RPC.</t>
     <t hangText="OAuth Popup">Using OAuth from a gadget requires opening a
     pop-up window to the OAuth service provider. We've added a JavaScript
     method to handle the some nuances required to get this right and provide a
     good user experience, such as avoiding popup blockers and detecting when
     the popup has been closed.</t>
     <t hangText="Extended View Support">Allows developers to define named
     views in their gadget spec and navigate to these views using JavaScript or
     templates.</t>
     <t hangText="Simplified Persistence API">Allows per-user key/value pairs
     stored on the container to be accessed as if they were extended profile
     fields.</t>
    </list>
   </section>
   <section title="Incompatible Changes">
    <t>None</t>
   </section>
  </section>
  <section title="Version 0.8.1">
   <t>Published September 25, 2008</t>
   <t>The server-to-server protocols are the primary focus of version 0.8.1.
   The Person schema has been aligned with the Portable Contacts effort, and an
   optional RPC proposal has been added.</t>
   <section title="OpenSocial specification changes">
    <list style="hanging">
     <t hangText="Server side API changes">Server to server functionality has
     been expanded with the addition of a 
     <eref target="./RPC-Protocol.xml">JSON RPC protocol</eref>, which will
     allow for simpler batching of requests. To maintain naming consistency,
     the RESTful API is now known as the RESTful protocol.</t>
     <t hangText="OpenSocial IDs now allow '-', '_', and '.' characters">
     OpenSocial IDs may now contain "-", "_", and "." in addition to
     alphanumeric characters.</t>
     <t hangText="Aligned with Portable Contacts"></t>
    </list>
   </section>
   <section title="Incompatible changes">
    <list style="hanging">
     <t hangText="RESTful protocol incompatibilities">The RESTful protocol has
     renamed or deleted many query and response fields. Please consult the
     following list of RESTful protocol changes for more detailed
     information.</t>
    </list>
   </section>
   <section title="RESTful protocol changes">
    <list style="hanging">
     <t hangText="Compatibility with PortableContacts">By implementing the
     RESTful protocol, a container now becomes technically compatible with the 
     <eref target="http://portablecontacts.net">Portable
     Contacts</eref> specification. Many of the following changes were
     implemented to facilitate this compatibility.</t>
     <t hangText="New format=xml response type">Requests will support the
     format=xml parameter. People requests must be made in either format=xml or
     format=json.</t>
     <t hangText="Containers MUST implement random access pagination">
     Containers are now required to implement paging of results via the
     startIndex and itemsPerPage parameters.</t>
     <t hangText="Removal of the link rel=next Collection field">This parameter
     has been removed from JSON Collection responses.</t>
     <t hangText="Removal of the author Collection field">This parameter has
     been removed from JSON collection responses.</t>
     <t hangText="Containers SHOULD support returning all contacts at once">It
     should be possible to return all the requested contacts in a single
     request, however containers may choose to limit the maximum items returned
     per request for performance reasons.</t>
     <t hangText="Default itemsPerPage behavior">It is up to each container to
     define the number of contacts returned when no itemsPerPage parameter is
     specified in a request.</t>
     <t hangText="Changes to sorting parameters">The orderBy parameter has been
     renamed to sortBy. A new sortOrder parameter has been introduced, with
     values ascending and descending. The default value of sortOrder is
     ascending.</t>
     <t hangText="New updatedSince query parameter">Queries may now specify
     that results only contain entries that have been updated in a specified
     interval.</t>
     <t hangText="Responses indicate whether sorting and filtering have taken place">
     Since sorting and filtering on arbitrary fields can be too expensive for a
     container to support, responses now contain top-level response fields
     filtered, sorted, and updatedSince, to indicate whether the content in the
     response was filtered according to the original request.</t>
     <t hangText="Ability to request deleted Person objects">Using a new
     @deleted selector and the updatedSince parameter, it is possible to
     retrieve all contacts that were deleted since the supplied date.</t>
     <t hangText="Person responses MUST contain at least the id and name fields">
     Containers must return at least a name and an id when returning Person
     data.</t>
     <t hangText="A profile URL is a URL, too">The value returned in the
     profileUrl Person field MUST also be returned in the urls field, as a
     type=profile entry.</t>
     <t hangText="New Person photos field">Person records now include a photos
     field, which will contain a list of entries with sub-fields url, type and
     primary. If the thumbnailUrl field is returned on a Person object, this
     url must also be present in the photos field, as a type=thumbnail
     entry.</t>
     <t hangText="New Person ims field">Person records now include an ims
     field, which will contain a list of entries with sub-fields value,
     type,and primary. The type values of "aim", "gtalk", "icq", "xmpp", "msn",
     "skype", "qq" and "yahoo" are defined to match several commonly used
     services, although new types may be defined as well.</t>
     <t hangText="New Person accounts field">Person records now include an
     accounts field, used to represent other services where the Person has
     accounts. This field will contain a list of entries with sub-fields
     domain, userid, username, and primary.</t>
     <t hangText="Plural Person fields get a primary sub-field">The emails,
     urls, ims, phoneNumbers, addresses, organizations, and photos Person
     fields will recieve an additional primary sub-field which will indicate
     which field in the list (if any) is the "primary value" of that type.</t>
     <t hangText="Combine the jobs and schools plural fields to organizations">
     Entries for jobs and schools will be combined into one array of
     Organization structures named organizations. The Organization structure
     will be extended with a type sub-field, with canonical values of "job" and
     "school".</t>
     <t hangText="Plural Person fields standardize on a value field">The
     primary textual value of plural Person fields should be stored in a
     sub-field named value. This will require renaming emails.address,
     phoneNumbers.number, urls.address and all instances of the {Enum}.key
     field to {Enum}.value. The addresses, accounts, and organizations fields
     are complex and do not have the concept of a value field. For the purposes
     of sorting and filtering, the corresponding "primary" sub-fields on these
     fields will be addresses.formatted, accounts.domain, and
     organizations.name.</t>
     <t hangText="The Person.gender field is now a string">Person records will
     now treat gender as a string field, with the canonical values of "male"
     and "female".</t>
     <t hangText="Addresses no longer contain extendedAddress or poBox sub-fields">
     The extendedAddress and poBox Address subfields have been removed in favor
     of storing a complete (and potentially multi-line) address in the
     streetAddress sub-field.</t>
     <t hangText="Rename unstructuredAddress to formatted">The
     unstructuredAddress sub-field of an Address is renamed to formatted.</t>
     <t hangText="Rename dateOfBirth to birthday">The dateOfBirth Person field
     is renamed to birthday.</t>
     <t hangText="Rename timeZone to utcOffset">The timeZone Person field is
     renamed to utcOffset.</t>
     <t hangText="Definition of nickname">The nickname Person field is now
     defined as "the casual way to address this person in real life".</t>
     <t hangText="Default set of Person fields is specified">If a Person
     request is missing the fields query parameter, the minimal set of fields
     that must be returned by default have been defined as id, name, and
     thumbnailUrl, to match the defaults for the JS API.</t>
     <t hangText="Query for supportedFields">The RESTful protocol now defines
     the endpoints /people/@supportedFields and /activities/@supportedFields,
     which will return lists of the Person and Activity fields supported by the
     container.</t>
     <t hangText="Removal of indexBy">The indexBy query parameter has been
     removed.</t>
     <t hangText="The Activity.title field is now an HTML string">The Activity
     title field is now treated as a string that may contain HTML markup,
     instead of a complex data object.</t>
     <t hangText="Rename unstructured to formatted">The unstructured Name field
     is renamed to formatted.</t>
     <t hangText="New displayName field added">The displayName field is added
     as a required top-level Person field.</t>
    </list>
   </section>
   <section title="RPC protocol changes">
    <list style="hanging">
     <t hangText="Introducing the RPC Protocol">A new, optional 
     <eref target="./RPC-Protocol.xml">JSON RPC protocol</eref> has been
     introduced to simplify batching and complex server-to-server
     operations.</t>
    </list>
   </section>
   <section title="opensocial.* JavaScript changes">
    <list style="hanging">
     <t hangText="New opensocial.IdSpec.GroupId enum">This enum may be used to
     construct an IdSpec object, using either the values of
     opensocial.IdSpec.GroupId.FRIENDS and opensocial.IdSpec.GroupId.SELF.</t>
     <t hangText="supportsField responses specified">The return values for
     opensocial.Environment.supportsField() calls have been defined as true
     when a container supports a field, and false otherwise.</t>
    </list>
   </section>
   <section title=" gadgets.* JavaScript changes">
    <list style="hanging">
     <t hangText="No changes have been made to the gadgets.* JavaScript API">
     </t>
    </list>
   </section>
   <section title="Gadgets XML changes">
    <list style="hanging">
     <t hangText="Support for OAuth in the &lt;Preload&gt; element">The
     &lt;Preload&gt; element now supports the value of "oauth" for its authz
     attribute. If authz=oauth is specified, then the oauth_service_name,
     oauth_token_name, oauth_request_token, and oauth_request_token_secret
     attributes will be accepted. These attributes have the same semantics and
     defaults as their corresponding gadgets.io.makeRequest parameters.</t>
    </list>
   </section>
  </section>
  <section title="Version 0.8">
   <t>Published May 27, 2008</t>
   <section title="OpenSocial specification changes">
    <list style="hanging">
     <t hangText="RESTful
            API">The OpenSocial specification now requires that containers
implement a REST based API according to the RESTful API specification. This
allows for servers, mobile devices, and desktop applications to interact with
OpenSocial containers. See the 
     <eref target="./REST-API.xml">specification</eref> for details.</t>
    </list>
   </section>
   <section title="Incompatible changes">
    <t>Version 0.8 introduces several changes to the OpenSocial JavaScript APIs
    that are not compatible with previous versions. Because most containers
    support multiple API versions, existing gadgets will continue to use the
    0.7 API and will work as before. However, gadgets that are updated to take
    advantage of 0.8 features will have to use the newer versions of these
    changed APIs. The incompatible changes are:</t>
    <list style="hanging">
     <t hangText="VIEWER_FRIENDS and OWNER_FRIENDS have been removed">Instead,
     use an IdSpec object with the appropriate NETWORK_DISTANCE parameter. See
     the 
     <eref target="./OpenSocial-Specification.xml#opensocial.DataRequest.newFetchPeopleRequest">
     API documentation</eref> for details.</t>
     <t hangText="opensocial.Activity.MediaItem is now opensocial.MediaItem">
     </t>
     <t hangText="LookingFor object">opensocial.Person.Field.LOOKING_FOR used
     to return a string, now returns an opensocial.Enum.LookingFor object.</t>
     <t hangText="opensocial.DataRequest.prototype.newFetchActivitiesRequest now returns a Collection">
     </t>
    </list>
   </section>
   <section title="opensocial.* JavaScript changes">
    <list style="hanging">
     <t hangText="Greater developer control over data escaping">Automatic data
     escaping has become easier to control with the addition of an escapeType
     parameter to the newFetchPersonAppData and getField methods, which allow a
     developer to specify whether the returned data should be escaped.</t>
     <t hangText="Persistence data treated as JSON">All data stored in the
     Persistence API is now treated as JSON-encoded. This allows for easier
     storage of complex objects as well as smart data escaping by the
     container.</t>
     <t hangText="A method to remove Persistence data">The 
     <eref target="./OpenSocial-Specification.xml#opensocial.DataRequest.newRemovePersonAppDataRequest">
     newRemovePersonAppDataRequest</eref> method was introduced to allow
     developers to delete stored data from the Persistence API.</t>
     <t hangText="Additional Person fields">The Person object has new 
     <eref target="./OpenSocial-Specification.xml#opensocial.Person.Field.HAS_APP">
     hasApp</eref> and 
     <eref target="./OpenSocial-Specification.xml#opensocial.Person.Field.NETWORK_PRESENCE">
     networkPresence</eref> fields. The lookingFor field has been changed to a
     more structured format.</t>
     <t hangText="More flexibility when requesting people">The new 
     <eref target="./OpenSocial-Specification.xml#opensocial.IdSpec">
     IdSpec</eref> object provides a structured way to define a group of people,
     including a NETWORK_DISTANCE parameter which will allow for querying
     friends of friends.</t>
     <t hangText="Additional filters for requesting people">The new 
     <eref target="./OpenSocial-Specification.xml#opensocial.DataRequest.FilterType.TOP_FRIENDS">
     topFriends</eref> and isFriendsWith fields allow developers to filter the
     results of Person requests in new ways.</t>
     <t hangText="Support for templates in messages">The Message object now has
     titleId and bodyId fields so that messages can use templates in the same
     way that activities do.</t>
     <t hangText="Additional error codes">Responses may now contain the new 
     <eref target="./OpenSocial-Specification.xml#opensocial.ResponseItem.Error.LIMIT_EXCEEDED">
     limitExceeded</eref> error code to indicate that a quota was exceeded by
     the request.</t>
     <t hangText="Support for container URL templates">The 
     <eref target="./OpenSocial-Specification.xml#opensocial.getContainerUrlTemplate">
     getContainerUrlTemplate</eref> method was added to simplify constructing
     navigation URLs.A container is now able to specify a template for the
     application's URL, so developers can construct navigation links without
     making synchronous JavaScript calls.</t>
     <t hangText="Greater control over requestShareApp application flows">The
     requestShareApp method now lets the developer set navigation targets that
     application users will see, both after accepting invites and also when
     sharing the application with friends.</t>
    </list>
   </section>
   <section title="gadgets.* JavaScript changes">
    <list style="hanging">
     <t hangText="Support for OAuth authorization">The
     gadgets.io.AuthorizationType.AUTHENTICATEDparameter has been deprecated in
     favor of the newly added gadgets.io.AuthorizationType.OAUTH. Gadgets may
     now consume web services requiring OAuth authorization.</t>
     <t hangText="Clarification of signed request functionality">The
     description of signed makeRequest calls has become much more detailed in
     the spec. The names of parameters that containers may or must include have
     been standardized, and key management practices are spelled out in
     detail.</t>
     <t hangText="Support for refresh intervals on proxied content">Calls to
     gadgets.io.getProxyUrl and gadgets.io.makeRequest may now include a
     parameter specifying how often the container should refresh the content
     which lives at the supplied URL.</t>
     <t hangText="Support for specifying a target OWNER when navigating between views">
     Calls to gadgets.views.requestNavigateTo may now specify an OWNER's ID
     number in order to navigate between viewson different users' profiles.</t>
     <t hangText="A method to sanitize HTML">The gadgets.util.sanitizeHtml
     method was added to convert potentially malicious HTML code to text safe
     for display.</t>
     <t hangText="Standardization of view types">The gadgets.views.ViewType
     enumeration has been modified to reflect the most well-known set of views:
     HOME, PROFILE, CANVAS, and PREVIEW.</t>
     <t hangText="A method for gadgets on the same view to communicate with each other">
     The new PubSub feature enables developers to send data between multiple
     gadgets on the same view.</t>
    </list>
   </section>
   <section title="Gadgets XML changes">
    <list style="hanging">
     <t hangText="Support for inline message bundles">Message bundles can now
     be inlined into the gadget XML, and no longer have to be in a separate
     file.</t>
     <t hangText="Support for preloading remote data during the gadget render">
     Gadgets can use the new &lt;Preload&gt; element to instruct the container
     to fetch data from a remote source during the gadget rendering process.
     This data will be inlined in the rendered output and available immediately
     when gadget code is executed. Use of this method should reduce latency for
     gadgets that depend on content from remote servers to render.</t>
     <t hangText="Support for signed requests when preloading data">The new
     &lt;Preload&gt; element also supports preloading responses from signed
     requests. Developers should add the authz="signed" attribute and value to
     the &lt;Preload&gt; element to specify that a request for the URL should
     be signed by the container.</t>
     <t hangText="Support for link elements in ModulePrefs, for container specific links">
     There is a new &lt;Link&gt; element that can be used within the gadget
     ModulePrefs section. This change is intended to allow containers to
     support new link types, such as gadgetsHelp and gadgetsSupport.</t>
     <t hangText="Additional display fields that can use message bundle substitutions">
     To improve localization support, substitutions are now supported for all
     hangman variables that get displayed to users (e.g. all Module.ModulePrefs
     attributes, UserPref@display_name)</t>
     <t hangText="Support for specifying OAuth URLs in the gadget spec">The
     ModulePrefs section can now be used to specify URLs for usage of
     OAuth.</t>
     <t hangText="Support for container lifecycle events such as install and uninstall">
     Gadgets now support lifecycle events. You can place link tags in gadget
     xml that specify URLs the container should hit when a specified type of
     event occurs. This way, a gadget can be notified of all app installs or
     uninstalls.</t>
     <t hangText="Support for specifying a preferred height and width on each content section of the gadget">
     You can use the new preferredHeight and preferredWidth tags to specify
     default height and width for each Content section.This means that gadgets
     with multiple views can have different default heights.</t>
    </list>
   </section>
  </section>
  <section title="Version 0.7">
   <t>Published January 25, 2008</t>
   <t>Version 0.7 of the OpenSocial JavaScript API is intended to be the first
   iteration that can fully support rich, social applications. All features are
   covered in the 
   <eref target="http://code.google.com/apis/opensocial/docs/0.7/reference/">
   API Reference (v0.7)</eref>, but differences between version 0.6 and version
   0.7 are explained in this section.</t>
   <list style="hanging">
    <t hangText="Standardized profile information fields">This release adds a
    slew of standard fields that you can access about a Person. These include
    location, schools, pets, movies, sports, and 
    <eref target="http://code.google.com/apis/opensocial/docs/0.7/reference/opensocial.Person.Field.html">
    more</eref>. However, keep in mind that a container may not have all of
    this information available so your application should always check first by
    using the supportsField method.</t>
    <t hangText="Support for viral growth">Two new methods allow your
    application to send messages on behalf of a user. You can invite a user's
    friends to install your application with the requestShareApp method. You
    can also send an application-specific message with the requestSendMessage
    method. Both of these methods require the user sending the message to
    authorize the request first.</t>
    <t hangText="Activity templates">You can now define activity messages with
    placeholders for pieces of applicaton or user data. This separation of data
    and presentation allows multiple activities to be combined into activity
    summaries?consolidated bundles of activities that let users know what their
    friends are up to without having to wade through a flood of messages. For
    example, instead of seeing five new updates about friends that installed a
    new application, you would see one update that says five of your friends
    added the application. For details on how to use activity templates in your
    application, see 
    <eref target="http://code.google.com/apis/opensocial/docs/0.7/reference/opensocial.Activity.html">
    opensocial.Activity</eref> in the OpenSocial API reference.</t>
    <t hangText="Simplified persistence API">Support for global and
    instance-scoped application data has been removed from the API. Global
    application data can be implemented using feeds (that can be prefetched for
    performance) and other web standards. Instance-scoped application data can
    be implemented on top of user-scoped data by including the module ID of the
    application in the key.</t>
   </list>
   <section title="Introducing the Gadgets Specification">
    <t>As part of the Apache Shindig project, gadgets have been open sourced.
    The new 
    <eref target="./Gadgets-API-Reference.xml">Gadgets
    Specification</eref> defines the gadgets.* JavaScript namespace where you'll
    find that some of your favorite methods from the Gadgets API have been
    re-namespaced into a cleaner API for your convenience and clarity. For
    example, _IG_Adjust_IFrame_Height is now available as
    gadgets.window.adjustHeight (and don't worry, these updates are backwards
    compatable, so the old methods will work with Shindig-based renderers).</t>
    <t>Some notable updates in the Gadgets API include:</t>
    <list style="hanging">
     <t hangText="More ways to be 'environmentally friendly.'">The Gadgets API
     provides methods that allow your application to get more information about
     how a container will render your gadget. You can get information about the
     dimensions available for your gadget with
     gadgets.windows.getViewportDimensions, and obtain information for
     internationalization, such as the country and language of the user, using
     the gadgets.Prefs object. You can also use the gadgets.skins.getProperty
     method to get information about the look and feel of the container, such
     as the color of the font or background.</t>
     <t hangText="Views - formerly known as surfaces">The methods for getting
     the current view, or navigating between views, have been removed from the
     Environment class and now live in the gadgets.views.* namespace.</t>
     <t hangText="Separate specifications for each view">The 
     <eref target="http://code.google.com/apis/gadgets/docs/gadgets-xsd.html">
     Gadgets XSD</eref> has been extended to support multiple &lt;Content&gt;
     blocks, where each &lt;Content&gt; block declares the views it should be
     rendered on. You can also use gadgets.views.getCurrentView to get the
     current view at run-time. For more information, see the 
     <eref target="http://code.google.com/apis/gadgets/docs/spec.html">Gadgets
     Specification</eref>.</t>
     <t hangText="Fetching remote content is now handled by the Gadgets API">
     The makeRequest method has been moved from the opensocial.* namespace to
     gadgets.io.makeRequest. Also, two new fields, HEADERS and POST_DATA, have
     been added to gadgets.io.RequestParameters so you can now send arbitrary
     HTTP headers or POST data in your request.</t>
     <t hangText="Determining what features a container supports is now handled by the Gadgets API.">
     The hasCapability method has been removed from the opensocial.Environment
     class. To check whether a function is supported by your current container,
     you now use gadgets.util.hasFeature.</t>
     <t hangText="Built-in JSON support.">You can now use the stringify and
     parse methods of the gadgets.json.* package to store objects using the 
     <eref target="http://code.google.com/apis/opensocial/docs/0.7/spec.html#persistence">
     Persistence API</eref> without having to import a third-party library. See
     the 
     <eref target="http://code.google.com/apis/opensocial/docs/0.7/reference.html/">
     OpenSocial API Reference</eref> for more info.</t>
    </list>
   </section>
  </section>
  <section title="Version 0.6">
   <t>Published December 21, 2007</t>
   <t>The OpenSocial JavaScript API (v0.6) introduces several new features.
   These are all covered in the 
   <eref target="http://code.google.com/apis/opensocial/docs/0.6/spec.html">API
   Specification (v0.6)</eref>, but differences between version 0.5 and version
   0.6 are explained in this section.</t>
   <list style="hanging">
    <t hangText="The ability for a gadget to respond differently according to its environment">
    The new Environment class includes a hasCapability method that takes a
    function name and tells you if that function is available in your current
    container. It also includes a supportsField method to check if a particular
    field is supported in person or activity objects. These new methods allow
    apps to cleanly handle container-specific extensions if they're provided.
    The Environment class also includes a getDomain method, which tells you
    which site you are in (such as orkut.com or myspace.com). However, keying
    on domain should only be used if the more explicit environment variables
    aren't sufficient.</t>
    <t hangText="Support for navigating from one surface to another">This
    release also adds a new Surface class. You can use
    opensocial.requestNavigateTo to take your gadget from one page of a
    container to another (for example, to link the profile to the canvas page).
    This call takes a Surface object, which you get from an Environment object
    (opensocial.getEnvironment()). The environment's getSupportedSurfaces
    method tells you which surfaces the container supports, and getSurface
    tells you which one you are currently on. The getParams method returns all
    of the parameters passed in by the requestNavigateTo call if any were
    requested. The Surface class currently has only two methods, getName and
    isPrimaryContent, but more methods may be added as the API progresses.</t>
    <t hangText="Tighter permission control">The beginning of tighter
    permission control is introduced in v0.6. Now, when a gadget uses a data
    request to fetch a viewer from the server, it is only returned if that
    gadget has access. If the gadget does not have access, one of the newly
    defined standard error codes, opensocial.ResponseItem.Error.UNAUTHORIZED,
    is returned instead. A gadget can also check ahead of time for its access
    by using the new opensocial.hasPermission call. If access is denied, you
    can use opensocial.requestPermission to ask the viewer for the specified
    permission. Of course, some containers may always grant viewer access, and
    some may always deny, but now this decision is up to the container.</t>
    <t hangText="Enhanced support for fetching remote content">Another addition
    to the API is the new opensocial.makeRequest method. This is an enhancement
    to the current gadget API 
    <eref target="http://code.google.com/apis/gadgets/docs/remote-content.html">
    IG_Fetch...</eref> methods. The opensocial.makeRequest method allows for
    POSTs as well as GETs, and you can specify whether you want your data fetch
    to be signed or even authenticated.</t>
    <t hangText="Activities have been streamlined">The Stream class is gone,
    and its fields are now part of the Activity class. The summary field on the
    Activity class has been removed because title and body seem to be
    sufficient for most developer's needs. Folders were deprecated in 0.5 and
    have been completely removed now.</t>
   </list>
   <t>When requesting people, instead of using broad categories (e.g. BASIC,
   MATCHING, FULL, and so on) for the
   opensocial.DataRequest.PeopleRequestFields.PROFILE_DETAILS value, you can
   now specify an array of Person fields (which you should check in advance
   with the supportsField method). Specifying fields instead of categories
   allows you to tailor the calls to deliver exactly what you need.</t>
   <t>Lastly, the init method on the container has been deleted. Make sure to
   use the requires tag in your gadgets to fetch opensocial. All other ways of
   initializing opensocial in your gadget are deprecated.</t>
  </section>
 </middle>
 <back>
 </back>
</rfc>

