Abstract

This specification describes the Activity vocabulary.

Author's Note

This section is non-normative.

This draft is heavily influenced by the JSON Activity Streams 1.0 specification originally co-authored by Martin Atkins, Will Norris, Chris Messina, Monica Wilkinson, Rob Dolin and James Snell. The author is very thankful for their significant contributions and gladly stands on their shoulders. Some portions of the original text of Activity Streams 1.0 are used in this document.

Status of This Document

This section describes the status of this document at the time of its publication. Other documents may supersede this document. A list of current W3C publications and the latest revision of this technical report can be found in the W3C technical reports index at http://www.w3.org/TR/.

This document was published by the Social Web Working Group as a First Public Working Draft. This document is intended to become a W3C Recommendation. If you wish to make comments regarding this document, please send them to public-socialweb@w3.org (subscribe, archives). All comments are welcome.

Publication as a First Public Working Draft does not imply endorsement by the W3C Membership. This is a draft document and may be updated, replaced or obsoleted by other documents at any time. It is inappropriate to cite this document as other than work in progress.

This document was produced by a group operating under the 5 February 2004 W3C Patent Policy. W3C maintains a public list of any patent disclosures made in connection with the deliverables of the group; that page also includes instructions for disclosing a patent. An individual who has actual knowledge of a patent which the individual believes contains Essential Claim(s) must disclose the information in accordance with section 6 of the W3C Patent Policy.

This document is governed by the 1 August 2014 W3C Process Document.

Table of Contents

1. Introduction

The Activity Streams 2.0 Core defines the JSON syntax for Activity Streams. This document defines the vocabulary terms.

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in [RFC2119].

1.1 Value Conventions

This specification uses IRIs [RFC3987]. Every URI [RFC3986] is also an IRI, so a URI may be used wherever an IRI is named. There are two special considerations: (1) when an IRI that is not also a URI is given for dereferencing, it MUST be mapped to a URI using the steps in Section 3.1 of [RFC3987] and (2) when an IRI is serving as an "id" value, it MUST NOT be so mapped.

Unless otherwise specified, all terms defined as timestamp values MUST conform to the "date-time" production in [RFC3339], with an uppercase "T" character used to separate date and time, and an uppercase "Z" character in the absence of a numeric time zone offset. All such timestamps SHOULD be represented relative to Coordinated Universal Time (UTC).

2. Classes

Base URI: http://activitystrea.ms/2.0/.

Classes: Object | Link | Activity | Collection | NaturalLanguageValue | Verb | ObjectType

Class Description Terms
Object URI: http://activitystrea.ms/2.0/Object

language | displayName | alias | author | content | summary | title | icon | image | location | generator | provider | published | updated | startTime | endTime | validFrom | validAfter | validUntil | validBefore | duration | rating | attachment | height | width | tag | inReplyTo | scope | action | memberOf | url | resultOf | replies

Notes: Describes an object of some kind. The Object class serves as a base class for many of the other kinds of objects defined in the Activity and Actions Vocabulary.
Link URI: http://activitystrea.ms/2.0/Link

rel | mediaType | language | displayName | title | hreflang

Notes: Describes a link to a separate resource.
Activity URI: http://activitystrea.ms/2.0/Activity

verb | actor | object | target | result | instrument | participant | priority | status | to | bto | cc | bcc

From Object:
language | displayName | alias | author | content | summary | title | icon | image | location | generator | provider | published | updated | startTime | endTime | validFrom | validAfter | validUntil | validBefore | duration | rating | attachment | height | width | tag | inReplyTo | scope | action | memberOf | url | resultOf | replies

Notes: Describes some form of action that is currently happening or that has already happened.
Type Of: Object
Collection URI: http://activitystrea.ms/2.0/Collection

items | totalItems | itemsPerPage | startIndex | itemsAfter | itemsBefore | current | next | prev | first | last | self

