docs: ♻️ Removed usage of null author, mandate usage of null for unset fields

This commit is contained in:
Jesse Wierzbinski 2025-06-07 20:40:10 +02:00
parent b2f98c1311
commit e6f7a27d3e
No known key found for this signature in database
5 changed files with 9 additions and 13 deletions

View file

@ -24,8 +24,8 @@ Having the authorization is defined as:
<Row>
<Col>
<Properties name="Delete">
<Property name="author" type="Reference | null" required={true} typeLink="/types#reference">
[Reference](/types#reference) to the `User` who is deleting the entity. [Can be set to `null` to represent the instance](/entities/instance-metadata#the-null-author).
<Property name="author" type="Reference" required={true} typeLink="/types#reference">
[Reference](/types#reference) to the `User` who is deleting the entity.
</Property>
<Property name="deleted_type" type="string" required={true}>
Type of the entity being deleted.

View file

@ -7,12 +7,6 @@ export const metadata = {
Contains metadata about a Versia instance, such as capabilities and endpoints. {{ className: 'lead' }}
## The `null` Author
On some entities that have an `author` field, the `author` can be `null` to represent the instance itself as the author (like ActivityPub's Server Actors).
Check the entity's documentation page to see if it supports this (it will be noted in the `author` field).
## Entity Definition
<Row>

View file

@ -12,7 +12,7 @@ Entities are the foundation of the Versia protocol. A similar concept to entitie
An entity is a simple JSON object that represents a core data structure in Versia. Entities are used to represent various types of data, such as users, notes, and more. Each entity has a unique `id` property that is used to identify it within the instance.
Any field in an entity not marked as `required` may be omitted or set to `null`.
Any field in an entity not marked as `required` may be set to `null`. These fields **must not** be omitted: they must be present with a `null` value if not set.
<Row>
<Col>