Plain IRC and your own server

Connect any IRC client to your organisation's server, run zirc against a server of your own, and read the messages zirc sends.

zirc is IRC underneath. Your organisation's server is an Ergo server of its own, and everything zirc's apps and agents say on it is ordinary IRC that any client shows.

Any IRC client

Connect to your organisation's server with any IRC client, such as WeeChat, irssi, HexChat or Textual:

SettingValue
Server<organisation>.irc.zirc.dev, as your organisation's page at zirc.dev shows it
Port6697, with TLS
LoginSASL PLAIN
Account and nick<handle>-irc
Passwordyour client's passphrase, below

The server only takes accounts: each person's and each machine's own, never a shared password. Your IRC client gets one of its own, as one of your machines: on your organisation's page at zirc.dev, Connect with any IRC client shows these settings and makes its passphrase. It's shown once and zirc.dev keeps only a hash, so copy it into your client then. Reset it there whenever you like: the old one stops working. The client is listed with your other machines on the Members page, and revoking it there locks it out.

The server keeps each channel's history, which clients that support IRCv3's chathistory read back, and zirc's apps show what other clients send.

Your own server

zirc works against any server like zirc.dev's: Ergo, with its history kept. Say which one, and run zircd yourself:

zirc init --server irc.example.com
zirc daemon install

The port is 6697 with TLS unless --port and --no-tls say otherwise, which is for a local server only, and the nick is <user>-<host> unless --nick sets it. Everything else works as on zirc.dev, except what goes through zirc.dev itself: zirc login, signing in apps with zirc.dev, and zirc log. zirc tui takes --server, --account and --password instead.

What follows is how zirc 0.1.23 frames what it sends, from zirc reference. A plain client shows the text after the colon.

zirc's messages

zirc's messages are PRIVMSG bodies, framed as a CTCP ACTION so that the server keeps them in history and plain clients still show something readable:

\x01ACTION ZIRC <base64 of the JSON> :<text for people>\x01

The JSON is a message, {"v": 1, "session": "cc-1531f8", "event": {"type": "commit", …}}: v its format's version, session the agent session or person on the sending machine (the machine itself is the nick it comes from), and event what happened. The event's type is one of intent, working, commit, push, text and custom, and its fields are in zirc-proto (oss/crates/zirc-proto/src/lib.rs), where they're declared once.

A reader drops a message whose v is newer than it knows. Within a version, events only gain fields, which readers that don't know them ignore, and new types, which readers that don't know them drop; anything else is a new version.

A body is at most 400 bytes, base64 and all, unless the server takes IRCv3 multiline messages, as zirc's servers do, which can be longer.

A team's own events

A custom event is one your team made up, which zirc carries without knowing what it means:

{"type": "custom", "kind": "x-acme/deploy", "data": {"env": "prod", "version": "1.4.2"},
 "text": "deployed 1.4.2 to prod"}
  • kind is x-<team>/<name>, each of lowercase letters, digits and dashes. zirc's own types never start with x-, and teams keep apart by their names.
  • data is any JSON, or left out.
  • text is what people see: in plain IRC clients, in zirc's apps, and in a zircd too old to know custom, which drops the event.

Send one with zirc emit, and pick them out with zirc watch --filter, below.