From Object:
language | displayName | alias | author | content | summary | title | icon | image | location | generator | provider | published | updated | startTime | endTime | validFrom | validAfter | validUntil | validBefore | duration | rating | attachment | height | width | tag | inReplyTo | scope | action | memberOf | url | resultOf | replies

Notes: An unordered collection of Object instances.
Type Of: Object
NaturalLanguageValue URI: http://activitystrea.ms/2.0/NaturalLanguageValue
Notes: A Natural Language Value is a representation of human-readable character sequences in one or more languages.
Verb URI: http://activitystrea.ms/2.0/Verb

From Object:
language | displayName | alias | author | content | summary | title | icon | image | location | generator | provider | published | updated | startTime | endTime | validFrom | validAfter | validUntil | validBefore | duration | rating | attachment | height | width | tag | inReplyTo | scope | action | memberOf | url | resultOf | replies

Notes: Describes a Verb.
Type Of: Object
ObjectType URI: http://activitystrea.ms/2.0/ObjectType

From Object:
language | displayName | alias | author | content | summary | title | icon | image | location | generator | provider | published | updated | startTime | endTime | validFrom | validAfter | validUntil | validBefore | duration | rating | attachment | height | width | tag | inReplyTo | scope | action | memberOf | url | resultOf | replies

Notes: Describes an Object Type.
Type Of: Object

3. Terms

Base URI: http://activitystrea.ms/2.0/.

Term Description
language URI: http://activitystrea.ms/2.0/language
Notes: Establishes the default language assumed for human-readable, natural-language metadata values included in the object. The value MUST be an [RFC5646] Language-Tag.
Domain: Object | Link
Range: [RFC5646] Language Tag
displayName URI: http://activitystrea.ms/2.0/displayName
Notes: A simple, human-readable, plain-text name for the object. HTML markup MUST NOT be included..
Domain: Object | Link
Value: NaturalLanguageValue
rel URI: http://activitystrea.ms/2.0/rel
Notes: The RFC 5988 Link Relation associated with a Link.
Domain: Link
Value: [RFC5988] or [HTML5] Link Relation
mediaType URI: http://activitystrea.ms/2.0/mediaType
Notes:

When used on a Link, identifies the MIME media type of the referenced resource.

When used on a Payload, identifies the MIME media type of the payload described. For instance, a Payload object with a mediaType of "application/json" would describe a JSON resource.

When used on a EmbeddedView, identifies the MIME media type of value contained in the content property, if any.

Domain: Link | Payload | EmbeddedView
Value: MIME Media Type
hreflang URI: http://activitystrea.ms/2.0/hreflang
Notes: Hints as to the language used by the target resource. Value MUST be a [RFC5646] Language-Tag.
Domain: Link
Range: [RFC5646] Language Tag
verb URI: http://activitystrea.ms/2.0/verb
Notes: Identifies the type of action represented in the Activity
Domain: Activity | PotentialAction
Value: Verb
actor URI: http://activitystrea.ms/2.0/actor
Notes: Describes one or more entities that either performed or are expected to perform the activity.
Domain: Activity | PotentialAction
Value: Object | Link
object URI: http://activitystrea.ms/2.0/object
Notes: Describes the direct object of the activity. For instance, in the activity "John saved a movie to his wishlist", the object of the activity is the movie saved.
Domain: Activity | PotentialAction
Value: Object | Link
target URI: http://activitystrea.ms/2.0/target
Notes: Describes the indirect object, or target, of the activity. The precise meaning of the target is largely dependent on the verb but will often be the object of the English preposition "to". For instance, in the activity "John saved a movie to his wishlist", the target of the activity is John's wishlist.
Domain: Activity | PotentialAction
Value: Object | Link
result URI: http://activitystrea.ms/2.0/result
Notes: Describes the result of the activity. For instance, if a particular action results in the creation of a new resource, the result property can be used to describe that new resource.
Domain: Activity
Value: Object | Link
Reverse Of: resultOf
instrument URI: http://activitystrea.ms/2.0/instrument
Notes: An optional Object that describes one or more objects used to perform the activity. For instance, in the activity, "Sally played music with a piano", the instrument of the activity is the piano.
Domain: Activity | PotentialAction
Value: Object | Link
participant URI: http://activitystrea.ms/2.0/participant
Notes: An optional Object that describes one or more additional actors that have (or will have) participated in the activity. For instance, in the activity, "Sally went to the movies with Joe", Sally is the primary actor, while Joe is a participant.
Domain: Activity | PotentialAction
Value: Object | Link
priority URI: http://activitystrea.ms/2.0/priority
Notes:

