23 lines
No EOL
755 B
Markdown
23 lines
No EOL
755 B
Markdown
[⬅️ Back to `index`](index.md)
|
|
|
|
# Formatting of socket
|
|
|
|
IRC is quite a hassle to understand, so the first thing to know about the protocol is the **socket** and **server/client**.
|
|
|
|
It's quite simple on client-side, but server-side has to supply more info:
|
|
|
|
```
|
|
↗️ PRIVMSG foo :content
|
|
🔀 :nick!ident@host PRIVMSG foo :content
|
|
↗️ COMMAND arg :content
|
|
↙️ :server RPL nick data :content
|
|
```
|
|
|
|
> [!CAUTION]
|
|
> If the command has content, the colon MUST be included, and is at the beginning of the content, not the end of the command/args.
|
|
> ```
|
|
> ↗️ COMMAND: content
|
|
> ↙️ :server 421 nick COMMAND: :Unknown command
|
|
> ^ Replace nick with the nickname of the current connection.
|
|
> ```
|
|
> For more info on 421, see [Not Found](notfound.md) |