Having the target
property in the object is a spec violation (because of the domain of the target property). It is a property of Activity
and not of Object
. But I understand the usefulness of knowing that “an object was created to be part of a collection and should only be considered in its context”. Therefore, maybe for objects use the context property instead and keep using target
only in activities?
For example:
{
"@context": "https://www.w3.org/ns/activitystreams",
"id": "http://example.org/activity/123",
"summary": "Sally posted a note to John's wall.",
"type": "Create",
"actor": "acct:sally@example.org",
"object": {
"id": "http://example.org/notes/123",
"type": "Note",
"content": "hello, world.",
"context": {
"target": "http://example.org/john/wall"
}
},
"target": "http://example.org/john/wall"
}