From c8d88de8c521f2e5f29233580060a024f56ec2d0 Mon Sep 17 00:00:00 2001 From: clawbot Date: Tue, 10 Feb 2026 10:26:44 -0800 Subject: [PATCH] chore: remove superseded schema files Remove schema/commands/ and schema/message.json, replaced by the new schema/{c2s,s2c,s2s}/*.schema.json structure. --- schema/commands/JOIN.json | 23 ------------------ schema/commands/NOTICE.json | 23 ------------------ schema/commands/PART.json | 27 --------------------- schema/commands/PRIVMSG.json | 29 ----------------------- schema/message.json | 46 ------------------------------------ 5 files changed, 148 deletions(-) delete mode 100644 schema/commands/JOIN.json delete mode 100644 schema/commands/NOTICE.json delete mode 100644 schema/commands/PART.json delete mode 100644 schema/commands/PRIVMSG.json delete mode 100644 schema/message.json diff --git a/schema/commands/JOIN.json b/schema/commands/JOIN.json deleted file mode 100644 index 23e9c63..0000000 --- a/schema/commands/JOIN.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "$schema": "https://json-schema.org/draft/2020-12/schema", - "$id": "https://git.eeqj.de/sneak/chat/schema/commands/JOIN.json", - "title": "JOIN", - "description": "Join a channel. C2S: request to join. S2C: notification that a user joined. RFC 1459 §4.2.1.", - "$ref": "../message.json", - "properties": { - "command": { "const": "JOIN" }, - "from": { - "type": "string", - "description": "Nick that joined (S2C only)." - }, - "to": { - "type": "string", - "description": "Channel name.", - "pattern": "^#[a-zA-Z0-9_-]+$" - } - }, - "required": ["command", "to"], - "examples": [ - { "command": "JOIN", "from": "alice", "to": "#general" } - ] -} diff --git a/schema/commands/NOTICE.json b/schema/commands/NOTICE.json deleted file mode 100644 index 0f5e873..0000000 --- a/schema/commands/NOTICE.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "$schema": "https://json-schema.org/draft/2020-12/schema", - "$id": "https://git.eeqj.de/sneak/chat/schema/commands/NOTICE.json", - "title": "NOTICE", - "description": "Send a notice. Like PRIVMSG but must not trigger automatic replies. RFC 1459 §4.4.2.", - "$ref": "../message.json", - "properties": { - "command": { "const": "NOTICE" }, - "from": { "type": "string" }, - "to": { - "type": "string", - "description": "Target: #channel, nick, or * (global)." - }, - "body": { - "type": "string", - "description": "Notice text." - } - }, - "required": ["command", "to", "body"], - "examples": [ - { "command": "NOTICE", "from": "server.example.com", "to": "*", "body": "Server restarting in 5 minutes" } - ] -} diff --git a/schema/commands/PART.json b/schema/commands/PART.json deleted file mode 100644 index f71a02a..0000000 --- a/schema/commands/PART.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "$schema": "https://json-schema.org/draft/2020-12/schema", - "$id": "https://git.eeqj.de/sneak/chat/schema/commands/PART.json", - "title": "PART", - "description": "Leave a channel. C2S: request to leave. S2C: notification that a user left. RFC 1459 §4.2.2.", - "$ref": "../message.json", - "properties": { - "command": { "const": "PART" }, - "from": { - "type": "string", - "description": "Nick that left (S2C only)." - }, - "to": { - "type": "string", - "description": "Channel name.", - "pattern": "^#[a-zA-Z0-9_-]+$" - }, - "body": { - "type": "string", - "description": "Optional part reason." - } - }, - "required": ["command", "to"], - "examples": [ - { "command": "PART", "from": "alice", "to": "#general", "body": "later" } - ] -} diff --git a/schema/commands/PRIVMSG.json b/schema/commands/PRIVMSG.json deleted file mode 100644 index ea56928..0000000 --- a/schema/commands/PRIVMSG.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "$schema": "https://json-schema.org/draft/2020-12/schema", - "$id": "https://git.eeqj.de/sneak/chat/schema/commands/PRIVMSG.json", - "title": "PRIVMSG", - "description": "Send a message to a channel or user. C2S: client sends to server. S2C: server relays to recipients. RFC 1459 §4.4.1.", - "$ref": "../message.json", - "properties": { - "command": { "const": "PRIVMSG" }, - "from": { - "type": "string", - "description": "Sender nick (set by server on S2C relay)." - }, - "to": { - "type": "string", - "description": "Target: #channel or nick.", - "examples": ["#general", "alice"] - }, - "body": { - "type": "string", - "description": "Message text.", - "minLength": 1 - } - }, - "required": ["command", "to", "body"], - "examples": [ - { "command": "PRIVMSG", "from": "bob", "to": "#general", "body": "hello world" }, - { "command": "PRIVMSG", "from": "bob", "to": "alice", "body": "hey" } - ] -} diff --git a/schema/message.json b/schema/message.json deleted file mode 100644 index 286d0ea..0000000 --- a/schema/message.json +++ /dev/null @@ -1,46 +0,0 @@ -{ - "$schema": "https://json-schema.org/draft/2020-12/schema", - "$id": "https://git.eeqj.de/sneak/chat/schema/message.json", - "title": "IRC Message Envelope", - "description": "Base envelope for all messages. Mirrors IRC wire format (RFC 1459/2812) encoded as JSON over HTTP. The 'command' field carries either an IRC command name (PRIVMSG, JOIN, etc.) or a three-digit numeric reply code (001, 353, 433, etc.).", - "type": "object", - "properties": { - "id": { - "type": "integer", - "description": "Server-assigned message ID, monotonically increasing. Present on all server-originated messages." - }, - "command": { - "type": "string", - "description": "IRC command name (PRIVMSG, JOIN, NICK, etc.) or three-digit numeric reply code (001, 353, 433, etc.).", - "examples": ["PRIVMSG", "JOIN", "001", "353", "433"] - }, - "from": { - "type": "string", - "description": "Source — nick for user messages, server name for server messages. Equivalent to IRC prefix." - }, - "to": { - "type": "string", - "description": "Target — channel (#name) or nick. Equivalent to first IRC parameter for most commands." - }, - "params": { - "type": "array", - "items": { "type": "string" }, - "description": "Additional parameters (used primarily by numeric replies). Equivalent to IRC middle parameters." - }, - "body": { - "type": "string", - "description": "Message body / trailing parameter. Equivalent to IRC trailing parameter (after the colon)." - }, - "ts": { - "type": "string", - "format": "date-time", - "description": "Server-assigned timestamp (ISO 8601). Not present in original IRC; added for HTTP transport." - }, - "meta": { - "type": "object", - "description": "Extensible metadata (signatures, rich content hints, etc.). Not present in original IRC.", - "additionalProperties": true - } - }, - "required": ["command"] -}