{"_id":"@amtixdev/simple-discord.js","_rev":"4-998b8ee0cd1b51ea775a70bc6df35e63","name":"@amtixdev/simple-discord.js","dist-tags":{"latest":"0.0.5-beta"},"versions":{"1.0.0":{"name":"@amtixdev/simple-discord.js","version":"1.0.0","keywords":["discord","bot","simplified","library"],"author":{"name":"AmtiXDev"},"license":"MIT","_id":"@amtixdev/simple-discord.js@1.0.0","maintainers":[{"name":"amtixdev","email":"amtixdev@gmail.com"}],"homepage":"https://github.com/Simple-Discord-js/Simple-Discord.js#readme","bugs":{"url":"https://github.com/Simple-Discord-js/Simple-Discord.js/issues"},"dist":{"shasum":"403f1c783a782a1776fefac41afae821bd304cc6","tarball":"https://registry.npmjs.org/@amtixdev/simple-discord.js/-/simple-discord.js-1.0.0.tgz","fileCount":3,"integrity":"sha512-NLnJ00Bm13NpeTZEaf3JOghVRV93Ybc5fOTnt2pUDOdkQ69DLcWHw5HYZKSTo/8csHxsrzUqWH1tsg1jJKYrdA==","signatures":[{"sig":"MEUCIFeq3WD8dRTjpOiSjNA65jDQPMduaOjXpFBdecju8Qf2AiEA6NfatfMbxye0GAU2Nlps0LcSML9hfbu+xSAjBfQQf8Q=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":5355},"main":"sdjs-main.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"amtixdev","email":"amtixdev@gmail.com"},"repository":{"url":"git+https://github.com/Simple-Discord-js/Simple-Discord.js.git","type":"git"},"_npmVersion":"10.2.4","description":"A simplified Discord.js library for beginners.","directories":{},"_nodeVersion":"20.11.0","dependencies":{"discord.js":"^14.16.2"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/simple-discord.js_1.0.0_1727130862099_0.4809299907901634","host":"s3://npm-registry-packages"}},"0.0.2-beta":{"name":"@amtixdev/simple-discord.js","version":"0.0.2-beta","keywords":["discord","bot","simplified","library"],"author":{"name":"AmtiXDev"},"license":"MIT","_id":"@amtixdev/simple-discord.js@0.0.2-beta","maintainers":[{"name":"amtixdev","email":"amtixdev@gmail.com"}],"homepage":"https://github.com/Simple-Discord-js/Simple-Discord.js#readme","bugs":{"url":"https://github.com/Simple-Discord-js/Simple-Discord.js/issues"},"dist":{"shasum":"77557b3c063e87f92fc35a02999d10b35eabab76","tarball":"https://registry.npmjs.org/@amtixdev/simple-discord.js/-/simple-discord.js-0.0.2-beta.tgz","fileCount":3,"integrity":"sha512-kEbtJzE8hZTkqYV1udvgJLoZUUiiC9JPUrhGl+I8r2wnoSmeiEMC+Rmq24JTxTnFTSFRwjv9MiBRGgRwO5KhWg==","signatures":[{"sig":"MEQCIG6mqE6FVJrnf+RYy0PHWIHGY/sfeux3YlKXaWSKqhICAiBd8xu59BlEEJfw1TT50/DHm7obJNKwoDfV5F3EqjFO6Q==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":7769},"main":"sdjs-main.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"amtixdev","email":"amtixdev@gmail.com"},"repository":{"url":"git+https://github.com/Simple-Discord-js/Simple-Discord.js.git","type":"git"},"_npmVersion":"10.2.4","description":"A simplified Discord.js library for beginners.","directories":{},"_nodeVersion":"20.11.0","dependencies":{"discord.js":"^14.16.2"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/simple-discord.js_0.0.2-beta_1732903060464_0.9469627666395011","host":"s3://npm-registry-packages"}},"0.0.3-beta":{"name":"@amtixdev/simple-discord.js","version":"0.0.3-beta","keywords":["discord","bot","simplified","library"],"author":{"name":"AmtiXDev"},"license":"MIT","_id":"@amtixdev/simple-discord.js@0.0.3-beta","maintainers":[{"name":"amtixdev","email":"amtixdev@gmail.com"}],"homepage":"https://github.com/Simple-Discord-js/Simple-Discord.js#readme","bugs":{"url":"https://github.com/Simple-Discord-js/Simple-Discord.js/issues"},"dist":{"shasum":"9ec30722650af4877a5355f407e63fd0134ec7fd","tarball":"https://registry.npmjs.org/@amtixdev/simple-discord.js/-/simple-discord.js-0.0.3-beta.tgz","fileCount":3,"integrity":"sha512-081RDgtqd9AlmzZT93UIXaorKiu3Wm2fynk9nWnORhY0YdtQAKlWUrIM1hAbeiklBQN25K018hxW5Msl7pkT4g==","signatures":[{"sig":"MEYCIQCMkZrw5rSyPIA0JZXbDDEBTf+7e+ctPrQFBq1MVzxKmgIhAOn7vdgyrByiml4ACPTZHJ6uNM+0qymTaaALpD/qdggE","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":7846},"main":"sdjs-main.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"amtixdev","email":"amtixdev@gmail.com"},"repository":{"url":"git+https://github.com/Simple-Discord-js/Simple-Discord.js.git","type":"git"},"_npmVersion":"10.2.4","description":"A simplified Discord.js library for beginners.","directories":{},"_nodeVersion":"20.11.0","dependencies":{"discord.js":"^14.16.2"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/simple-discord.js_0.0.3-beta_1733085646196_0.39572308444930515","host":"s3://npm-registry-packages"}},"0.0.4-beta":{"name":"@amtixdev/simple-discord.js","version":"0.0.4-beta","keywords":["discord","bot","simplified","library"],"author":{"name":"AmtiXDev"},"license":"MIT","_id":"@amtixdev/simple-discord.js@0.0.4-beta","maintainers":[{"name":"amtixdev","email":"amtixdev@gmail.com"}],"homepage":"https://github.com/Simple-Discord-js/Simple-Discord.js#readme","bugs":{"url":"https://github.com/Simple-Discord-js/Simple-Discord.js/issues"},"dist":{"shasum":"8221a603cc074c29208c8dfbd400c2a89d9e5c4b","tarball":"https://registry.npmjs.org/@amtixdev/simple-discord.js/-/simple-discord.js-0.0.4-beta.tgz","fileCount":3,"integrity":"sha512-Uyhw++q/mw7PWJ4QbghTHCegiwjh2Km0CbiR7W8OTTdbYlMVcQg93bKc+r/OK72MBQJuTQSV6wMLXunsmVJDNA==","signatures":[{"sig":"MEUCIQC/1gXuUJXlIucCUSgWiC7TTue37hq09LiOHngBspVvAQIgTLA8HFEkCpHKms7S17F2UmHuiWB3u9loaJJDsR/TKL4=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":7888},"main":"sdjs-main.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"amtixdev","email":"amtixdev@gmail.com"},"repository":{"url":"git+https://github.com/Simple-Discord-js/Simple-Discord.js.git","type":"git"},"_npmVersion":"10.2.4","description":"A simplified Discord.js library for beginners.","directories":{},"_nodeVersion":"20.11.0","dependencies":{"discord.js":"^14.16.2"},"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/simple-discord.js_0.0.4-beta_1733086118665_0.5960120532613824","host":"s3://npm-registry-packages"}},"0.0.5-beta":{"name":"@amtixdev/simple-discord.js","version":"0.0.5-beta","description":"A simplified Discord.js library for beginners.","main":"src/sdjs-main.js","types":"types/index.d.ts","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"keywords":["discord","bot","simplified","library"],"author":{"name":"AmtiXDev"},"license":"MIT","dependencies":{"discord.js":"^14.16.2"},"repository":{"type":"git","url":"git+https://github.com/Simple-Discord-js/Simple-Discord.js.git"},"bugs":{"url":"https://github.com/Simple-Discord-js/Simple-Discord.js/issues"},"homepage":"https://github.com/Simple-Discord-js/Simple-Discord.js#readme","devDependencies":{"typescript":"^5.0.0"},"_id":"@amtixdev/simple-discord.js@0.0.5-beta","_nodeVersion":"20.11.0","_npmVersion":"10.2.4","dist":{"integrity":"sha512-GERYmQCvcx+rp4k/ahICRgA3Igc0fA0/HZk2UM13tAapA/WkAw02RyEhdTgQrqj19oZxesYmC0IcQXg00Sq0Xg==","shasum":"d863832c9693999737573db0aa2d5918d9c97191","tarball":"https://registry.npmjs.org/@amtixdev/simple-discord.js/-/simple-discord.js-0.0.5-beta.tgz","fileCount":4,"unpackedSize":9055,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIB7b+PcFTzDuVO3/P37nWt1dfrh47+ZXxGcv8m8epNiCAiEA6/lUFne0ZMwqMHtOAdzGhriZcjcSsnTymQ7nkhzeftE="}]},"_npmUser":{"name":"amtixdev","email":"amtixdev@gmail.com"},"directories":{},"maintainers":[{"name":"amtixdev","email":"amtixdev@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/simple-discord.js_0.0.5-beta_1733087770567_0.49989329349641287"},"_hasShrinkwrap":false}},"time":{"created":"2024-09-23T22:34:21.993Z","modified":"2024-12-01T21:16:10.892Z","1.0.0":"2024-09-23T22:34:22.268Z","0.0.2-beta":"2024-11-29T17:57:40.614Z","0.0.3-beta":"2024-12-01T20:40:46.409Z","0.0.4-beta":"2024-12-01T20:48:38.845Z","0.0.5-beta":"2024-12-01T21:16:10.736Z"},"bugs":{"url":"https://github.com/Simple-Discord-js/Simple-Discord.js/issues"},"author":{"name":"AmtiXDev"},"license":"MIT","homepage":"https://github.com/Simple-Discord-js/Simple-Discord.js#readme","keywords":["discord","bot","simplified","library"],"repository":{"type":"git","url":"git+https://github.com/Simple-Discord-js/Simple-Discord.js.git"},"description":"A simplified Discord.js library for beginners.","maintainers":[{"name":"amtixdev","email":"amtixdev@gmail.com"}],"readme":"# Simple Discord.js\r\n\r\nA simplified Discord.js library designed for beginners, making it easier to create Discord bots.\r\n\r\n## Table of Contents\r\n\r\n- [Installation](#installation)\r\n- [Usage](#usage)\r\n- [Creating Your Bot](#creating-your-bot)\r\n- [Prefix Commands](#prefix-commands)\r\n- [Slash Commands](#slash-commands)\r\n- [Events](#events)\r\n- [License](#license)\r\n\r\n## Installation\r\n\r\nTo install the Simple Discord.js library, run the following command in your terminal:\r\n\r\n```bash\r\nnpm install @amtixdev/simple-discord.js\r\n```\r\n\r\n## Usage\r\n\r\n### Importing the Library\r\n\r\nYou can import the `SimpleBot` class from the package like this:\r\n\r\n```javascript\r\nconst SimpleBot = require('@amtixdev/simple-discord.js');\r\nconst { GatewayIntentBits } = require('discord.js');\r\n```\r\n\r\n### Creating Your Bot\r\n\r\n1.  **Set Up Your Project**\r\n    \r\n    Create a new directory for your project and initialize it:\r\n    \r\n    ```bash\r\n    mkdir my-discord-bot\r\n    cd my-discord-bot\r\n    npm init -y\r\n    ```\r\n    \r\n2.  **Install Dependencies**\r\n    \r\n    Install the Simple Discord.js library and Discord.js:\r\n    \r\n    ```bash\r\n    npm install @amtixdev/simple-discord.js discord.js\r\n    ```\r\n    \r\n3.  **Create Your Bot Script**\r\n    \r\n    Create a file named `bot.js` and add the following code:\r\n    \r\n    ```javascript\r\n    // bot.js\r\n    const SimpleBot = require('@amtixdev/simple-discord.js');\r\n    const { GatewayIntentBits } = require('discord.js');\r\n    \r\n    // Define the intents your bot needs\r\n    const intents = [\r\n      GatewayIntentBits.Guilds,\r\n      GatewayIntentBits.GuildMessages,\r\n      GatewayIntentBits.MessageContent,\r\n    ];\r\n    \r\n    // Create a new bot instance\r\n    const bot = new SimpleBot('YOUR_DISCORD_BOT_TOKEN_HERE', intents);\r\n    \r\n    // Register a prefix-based command\r\n    bot.command('!ping', (msg) => {\r\n      msg.reply('Pong!');\r\n    });\r\n    \r\n    // Register a slash command\r\n    bot.slashCommand(\r\n      {\r\n        name: 'ping',\r\n        description: 'Replies with Pong!',\r\n      },\r\n      async (interaction) => {\r\n        await interaction.reply('Pong!');\r\n      }\r\n    );\r\n    \r\n    // Define a custom action for the messageCreate event\r\n    bot.on('messageCreate', (msg) => {\r\n      console.log(`Message received: ${msg.content}`);\r\n    });\r\n    \r\n    // Start the bot\r\n    bot.start();\r\n    \r\n    ```\r\n    \r\n4.  **Replace Your Bot Token**\r\n    \r\n    Replace `'YOUR_DISCORD_BOT_TOKEN_HERE'` with your actual bot token, which you can get from the [Discord Developer Portal](https://discord.com/developers/applications).\r\n    \r\n5.  **Run Your Bot**\r\n    \r\n    Save your `bot.js` file and run the bot using:\r\n    \r\n    ```bash\r\n    node bot.js\r\n    ```\r\n    \r\n    Your bot should now be online and responding to both prefix and slash commands!\r\n    \r\n\r\n## Prefix Commands\r\n\r\nYou can register prefix-based commands using the `command` method. The first argument is the command name, and the second is the callback function that will be executed when the command is called.\r\n\r\n### Example\r\n\r\n```javascript\r\nbot.command('!hello', (msg) => {\r\n  msg.reply('Hello there!');\r\n});\r\n```\r\n\r\n## Slash Commands\r\n\r\nYou can register slash commands using the `slashCommand` method. The first argument is an object defining the slash command data, and the second is the callback function that will be executed when the command is invoked.\r\n\r\n### Example\r\n\r\n```javascript\r\nbot.slashCommand(\r\n  {\r\n    name: 'greet',\r\n    description: 'Sends a greeting message',\r\n  },\r\n  async (interaction) => {\r\n    await interaction.reply('Greetings!');\r\n  }\r\n);\r\n```\r\n\r\nThe library automatically registers slash commands with Discord when the bot starts.\r\n\r\n## Events\r\n\r\nYou can listen for various events using the `on` method. The first argument is the event name, and the second is the callback function.\r\n\r\n### Example Events\r\n\r\n-   **messageCreate**: Triggered when a new message is created.\r\n\r\n```javascript\r\nbot.on('messageCreate', (msg) => {\r\n  console.log(`Message received: ${msg.content}`);\r\n});\r\n```\r\n\r\n-   **interactionCreate**: Triggered when an interaction (e.g., a slash command) is created.\r\n\r\n```javascript\r\nbot.on('interactionCreate', (interaction) => {\r\n  console.log(`Interaction received: ${interaction.commandName}`);\r\n});\r\n```\r\n\r\n-   **guildMemberAdd**: Triggered when a new member joins the guild.\r\n\r\n```javascript\r\nbot.on('guildMemberAdd', (member) => {\r\n  console.log(`New member joined: ${member.user.tag}`);\r\n});\r\n```\r\n\r\n## License\r\n\r\nThis project is licensed under the MIT License. See the [LICENSE](https://chatgpt.com/c/LICENSE) file for details.\r\n\r\nMaintained by [AmtiXDev](https://github.com/lifeisunusefull). For any questions or suggestions, feel free to open an issue or reach out.\r\n\r\n[![Discord Banner](https://api.weblutions.com/discord/invite/FqceHDU8QP/)](https://discord.gg/FqceHDU8QP)\r\n\r\n[![Discord Banner](https://api.weblutions.com/discord/invite/xEnX3Kbmsm/)](https://discord.gg/xEnX3Kbmsm)","readmeFilename":"README.md"}