An optional indicator of the relative priority, or importance, that the creator of the activity considers it to have. Represented as a non-negative, numeric decimal between 0.00 and 1.00 (inclusive), with two decimal places of precision. If the property is omitted or set to null, the assumption is that a default priority can be assumed by the implementation. The value 0.00 represents the lowest possible priority while 1.00 represents the highest.

The use of the priority property does not impose any specific processing or display requirements on the part of any consuming implementation.

Expressing the value as a range of numeric decimal values is intended to provide the greatest level of flexibility in the expression and consumption of prioritization detail. It is expected that implementors consuming activity objects containing priority will utilize and expose the additional information in a number of different ways depending on the unique requirements of each application use case.

Many existing systems do not represent priority values as numeric ranges. Such systems might use fixed, labeled brackets such as "low", "normal" and "high" or "urgent". Similar mechanisms can be established, by convention, when using the priority property. In typical use, it is RECOMMENDED that implementations wishing to work with such defined categories treat priority property values in the range 0.00 to 0.25 as "low" priority; values greater than 0.25 to 0.75 as "normal" priority; and values greater than 0.75 to 1.00 as "high" priority. Specific implementations are free to establish alternative conventions for the grouping of priority values with the caveat that such conventions likely will not be understood by all implementations.

Domain: Activity | PotentialAction
Value: xsd:decimal
Domain: 0.00 <= priority <= 1.00
status URI: http://activitystrea.ms/2.0/status
Notes: An optional, explicit indicator of the current status of the activity. "http://activitystrea.ms/2.0/status/active" indicates that the activity is ongoing, "http://activitystrea.ms/2.0/status/canceled" indicates that the activity has been aborted, "http://activitystrea.ms/2.0/status/completed" indicates that the activity has concluded, "http://activitystrea.ms/2.0/status/pending" indicates that the activity is expected to begin, "http://activitystrea.ms/2.0/status/tentative" indicates that the activity has been proposed, and "http://activitystrea.ms/2.0/status/voided" indicates that the activity has been retracted or should be considered invalid.
Domain: Activity
Value: xsd:anyURI
to URI: http://activitystrea.ms/2.0/to
Notes: Specifies the public primary audience
Domain: Activity
Value: Link
cc URI: http://activitystrea.ms/2.0/cc
Notes: Specifies the public secondary audience
Domain: Activity
Value: Link
bto URI: http://activitystrea.ms/2.0/bto
Notes: Specifies the private primary audience
Domain: Activity
Value: Link
bcc URI: http://activitystrea.ms/2.0/bcc
Notes: Specifies the private secondary audience
Domain: Activity
Value: Link
alias URI: http://activitystrea.ms/2.0/alias
Notes: Provides a contextually meaningful alternative label for the object in addition to the id. For instance, within some systems, groups can be identified by both a unique global identifier and a more "human-friendly" label such as "@friends" or "@network". The value of the alias property MUST match either the isegment-nz-nc or IRI productions in [RFC3987]. The use of a relative reference other than a simple name is not allowed.
Domain: Object
Value: xsd:anyURI
author URI: http://activitystrea.ms/2.0/author
Notes: An Object referencing one or more entities credited with creating or authoring the object.
Domain: Object
Value: Object | Link
content URI: http://activitystrea.ms/2.0/content
Notes: A NaturalLanguageValue description of the object content. HTML markup, including visual elements such as images, MAY be included.
Domain: Object
Value: NaturalLanguageValue
summary URI: http://activitystrea.ms/2.0/summary
Notes: A NaturalLanguageValue summarization of the object. HTML markup, including visual images such as images, MAY be included.
Domain: Object
Value: NaturalLanguageValue
title URI: http://activitystrea.ms/2.0/title
Notes: A NaturalLanguageValue title of the object. HTML markup, including visual images such as images, MAY be included. The title and displayName properties are closely related and overlap in function with the key difference being that title is permitted to contain HTML markup while displayName is not.
Domain: Object | Link
Value: NaturalLanguageValue
icon URI: http://activitystrea.ms/2.0/icon
Notes: A Link referencing one or more graphic representations of the object. The visual element SHOULD have an aspect ratio of one (horizontal) to one (vertical) and SHOULD be suitable for presentation at a small size.
Domain: Object
Value: Link
image URI: http://activitystrea.ms/2.0/image
Notes: A Link referencing one or more graphic representations of the object. Unlike the icon property, there are no aspect ratio or display size limitations assumed.
Domain: Object
Value: Link
location URI: http://activitystrea.ms/2.0/location
Notes: An Object or Link referencing one or more physical or logical locations associated with the object.
Domain: Object
Value: Object | Link
generator URI: http://activitystrea.ms/2.0/generator
Notes: An Object or Link referencing the resource (e.g. an application) that generated the object.
Domain: Object
Value: Object | Link
provider URI: http://activitystrea.ms/2.0/provider
Notes: An Object or Link referencing the resource (e.g. an application) that published the object. Note that this is not necessarily the same entity that generated the object.
Domain: Object
Value: Object | Link
published URI: http://activitystrea.ms/2.0/published
Notes: The date and time at which the object was published
Domain: Object
Value: timestamp
updated URI: http://activitystrea.ms/2.0/updated
Notes: The date and time at which the object was updated
Domain: Object
Value: timestamp
startTime URI: http://activitystrea.ms/2.0/startTime
Notes: The date and time describing the actual or expected starting time of the object. When used with an Activity object, for instance, the startTime property specifies the moment the activity began or is scheduled to begin.
Domain: Object
Value: timestamp
endTime URI: http://activitystrea.ms/2.0/endTime
Notes: The date and time describing the actual or expected ending time of the object. When used with an Activity object, for instance, the endTime property specifies the moment the activity concluded or is expected to conclude.
Domain: Object
Value: timestamp
validFrom URI: http://activitystrea.ms/2.0/validFrom
Notes: The date and time at or after which (inclusive) the object is considered to be valid.
Domain: Object
Value: timestamp
validAfter URI: http://activitystrea.ms/2.0/validAfter
Notes: The date and time after which (exclusive) the object is considered to be valid.
Domain: Object
Value: timestamp
validUntil URI: http://activitystrea.ms/2.0/validUntil
Notes: The date and time at or before which (inclusive) the object is considered to be valid. Once this moment has passed, the object is considered to have expired.
Domain: Object
Value: timestamp
validBefore URI: http://activitystrea.ms/2.0/validBefore
Notes: The date and time at or after which the object is considered to have expired.
Domain: Object
Value: timestamp
duration URI: http://activitystrea.ms/2.0/duration
Notes: When the object describes a time-bound resource, such as an audio or video, a meeting, etc, the duration property indicates the object's approximate duration. The value SHOULD be expressed as an [RFC3339] duration (e.g. a period of 5 seconds is represented as "PT5S") but MAY be specified as a non-negative integer specifying the duration as a number of non-fractional seconds.
Domain: Object
Value: xsd:integer | xsd:duration
rating URI: http://activitystrea.ms/2.0/rating
Notes: A quality rating expressed as a non-negative decimal number between 0.0 and 5.0 (inclusive) with one decimal place of precision.
Domain: Object
Value: xsd:decimal
Comment: 0.0 <= rating <= 5.0
attachment URI: http://activitystrea.ms/2.0/attachments
Notes: An Object or Link referencing one or more objects associated with the containing object. These are similar in concept to files attached to an email.
Domain: Object
Value: Object | Link
height URI: http://activitystrea.ms/2.0/height
Notes: When the object describes a visual resource, such as an image, video or embeddable HTML, the height property indicates the recommended display height in terms of device-independent pixels.
Domain: Object
Value: xsd:nonNegativeInteger
width URI: http://activitystrea.ms/2.0/width
Notes: When the object describes a visual resource, such as an image, video or embeddable HTML, the width property indicates the recommended display width in terms of device-independent pixels.
Domain: Object
Value: xsd:nonNegativeInteger
tag URI: http://activitystrea.ms/2.0/tags
Notes: An Object or Link referencing one or more resources that are loosely associated with the containing object. The tag and attachment properties differ from one another in that the tag property asserts "association by reference" while attachment asserts "association by enclosure".
Domain: Object
Value: Object | Link
inReplyTo URI: http://activitystrea.ms/2.0/inReplyTo
Notes: An Object or Link referencing one or more other objects to which the containing object can be considered a response.
Domain: Object
Value: Object | Link
scope URI: http://activitystrea.ms/2.0/scope
Notes: An Object or Link referencing one or more resources that define the total population of entities for which the object can considered to be relevant.
Domain: Object
Value: Object | Link
action URI: http://activitystrea.ms/2.0/action
Notes: A PotentialAction that can be performed with the object
Domain: Object
Value: PotentialAction
Reverse Of: object
memberOf URI: http://activitystrea.ms/2.0/memberOf
Notes: Identifies a Collection to which this Object belongs
Domain: Object
Value: Collection
Reverse Of: items
url URI: http://activitystrea.ms/2.0/url
Notes: The url property is typically used to point to a displayable representation of an object (usually an HTML page).
Domain: Object
Value: Link
resultOf URI: http://activitystrea.ms/2.0/resultOf
Notes: Identifies the Activity of which this object or link is a result.
Domain: Object
Value: Activity
Reverse Of: result

