diff options
author | Joas Schilling <coding@schilljs.com> | 2024-01-25 15:39:03 +0100 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2024-01-30 12:38:47 +0100 |
commit | 0d1fc13e36e40a6cd8dfa80915ea77f06b835f80 (patch) | |
tree | 678600aa588b60da1bbde38f61002699a6f68ece /docs | |
parent | 0f03723f51f41f2863620ea3666585b14bce567f (diff) |
feat(chat): Store and expose whether a message or call was silent
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'docs')
-rw-r--r-- | docs/capabilities.md | 1 | ||||
-rw-r--r-- | docs/chat.md | 47 |
2 files changed, 25 insertions, 23 deletions
diff --git a/docs/capabilities.md b/docs/capabilities.md index fd45c3d7e..257b74745 100644 --- a/docs/capabilities.md +++ b/docs/capabilities.md @@ -142,3 +142,4 @@ ## 19 * `delete-messages-unlimited` - Whether messages can be deleted at any time (used to be restricted to 6 hours after posting) * `edit-messages` - Whether messages can be edited (restricted to 24 hours after posting) +* `silent-send-state` - Whether messages contain a flag that they were sent silently diff --git a/docs/chat.md b/docs/chat.md index a892072cb..5a013458d 100644 --- a/docs/chat.md +++ b/docs/chat.md @@ -43,29 +43,30 @@ Base endpoint is: `/ocs/v2.php/apps/spreed/api/v1`: since Nextcloud 13 - Data: Array of messages, each message has at least: -| field | type | Description | -|----------------------------|----------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| `id` | int | ID of the comment | -| `token` | string | Conversation token | -| `actorType` | string | See [Constants - Actor types of chat messages](constants.md#actor-types-of-chat-messages) | -| `actorId` | string | Actor id of the message author | -| `actorDisplayName` | string | Display name of the message author (can be empty for type `deleted_users` and `guests`) | -| `timestamp` | int | Timestamp in seconds and UTC time zone | -| `systemMessage` | string | empty for normal chat message or the type of the system message (untranslated) | -| `messageType` | string | Currently known types are `comment`, `comment_deleted`, `system` and `command` | -| `isReplyable` | bool | True if the user can post a reply to this message (only available with `chat-replies` capability) | -| `referenceId` | string | A reference string that was given while posting the message to be able to identify a sent message again (only available with `chat-reference-id` capability) | -| `message` | string | Message string with placeholders (see [Rich Object String](https://github.com/nextcloud/server/issues/1706)) | -| `messageParameters` | array | Message parameters for `message` (see [Rich Object String](https://github.com/nextcloud/server/issues/1706)) | -| `expirationTimestamp` | int | Unix time stamp when the message expires and show be removed from the clients UI without further note or warning (only available with `message-expiration` capability) | -| `parent` | array | **Optional:** See `Parent data` below | -| `reactions` | int[] | **Optional:** An array map with relation between reaction emoji and total count of reactions with this emoji | -| `reactionsSelf` | string[] | **Optional:** When the user reacted this is the list of emojis the user reacted with | -| `markdown` | bool | **Optional:** Whether the message should be rendered as markdown or shown as plain text | -| `lastEditActorType` | string | Actor type of the last editing author - See [Constants - Actor types of chat messages](constants.md#actor-types-of-chat-messages) (only available with `edit-messages` capability and when the message was actually edited) | -| `lastEditActorId` | string | Actor id of the last editing author (only available with `edit-messages` capability and when the message was actually edited) | -| `lastEditActorDisplayName` | string | Display name of the last editing author (only available with `edit-messages` capability and when the message was actually edited) (can be empty for type `deleted_users` and `guests`) | -| `lastEditTimestamp` | int | Unix time stamp when the message was last edited (only available with `edit-messages` capability and when the message was actually edited) | +| field | type | Description | +|----------------------------|----------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| `id` | int | ID of the comment | +| `token` | string | Conversation token | +| `actorType` | string | See [Constants - Actor types of chat messages](constants.md#actor-types-of-chat-messages) | +| `actorId` | string | Actor id of the message author | +| `actorDisplayName` | string | Display name of the message author (can be empty for type `deleted_users` and `guests`) | +| `timestamp` | int | Timestamp in seconds and UTC time zone | +| `systemMessage` | string | empty for normal chat message or the type of the system message (untranslated) | +| `messageType` | string | Currently known types are `comment`, `comment_deleted`, `system` and `command` | +| `isReplyable` | bool | True if the user can post a reply to this message (only available with `chat-replies` capability) | +| `referenceId` | string | A reference string that was given while posting the message to be able to identify a sent message again (only available with `chat-reference-id` capability) | +| `message` | string | Message string with placeholders (see [Rich Object String](https://github.com/nextcloud/server/issues/1706)) | +| `messageParameters` | array | Message parameters for `message` (see [Rich Object String](https://github.com/nextcloud/server/issues/1706)) | +| `expirationTimestamp` | int | Unix time stamp when the message expires and show be removed from the clients UI without further note or warning (only available with `message-expiration` capability) | +| `parent` | array | **Optional:** See `Parent data` below | +| `reactions` | int[] | **Optional:** An array map with relation between reaction emoji and total count of reactions with this emoji | +| `reactionsSelf` | string[] | **Optional:** When the user reacted this is the list of emojis the user reacted with | +| `markdown` | bool | **Optional:** Whether the message should be rendered as markdown or shown as plain text | +| `lastEditActorType` | string | **Optional:** Actor type of the last editing author - See [Constants - Actor types of chat messages](constants.md#actor-types-of-chat-messages) (only available with `edit-messages` capability and when the message was actually edited) | +| `lastEditActorId` | string | **Optional:** Actor id of the last editing author (only available with `edit-messages` capability and when the message was actually edited) | +| `lastEditActorDisplayName` | string | **Optional:** Display name of the last editing author (only available with `edit-messages` capability and when the message was actually edited) (can be empty for type `deleted_users` and `guests`) | +| `lastEditTimestamp` | int | **Optional:** Unix time stamp when the message was last edited (only available with `edit-messages` capability and when the message was actually edited) | +| `silent` | bool | **Optional:** Whether the message was sent silently (only available with `silent-send-state` capability) | #### Parent data |