Skip to content

Commit

Permalink
fix(docs): Add capability and documentation
Browse files Browse the repository at this point in the history
Signed-off-by: Joas Schilling <coding@schilljs.com>
  • Loading branch information
nickvergessen committed Sep 27, 2023
1 parent 7c2799d commit b3af051
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/capabilities.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,4 +129,5 @@

## 18
* `session-state` - Sessions can mark themselves as inactive, so the participant receives notifications again
* `note-to-self` - Support for "Note-to-self" conversation exists
* `config => chat => has-translation-providers` - When true, translation tuples can be loaded from the [OCS Translation API](https://docs.nextcloud.com/server/latest/developer_manual/client_apis/OCS/ocs-translation-api.html#get-available-translation-options).
33 changes: 33 additions & 0 deletions docs/conversation.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,39 @@

- Data: See array definition in `Get user´s conversations`

## Get "Note-to-self" conversation

The conversation is like a group conversation and the user is the owner, but with the following limitations:

* Can not add participants to the conversation
* Can not allow guests
* Can not make read-only
* Can not open the conversations to users or guests
* Can not change permissions
* Can not set lobby
* Can not enable SIP
* Can not configure breakout rooms
* Can not call

If the conversation does not exist at the moment, it will be generated and the user added automatically.

* Required capability: `note-to-self`
* Method: `GET`
* Endpoint: `/room/note-to-self`

* Response:
- Status code:
+ `200 OK`
+ `401 Unauthorized` When the user is not logged in

- Header:

| field | type | Description |
|-------------------------|--------|----------------------------------------------------------------------------------------------------------------------------------------------------------|
| `X-Nextcloud-Talk-Hash` | string | Sha1 value over some config. When you receive a different value on subsequent requests, the capabilities and the signaling settings should be refreshed. |

- Data: See array definition in `Get user´s conversations`

## Get open conversations

* Required capability: `listable-rooms`
Expand Down
1 change: 1 addition & 0 deletions lib/Capabilities.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,7 @@ public function getCapabilities(): array {
'bots-v1',
'markdown-messages',
'session-state',
'note-to-self',
],
'config' => [
'attachments' => [
Expand Down
1 change: 1 addition & 0 deletions tests/php/CapabilitiesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ public function setUp(): void {
'bots-v1',
'markdown-messages',
'session-state',
'note-to-self',
'message-expiration',
'reactions',
];
Expand Down

0 comments on commit b3af051

Please sign in to comment.