4. Collection Terms

Base URI: http://activitystrea.ms/2.0/.

Term Description
items URI: http://activitystrea.ms/2.0/items
Notes: An unordered set of Objects contained by the collection.
Domain: Collection
Value: Object
Reverse Of: memberOf
totalItems URI: http://activitystrea.ms/2.0/totalItems
Notes: A non-negative integer specifying the total number of objects contained by the logical view of the collection. This number might not reflect the actual number of items serialized within the Collection object instance.
Domain: Collection
Value: xsd:nonNegativeInteger
itemsPerPage URI: http://activitystrea.ms/2.0/itemsPerPage
Notes: A non-negative integer specifying the maximum number of items that will be included in the value of the items array.
Domain: Collection
Value: xsd:nonNegativeInteger
startIndex URI: http://activitystrea.ms/2.0/startIndex
Notes: A non-negative integer value identifying the relative position within the logical view of the collection of the first object contained in the items array.
Domain: Collection
Value: xsd:nonNegativeInteger
itemsAfter URI: http://activitystrea.ms/2.0/itemsAfter
Notes: An RFC 3339 date-time that indicates that the collection contains only items published or updated strictly after the date and time specified.
Domain: Collection
Value: timestamp
itemsBefore URI: http://activitystrea.ms/2.0/itemsBefore
Notes: An RFC 3339 date-time that indicates that the collection contains only items published or updated strictly before the date and time specified.
Domain: Collection
Value: timestamp
replies URI: http://activitystrea.ms/2.0/replies
Notes: Provides information about the set of objects that can be considered to be replies to the containing object.
Domain: Object
Value: Collection
current URI: http://activitystrea.ms/2.0/current
Notes: Provides a link to the collection page containing the most recently published or updated items.
Domain: Collection
Value: Link
next URI: http://activitystrea.ms/2.0/next
Notes: Provides a link to the next page of items in the collection
Domain: Collection
Value: Link
prev URI: http://activitystrea.ms/2.0/prev
Notes: Provides a link to the previous page of item in the collection
Domain: Collection
Value: Link
first URI: http://activitystrea.ms/2.0/first
Notes: Provides a link to the further preceeding page in the collection
Domain: Collection
Value: Link
last URI: http://activitystrea.ms/2.0/last
Notes: Provides a link to furthest page in the collection
Domain: Collection
Value: Link
self URI: http://activitystrea.ms/2.0/self
Notes: Provides a link to this page of the collection
Domain: Collection
Value: Link

