IRC Protocol
Repartee implements comprehensive IRC protocol support covering RFC 2812 and a wide range of IRCv3 extensions, all negotiated automatically at connection time.
Core Protocol
The core IRC layer handles all standard protocol operations defined in RFC 2812:
- Connection registration -- NICK, USER, PASS, and capability negotiation
- Channel operations -- JOIN, PART, KICK, INVITE, TOPIC, MODE, ban lists
- Messaging -- PRIVMSG, NOTICE to channels and users
- Server queries -- MOTD, LUSERS, VERSION, STATS, INFO, ADMIN, TIME, LINKS
- User queries -- WHO, WHOIS, WHOWAS, NAMES, LIST
- CTCP -- VERSION, PING, TIME, ACTION, and custom CTCP queries
IRCv3 Capabilities
Repartee negotiates IRCv3 capabilities during connection via CAP LS/REQ/ACK. The following capabilities are requested when the server supports them:
| Capability | Description |
|---|---|
multi-prefix | Multiple mode prefixes per nick (e.g. @+nick) |
extended-join | Account name and realname in JOIN messages |
ircnet.com/extended-join | IRCnet ircd 2.12 extension -- JOIN also carries UID, IP and netjoin flag |
server-time | Message timestamps from the server |
account-tag | Account name on every message |
cap-notify | Server-side capability change notifications |
away-notify | Real-time away status changes |
account-notify | Account login/logout notifications |
chghost | Real-time ident/hostname changes |
setname | Live realname updates (/setname) |
echo-message | Authoritative echo of sent messages |
labeled-response | Request/response correlation across batch and single replies |
invite-notify | Notifications for channel invites |
batch | Grouped message batches (netsplit/netjoin, multiline, chathistory, search) |
userhost-in-names | Full user@host in NAMES replies |
no-implicit-names | Suppresses implicit NAMES on JOIN when negotiated (no-implicit-names, draft/no-implicit-names, soju.im/no-implicit-names) |
message-tags | Arbitrary IRCv3 message metadata (incl. msgid), and client tags on TAGMSG |
extended-monitor | MONITOR online/offline watching (/monitor) plus real-time away/account/host/realname notifications (extended-monitor / draft/extended-monitor) |
draft/chathistory | Server/bouncer history: CHATHISTORY TARGETS discovery, scroll-back paging, reconnect gap-fill, BETWEEN & AROUND |
draft/event-playback | JOIN/PART/mode replay inside history batches |
draft/multiline | A multi-line message sent as one logical message |
draft/read-marker | Cross-client read-marker synchronization (MARKREAD, plus soju.im/read) |
draft/message-redaction | Message deletion (REDACT via /redact) |
draft/account-registration | In-band account registration and verification (/account) |
draft/metadata-2 | Conversation metadata (pin, mute, block) and live sync (/bmeta) |
draft/extended-isupport | Extended RPL_ISUPPORT parameter negotiation |
draft/channel-context | Channel context client tag (+draft/channel-context / channel-context) |
draft/webpush | Browser WebPush notifications via bouncer (draft/webpush / soju.im/webpush) |
soju.im/bouncer-networks | Bouncer network discovery, live updates (soju.im/bouncer-networks-notify), and BOUNCER BIND (/bouncer) |
soju.im/search | Server-side message search (/bsearch) |
soju.im/client-cert | Bouncer TLS client certificate pinning and generation (/bcert) |
The ratified +typing client tag rides on TAGMSG over message-tags, so it needs no capability of its own.
First-Class Bouncer Support (Soju & Lurker)
Repartee treats modern IRCv3 bouncers — Soju and Lurker — as first-class citizens:
- Control connections & auto-discovery -- Set
bouncer_control = true(or/server add ... -bouncer-control) to negotiatesoju.im/bouncer-networks, list all upstream networks, and automatically spawn child connections for each configured network. Manage networks live with/bouncer(list,refresh,connect,add,change,delete). - Explicit & legacy network binding -- Bind directly to a bouncer network ID with
bouncer_network_id(BOUNCER BIND <id>) or keep existingusername/PASSnetwork selectors (user/net@client). Autojoin is suppressed on bound connections so the bouncer restores its joined channels cleanly. - Conversation discovery & server-owned history -- Discovers active channels and queries via
CHATHISTORY TARGETS, pages scrollback on demand, and keeps bouncer history server-owned (without duplicating messages into local SQLite logs). - Read-marker sync -- Negotiates
draft/read-markerandsoju.im/read(MARKREAD) so read state stays synchronized across Repartee's TUI, web frontend, and other bouncer clients. - Bouncer commands -- Search server-side history with
/bsearch(soju.im/searchorCHATHISTORY BETWEEN/AROUND), manage conversationpin/mute/blockmetadata with/bmeta, manage TLS client certificates with/bcert, authenticate upstream accounts with/authand/account, and upload files up to 64 MiB via bouncerFILEHOSTwith/upload.
Server History & Multiline
When a server or bouncer (soju, lurker, ergo, …) advertises draft/chathistory, Repartee pulls history over the wire: scroll a channel toward the top to page older messages (CHATHISTORY BEFORE), open an empty bouncer query to load its recent backlog, and after a reconnect the gap since your last message is filled automatically (CHATHISTORY AFTER/LATEST). Direct IRC connections fold history into the local SQLite backlog, while bouncer-backed connections keep history server-owned in memory. History is de-duplicated by msgid and rendered quietly (no notification spam).
draft/multiline lets a pasted or composed multi-line message travel as a single logical message — framed as one BATCH, reassembled on the other side, and E2E-safe so an encrypted block stays one RPE2E unit. In the TUI, Alt+Enter inserts a line break. See the IRCv3 Support reference for the full behaviour.
Typing Indicators
Repartee implements the ratified IRCv3 +typing client tag, so you can see who is actively composing a message in the current channel or query — shown as a status-line item in the TUI and a matching indicator in the web UI (alice and bob are typing…).
Notifications are throttled to one every 3 seconds and expire on their own (6 s after an active, 30 s after a paused), so a peer who disappears mid-sentence never leaves a stuck indicator. Sending the message retracts it. A /me draft counts as typing; a /command draft does not. Typing frames are charged against the normal flood budget, and a TAGMSG never opens a buffer, lands in your log, or bumps an unread counter.
Sending is on by default. Out of the box, people in your channels and queries can see when you are composing. Turn it off with /set typing.send_channels false and /set typing.send_queries false; /set typing.show false stops displaying everyone else's. See the [typing] configuration.
SASL Authentication
Repartee supports six SASL mechanisms for authenticating with IRC services and bouncers:
- EXTERNAL -- TLS client certificate authentication (
client_cert_pathPEM chain + key) - ECDSA-NIST256P-CHALLENGE -- NIST P-256 public-key challenge-response
- SCRAM-SHA-512, SCRAM-SHA-256, SCRAM-SHA-1 -- salted challenge-response authentication with server signature verification and no plaintext password transmission
- PLAIN -- username and password authentication
- OAUTHBEARER -- RFC 7628 OAuth 2.0 bearer token authentication (explicit opt-in via
sasl_mechanism = "OAUTHBEARER"for OAuth-enabled bouncers)
Tip: SASL authentication is configured per-server in your config.toml. When sasl_mechanism is omitted, Repartee automatically selects the strongest usable mechanism offered by the server.
WHOX Support
WHOX (extended WHO) is auto-detected when the server advertises it via ISUPPORT. Repartee uses WHOX queries to populate account names and full user@host information for nick entries, providing richer user data in the nick list and enabling account-based features like extbans.
Full parity on ircu-family and IRCnet servers. /who — and the nick-list metadata the automatic join-time WHO feeds — understands the SID/UID-aware replies these ircds send, so away state, account names, ident and real hostnames populate correctly there instead of coming back blank. Repartee picks the right field selector per server lineage, disambiguates the reply layout by argument count, and strips IRCnet's extra SID token so it no longer renders glued to the realname. Plain WHO (352) updates nick entries too, so even servers without WHOX get away state and real hostnames.
Extban
Repartee supports the $a:account extended ban type, which bans users by their services account name rather than by hostmask. This is more reliable than hostmask bans since accounts persist across reconnections and host changes.
Use the /ban -a shorthand to quickly set an account-based ban on a user in the current channel.
DCC CHAT
Repartee supports direct peer-to-peer chat connections via the DCC CHAT protocol:
- Active and passive modes -- initiate direct connections or use reverse (passive) DCC for users behind NAT
=nickbuffer convention -- DCC chats appear as=Alicein the buffer list, matching irssi behavior- Auto IP detection -- from the IRC socket, with manual override via
/set dcc.own_ip - Auto-accept masks -- configure trusted hostmasks to automatically accept DCC requests
- Tab-completable commands --
/dcc chat,/dcc close,/dcc list,/dcc reject
Flood Protection
Repartee includes built-in flood protection to prevent being disconnected for sending too many messages too quickly. Outgoing messages are rate-limited to comply with server-side flood thresholds (including provider SAFERATE ISUPPORT limits), with automatic queuing and draining.
Netsplit Detection
Netsplit events (server-to-server link failures) are automatically detected and displayed as collapsed, human-readable summaries rather than flooding your channel with individual QUIT and JOIN messages. This uses the IRCv3 batch capability when available, with pattern-based heuristic detection as a fallback.
Multi-Network Support
Repartee supports connecting to multiple IRC networks simultaneously. Add multiple [servers.*] sections to your config file and each network gets its own connection, set of channel buffers, and independent state. All connections share a single event loop for efficient resource usage.
Next: See the IRCv3 Support reference for detailed protocol coverage, or the Configuration guide to set up server connections.