Skip to content

Commit 2c52155

Browse files
committed
chathistory: clarify limit requirements for servers
1 parent d0a37ae commit 2c52155

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

extensions/chathistory.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@ The `target` parameter specifies a single buffer (channel or nickname) from whic
6666

6767
A `timestamp` parameter MUST have the format `timestamp=YYYY-MM-DDThh:mm:ss.sssZ`, as in the [server-time][server-time] extension. A `msgid` parameter MUST have the format `msgid=foobar`, as in the [message-ids][message-ids] extension.
6868

69+
A `limit` parameter MUST be a positive integer. Server should attempt to return exactly `limit` messages (or as many as available), but MAY return more or fewer due to implementation constraints. The `draft/chathistory-end` tag indicates whether more messages are available.
70+
6971
If the `batch` capability was negotiated, the server MUST reply to a successful `CHATHISTORY` command using a [`batch`][batch]. For subcommands that return message history (i.e. all subcommands other than `TARGETS`), the batch MUST have type `chathistory` and take a single additional parameter, the canonical name of the target being queried. For `TARGETS`, the batch MUST have type `draft/chathistory-targets`. If no content exists to return, the server SHOULD return an empty batch in order to avoid the client waiting for a reply.
7072

7173
If the client has not negotiated the `draft/event-playback` capability, the server MUST NOT send any lines other than `PRIVMSG` and `NOTICE` in the reply batch, unless allowed by a capability negotiated by the client. If the client has negotiated `draft/event-playback`, the server SHOULD send additional lines relevant to the chat history, including but not limited to `TAGMSG`, `JOIN`, `PART`, `QUIT`, `MODE`, `TOPIC`, and `NICK`.

0 commit comments

Comments
 (0)