5. Activity Streams 1.0 Terms

Term Description
id URI: http://activitystrea.ms/1.0/id
Notes: Provides a permanent, universally unique identifier for the object in the form of an absolute IRI [RFC3987].
Domain: Object
Equivalent To: [JSON-LD] "@id"
objectType URI: http://activitystrea.ms/1.0/objectType
Notes: Identifies the type of object. If an object does not either the objectType or @type properties, the object has no specific type.
Domain: Object
Equivalent To: [JSON-LD] @type
downstreamDuplicates URI: http://activitystrea.ms/1.0/downstreamDuplicates
Notes: The downstreamDuplicates property is used when there are known objects, possibly in a different system, that duplicate the content in this object. This would be used as a hint for consumers to use when resolving duplicates between objects received from different sources. In Activity Streams 2.0, the downstreamDuplicates property is deprecated and SHOULD NOT be used.
Domain: Object
Value: xsd:anyURI
upstreamDuplicates URI: http://activitystrea.ms/1.0/upstreamDuplicates
Notes: The upstreamDuplicates property is used when there are known objects, possibly in a different system, that duplicate the content in this object. This would be used as a hint for consumers to use when resolving duplicates between objects received from different sources. In Activity Streams 2.0, the upstreamDuplicates property is deprecated and SHOULD NOT be used.
Domain: Object
Value: xsd:anyURI
tags URI: http://activitystrea.ms/1.0/tags
Notes: In the Activity Streams 2.0 vocabulary, tags is renamed to the singular form tag for consistency.
Domain: Object
Value: Object | Link
Equivalent To: tag
attachments URI: http://activitystrea.ms/1.0/attachments
Notes: In the Activity Streams 2.0 vocabulary, attachments is renamed to the singular form attachment for consistency.
Domain: Object
Value: Object | Link
Equivalent To: attachment

