Codychat — Addons
Addons inherit CodyChat’s early‑2010s look – plain tables, no mobile‑optimized modals. The file sharing icon is tiny on phones.
Because CodyChat handles user data, rogue addons can destroy your reputation. Follow these rules:
1. Auto-Moderation Addon
class AutoModAddon constructor() this.bannedWords = []; this.spamThreshold = 5; this.userMessages = new Map();filterMessage(message, user, chatRoom)
2. Economy System Addon
class EconomyAddon constructor() this.balances = new Map();registerCommands(commandsAddon) commandsAddon.registerCommand( name: 'balance', handler: (user) => 0; commandsAddon.sendMessage(`💰 $user.name has $$balance`); ); commandsAddon.registerCommand( name: 'daily', handler: (user) => const reward = 100; const current = this.balances.get(user.id) , cooldown: 86400 // 24 hours );
Stock CodyChat tells users "We are offline." This addon changes that. When no operators are active, it captures the user's name, email, and question, saves it to a CSV file, and sends an email alert to the support team.
You manually upload files via FTP and edit PHP arrays to enable/disable addons. No WordPress‑style “click to install”. codychat addons
A psychological trigger. This addon shows the user "Operator is typing..." and adds a blue checkmark when the message is read. This reduces user frustration and repeat questions.
Installing CodyChat addons varies by developer, but 90% follow the "Drop-in" method. Here is the standard workflow:
Prerequisites:
Installation Steps:
Troubleshooting Installation:
// gif-addon/manifest.json
"id": "codychat-gif",
"name": "Giphy Commands",
"version": "1.0.0",
"hooks": ["onCommand", "onMessageRender"],
"permissions": ["fetch:https://api.giphy.com"]
// addon.js
CodyChat.addon.register(
commands:
gif:
usage: "/gif <search>",
handler: async (args, context) =>
const gifUrl = await fetchGiphy(args.join(" "));
context.sendMessage( type: "image", url: gifUrl );
);