Using types from other namespaces as as:object

Hi there,
i’m new in RDFS, AS, AP, etc. And have a problem understanding the reuse of schemas.
If i want to add a as:object to a as:Activity that’s type is not from the AS namespace, how do i do that?

  "@context": "",
  "summary": "Martin created an email",
  "type": "Create",
  "actor": "http://www.test.example/martin",
  "object" : {
   "id": "http://www.test.example/mail/abc123/xyz",
   "type": "Object",
   "url": "http://www.test.example/mail/abc123/xyz"

thr url points to a schema:EmailMessage.
Or do i have to create a new owl:Class that extends schema:EmailMessage and has a “id” and a “type” property?

Thanks Fredy

Ah, as:id is domain owl:Class, so i can use it for schema:EmailMessage!
But there is no property as:type in ???

as:id a owl:DatatypeProperty ,
        owl:DeprecatedProperty ;
  rdfs:label "id"@en ;
  rdfs:range xsd:anyURI ;
  rdfs:domain [
    a owl:Class ;
    owl:unionOf (as:Link as:Object)
  ] .

You add your namespace and then aliases to it in your @context, like so:

        "example": "",
        "customProperty": "example:customProperty"

Mastodon does this exact thing with its toot namespace for example.

Hi @smithereen,
this would mean, that i have to add all properties that i want to use of schema:EmailMessage to the context. And that for each Activity i create. Did I understand you right?

Yes that’s right. Just look at Mastodon’s @contexts.