%ents; ]>
User Activity This JEP defines a protocol for communicating information about user activities. &LEGALNOTICE; 0108 Draft Standards Track Standards JIG XMPP Core JEP-0060 activity http://jabber.org/protocol/activity/activity.xsd &ralphm; &stpeter; 1.0 2004-10-20 psa/rm Per a vote of the Jabber Council, advanced status to Draft; per Council discussion, also adjusted structure to use nested elements rather than XML character data. 0.4 2004-09-15 psa Added internationalization considerations. 0.3 2004-04-25 psa Corrected several errors; added reference to JEP-0033. 0.2 2004-02-19 psa Minor text and schema changes; added RPID mapping. 0.1 2003-07-22 rm Initial version.

This JEP defines an extension mechanism for capturing "extended presence" data about user activities, above and beyond availability as defined in &xmppim; (e.g., the 'away', 'extended away', and 'dnd' values of the <show/> child of the <presence/> stanza).

Information about user activities is provided by the user and propagated on the network by the user's client. The information is structured by means of an <activity/> element that is qualified by the 'http://jabber.org/protocol/activity' namespace. The general activity is provided as the element name of a first-level child of the <activity/> element (e.g., <relaxing/>); one such general activity element is REQUIRED. The general activity element MAY contain a child element that specifies a more particular form of the general activity (e.g., <partying/>). The user MAY also specify a natural-language description of the activity in the OPTIONAL <text/> child of the <activity/> element. Here is an example:

My nurse's birthday! ]]>

Instead of (but not in addition to) one of the specific activity elements defined herein, an application MAY include a properly-namespaced child element for the specific activity. Here is an example:

]]>

Finally, one of the specific activity elements defined herein MAY itself contain a properly-namespaced child element that provides more detailed information about the specific activity. Here is an example:

]]>

In accordance with &xmppcore;, the receiving application MUST ignore a specific activity element or detailed activity element if it does not understand the namespace that qualifies the element.

The <activity/> element SHOULD be communicated by means of &jep0060;. Because activity information is not pure presence information and can change independently of the user's availability, it SHOULD NOT be provided as an extension to &PRESENCE;.

My nurse's birthday! ]]>

The activity is then delivered to all subscribers:

My nurse's birthday! . . . ]]>

As mentioned in JEP-0060, the stanza containing the event notification or payload MAY also include 'replyto' data (as specified by the &jep0033; protocol) to provide an explicit association between the published data and the user:

My nurse's birthday!
]]>

Each activity has a REQUIRED general category and an OPTIONAL specific instance. One can understand each specifier as '[user] is [activity]' (e.g., 'Juliet is partying'), where the relevant value is the most specific activity provided (e.g., specifically "partying" rather than generally "relaxing").

The activity values defined in this taxonomy are as follows, where the first indentation level is the general category and the second indentation level is the specific instance. Note: The specific activity elements are RECOMMENDED as forms of the general activities shown below, but can be included under any general activity (e.g., "gardening" could be used as the specific activity under "relaxing" rather than "doing_chores").

  • doing_chores
    • buying_groceries
    • cleaning
    • cooking
    • doing_maintenance
    • doing_the_dishes
    • doing_the_laundry
    • gardening
    • running_an_errand
    • walking_the_dog
  • drinking
    • having_a_beer
    • having_coffee
    • having_tea
  • eating
    • having_a_snack
    • having_breakfast
    • having_dinner
    • having_lunch
  • exercising
    • cycling
    • hiking
    • jogging
    • playing_sports
    • running
    • skiing
    • swimming
    • working_out
  • grooming
    • at_the_spa
    • brushing_teeth
    • getting_a_haircut
    • shaving
    • taking_a_bath
    • taking_a_shower
  • having_appointment
  • inactive
    • day_off
    • hanging_out
    • on_vacation
    • scheduled_holiday
    • sleeping
  • relaxing
    • gaming
    • going_out
    • partying
    • reading
    • rehearsing
    • shopping
    • socializing
    • sunbathing
    • watching_tv
    • watching_a_movie
  • talking
    • in_real_life
    • on_the_phone
  • traveling
    • commuting
    • cycling
    • driving
    • in_a_car
    • on_a_bus
    • on_a_plane
    • on_a_train
    • on_a_trip
    • walking
  • working
    • coding
    • in_a_meeting
    • studying
    • writing

In addition, the specific activity element can be <other/> in order to handle activities not defined herein. In the absence of a <text/> element, the recipient is free to draw whatever conclusions he or she may like regarding the nature of the "other" activity. Naturally, emoticons can be provided as the XML character data of the <text/> element. ;-)

&rfc4480; defines several extensions to the &pidf; for so-called "rich presence". One such extension is the <activity/> element (see Section 4.2), which "describes what the presentity is currently doing". The following table shows a mapping from the defined RPID activity values to the Jabber values defined herein.

RPID <activity/> General activity element Specific activity element
appointment having_appointment --
away In XMPP, "away" is not an activity, but an availability state captured by means of a <presence/> stanza with a <show>away</show> child (see XMPP IM).
busy In XMPP, "busy" is not an activity, but an availability state captured by means of a <presence/> stanza with <show>dnd</show> child (see XMPP IM). Alternatively, the RPID "busy" activity could map to any number of more specific Jabber activities as defined herein.
holiday inactive scheduled_holiday
in-transit traveling Appropriate specific values in the "traveling" category would be "in_a_car", "on_a_bus", and "on_a_train".
meal eating The "eating" category can be further specified by "having_a_snack", "having_breakfast", "having_lunch", or "having_dinner".
meeting working in_a_meeting
on-the-phone talking on_the_phone
performance -- --
permanent-absence In XMPP, "permanent absence" is not an activity, but instead would be sent to a contact via the <gone/> stanza error (see &xmppcore;).
sleeping inactive sleeping
steering traveling driving
travel traveling on_a_trip
vacation inactive on_vacation

The full range of activities defined herein is considerably richer than that defined in RPID; no mapping to RPID is provided by this specification for activity values that are not present in RPID, and any such mapping is the responsibility of a gateway between the two systems.

The XML character data values of the <text/> element are intended for presentation to human users; therefore, if a <text/> element is included the sending application SHOULD also ensure that the <text/> element or the parent <activity/> element possesses an 'xml:lang' attribute with an appropriate value.

Because user activities may be published to a large number of pubsub subscribers, users should take care in approving subscribers and in characterizing their current activities.

This JEP requires no interaction with &IANA;.

The ®ISTRAR; includes 'http://jabber.org/protocol/activity' in its registry of protocol namespaces.

]]>