A. References

A.1 Normative references

[JSON-LD]
Manu Sporny; Gregg Kellogg; Markus Lanthaler. JSON-LD 1.0. 16 January 2014. W3C Recommendation. URL: http://www.w3.org/TR/json-ld/
[RFC2119]
S. Bradner. Key words for use in RFCs to Indicate Requirement Levels. March 1997. Best Current Practice. URL: http://www.ietf.org/rfc/rfc2119.txt
[RFC3339]
G. Klyne; C. Newman. Date and Time on the Internet: Timestamps. July 2002. Proposed Standard. URL: http://www.ietf.org/rfc/rfc3339.txt
[RFC3986]
T. Berners-Lee; R. Fielding; L. Masinter. Uniform Resource Identifier (URI): Generic Syntax. January 2005. Internet Standard. URL: http://www.ietf.org/rfc/rfc3986.txt
[RFC3987]
M. Duerst; M. Suignard. Internationalized Resource Identifiers (IRIs). January 2005. Proposed Standard. URL: http://www.ietf.org/rfc/rfc3987.txt
[RFC5646]
A. Phillips, Ed.; M. Davis, Ed.. Tags for Identifying Languages. September 2009. Best Current Practice. URL: http://www.ietf.org/rfc/rfc5646.txt
[RFC5988]
M. Nottingham. Web Linking. October 2010. Proposed Standard. URL: http://www.ietf.org/rfc/rfc5988.txt