diff options
author | Vitor Mattos <vitor@php.rio> | 2023-03-02 13:04:43 -0300 |
---|---|---|
committer | Vitor Mattos <vitor@php.rio> | 2023-03-02 22:00:33 -0300 |
commit | 8ca055cc683400635e8825c1e334d19480279905 (patch) | |
tree | d163d9350a2dc77e549ca1a1c9f514b62e012524 /docs | |
parent | 2e15b55e3e8d29374fd96936b5bb593a5ef1304d (diff) |
* Convert arguments and options to table format
* Add the markdown occ to mkdocs
* Add GitHub Action to check if the documentation is up to date
Signed-off-by: Vitor Mattos <vitor@php.rio>
Diffstat (limited to 'docs')
-rw-r--r-- | docs/occ.md | 785 |
1 files changed, 144 insertions, 641 deletions
diff --git a/docs/occ.md b/docs/occ.md index a8c139f64..0518f6ffb 100644 --- a/docs/occ.md +++ b/docs/occ.md @@ -27,6 +27,7 @@ * [talk:turn:list](#talkturnlist) * [talk:user:remove](#talkuserremove) * [talk:user:transfer-ownership](#talkusertransfer-ownership) + ## talk:command:add Add a new command @@ -35,47 +36,14 @@ Add a new command * `talk:command:add <cmd> <name> <script> <response> <enabled>` -### Arguments - -#### `cmd` - -The command as used in the chat "/help" => "help" - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `name` - -Name of the user posting the response - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `script` - -Script to execute (Must be using absolute paths only) - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `response` - -Who should see the response: 0 - No one, 1 - User, 2 - All -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `enabled` - -Who can use this command: 0 - Disabled, 1 - Moderators, 2 - Users, 3 - Guests - -* Is required: yes -* Is array: no -* Default: `NULL` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `cmd` | The command as used in the chat "/help" => "help" | yes | no | `NULL` | +| `name` | Name of the user posting the response | yes | no | `NULL` | +| `script` | Script to execute (Must be using absolute paths only) | yes | no | `NULL` | +| `response` | Who should see the response: 0 - No one, 1 - User, 2 - All | yes | no | `NULL` | +| `enabled` | Who can use this command: 0 - Disabled, 1 - Moderators, 2 - Users, 3 - Guests | yes | no | `NULL` | ## talk:command:add-samples @@ -86,6 +54,7 @@ Adds some sample commands: /wiki, … * `talk:command:add-samples` + ## talk:command:delete Remove an existing command @@ -94,13 +63,10 @@ Remove an existing command * `talk:command:delete <command-id>` -### Arguments - -#### `command-id` -* Is required: yes -* Is array: no -* Default: `NULL` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `command-id` | | yes | no | `NULL` | ## talk:command:list @@ -110,27 +76,14 @@ List all available commands * `talk:command:list [--output [OUTPUT]] [--] [<app>]` -### Arguments - -#### `app` -Only list the commands of a specific app, "custom" to list all custom commands +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `app` | Only list the commands of a specific app, "custom" to list all custom commands | no | no | `NULL` | -* Is required: no -* Is array: no -* Default: `NULL` - -### Options - -#### `--output` - -Output format (plain, json or json_pretty, default is plain) - -* Accept value: yes -* Is value required: no -* Is multiple: no -* Is negatable: no -* Default: `'plain'` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--output` | Output format (plain, json or json_pretty, default is plain) | yes | no | no | no | 'plain'` | ## talk:command:update @@ -140,53 +93,15 @@ Add a new command * `talk:command:update <command-id> <cmd> <name> <script> <response> <enabled>` -### Arguments - -#### `command-id` - -* Is required: yes -* Is array: no -* Default: `NULL` -#### `cmd` - -The command as used in the chat "/help" => "help" - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `name` - -Name of the user posting the response - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `script` - -Script to execute (Must be using absolute paths only) - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `response` - -Who should see the response: 0 - No one, 1 - User, 2 - All - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `enabled` - -Who can use this command: 0 - Disabled, 1 - Moderators, 2 - Users, 3 - Guests - -* Is required: yes -* Is array: no -* Default: `NULL` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `command-id` | | yes | no | `NULL` | +| `cmd` | The command as used in the chat "/help" => "help" | yes | no | `NULL` | +| `name` | Name of the user posting the response | yes | no | `NULL` | +| `script` | Script to execute (Must be using absolute paths only) | yes | no | `NULL` | +| `response` | Who should see the response: 0 - No one, 1 - User, 2 - All | yes | no | `NULL` | +| `enabled` | Who can use this command: 0 - Disabled, 1 - Moderators, 2 - Users, 3 - Guests | yes | no | `NULL` | ## talk:developer:update-docs @@ -194,8 +109,12 @@ Update documentation of commands ### Usage -* `talk:developer:update-docs` +* `talk:developer:update-docs [<name>]` + +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `name` | The name of command to update. When have this argument, don't will upate the documentation, only will print the markdown output. | no | no | `NULL` | ## talk:monitor:calls @@ -204,17 +123,10 @@ Prints a list with conversations that have an active call as well as their parti ### Usage * `talk:monitor:calls [--output [OUTPUT]]` -### Options -#### `--output` - -Output format (plain, json or json_pretty, default is plain) - -* Accept value: yes -* Is value required: no -* Is multiple: no -* Is negatable: no -* Default: `'plain'` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--output` | Output format (plain, json or json_pretty, default is plain) | yes | no | no | no | 'plain'` | ## talk:active-calls @@ -223,17 +135,10 @@ Allows you to check if calls are currently in process ### Usage * `talk:active-calls [--output [OUTPUT]]` -### Options - -#### `--output` -Output format (plain, json or json_pretty, default is plain) - -* Accept value: yes -* Is value required: no -* Is multiple: no -* Is negatable: no -* Default: `'plain'` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--output` | Output format (plain, json or json_pretty, default is plain) | yes | no | no | no | 'plain'` | ## talk:monitor:room @@ -243,37 +148,15 @@ Prints a list with conversations that have an active call as well as their parti * `talk:monitor:room [--output [OUTPUT]] [--separator SEPARATOR] [--] <token>` -### Arguments - -#### `token` - -Token of the room to monitor - -* Is required: yes -* Is array: no -* Default: `NULL` - -### Options - -#### `--output` -Output format (plain, json or json_pretty, default is plain) +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `token` | Token of the room to monitor | yes | no | `NULL` | -* Accept value: yes -* Is value required: no -* Is multiple: no -* Is negatable: no -* Default: `'plain'` - -#### `--separator` - -Separator for the CSV list when output=csv is used - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `','` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--output` | Output format (plain, json or json_pretty, default is plain) | yes | no | no | no | 'plain'` | +| `--separator` | Separator for the CSV list when output=csv is used | yes | yes | no | no | ','` | ## talk:room:add @@ -283,37 +166,15 @@ Adds users to a room * `talk:room:add [--user USER] [--group GROUP] [--] <token>` -### Arguments - -#### `token` - -Token of the room to add users to - -* Is required: yes -* Is array: no -* Default: `NULL` -### Options +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `token` | Token of the room to add users to | yes | no | `NULL` | -#### `--user` - -Invites the given users to the room - -* Accept value: yes -* Is value required: yes -* Is multiple: yes -* Is negatable: no -* Default: `array ()` - -#### `--group` - -Invites all members of the given groups to the room - -* Accept value: yes -* Is value required: yes -* Is multiple: yes -* Is negatable: no -* Default: `array ()` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--user` | Invites the given users to the room | yes | yes | yes | no | array ()` | +| `--group` | Invites all members of the given groups to the room | yes | yes | yes | no | array ()` | ## talk:room:create @@ -323,117 +184,23 @@ Create a new room * `talk:room:create [--description DESCRIPTION] [--user USER] [--group GROUP] [--public] [--readonly] [--listable LISTABLE] [--password PASSWORD] [--owner OWNER] [--moderator MODERATOR] [--message-expiration MESSAGE-EXPIRATION] [--] <name>` -### Arguments - -#### `name` - -The name of the room to create - -* Is required: yes -* Is array: no -* Default: `NULL` - -### Options - -#### `--description` - -The description of the room to create - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--user` - -Invites the given users to the room to create - -* Accept value: yes -* Is value required: yes -* Is multiple: yes -* Is negatable: no -* Default: `array ()` - -#### `--group` - -Invites all members of the given group to the room to create - -* Accept value: yes -* Is value required: yes -* Is multiple: yes -* Is negatable: no -* Default: `array ()` -#### `--public` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `name` | The name of the room to create | yes | no | `NULL` | -Creates the room as public room if set - -* Accept value: no -* Is value required: no -* Is multiple: no -* Is negatable: no -* Default: `false` - -#### `--readonly` - -Creates the room with read-only access only if set - -* Accept value: no -* Is value required: no -* Is multiple: no -* Is negatable: no -* Default: `false` - -#### `--listable` - -Creates the room with the given listable scope - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--password` - -Protects the room to create with the given password - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--owner` - -Sets the given user as owner of the room to create - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--moderator` - -Promotes the given users to moderators - -* Accept value: yes -* Is value required: yes -* Is multiple: yes -* Is negatable: no -* Default: `array ()` - -#### `--message-expiration` - -Seconds to expire a message after sent. If zero will disable the expire message duration. - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--description` | The description of the room to create | yes | yes | no | no | NULL` | +| `--user` | Invites the given users to the room to create | yes | yes | yes | no | array ()` | +| `--group` | Invites all members of the given group to the room to create | yes | yes | yes | no | array ()` | +| `--public` | Creates the room as public room if set | no | no | no | no | false` | +| `--readonly` | Creates the room with read-only access only if set | no | no | no | no | false` | +| `--listable` | Creates the room with the given listable scope | yes | yes | no | no | NULL` | +| `--password` | Protects the room to create with the given password | yes | yes | no | no | NULL` | +| `--owner` | Sets the given user as owner of the room to create | yes | yes | no | no | NULL` | +| `--moderator` | Promotes the given users to moderators | yes | yes | yes | no | array ()` | +| `--message-expiration` | Seconds to expire a message after sent. If zero will disable the expire message duration. | yes | yes | no | no | NULL` | ## talk:room:delete @@ -443,15 +210,10 @@ Deletes a room * `talk:room:delete <token>` -### Arguments - -#### `token` - -Token of the room to delete -* Is required: yes -* Is array: no -* Default: `NULL` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `token` | Token of the room to delete | yes | no | `NULL` | ## talk:room:demote @@ -461,23 +223,11 @@ Demotes participants of a room to regular users * `talk:room:demote <token> <participant>...` -### Arguments - -#### `token` - -Token of the room in which users should be demoted -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `participant` - -Demotes the given participants of the room to regular users - -* Is required: yes -* Is array: yes -* Default: `array ()` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `token` | Token of the room in which users should be demoted | yes | no | `NULL` | +| `participant` | Demotes the given participants of the room to regular users | yes | yes | `array ()` | ## talk:room:promote @@ -487,23 +237,11 @@ Promotes participants of a room to moderators * `talk:room:promote <token> <participant>...` -### Arguments - -#### `token` - -Token of the room in which users should be promoted - -* Is required: yes -* Is array: no -* Default: `NULL` -#### `participant` - -Promotes the given participants of the room to moderators - -* Is required: yes -* Is array: yes -* Default: `array ()` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `token` | Token of the room in which users should be promoted | yes | no | `NULL` | +| `participant` | Promotes the given participants of the room to moderators | yes | yes | `array ()` | ## talk:room:remove @@ -513,23 +251,11 @@ Remove users from a room * `talk:room:remove <token> <participant>...` -### Arguments - -#### `token` - -Token of the room to remove users from - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `participant` -Removes the given participants from the room - -* Is required: yes -* Is array: yes -* Default: `array ()` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `token` | Token of the room to remove users from | yes | no | `NULL` | +| `participant` | Removes the given participants from the room | yes | yes | `array ()` | ## talk:room:update @@ -539,97 +265,21 @@ Updates a room * `talk:room:update [--name NAME] [--description DESCRIPTION] [--public PUBLIC] [--readonly READONLY] [--listable LISTABLE] [--password PASSWORD] [--owner OWNER] [--message-expiration MESSAGE-EXPIRATION] [--] <token>` -### Arguments - -#### `token` - -The token of the room to update - -* Is required: yes -* Is array: no -* Default: `NULL` - -### Options - -#### `--name` - -Sets a new name for the room - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--description` - -Sets a new description for the room - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--public` -Modifies the room to be a public room (value 1) or private room (value 0) +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `token` | The token of the room to update | yes | no | `NULL` | -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--readonly` - -Modifies the room to be read-only (value 1) or read-write (value 0) - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--listable` - -Modifies the room's listable scope - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--password` - -Sets a new password for the room; pass an empty value to remove password protection - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--owner` - -Sets the given user as owner of the room; pass an empty value to remove the owner - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` - -#### `--message-expiration` - -Seconds to expire a message after sent. If zero will disable the expire message duration. - -* Accept value: yes -* Is value required: yes -* Is multiple: no -* Is negatable: no -* Default: `NULL` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--name` | Sets a new name for the room | yes | yes | no | no | NULL` | +| `--description` | Sets a new description for the room | yes | yes | no | no | NULL` | +| `--public` | Modifies the room to be a public room (value 1) or private room (value 0) | yes | yes | no | no | NULL` | +| `--readonly` | Modifies the room to be read-only (value 1) or read-write (value 0) | yes | yes | no | no | NULL` | +| `--listable` | Modifies the room's listable scope | yes | yes | no | no | NULL` | +| `--password` | Sets a new password for the room; pass an empty value to remove password protection | yes | yes | no | no | NULL` | +| `--owner` | Sets the given user as owner of the room; pass an empty value to remove the owner | yes | yes | no | no | NULL` | +| `--message-expiration` | Seconds to expire a message after sent. If zero will disable the expire message duration. | yes | yes | no | no | NULL` | ## talk:signaling:add @@ -639,35 +289,15 @@ Add an external signaling server. * `talk:signaling:add [--verify] [--] <server> <secret>` -### Arguments - -#### `server` - -A server string, ex. wss://signaling.example.org - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `secret` - -A shared secret string. - -* Is required: yes -* Is array: no -* Default: `NULL` - -### Options - -#### `--verify` -Validate SSL certificate if set. +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `server` | A server string, ex. wss://signaling.example.org | yes | no | `NULL` | +| `secret` | A shared secret string. | yes | no | `NULL` | -* Accept value: no -* Is value required: no -* Is multiple: no -* Is negatable: no -* Default: `false` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--verify` | Validate SSL certificate if set. | no | no | no | no | false` | ## talk:signaling:delete @@ -677,15 +307,10 @@ Remove an existing signaling server. * `talk:signaling:delete <server>` -### Arguments -#### `server` - -An external signaling server string, ex. wss://signaling.example.org - -* Is required: yes -* Is array: no -* Default: `NULL` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `server` | An external signaling server string, ex. wss://signaling.example.org | yes | no | `NULL` | ## talk:signaling:list @@ -694,17 +319,10 @@ List external signaling servers. ### Usage * `talk:signaling:list [--output [OUTPUT]]` -### Options - -#### `--output` -Output format (plain, json or json_pretty, default is plain) - -* Accept value: yes -* Is value required: no -* Is multiple: no -* Is negatable: no -* Default: `'plain'` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--output` | Output format (plain, json or json_pretty, default is plain) | yes | no | no | no | 'plain'` | ## talk:stun:add @@ -714,15 +332,10 @@ Add a new STUN server. * `talk:stun:add <server>` -### Arguments - -#### `server` - -A domain name and port number separated by the colons, ex. stun.nextcloud.com:443 -* Is required: yes -* Is array: no -* Default: `NULL` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `server` | A domain name and port number separated by the colons, ex. stun.nextcloud.com:443 | yes | no | `NULL` | ## talk:stun:delete @@ -732,15 +345,10 @@ Remove an existing STUN server. * `talk:stun:delete <server>` -### Arguments -#### `server` - -A domain name and port number separated by the colons, ex. stun.nextcloud.com:443 - -* Is required: yes -* Is array: no -* Default: `NULL` +| Arguments | Description | Is required | Is array | Default | +|---|---|---|---|---| +| `server` | A domain name and port number separated by the colons, ex. stun.nextcloud.com:443 | yes | no | `NULL` | ## talk:stun:list @@ -749,17 +357,10 @@ List STUN servers. ### Usage * `talk:stun:list [--output [OUTPUT]]` -### Options - -#### `--output` -Output format (plain, json or json_pretty, default is plain) - -* Accept value: yes -* Is value required: no -* Is multiple: no -* Is negatable: no -* Default: `'plain'` +| Options | Accept value | Is value required | Is multiple | is nagatable | Default | +|---|---|---|---|---|---| +| `--output` | Output format (plain, json or json_pretty, default is plain) | yes | no | no | no | 'plain'` | ## talk:turn:add @@ -769,53 +370,17 @@ Add a TURN server. * `talk:turn:add [--secret SECRET] [--generate-secret] [--] <schemes> <server> <protocols>` -### Arguments - -#### `schemes` - -Schemes, can be turn or turns or turn,turns. - -* Is required: yes -* Is array: no -* Default: `NULL` - -#### `server` - -A domain name, ex. turn.nextcloud.com - -* Is required: ye |