{"_id":"@aarekaz/switchboard-discord","_rev":"2-5af6944ab62baf6d54c4896ac4efed19","name":"@aarekaz/switchboard-discord","dist-tags":{"latest":"0.3.5"},"versions":{"0.3.1":{"name":"@aarekaz/switchboard-discord","version":"0.3.1","keywords":["switchboard","discord","bot","adapter"],"author":{"name":"Aarekaz"},"license":"MIT","_id":"@aarekaz/switchboard-discord@0.3.1","maintainers":[{"name":"aarekaz","email":"anuragdhungana5@gmail.com"}],"homepage":"https://github.com/Aarekaz/switchboard#readme","bugs":{"url":"https://github.com/Aarekaz/switchboard/issues"},"dist":{"shasum":"3b3faa15902fad04a11c0d96ace2f698f22de595","tarball":"https://registry.npmjs.org/@aarekaz/switchboard-discord/-/switchboard-discord-0.3.1.tgz","fileCount":5,"integrity":"sha512-jtKBGm8R2b3XWNJHZxzS7HCmWGAPZi76lZyjEKwfYWmciu2blAAULh7ct9s6+gWx+4ppeXjHgdb+lToO/oyrbg==","signatures":[{"sig":"MEQCIFNfTxoxfaHeIcHbNZkcpJHEcxVXjbaBwK4qpBL2FmmRAiBeJzfYmsZ2TTh5YajsEfxSYxWNXY1RlRzDX8a02/Wx3w==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":63885},"main":"./dist/index.js","type":"module","_from":"file:aarekaz-switchboard-discord-0.3.1.tgz","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"scripts":{"dev":"tsup --watch","build":"tsup","clean":"rm -rf dist *.tsbuildinfo","typecheck":"tsc --noEmit"},"_npmUser":{"name":"aarekaz","email":"anuragdhungana5@gmail.com"},"_resolved":"/tmp/69adc2465164958aca59f0c0fb9219ec/aarekaz-switchboard-discord-0.3.1.tgz","_integrity":"sha512-jtKBGm8R2b3XWNJHZxzS7HCmWGAPZi76lZyjEKwfYWmciu2blAAULh7ct9s6+gWx+4ppeXjHgdb+lToO/oyrbg==","repository":{"url":"git+https://github.com/Aarekaz/switchboard.git","type":"git","directory":"packages/discord"},"_npmVersion":"10.8.2","description":"Discord adapter for Switchboard SDK","directories":{},"_nodeVersion":"20.19.6","dependencies":{"discord.js":"^14.14.1","@aarekaz/switchboard-core":"0.3.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.0.1","typescript":"^5.3.3"},"_npmOperationalInternal":{"tmp":"tmp/switchboard-discord_0.3.1_1768284413851_0.8827034233048157","host":"s3://npm-registry-packages-npm-production"}},"0.3.5":{"name":"@aarekaz/switchboard-discord","version":"0.3.5","description":"Discord adapter for Switchboard SDK","keywords":["switchboard","discord","bot","adapter"],"homepage":"https://github.com/Aarekaz/switchboard#readme","repository":{"type":"git","url":"git+https://github.com/Aarekaz/switchboard.git","directory":"packages/discord"},"license":"MIT","author":{"name":"Aarekaz"},"type":"module","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js"}},"main":"./dist/index.js","module":"./dist/index.js","types":"./dist/index.d.ts","dependencies":{"discord.js":"^14.25.1","@aarekaz/switchboard-core":"0.3.5"},"devDependencies":{"tsup":"^8.5.1","typescript":"^5.9.3"},"publishConfig":{"access":"public"},"scripts":{"build":"tsup","dev":"tsup --watch","typecheck":"tsc --noEmit","clean":"rm -rf dist *.tsbuildinfo"},"_id":"@aarekaz/switchboard-discord@0.3.5","bugs":{"url":"https://github.com/Aarekaz/switchboard/issues"},"_integrity":"sha512-RA4csLMuyPx4auKtq0AfaXnrK2EC4SuW3sFmDibTpsmSdyU7YYP38ohaVmj6UoMjgzHrCzFQhTogpvGyxOse/Q==","_resolved":"/tmp/1450fc90eca576d8ecaf14c6bb144533/aarekaz-switchboard-discord-0.3.5.tgz","_from":"file:aarekaz-switchboard-discord-0.3.5.tgz","_nodeVersion":"20.19.6","_npmVersion":"10.8.2","dist":{"integrity":"sha512-RA4csLMuyPx4auKtq0AfaXnrK2EC4SuW3sFmDibTpsmSdyU7YYP38ohaVmj6UoMjgzHrCzFQhTogpvGyxOse/Q==","shasum":"ec4f05ba96f12c12dc81a701e9e281615e158b4e","tarball":"https://registry.npmjs.org/@aarekaz/switchboard-discord/-/switchboard-discord-0.3.5.tgz","fileCount":5,"unpackedSize":63860,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIH8YkxZ+MRUiDzBh29T1ApbTaxfVmQGjHBDaShI6UulmAiEAkVatIACA6ormIJFk7WjpsPheLvb0PQzxbU5N4oFeYWA="}]},"_npmUser":{"name":"aarekaz","email":"anuragdhungana5@gmail.com"},"directories":{},"maintainers":[{"name":"aarekaz","email":"anuragdhungana5@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/switchboard-discord_0.3.5_1768349419001_0.4947444619983812"},"_hasShrinkwrap":false}},"time":{"created":"2026-01-13T06:06:53.702Z","modified":"2026-01-14T00:10:19.270Z","0.3.1":"2026-01-13T06:06:53.989Z","0.3.5":"2026-01-14T00:10:19.164Z"},"bugs":{"url":"https://github.com/Aarekaz/switchboard/issues"},"author":{"name":"Aarekaz"},"license":"MIT","homepage":"https://github.com/Aarekaz/switchboard#readme","keywords":["switchboard","discord","bot","adapter"],"repository":{"type":"git","url":"git+https://github.com/Aarekaz/switchboard.git","directory":"packages/discord"},"description":"Discord adapter for Switchboard SDK","maintainers":[{"name":"aarekaz","email":"anuragdhungana5@gmail.com"}],"readme":"# @aarekaz/switchboard-discord\n\nDiscord adapter for Switchboard SDK.\n\n## Installation\n\n```bash\nnpm install @aarekaz/switchboard-core @aarekaz/switchboard-discord\n# or\npnpm add @aarekaz/switchboard-core @aarekaz/switchboard-discord\n```\n\n## Usage\n\nSimply import the Discord adapter and it will auto-register with Switchboard core:\n\n```typescript\nimport { createBot } from '@aarekaz/switchboard-core';\nimport '@aarekaz/switchboard-discord'; // Auto-registers Discord adapter\n\nconst bot = createBot({\n  platform: 'discord',\n  credentials: {\n    token: process.env.DISCORD_TOKEN,\n  },\n});\n\nbot.onMessage(async (message) => {\n  if (message.text.includes('ping')) {\n    await bot.reply(message, 'pong! 🏓');\n  }\n});\n\nawait bot.start();\n```\n\n## Getting a Discord Bot Token\n\n1. Go to [Discord Developer Portal](https://discord.com/developers/applications)\n2. Create a new application\n3. Go to \"Bot\" → \"Add Bot\"\n4. Copy the token\n5. Enable \"Message Content Intent\" under \"Privileged Gateway Intents\"\n\n## Inviting Your Bot\n\n1. Go to \"OAuth2\" → \"URL Generator\"\n2. Select scopes: `bot`\n3. Select permissions: `Send Messages`, `Read Message History`, `Add Reactions`\n4. Copy the generated URL and open it in your browser\n5. Select a server and authorize\n\n## Discord-Specific Features\n\nYou can use Discord-specific features by passing platform-specific options:\n\n```typescript\nimport { EmbedBuilder } from 'discord.js';\n\nawait bot.sendMessage('channel-id', 'Check out this embed!', {\n  discord: {\n    embeds: [\n      new EmbedBuilder()\n        .setTitle('Hello!')\n        .setDescription('This is a Discord embed')\n        .setColor(0x0099ff),\n    ],\n  },\n});\n```\n\n## Known Limitations\n\n- **Message editing/deletion**: Requires implementing message caching (coming in Phase 5)\n- **Reactions**: Requires implementing message caching (coming in Phase 5)\n- **Threads**: Requires implementing message caching (coming in Phase 5)\n\nThese features will be fully supported once we implement the message cache system.\n\n## Documentation\n\nFor full documentation, visit [github.com/Aarekaz/switchboard](https://github.com/Aarekaz/switchboard)\n\n## License\n\nMIT\n","readmeFilename":"README.md"}