onTicketOpen
An event that emits when someone creates a ticket! It will emit with all modes: button
, dropdown
or /ticket
!
Parameters
Parameter | Type | Notes |
---|---|---|
user | discord.User | The user that created the ticket |
channel | discord.TextChannel | The ticket channel |
guild | discord.Guild | The ticket server/guild |
date | Date | The date of ticket creation |
ticketdata | Ticket Data (status, option, claim data, ...) |
Example
example.plugin.js
//log to console when someone creates a ticket!
events.onTicketOpen((user,channel,guild,date,ticketdata) => {
console.log("hello, "+user.username+" opened a ticket!")
})