1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-12 14:14:48 +02:00

relay/api: fix name of body field "buffer_name" in doc of POST /api/input

This commit is contained in:
Sébastien Helleu
2025-01-05 10:36:04 +01:00
parent de88cd3b58
commit 3eaa1a3a6e
4 changed files with 8 additions and 8 deletions
+2 -2
View File
@@ -1184,7 +1184,7 @@ Body parameters:
* `buffer_id` (integer, optional): buffer unique identifier (not to be confused
with the buffer number, which is different)
* `buffer` (string, optional, default: `core.weechat`): buffer name
* `buffer_name` (string, optional, default: `core.weechat`): buffer name
* `command` (string, **required**): command or text to send to the buffer
Request example: say "hello!" on channel #weechat:
@@ -1192,7 +1192,7 @@ Request example: say "hello!" on channel #weechat:
[source,shell]
----
curl -L -u 'plain:secret_password' -X POST \
-d '{"buffer": "irc.libera.#weechat", "command": "hello!"}' \
-d '{"buffer_name": "irc.libera.#weechat", "command": "hello!"}' \
'https://localhost:9000/api/input'
----
+2 -2
View File
@@ -1196,7 +1196,7 @@ Paramètres du corps :
* `buffer_id` (entier, facultatif) : identifiant unique du tampon (à ne pas
confondre avec le numéro du tampon, qui est différent)
* `buffer_name` (chaîne, facultatif) : nom de tampon
* `buffer_name` (chaîne, facultatif, par défaut: `core.weechat`) : nom de tampon
* `command` (chaîne, **obligatoire**) : commande ou texte à envoyer au tampon
Exemple de requête : dire "hello!" sur le canal #weechat :
@@ -1204,7 +1204,7 @@ Exemple de requête : dire "hello!" sur le canal #weechat :
[source,shell]
----
curl -L -u 'plain:secret_password' -X POST \
-d '{"buffer": "irc.libera.#weechat", "command": "hello!"}' \
-d '{"buffer_name": "irc.libera.#weechat", "command": "hello!"}' \
'https://localhost:9000/api/input'
----
+3 -3
View File
@@ -994,7 +994,7 @@ error:
* {
* "request": "POST /api/input",
* "body": {
* "buffer": "irc.libera.#weechat",
* "buffer_name": "irc.libera.#weechat",
* "command": "hello!"
* }
* }
@@ -1002,10 +1002,10 @@ error:
* It is converted to an HTTP request which could have been:
*
* POST /api/input HTTP/1.1
* Content-Length: 53
* Content-Length: 58
* Content-Type: application/json
*
* {"buffer": "irc.libera.#weechat","command": "hello!"}
* {"buffer_name": "irc.libera.#weechat","command": "hello!"}
*
* The JSON can also be an array of requests, for example to fetch all buffers
* data and synchronize at same time:
+1 -1
View File
@@ -991,7 +991,7 @@ components:
format: int64
description: Buffer identifier (≥ 0)
example: 1709932823238637
buffer:
buffer_name:
type: string
description: >-
Buffer full name