Changes
4 changed files (+185/-195)
-
-
@@ -76,103 +76,102 @@ var validActivityTypes = [...]ActivityVocabularyType{// It is important to note that the Activity type itself does not carry any specific semantics // about the kind of action being taken. type Activity struct { // Provides the globally unique identifier for an Activity Pub Object or Link. // ID providesthe globally unique identifier for an Activity Pub Object or Link. ID ObjectID `jsonld:"id,omitempty"` // Identifies the Activity Pub Object or Link type. Multiple values may be specified. // Type identifies the Activity Pub Object or Link type. Multiple values may be specified. Type ActivityVocabularyType `jsonld:"type,omitempty"` // A simple, human-readable, plain-text name for the object. // Name a simple, human-readable, plain-text name for the object. // HTML markup MUST NOT be included. The name MAY be expressed using multiple language-tagged values. Name NaturalLanguageValue `jsonld:"name,omitempty,collapsible"` // Identifies a resource attached or related to an object that potentially requires special handling. // Attachment identifies a resource attached or related to an object that potentially requires special handling. // The intent is to provide a model that is at least semantically similar to attachments in email. Attachment Item `jsonld:"attachment,omitempty"` // Identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // AttributedTo identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // For instance, an object might be attributed to the completion of another activity. AttributedTo Item `jsonld:"attributedTo,omitempty"` // Identifies one or more entities that represent the total population of entities // Audience identifies one or more entities that represent the total population of entities // for which the object can considered to be relevant. Audience Item `jsonld:"audience,omitempty"` // The content or textual representation of the Activity Pub Object encoded as a JSON string. // Content the content or textual representation of the Activity Pub Object encoded as a JSON string. // By default, the value of content is HTML. // The mediaType property can be used in the object to indicate a different content type. // (The content MAY be expressed using multiple language-tagged values.) Content NaturalLanguageValue `jsonld:"content,omitempty,collapsible"` // Identifies the context within which the object exists or an activity was performed. // Context identifies the context within which the object exists or an activity was performed. // The notion of "context" used is intentionally vague. // The intended function is to serve as a means of grouping objects and activities that share a // common originating context or purpose. An example could be all activities relating to a common project or event. Context Item `jsonld:"context,omitempty"` // The date and time describing the actual or expected ending time of the object. // EndTime 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. EndTime time.Time `jsonld:"endTime,omitempty"` // Identifies the entity (e.g. an application) that generated the object. // Generator identifies the entity (e.g. an application) that generated the object. Generator Item `jsonld:"generator,omitempty"` // Indicates an entity that describes an icon for this object. // Icon indicates an entity that describes an icon for this object. // The image should have an aspect ratio of one (horizontal) to one (vertical) // and should be suitable for presentation at a small size. Icon Item `jsonld:"icon,omitempty"` // Indicates an entity that describes an image for this object. // Image indicates an entity that describes an image for this object. // Unlike the icon property, there are no aspect ratio or display size limitations assumed. Image Item `jsonld:"image,omitempty"` // Indicates one or more entities for which this object is considered a response. // InReplyTo indicates one or more entities for which this object is considered a response. InReplyTo Item `jsonld:"inReplyTo,omitempty"` // Indicates one or more physical or logical locations associated with the object. // Location indicates one or more physical or logical locations associated with the object. Location Item `jsonld:"location,omitempty"` // Identifies an entity that provides a preview of this object. // Preview identifies an entity that providesa preview of this object. Preview Item `jsonld:"preview,omitempty"` // The date and time at which the object was published // Published the date and time at which the object was published Published time.Time `jsonld:"published,omitempty"` // Identifies a Collection containing objects considered to be responses to this object. // Replies identifies a Collection containing objects considered to be responses to this object. Replies Item `jsonld:"replies,omitempty"` // The date and time describing the actual or expected starting time of the object. // StartTime 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. StartTime time.Time `jsonld:"startTime,omitempty"` // A natural language summarization of the object encoded as HTML. // Summary a natural language summarization of the object encoded as HTML. // *Multiple language tagged summaries may be provided.) Summary NaturalLanguageValue `jsonld:"summary,omitempty,collapsible"` // One or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // Tag One or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // The key difference between attachment and tag is that the former implies association by inclusion, // while the latter implies associated by reference. Tag Item `jsonld:"tag,omitempty"` // The date and time at which the object was updated // Updated the date and time at which the object was updated Updated time.Time `jsonld:"updated,omitempty"` // Identifies one or more links to representations of the object // URL identifies one or more links to representations of the object URL LinkOrURI `jsonld:"url,omitempty"` // Identifies an entity considered to be part of the public primary audience of an Activity Pub Object // To identifies an entity considered to be part of the public primary audience of an Activity Pub Object To ItemCollection `jsonld:"to,omitempty"` // Identifies an Activity Pub Object that is part of the private primary audience of this Activity Pub Object. // Bto identifies an Activity Pub Object that is part of the private primary audience of this Activity Pub Object. Bto ItemCollection `jsonld:"bto,omitempty"` // Identifies an Activity Pub Object that is part of the public secondary audience of this Activity Pub Object. // CC identifies an Activity Pub Object that is part of the public secondary audience of this Activity Pub Object. CC ItemCollection `jsonld:"cc,omitempty"` // Identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. // BCC identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. BCC ItemCollection `jsonld:"bcc,omitempty"` // When the object describes a time-bound resource, such as an audio or video, a meeting, etc, // Duration 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 must be expressed as an xsd:duration as defined by [ xmlschema11-2], // section 3.3.6 (e.g. a period of 5 seconds is represented as "PT5S"). Duration time.Duration `jsonld:"duration,omitempty"` // Describes one or more entities that either performed or are expected to perform the activity. // Actor describes one or more entities that either performed or are expected to perform the activity. // Any single activity can have multiple actors. The actor may be specified using an indirect Link. Actor Item `jsonld:"actor,omitempty"` // Describes the indirect object, or target, of the activity. // Target describes the indirect object, or target, of the activity. // The precise meaning of the target is largely dependent on the type of action being described // but will often be the object of the English preposition "to". // For instance, in the activity "John added a movie to his wishlist", // the target of the activity is John's wishlist. An activity can have more than one target. Target Item `jsonld:"target,omitempty"` // Describes the result of the activity. For instance, if a particular action results in the creation // Result 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. Result Item `jsonld:"result,omitempty"` // Describes an indirect object of the activity from which the activity is directed. // Origin describes an indirect object of the activity from which the activity is directed. // The precise meaning of the origin is the object of the English preposition "from". // For instance, in the activity "John moved an item to List B from List A", the origin of the activity is "List A". Origin Item `jsonld:"origin,omitempty"` // Identifies one or more objects used (or to be used) in the completion of an Activity. Instrument Item `jsonld:"instrument,omitempty"` Source Source `jsonld:"source,omitempty"` // When used within an Activity, describes the direct object of the activity. // Instrument identifies one or more objects used (or to be used) in the completion of an Activity. Instrument Item `jsonld:"instrument,omitempty"` // Object When used within an Activity, describes the direct object of the activity. // For instance, in the activity "John added a movie to his wishlist", // the object of the activity is the movie added. // When used within a Relationship describes the entity to which the subject is related.
-
@@ -182,102 +181,101 @@ type Activity struct {// IntransitiveActivity Instances of IntransitiveActivity are a subtype of Activity representing intransitive actions. // The object property is therefore inappropriate for these activities. type IntransitiveActivity struct { // Provides the globally unique identifier for an Activity Pub Object or Link. // ID providesthe globally unique identifier for an Activity Pub Object or Link. ID ObjectID `jsonld:"id,omitempty"` // Identifies the Activity Pub Object or Link type. Multiple values may be specified. // Type identifies the Activity Pub Object or Link type. Multiple values may be specified. Type ActivityVocabularyType `jsonld:"type,omitempty"` // A simple, human-readable, plain-text name for the object. // Name a simple, human-readable, plain-text name for the object. // HTML markup MUST NOT be included. The name MAY be expressed using multiple language-tagged values. Name NaturalLanguageValue `jsonld:"name,omitempty,collapsible"` // Identifies a resource attached or related to an object that potentially requires special handling. // Attachment identifies a resource attached or related to an object that potentially requires special handling. // The intent is to provide a model that is at least semantically similar to attachments in email. Attachment Item `jsonld:"attachment,omitempty"` // Identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // AttributedTo identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // For instance, an object might be attributed to the completion of another activity. AttributedTo Item `jsonld:"attributedTo,omitempty"` // Identifies one or more entities that represent the total population of entities // Audience identifies one or more entities that represent the total population of entities // for which the object can considered to be relevant. Audience Item `jsonld:"audience,omitempty"` // The content or textual representation of the Activity Pub Object encoded as a JSON string. // Content the content or textual representation of the Activity Pub Object encoded as a JSON string. // By default, the value of content is HTML. // The mediaType property can be used in the object to indicate a different content type. // (The content MAY be expressed using multiple language-tagged values.) Content NaturalLanguageValue `jsonld:"content,omitempty,collapsible"` // Identifies the context within which the object exists or an activity was performed. // Context identifies the context within which the object exists or an activity was performed. // The notion of "context" used is intentionally vague. // The intended function is to serve as a means of grouping objects and activities that share a // common originating context or purpose. An example could be all activities relating to a common project or event. Context Item `jsonld:"context,omitempty"` // The date and time describing the actual or expected ending time of the object. // EndTime 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. EndTime time.Time `jsonld:"endTime,omitempty"` // Identifies the entity (e.g. an application) that generated the object. // Generator identifies the entity (e.g. an application) that generated the object. Generator Item `jsonld:"generator,omitempty"` // Indicates an entity that describes an icon for this object. // Icon indicates an entity that describes an icon for this object. // The image should have an aspect ratio of one (horizontal) to one (vertical) // and should be suitable for presentation at a small size. Icon Item `jsonld:"icon,omitempty"` // Indicates an entity that describes an image for this object. // Image indicates an entity that describes an image for this object. // Unlike the icon property, there are no aspect ratio or display size limitations assumed. Image Item `jsonld:"image,omitempty"` // Indicates one or more entities for which this object is considered a response. // InReplyTo indicates one or more entities for which this object is considered a response. InReplyTo Item `jsonld:"inReplyTo,omitempty"` // Indicates one or more physical or logical locations associated with the object. // Location indicates one or more physical or logical locations associated with the object. Location Item `jsonld:"location,omitempty"` // Identifies an entity that provides a preview of this object. // Preview identifies an entity that providesa preview of this object. Preview Item `jsonld:"preview,omitempty"` // The date and time at which the object was published // Published the date and time at which the object was published Published time.Time `jsonld:"published,omitempty"` // Identifies a Collection containing objects considered to be responses to this object. // Replies identifies a Collection containing objects considered to be responses to this object. Replies Item `jsonld:"replies,omitempty"` // The date and time describing the actual or expected starting time of the object. // StartTime 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. StartTime time.Time `jsonld:"startTime,omitempty"` // A natural language summarization of the object encoded as HTML. // Summary a natural language summarization of the object encoded as HTML. // *Multiple language tagged summaries may be provided.) Summary NaturalLanguageValue `jsonld:"summary,omitempty,collapsible"` // One or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // Tag One or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // The key difference between attachment and tag is that the former implies association by inclusion, // while the latter implies associated by reference. Tag Item `jsonld:"tag,omitempty"` // The date and time at which the object was updated // Updated the date and time at which the object was updated Updated time.Time `jsonld:"updated,omitempty"` // Identifies one or more links to representations of the object // URL identifies one or more links to representations of the object URL LinkOrURI `jsonld:"url,omitempty"` // Identifies an entity considered to be part of the public primary audience of an Activity Pub Object // To identifies an entity considered to be part of the public primary audience of an Activity Pub Object To ItemCollection `jsonld:"to,omitempty"` // Identifies an Activity Pub Object that is part of the private primary audience of this Activity Pub Object. // Bto identifies an Activity Pub Object that is part of the private primary audience of this Activity Pub Object. Bto ItemCollection `jsonld:"bto,omitempty"` // Identifies an Activity Pub Object that is part of the public secondary audience of this Activity Pub Object. // CC identifies an Activity Pub Object that is part of the public secondary audience of this Activity Pub Object. CC ItemCollection `jsonld:"cc,omitempty"` // Identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. // BCC identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. BCC ItemCollection `jsonld:"bcc,omitempty"` // When the object describes a time-bound resource, such as an audio or video, a meeting, etc, // Duration 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 must be expressed as an xsd:duration as defined by [ xmlschema11-2], // section 3.3.6 (e.g. a period of 5 seconds is represented as "PT5S"). Duration time.Duration `jsonld:"duration,omitempty"` // Describes one or more entities that either performed or are expected to perform the activity. // Actor describes one or more entities that either performed or are expected to perform the activity. // Any single activity can have multiple actors. The actor may be specified using an indirect Link. Actor Actor `jsonld:"actor,omitempty"` // Describes the indirect object, or target, of the activity. // Target describes the indirect object, or target, of the activity. // The precise meaning of the target is largely dependent on the type of action being described // but will often be the object of the English preposition "to". // For instance, in the activity "John added a movie to his wishlist", // the target of the activity is John's wishlist. An activity can have more than one target. Target Item `jsonld:"target,omitempty"` // Describes the result of the activity. For instance, if a particular action results in the creation // Result 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. Result Item `jsonld:"result,omitempty"` // Describes an indirect object of the activity from which the activity is directed. // Origin describes an indirect object of the activity from which the activity is directed. // The precise meaning of the origin is the object of the English preposition "from". // For instance, in the activity "John moved an item to List B from List A", the origin of the activity is "List A". Origin Item `jsonld:"origin,omitempty"` // Identifies one or more objects used (or to be used) in the completion of an Activity. Instrument Item `jsonld:"instrument,omitempty"` Source Source `jsonld:"source,omitempty"` // Instrument identifies one or more objects used (or to be used) in the completion of an Activity. Instrument Item `jsonld:"instrument,omitempty"` } type (
-
@@ -393,109 +391,108 @@ type (// Either of the anyOf and oneOf properties may be used to express possible answers, // but a Question object must not have both properties. type Question struct { // Provides the globally unique identifier for an Activity Pub Object or Link. // ID providesthe globally unique identifier for an Activity Pub Object or Link. ID ObjectID `jsonld:"id,omitempty"` // Identifies the Activity Pub Object or Link type. Multiple values may be specified. // Type identifies the Activity Pub Object or Link type. Multiple values may be specified. Type ActivityVocabularyType `jsonld:"type,omitempty"` // A simple, human-readable, plain-text name for the object. // Name a simple, human-readable, plain-text name for the object. // HTML markup MUST NOT be included. The name MAY be expressed using multiple language-tagged values. Name NaturalLanguageValue `jsonld:"name,omitempty,collapsible"` // Identifies a resource attached or related to an object that potentially requires special handling. // Attachment identifies a resource attached or related to an object that potentially requires special handling. // The intent is to provide a model that is at least semantically similar to attachments in email. Attachment Item `jsonld:"attachment,omitempty"` // Identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // AttributedTo identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // For instance, an object might be attributed to the completion of another activity. AttributedTo Item `jsonld:"attributedTo,omitempty"` // Identifies one or more entities that represent the total population of entities // Audience identifies one or more entities that represent the total population of entities // for which the object can considered to be relevant. Audience Item `jsonld:"audience,omitempty"` // The content or textual representation of the Activity Pub Object encoded as a JSON string. // Content the content or textual representation of the Activity Pub Object encoded as a JSON string. // By default, the value of content is HTML. // The mediaType property can be used in the object to indicate a different content type. // (The content MAY be expressed using multiple language-tagged values.) Content NaturalLanguageValue `jsonld:"content,omitempty,collapsible"` // Identifies the context within which the object exists or an activity was performed. // Context identifies the context within which the object exists or an activity was performed. // The notion of "context" used is intentionally vague. // The intended function is to serve as a means of grouping objects and activities that share a // common originating context or purpose. An example could be all activities relating to a common project or event. Context Item `jsonld:"context,omitempty"` // The date and time describing the actual or expected ending time of the object. // EndTime 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. EndTime time.Time `jsonld:"endTime,omitempty"` // Identifies the entity (e.g. an application) that generated the object. // Generator identifies the entity (e.g. an application) that generated the object. Generator Item `jsonld:"generator,omitempty"` // Indicates an entity that describes an icon for this object. // Icon indicates an entity that describes an icon for this object. // The image should have an aspect ratio of one (horizontal) to one (vertical) // and should be suitable for presentation at a small size. Icon Item `jsonld:"icon,omitempty"` // Indicates an entity that describes an image for this object. // Image indicates an entity that describes an image for this object. // Unlike the icon property, there are no aspect ratio or display size limitations assumed. Image Item `jsonld:"image,omitempty"` // Indicates one or more entities for which this object is considered a response. // InReplyTo indicates one or more entities for which this object is considered a response. InReplyTo Item `jsonld:"inReplyTo,omitempty"` // Indicates one or more physical or logical locations associated with the object. // Location indicates one or more physical or logical locations associated with the object. Location Item `jsonld:"location,omitempty"` // Identifies an entity that provides a preview of this object. // Preview identifies an entity that providesa preview of this object. Preview Item `jsonld:"preview,omitempty"` // The date and time at which the object was published // Published the date and time at which the object was published Published time.Time `jsonld:"published,omitempty"` // Identifies a Collection containing objects considered to be responses to this object. // Replies identifies a Collection containing objects considered to be responses to this object. Replies Item `jsonld:"replies,omitempty"` // The date and time describing the actual or expected starting time of the object. // StartTime 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. StartTime time.Time `jsonld:"startTime,omitempty"` // A natural language summarization of the object encoded as HTML. // Summary a natural language summarization of the object encoded as HTML. // *Multiple language tagged summaries may be provided.) Summary NaturalLanguageValue `jsonld:"summary,omitempty,collapsible"` // One or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // Tag One or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // The key difference between attachment and tag is that the former implies association by inclusion, // while the latter implies associated by reference. Tag Item `jsonld:"tag,omitempty"` // The date and time at which the object was updated // Updated the date and time at which the object was updated Updated time.Time `jsonld:"updated,omitempty"` // Identifies one or more links to representations of the object // URL identifies one or more links to representations of the object URL LinkOrURI `jsonld:"url,omitempty"` // Identifies an entity considered to be part of the public primary audience of an Activity Pub Object // To identifies an entity considered to be part of the public primary audience of an Activity Pub Object To ItemCollection `jsonld:"to,omitempty"` // Identifies an Activity Pub Object that is part of the private primary audience of this Activity Pub Object. // Bto identifies an Activity Pub Object that is part of the private primary audience of this Activity Pub Object. Bto ItemCollection `jsonld:"bto,omitempty"` // Identifies an Activity Pub Object that is part of the public secondary audience of this Activity Pub Object. // CC identifies an Activity Pub Object that is part of the public secondary audience of this Activity Pub Object. CC ItemCollection `jsonld:"cc,omitempty"` // Identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. // BCC identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. BCC ItemCollection `jsonld:"bcc,omitempty"` // When the object describes a time-bound resource, such as an audio or video, a meeting, etc, // Duration 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 must be expressed as an xsd:duration as defined by [ xmlschema11-2], // section 3.3.6 (e.g. a period of 5 seconds is represented as "PT5S"). Duration time.Duration `jsonld:"duration,omitempty"` // Describes one or more entities that either performed or are expected to perform the activity. // Actor describes one or more entities that either performed or are expected to perform the activity. // Any single activity can have multiple actors. The actor may be specified using an indirect Link. Actor Actor `jsonld:"actor,omitempty"` // Describes the indirect object, or target, of the activity. // Target describes the indirect object, or target, of the activity. // The precise meaning of the target is largely dependent on the type of action being described // but will often be the object of the English preposition "to". // For instance, in the activity "John added a movie to his wishlist", // the target of the activity is John's wishlist. An activity can have more than one target. Target Item `jsonld:"target,omitempty"` // Describes the result of the activity. For instance, if a particular action results in the creation // Result 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. Result Item `jsonld:"result,omitempty"` // Describes an indirect object of the activity from which the activity is directed. // Origin describes an indirect object of the activity from which the activity is directed. // The precise meaning of the origin is the object of the English preposition "from". // For instance, in the activity "John moved an item to List B from List A", the origin of the activity is "List A". Origin Item `jsonld:"origin,omitempty"` // Identifies one or more objects used (or to be used) in the completion of an Activity. Instrument Item `jsonld:"instrument,omitempty"` Source Source `jsonld:"source,omitempty"` // Identifies an exclusive option for a Question. Use of oneOf implies that the Question // Instrument identifies one or more objects used (or to be used) in the completion of an Activity. Instrument Item `jsonld:"instrument,omitempty"` // OneOf identifies an exclusive option for a Question. Use of oneOf implies that the Question // can have only a single answer. To indicate that a Question can have multiple answers, use anyOf. OneOf Item `jsonld:"oneOf,omitempty"` // Identifies an inclusive option for a Question. Use of anyOf implies that the Question can have multiple answers. // AnyOf identifies an inclusive option for a Question. Use of anyOf implies that the Question can have multiple answers. // To indicate that a Question can have only one answer, use oneOf. AnyOf Item `jsonld:"anyOf,omitempty"` // Indicates that a question has been closed, and answers are no longer accepted. // Closed indicates that a question has been closed, and answers are no longer accepted. Closed bool `jsonld:"closed,omitempty"` }
-
-
-
@@ -28,23 +28,23 @@ var validActorTypes = [...]ActivityVocabularyType{// This mapping may be nested inside the actor document as the value or may be a link to // a JSON-LD document with these properties. type Endpoints struct { // Upload endpoint URI for this user for binary data. // UploadMedia Upload endpoint URI for this user for binary data. UploadMedia Item `jsonld:"uploadMedia,omitempty"` // Endpoint URI so this actor's clients may access remote ActivityStreams objects which require authentication // OauthAuthorizationEndpoint Endpoint URI so this actor's clients may access remote ActivityStreams objects which require authentication // to access. To use this endpoint, the client posts an x-www-form-urlencoded id parameter with the value being // the id of the requested ActivityStreams object. OauthAuthorizationEndpoint Item `jsonld:"oauthAuthorizationEndpoint,omitempty"` // If OAuth 2.0 bearer tokens [RFC6749] [RFC6750] are being used for authenticating client to server interactions, // OauthTokenEndpoint If OAuth 2.0 bearer tokens [RFC6749] [RFC6750] are being used for authenticating client to server interactions, // this endpoint specifies a URI at which a browser-authenticated user may obtain a new authorization grant. OauthTokenEndpoint Item `jsonld:"oauthTokenEndpoint,omitempty"` // If OAuth 2.0 bearer tokens [RFC6749] [RFC6750] are being used for authenticating client to server interactions, // ProvideClientKey If OAuth 2.0 bearer tokens [RFC6749] [RFC6750] are being used for authenticating client to server interactions, // this endpoint specifies a URI at which a client may acquire an access token. ProvideClientKey Item `jsonld:"provideClientKey,omitempty"` // If Linked Data Signatures and HTTP Signatures are being used for authentication and authorization, // SignClientKey If Linked Data Signatures and HTTP Signatures are being used for authentication and authorization, // this endpoint specifies a URI at which browser-authenticated users may authorize a client's public // key for client to server interactions. SignClientKey Item `jsonld:"signClientKey,omitempty"` // If Linked Data Signatures and HTTP Signatures are being used for authentication and authorization, // SharedInbox If Linked Data Signatures and HTTP Signatures are being used for authentication and authorization, // this endpoint specifies a URI at which a client key may be signed by the actor's key for a time window to // act on behalf of the actor in interacting with foreign servers. SharedInbox Item `jsonld:"sharedInbox,omitempty"`
-
-
-
@@ -264,7 +264,7 @@ func CollectionNew(id ObjectID) *Collection {return &c } // CollectionNew initializes a new Collection // OrderedCollectionNew initializes a new OrderedCollection func OrderedCollectionNew(id ObjectID) *OrderedCollection { o := OrderedCollection{ID: id, Type: OrderedCollectionType} o.Name = NaturalLanguageValueNew()
-
@@ -285,7 +285,7 @@ func CollectionPageNew(parent CollectionInterface) *CollectionPage {return &p } // CollectionNew initializes a new OrderedCollectionPage // OrderedCollectionPageNew initializes a new OrderedCollectionPage func OrderedCollectionPageNew(parent CollectionInterface) *OrderedCollectionPage { p := OrderedCollectionPage{ PartOf: parent.GetLink(),
-
-
-
@@ -249,82 +249,82 @@ func (n *NaturalLanguageValue) UnmarshalText(data []byte) error {// The Activity Pub Object type serves as the base type for most of the other kinds of objects defined in the Activity Vocabulary, // including other Core types such as Activity, IntransitiveActivity, Collection and OrderedCollection. type Object struct { // Provides the globally unique identifier for anActivity Pub Object or Link. // ID provides the globally unique identifier for anActivity Pub Object or Link. ID ObjectID `jsonld:"id,omitempty"` // Identifies the Activity Pub Object or Link type. Multiple values may be specified. // Type identifies the Activity Pub Object or Link type. Multiple values may be specified. Type ActivityVocabularyType `jsonld:"type,omitempty"` // A simple, human-readable, plain-text name for the object. // Name a simple, human-readable, plain-text name for the object. // HTML markup MUST NOT be included. The name MAY be expressed using multiple language-tagged values. Name NaturalLanguageValue `jsonld:"name,omitempty,collapsible"` // Identifies a resource attached or related to an object that potentially requires special handling. // Attachment identifies a resource attached or related to an object that potentially requires special handling. // The intent is to provide a model that is at least semantically similar to attachments in email. Attachment Item `jsonld:"attachment,omitempty"` // Identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // AttributedTo identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // For instance, an object might be attributed to the completion of another activity. AttributedTo Item `jsonld:"attributedTo,omitempty"` // Identifies one or more entities that represent the total population of entities // Audience identifies one or more entities that represent the total population of entities // for which the object can considered to be relevant. Audience Item `jsonld:"audience,omitempty"` // The content or textual representation of the Activity Pub Object encoded as a JSON string. // Content or textual representation of the Activity Pub Object encoded as a JSON string. // By default, the value of content is HTML. // The mediaType property can be used in the object to indicate a different content type. // (The content MAY be expressed using multiple language-tagged values.) Content NaturalLanguageValue `jsonld:"content,omitempty,collapsible"` // Identifies the context within which the object exists or an activity was performed. // Context identifies the context within which the object exists or an activity was performed. // The notion of "context" used is intentionally vague. // The intended function is to serve as a means of grouping objects and activities that share a // common originating context or purpose. An example could be all activities relating to a common project or event. Context Item `jsonld:"context,omitempty"` // When used on an Object, identifies the MIME media type of the value of the content property. // MediaType when used on an Object, identifies the MIME media type of the value of the content property. // If not specified, the content property is assumed to contain text/html content. MediaType MimeType `jsonld:"mediaType,omitempty"` // The date and time describing the actual or expected ending time of the object. // EndTime 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. EndTime time.Time `jsonld:"endTime,omitempty"` // Identifies the entity (e.g. an application) that generated the object. // Generator identifies the entity (e.g. an application) that generated the object. Generator Item `jsonld:"generator,omitempty"` // Indicates an entity that describes an icon for this object. // Icon indicates an entity that describes an icon for this object. // The image should have an aspect ratio of one (horizontal) to one (vertical) // and should be suitable for presentation at a small size. Icon Item `jsonld:"icon,omitempty"` // Indicates an entity that describes an image for this object. // Image indicates an entity that describes an image for this object. // Unlike the icon property, there are no aspect ratio or display size limitations assumed. Image Item `jsonld:"image,omitempty"` // Indicates one or more entities for which this object is considered a response. // InReplyTo indicates one or more entities for which this object is considered a response. InReplyTo Item `jsonld:"inReplyTo,omitempty"` // Indicates one or more physical or logical locations associated with the object. // Location indicates one or more physical or logical locations associated with the object. Location Item `jsonld:"location,omitempty"` // Identifies an entity that provides a preview of this object. // Preview identifies an entity that provides a preview of this object. Preview Item `jsonld:"preview,omitempty"` // The date and time at which the object was published // Published the date and time at which the object was published Published time.Time `jsonld:"published,omitempty"` // Identifies a Collection containing objects considered to be responses to this object. // Replies identifies a Collection containing objects considered to be responses to this object. Replies Item `jsonld:"replies,omitempty"` // The date and time describing the actual or expected starting time of the object. // StartTime 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. StartTime time.Time `jsonld:"startTime,omitempty"` // A natural language summarization of the object encoded as HTML. // Summary a natural language summarization of the object encoded as HTML. // *Multiple language tagged summaries may be provided.) Summary NaturalLanguageValue `jsonld:"summary,omitempty,collapsible"` // One or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // Tag one or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // The key difference between attachment and tag is that the former implies association by inclusion, // while the latter implies associated by reference. Tag Item `jsonld:"tag,omitempty"` // The date and time at which the object was updated // Updated the date and time at which the object was updated Updated time.Time `jsonld:"updated,omitempty"` // Identifies one or more links to representations of the object // URL identifies one or more links to representations of the object URL LinkOrURI `jsonld:"url,omitempty"` // Identifies an entity considered to be part of the public primary audience of an Activity Pub Object // To identifies an entity considered to be part of the public primary audience of an Activity Pub Object To ItemCollection `jsonld:"to,omitempty"` // Identifies anActivity Pub Object that is part of the private primary audience of this Activity Pub Object. // Bto identifies anActivity Pub Object that is part of the private primary audience of this Activity Pub Object. Bto ItemCollection `jsonld:"bto,omitempty"` // Identifies anActivity Pub Object that is part of the public secondary audience of this Activity Pub Object. // CC identifies anActivity Pub Object that is part of the public secondary audience of this Activity Pub Object. CC ItemCollection `jsonld:"cc,omitempty"` // Identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. // BCC identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. BCC ItemCollection `jsonld:"bcc,omitempty"` // When the object describes a time-bound resource, such as an audio or video, a meeting, etc, // Duration 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 must be expressed as an xsd:duration as defined by [ xmlschema11-2], // section 3.3.6 (e.g. a period of 5 seconds is represented as "PT5S").
-
@@ -332,38 +332,38 @@ type Object struct {} type ( // Article Represents any kind of multi-paragraph written work. // Article represents any kind of multi-paragraph written work. Article Object // Audio Represents an audio document of any kind. // Audio represents an audio document of any kind. Audio Document // Document Represents a document of any kind. // Document represents a document of any kind. Document Object // Event Represents any kind of event. // Event represents any kind of event. Event Object // Image An image document of any kind Image Document // Note Represents a short written work typically less than a single paragraph in length. // Note represents a short written work typically less than a single paragraph in length. Note Object // Page Represents a Web Page. // Page represents a Web Page. Page Document // Video Represents a video document of any kind // Video represents a video document of any kind Video Document ) // Place Represents a logical or physical location. See 5.3 Representing Places for additional information. // Place represents a logical or physical location. See 5.3 Representing Places for additional information. type Place struct { Object // Accuracy Indicates the accuracy of position coordinates on a Place objects. // Accuracy indicates the accuracy of position coordinates on a Place objects. // Expressed in properties of percentage. e.g. "94.0" means "94.0% accurate". Accuracy float32 // Altitude Indicates the altitude of a place. The measurement units is indicated using the units property. // Altitude indicates the altitude of a place. The measurement units is indicated using the units property. // If units is not specified, the default is assumed to be "m" indicating meters. Altitude float32 // Latitude The latitude of a place // Latitude the latitude of a place Latitude float32 // Longitude The longitude of a place // Longitude the longitude of a place Longitude float32 // Radius The radius from the given latitude and longitude for a Place. // Radius the radius from the given latitude and longitude for a Place. // The units is expressed by the units property. If units is not specified, // the default is assumed to be "m" indicating "meters". Radius int
-
@@ -373,16 +373,16 @@ type Place struct {Units string } // Profile A Profile is a content object that describes another Object, // Profile a Profile is a content object that describes another Object, // typically used to describe Actor Type objects. // The Describes property is used to reference the object being described by the profile. // The describes property is used to reference the object being described by the profile. type Profile struct { Object // Describes On a Profile object, the describes property identifies the object described by the Profile. Describes Item `jsonld:"describes,omitempty"` } // Relationship Describes a relationship between two individuals. // Relationship describes a relationship between two individuals. // The subject and object properties are used to identify the connected individuals. //See 5.2 Representing Relationships Between Entities for additional information. // 5.2: The relationship property specifies the kind of relationship that exists between the two individuals identified
-
@@ -390,87 +390,87 @@ type Profile struct {// as a "reified statement" where subject identifies the subject, relationship identifies the predicate, // and object identifies the object. type Relationship struct { // Provides the globally unique identifier for anActivity Pub Object or Link. // ID provides the globally unique identifier for anActivity Pub Object or Link. ID ObjectID `jsonld:"id,omitempty"` // Identifies the Activity Pub Object or Link type. Multiple values may be specified. // Type identifies the Activity Pub Object or Link type. Multiple values may be specified. Type ActivityVocabularyType `jsonld:"type,omitempty"` // A simple, human-readable, plain-text name for the object. // Name a simple, human-readable, plain-text name for the object. // HTML markup MUST NOT be included. The name MAY be expressed using multiple language-tagged values. Name NaturalLanguageValue `jsonld:"name,omitempty,collapsible"` // Identifies a resource attached or related to an object that potentially requires special handling. // Attachment identifies a resource attached or related to an object that potentially requires special handling. // The intent is to provide a model that is at least semantically similar to attachments in email. Attachment Item `jsonld:"attachment,omitempty"` // Identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // AttributedTo identifies one or more entities to which this object is attributed. The attributed entities might not be Actors. // For instance, an object might be attributed to the completion of another activity. AttributedTo Item `jsonld:"attributedTo,omitempty"` // Identifies one or more entities that represent the total population of entities // Audience identifies one or more entities that represent the total population of entities // for which the object can considered to be relevant. Audience Item `jsonld:"audience,omitempty"` // The content or textual representation of the Activity Pub Object encoded as a JSON string. // Content the content or textual representation of the Activity Pub Object encoded as a JSON string. // By default, the value of content is HTML. // The mediaType property can be used in the object to indicate a different content type. // (The content MAY be expressed using multiple language-tagged values.) Content NaturalLanguageValue `jsonld:"content,omitempty,collapsible"` // Identifies the context within which the object exists or an activity was performed. // Context identifies the context within which the object exists or an activity was performed. // The notion of "context" used is intentionally vague. // The intended function is to serve as a means of grouping objects and activities that share a // common originating context or purpose. An example could be all activities relating to a common project or event. Context Item `jsonld:"context,omitempty"` // When used on an Object, identifies the MIME media type of the value of the content property. // MediaType when used on an Object, identifies the MIME media type of the value of the content property. // If not specified, the content property is assumed to contain text/html content. MediaType MimeType `jsonld:"mediaType,omitempty"` // The date and time describing the actual or expected ending time of the object. // EndTime 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. EndTime time.Time `jsonld:"endTime,omitempty"` // Identifies the entity (e.g. an application) that generated the object. // Generator identifies the entity (e.g. an application) that generated the object. Generator Item `jsonld:"generator,omitempty"` // Indicates an entity that describes an icon for this object. // Icon indicates an entity that describes an icon for this object. // The image should have an aspect ratio of one (horizontal) to one (vertical) // and should be suitable for presentation at a small size. Icon Item `jsonld:"icon,omitempty"` // Indicates an entity that describes an image for this object. // Image indicates an entity that describes an image for this object. // Unlike the icon property, there are no aspect ratio or display size limitations assumed. Image Item `jsonld:"image,omitempty"` // Indicates one or more entities for which this object is considered a response. // InReplyTo indicates one or more entities for which this object is considered a response. InReplyTo Item `jsonld:"inReplyTo,omitempty"` // Indicates one or more physical or logical locations associated with the object. // Location indicates one or more physical or logical locations associated with the object. Location Item `jsonld:"location,omitempty"` // Identifies an entity that provides a preview of this object. // Preview identifies an entity that provides a preview of this object. Preview Item `jsonld:"preview,omitempty"` // The date and time at which the object was published // Published the date and time at which the object was published Published time.Time `jsonld:"published,omitempty"` // Identifies a Collection containing objects considered to be responses to this object. // Replies identifies a Collection containing objects considered to be responses to this object. Replies Item `jsonld:"replies,omitempty"` // The date and time describing the actual or expected starting time of the object. // StartTime 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. StartTime time.Time `jsonld:"startTime,omitempty"` // A natural language summarization of the object encoded as HTML. // Summary a natural language summarization of the object encoded as HTML. // *Multiple language tagged summaries may be provided.) Summary NaturalLanguageValue `jsonld:"summary,omitempty,collapsible"` // One or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // Tag one or more "tags" that have been associated with an objects. A tag can be any kind of Activity Pub Object. // The key difference between attachment and tag is that the former implies association by inclusion, // while the latter implies associated by reference. Tag Item `jsonld:"tag,omitempty"` // The date and time at which the object was updated // Updated the date and time at which the object was updated Updated time.Time `jsonld:"updated,omitempty"` // Identifies one or more links to representations of the object // URL identifies one or more links to representations of the object URL LinkOrURI `jsonld:"url,omitempty"` // Identifies an entity considered to be part of the public primary audience of an Activity Pub Object // To identifies an entity considered to be part of the public primary audience of an Activity Pub Object To ItemCollection `jsonld:"to,omitempty"` // Identifies anActivity Pub Object that is part of the private primary audience of this Activity Pub Object. // Bto identifies anActivity Pub Object that is part of the private primary audience of this Activity Pub Object. Bto ItemCollection `jsonld:"bto,omitempty"` // Identifies anActivity Pub Object that is part of the public secondary audience of this Activity Pub Object. // CC identifies anActivity Pub Object that is part of the public secondary audience of this Activity Pub Object. CC ItemCollection `jsonld:"cc,omitempty"` // Identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. // BCC identifies one or more Objects that are part of the private secondary audience of this Activity Pub Object. BCC ItemCollection `jsonld:"bcc,omitempty"` // When the object describes a time-bound resource, such as an audio or video, a meeting, etc, // Duration 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 must be expressed as an xsd:duration as defined by [ xmlschema11-2], // section 3.3.6 (e.g. a period of 5 seconds is represented as "PT5S"). Duration time.Duration `jsonld:"duration,omitempty"` // Subject On a Relationship object, the subject property identifies one of the connected individuals. // Subject Subject On a Relationship object, the subject property identifies one of the connected individuals. // For instance, for a Relationship object describing "John is related to Sally", subject would refer to John. Subject Item // Object
-
@@ -480,7 +480,7 @@ type Relationship struct {Relationship Item } // Tombstone A Tombstone represents a content object that has been deleted. // Tombstone a Tombstone represents a content object that has been deleted. // It can be used in Collections to signify that there used to be an object at this position, // but it has been deleted. type Tombstone struct {
-
@@ -494,13 +494,6 @@ type Tombstone struct {// ContentType represents the content type for a Source object type ContentType string // Source is intended to convey some sort of source from which the content markup was derived, // as a form of provenance, or to support future editing by clients. type Source struct { Content ContentType MediaType string } // ValidGenericType validates the type against the valid generic object types func ValidGenericType(typ ActivityVocabularyType) bool { for _, v := range validGenericObjectTypes {
-