This JEP defines a protocol for making annotations about roster items and other entities.
WARNING: This Standards-Track JEP is Experimental. Publication as a Jabber Enhancement Proposal does not imply approval of this proposal by the Jabber Software Foundation. Implementation of the protocol described herein is encouraged in exploratory implementations, but production systems should not deploy implementations of this protocol until it advances to a status of Draft.
Type: Standards Track
Last Updated: 2004-11-05
JIG: Standards JIG
Approving Body: Jabber Council
Dependencies: XMPP Core, JEP-0001, JEP-0049
Superseded By: None
Short Name: Not yet assigned
This Jabber Enhancement Proposal is copyright 1999 - 2004 by the Jabber Software Foundation (JSF) and is in full conformance with the JSF's Intellectual Property Rights Policy <http://www.jabber.org/jsf/ipr-policy.php>. This material may be distributed only subject to the terms and conditions set forth in the Open Publication License, v1.0 or later (the latest version is presently available at <http://www.opencontent.org/openpub/>).
The preferred venue for discussion of this document is the Standards-JIG discussion list: <http://mail.jabber.org/mailman/listinfo/standards-jig>.
The Extensible Messaging and Presence Protocol (XMPP) is defined in the XMPP Core (RFC 3920) and XMPP IM (RFC 3921) specifications contributed by the Jabber Software Foundation to the Internet Standards Process, which is managed by the Internet Engineering Task Force in accordance with RFC 2026. Any protocols defined in this JEP have been developed outside the Internet Standards Process and are to be understood as extensions to XMPP rather than as an evolution, development, or modification of XMPP itself.
The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119.
Many modern IM clients offer functionality that enables users to make notes about items in their roster. This comes in handy if users don't have meaningful information in their vCard or if you need to remember additional things related with another entitity.
This specification defines a protocol for storing annotations about a given set of entities. Its primary goal is to enable users to store some personal piece of information with their roster items. Private XML Storage  provides us with a convenient method for storing user data on the server using jabber:iq:private; all we need to do is define a namespace and schema for storing this sort of information. For this the 'storage' element introduced at Bookmark Storage  is being reused and a new namespace of 'storage:notes' is added.
A server MUST implement JEP-0049 so that clients can use the functionality described in this document.
Annotations are stored in the jabber:iq:private namespace. A storage element marked by the storage:notes namespace will contain a collection of 'note' elements, each representing a 'note' about a given entity. For any given JID there MUST NOT be more than one note.
Attribute 'jid' of the 'note' element SHOULD be used without a resource. Along with the annotation a client MAY choose to store creation time ('cdate') and modification time ('mdate') as attributes to the 'note' element containing the note.
<iq type='set' id='a1'> <query xmlns='jabber:iq:private'> <storage xmlns='storage:notes'> <note email@example.com' cdate='20040924T15:23:21' mdate='20040924T15:23:21'>Seems to be a good writer</note> <note firstname.lastname@example.org' cdate='20040927T17:23:14' mdate='20040928T12:43:12'>Oh my sweetest love ...</note> </storage> </query> </iq>
Note: All notes are stored as a "bundle" within the same <storage/> element.
Retrieving notes is pretty straight forward as how it is described in JEP-0049.
<iq type='get' id='a2'> <query xmlns='jabber:iq:private'> <storage xmlns='storage:notes' /> </query> </iq>
<iq type='result' id='a2' to='client' from='server'> <query xmlns='jabber:iq:private'> <storage xmlns='storage:notes'> <note email@example.com' cdate='20040924T15:23:21' mdate='20040924T15:23:21'>Seems to be a good writer</note> <note firstname.lastname@example.org' cdate='20040927T17:23:14' mdate='20040928T12:43:12'>Oh my sweetest love ...</note> </storage> </query> </iq>
Security considerations related to private XML storage are described in JEP-0049.
No interaction with the Internet Assigned Numbers Authority (IANA)  is required as a result of this JEP.
No namespaces or parameters need to be registered with the Jabber Registrar  as a result of this JEP.
<?xml version='1.0' encoding='UTF-8'?> <xs:schema xmlns:xs='http://www.w3.org/2001/XMLSchema' targetNamespace='storage:notes' xmlns='storage:notes' elementFormDefault='qualified'> <xs:element name='storage'> <xs:complexType> <xs:element ref='note'/> </xs:complexType> </xs:element> <xs:element name='note'> <xs:complexType> <xs:simpleContent> <xs:extension base='xs:string'> <xs:attribute name='jid' type='xs:string' use='required'/> <xs:attribute name='cdate' type='xs:string' use='optional'/> <xs:attribute name='mdate' type='xs:string' use='optional'/> </xs:extension> </xs:simpleContent> </xs:complexType> </xs:element> </xs:schema>
1. JEP-0049: Private XML Storage <http://www.jabber.org/jeps/jep-0049.html>.
2. JEP-0048: Bookmark Storage <http://www.jabber.org/jeps/jep-0048.html>.
3. The Internet Assigned Numbers Authority (IANA) is the central coordinator for the assignment of unique parameter values for Internet protocols, such as port numbers and URI schemes. For further information, see <http://www.iana.org/>.
4. The Jabber Registrar maintains a list of reserved Jabber protocol namespaces as well as registries of parameters used in the context of protocols approved by the Jabber Software Foundation. For further information, see <http://www.jabber.org/registrar/>.