npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

ogskies_discord_ticket

v0.0.5

Published

Create tickets using discord.js without any effort using our module!

Downloads

4

Readme

Info

Create tickets using Our Module ogskies_discord_ticket in discord.js without any effort!!

Useful Links

Contacts


||========> contact me Block Bytes#7245 on discord <========||


How to use our module

npm i ogskies_discord_ticket

// Importing Modules
const Discord = require('discord.js')
const client = new Discord.Client()
const { OGSkiesTicket } = require('ogskies_discord_ticket')
const ticket = new OGSkiesTicket()

// When bot is ready
client.on('ready', () => {
    console.log(`${client.user.tag} is now online!`)
    console.log("Bot: Hosting " +
      `${client.users.cache.size}` +
      " users, in " +
      `${client.channels.cache.size}` +
      " channels of " +
      `${client.guilds.cache.size}` +
      " guilds."
  );)
  // Example: Bot: Hosting 1053 users, in 265 channels of 10 guilds.
})


client.on('message', async message => {
    let prefix = "+";
    const args = message.content.slice(prefix.length).split(" ");
    const command = args.shift().toLowerCase();
    if ( command == 'ticket' ) {
        const reason = args.join(" ") ? args.join(" ") : "No Reason Provoided"
        ticket.makeTicket(message, reason)
        /*
         Creates a new ticket
         if no reason is provoided the reason is "No Reason Provoided"
         Reason is optional and not needed to create a channel
         if you want the message author to be dmed that he created a
         ticket pls use >>> ticket.makeTicket(message, args.join(" "), true)
         for default its set for false
        */
    } else if ( command == 'close' ) {
        ticket.closeTicket(message)
    } else if ( command == 'role' ) {
        ticket.setRole(message)
        // Seting a support role
        // Support roles gets pinged whenever a ticket is maded
    } else if ( command == 'remove-role' ) {
        ticket.DelRole(message, client)
        // Remove a support role
    } else if ( command == 'send' ) {
        ticket.msgTicketChannel(message, prefix)
        // send a message to a ticket
    } else if ( command == 'category' ) {
        ticket.Category(message, client, args.join(" "))
        // creates a ticket at the selected Category
    } else if ( command == 'delcategory' ) {
        ticket.DelCategory(message, client)
        // Deleated the selected category from the list of creating 
        // tickets, next time tickets will not be created at that category
    } else if ( command == 'embed-message' ) {
        ticket.editEmbed(message, args.join(" "))
        // Set's a message when user creates a ticket
    } else if ( command == 'remove-embed' ) {
        ticket.DelEmbed(message, client)
        // Removes the embed message that are used in every ticket getting 
        // created
    } else if ( command == `adduser` ) {
        ticket.ticketAddUser(message);
        // Add's a user to a ticket
    } else if ( command === `id` ) {
        ticket.fetchChanID(message, args.join(" "))
        // gets a channel id
    }
})
client.login('TOKEN')

Make sure to try this code above if you didnt understand a part or dont know how to use a specific command 👍