mpticket
Version:
A V13 TICKET SYSTEM
97 lines (78 loc) • 2.45 kB
Markdown
<div align="center">
<br />
<p>
<a href="https://www.npmjs.com/package/mpticket"><img src="https://cdn.discordapp.com/attachments/942399915483619349/942805418068045894/MPTICKET_2.png" width="546" alt="mpticket" /></a>
</p>
<br />
</div>
If you restart your bot, the system will be reset
MPTICKET is a powerful [Discord.js](https://www.npmjs.com/package/discord.js) module !
With this module you will be able to make a ticket system by mp easily.
- Ticket System
- Eeasily
- Performant
- Free
```sh-session
npm install mpticket@latest
yarn add mpticket
pnpm add mpticket
```
Install all required dependencies:
```sh-session
npm install mpticket@latest
yarn add mpticket
pnpm add mpticket
```
**REQUIRED:**
```js
const { onPanel, onMessage } = require('mpticket');
// MODULE
const client = new Client({
intents: ["DIRECT_MESSAGES"], partials: ["CHANNEL"]
}); // THE MODULE NEED THIS
```
Afterwards we can create a quite simple example command:
```js
const { onPanel, onMessage } = require('mpticket');
// MODULE
const client = new Client({
intents: ["DIRECT_MESSAGES"], partials: ["CHANNEL"]
}); // THE MODULE NEED THIS
onPanel({
// OPTIONS
prefix: "!",
guildid: "guildid",
categoryid: "categoryid",
// EMBEB
EmbebColor: "RANDOM",
// Close
CloseMsg: "❌ – Support has marked your query as classified, thanks to you no need to reply after this message",
// Send
SAMTitle: "It’s done! Sent by",
SAMDesc: "I sent",
SMTitle: "Response From",
// Error
ErrTicket: "❌ – Error this channel is not a ticket",
// Create
CTMTitle: "✔️ - Ticket created",
CTMDesc: "Support will contact you as soon as possible.",
})
// CHECK MESSAGE
client.on('messageCreate', (message) => onMessage(message, client));
```
To execute a command add the prefix you defined in the panel function before the command name
```diff
- close
```
Allows you to close the ticket (Perform in the ticket lounge)
```diff
- send
```
Allows you to reply to the ticket (Perform in the ticket lounge)
## Help
If you don't understand something, you are experiencing problems, or you just need a gentle
nudge in the right direction, please don't hesitate to join our official [Support Server](https://discord.gg/x7bFpHjW2n).