Added all the new config variables for v4.1.0!

This commit is contained in:
DJj123dj
2025-08-05 10:42:15 +02:00
parent adc2433216
commit 549c161830
18 changed files with 455 additions and 86 deletions
+48 -9
View File
@@ -245,8 +245,9 @@ export const defaultGeneralStructure = new api.ODCheckerObjectStructure("opendis
checker:new api.ODCheckerObjectStructure("opendiscord:status",{children:[
{key:"enabled",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:status-enabled",{cliDisplayName:"Enabled",cliDisplayDescription:"Enable/disable the status. When disabled, the bot will be online without any status."})},
{key:"type",optional:false,priority:0,checker:new api.ODCheckerStringStructure("opendiscord:status-type",{choices:["listening","watching","playing","custom"],cliDisplayName:"Type",cliDisplayDescription:"The type of status: Listening, Watching, Playing or Custom."})},
{key:"mode",optional:false,priority:0,checker:new api.ODCheckerStringStructure("opendiscord:status-mode",{choices:["online","invisible","idle","dnd"],cliDisplayName:"Mode",cliDisplayDescription:"The profile status/mode of the bot: Online, Invisible, Idle or Do Not Disturb."})},
{key:"text",optional:false,priority:0,checker:new api.ODCheckerStringStructure("opendiscord:status-text",{minLength:1,maxLength:128,cliDisplayName:"Text",cliDisplayDescription:"The text displayed in the status."})},
{key:"status",optional:false,priority:0,checker:new api.ODCheckerStringStructure("opendiscord:status-status",{choices:["online","invisible","idle","dnd"],cliDisplayName:"Status",cliDisplayDescription:"The profile status of the bot: Online, Invisible, Idle or Do Not Disturb."})},
{key:"state",optional:false,priority:0,checker:new api.ODCheckerStringStructure("opendiscord:status-state",{maxLength:128,cliDisplayName:"State",cliDisplayDescription:"Additional text displayed below the status 'text'."})},
],cliDisplayName:"Bot Status",cliDisplayDescription:"Manage the status of the bot."}),
cliDisplayName:"Bot Status",
cliDisplayDescription:"Manage the status of the bot."
@@ -254,16 +255,29 @@ export const defaultGeneralStructure = new api.ODCheckerObjectStructure("opendis
//SYSTEM
{key:"system",optional:false,priority:0,checker:new api.ODCheckerObjectStructure("opendiscord:system",{children:[
{key:"removeParticipantsOnClose",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:remove-participants-on-close",{cliDisplayName:"Remove Participants On Close",cliDisplayDescription:"When enabled, all participants except admins will be removed from the ticket."})},
{key:"replyOnTicketCreation",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:reply-on-ticket-creation",{cliDisplayName:"Reply On Ticket Creation",cliDisplayDescription:"When enabled, the bot will send an ephemeral reply in the channel of the panel when creating a ticket."})},
{key:"replyOnReactionRole",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:reply-on-reaction-role",{cliDisplayName:"Reply On Reaction Role",cliDisplayDescription:"When enabled, the bot will send an ephemeral reply in the channel of the panel when using a role button."})},
{key:"useTranslatedConfigChecker",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:use-translated-config-checker",{cliDisplayName:"Use Translated Config Checker",cliDisplayDescription:"Use a translated config checker to better understand the errors the bot gives."})},
{key:"preferSlashOverText",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:prefer-slash-over-text",{cliDisplayName:"Prefer Slash Over Text",cliDisplayDescription:"Prefer displaying slash commands over text commands in help menus."})},
{key:"sendErrorOnUnknownCommand",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:send-error-on-unknown-command",{cliDisplayName:"Send Error On Unknown Command",cliDisplayDescription:"Send an error when using the text-command prefix without a valid command."})},
{key:"questionFieldsInCodeBlock",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:question-fields-in-code-block",{cliDisplayName:"Questions Fields In Code Blocks",cliDisplayDescription:"Display question fields in code blocks instead of plain text."})},
{key:"displayFieldsWithQuestions",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:display-fields-with-questions",{cliDisplayName:"Display Fields With Questions",cliDisplayDescription:"Display embed fields together with question fields (in a ticket message)."})},
{key:"showGlobalAdminsInPanelRoles",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:global-admins-in-panel-roles",{cliDisplayName:"Show Global Admins In Panel Roles",cliDisplayDescription:"Show global admins roles together with ticket admins in panel embeds."})},
{key:"disableVerifyBars",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:disable-verify-bars",{cliDisplayName:"Disable Verifybars",cliDisplayDescription:"Disable the (✅/❌) verify buttons in all commands. (Not recommended)"})},
{key:"useRedErrorEmbeds",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:use-red-error-embeds",{cliDisplayName:"Use Red Error Embeds",cliDisplayDescription:"Display all error messages with a red border instead of the default color of the bot."})},
{key:"alwaysShowReason",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:always-show-reason",{cliDisplayName:"Always Show Reason",cliDisplayDescription:"Always show the reason field in embeds, even when there is no reason provided."})},
{key:"emojiStyle",optional:false,priority:0,checker:new api.ODCheckerStringStructure("opendiscord:emoji-style",{choices:["before","after","double","disabled"],cliDisplayName:"Emoji Style",cliDisplayDescription:"Choose how the bot will display emojis in message titles. (Visit docs for more info)"})},
{key:"pinEmoji",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_EmojiString("opendiscord:pin-emoji",1,1,false,{cliDisplayName:"Pin Emoji",cliDisplayDescription:"The emoji used when pinning tickets. This is '📌' by default."})},
{key:"replyOnTicketCreation",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:reply-on-ticket-creation",{cliDisplayName:"Reply On Ticket Creation",cliDisplayDescription:"When enabled, the bot will send an ephemeral reply in the channel of the panel when creating a ticket."})},
{key:"replyOnReactionRole",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:reply-on-reaction-role",{cliDisplayName:"Reply On Reaction Role",cliDisplayDescription:"When enabled, the bot will send an ephemeral reply in the channel of the panel when using a role button."})},
{key:"showPreAutocloseWarning",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:show-pre-autoclose-warning",{cliDisplayName:"Show Pre-Autoclose Warning",cliDisplayDescription:"Show a warning message before the ticket gets autoclosed. This will happen when only 1/4th of the autoclose time remains."})},
{key:"askPriorityOnTicketCreation",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:ask-priority-creation",{cliDisplayName:"Ask Priority On Ticket Creation",cliDisplayDescription:"Ask for the priority of this ticket on ticket creation. This will happen in a dropdown in the ticket message."})},
{key:"removeParticipantsOnClose",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:remove-participants-on-close",{cliDisplayName:"Remove Participants On Close",cliDisplayDescription:"When enabled, all participants except admins will be removed from the ticket."})},
{key:"disableAutocloseAfterReopen",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:disable-autoclose-reopen",{cliDisplayName:"Disable Autoclose On Reopen",cliDisplayDescription:"Disable autoclose for a ticket when it has been closed and re-opened."})},
{key:"autodeleteRequiresClosedTicket",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:autodelete-requires-closed-ticket",{cliDisplayName:"Autodelete Requires Closed Ticket",cliDisplayDescription:"Only allow autodelete when the ticket is already closed."})},
{key:"adminOnlyDeleteWithoutTranscript",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:adminonly-delete-without-transcript",{cliDisplayName:"Admin-only Delete Without Transcript",cliDisplayDescription:"When enabled, only global admins are able to delete a ticket without transcript."})},
{key:"allowCloseBeforeMessage",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:allow-close-before-message",{cliDisplayName:"Allow Close Before Message",cliDisplayDescription:"Only allow ticket closing when at least 1 message has been sent by the creator. (admins are able to bypass)"})},
{key:"allowCloseBeforeAdminMessage",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:allow-close-before-admin-message",{cliDisplayName:"Allow Close Before Admin Message",cliDisplayDescription:"Only allow ticket closing when at least 1 message has been sent by a global or ticket admin. (admins are able to bypass)"})},
{key:"useTranslatedConfigChecker",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:use-translated-config-checker",{cliDisplayName:"Use Translated Config Checker",cliDisplayDescription:"Use a translated config checker to better understand the errors the bot gives."})},
{key:"pinFirstTicketMessage",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:pin-first-ticket-message",{cliDisplayName:"Pin First Ticket Message",cliDisplayDescription:"Pin the (first) ticket message in the channel. This simulates old behaviour like Open Ticket v1, v2 & v3."})},
{key:"enableTicketClaimButtons",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:enable-ticket-claim-buttons",{cliDisplayName:"Enable Ticket Claim Buttons",cliDisplayDescription:"Enable/disable buttons for claiming a ticket. Be aware that this doesn't disable the command!"})},
{key:"enableTicketCloseButtons",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:enable-ticket-close-buttons",{cliDisplayName:"Enable Ticket Close Buttons",cliDisplayDescription:"Enable/disable buttons for closing a ticket. Be aware that this doesn't disable the command!"})},
@@ -283,6 +297,19 @@ export const defaultGeneralStructure = new api.ODCheckerObjectStructure("opendis
{key:"userMaximum",optional:false,priority:0,checker:new api.ODCheckerNumberStructure("opendiscord:limits-user",{zeroAllowed:false,negativeAllowed:false,floatAllowed:false,min:1,cliDisplayName:"User Maximum",cliDisplayDescription:"The maximum amount of tickets from a specific user that are able to exist in the server at the same time."})}
],cliDisplayName:"Global Limits",cliDisplayDescription:"Manage global limits for ticket creation to reduce the workload on your support team."}),cliDisplayName:"Global Limits",cliDisplayDescription:"Manage global limits for ticket creation to reduce the workload on your support team."})},
{key:"channelTopic",optional:false,priority:0,checker:new api.ODCheckerObjectStructure("opendiscord:channel-topic",{children:[
{key:"showOptionName",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:topic-show-option-name",{cliDisplayName:"Show Option Name",cliDisplayDescription:"Show the option name in the channel topic."})},
{key:"showOptionDescription",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:topic-show-option-description",{cliDisplayName:"Show Option Description",cliDisplayDescription:"Show the option description in the channel topic."})},
{key:"showOptionTopic",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:topic-show-option-topic",{cliDisplayName:"Show Option Topic",cliDisplayDescription:"Show the option topic text in the channel topic (configured in the options.json config)."})},
{key:"showClosed",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:topic-show-closed",{cliDisplayName:"Show Closed Status",cliDisplayDescription:"Show the current close/reopen status in the channel topic (auto-updated)."})},
{key:"showClaimed",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:topic-show-claimed",{cliDisplayName:"Show Claimed Status",cliDisplayDescription:"Show the current claim status in the channel topic (auto-updated)."})},
{key:"showPinned",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:topic-show-pinned",{cliDisplayName:"Show Pinned Status",cliDisplayDescription:"Show the current pin status in the channel topic (auto-updated)."})},
{key:"showPriority",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:topic-show-priority",{cliDisplayName:"Show Priority",cliDisplayDescription:"Show the current priority in the channel topic (auto-updated)."})},
{key:"showCreator",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:topic-show-creator",{cliDisplayName:"Show Creator",cliDisplayDescription:"Show the creator of the ticket in the channel topic (auto-updated on transfer)."})},
{key:"showParticipants",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:topic-show-participants",{cliDisplayName:"Show Participants",cliDisplayDescription:"Show the first 5 participants of the ticket in the channel topic (auto-updated)."})},
],cliDisplayName:"Channel Topic",cliDisplayDescription:"Manage stats and text of ticket channel topics."})},
{key:"permissions",optional:false,priority:0,checker:new api.ODCheckerObjectStructure("opendiscord:system-permissions",{children:[
{key:"help",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-help","role",false,["admin","everyone","none"],{cliDisplayName:"Help",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})},
{key:"panel",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-panel","role",false,["admin","everyone","none"],{cliDisplayName:"Panel",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})},
@@ -302,7 +329,10 @@ export const defaultGeneralStructure = new api.ODCheckerObjectStructure("opendis
{key:"stats",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-stats","role",false,["admin","everyone","none"],{cliDisplayName:"Stats",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})},
{key:"clear",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-clear","role",false,["admin","everyone","none"],{cliDisplayName:"Clear Tickets",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})},
{key:"autoclose",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-autoclose","role",false,["admin","everyone","none"],{cliDisplayName:"Autoclose",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})},
{key:"autodelete",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-autodelete","role",false,["admin","everyone","none"],{cliDisplayName:"Autodelete",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})}
{key:"autodelete",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-autodelete","role",false,["admin","everyone","none"],{cliDisplayName:"Autodelete",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})},
{key:"transfer",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-transfer","role",false,["admin","everyone","none"],{cliDisplayName:"Transfer",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})},
{key:"topic",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-topic","role",false,["admin","everyone","none"],{cliDisplayName:"Topic",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})},
{key:"priority",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:permissions-priority","role",false,["admin","everyone","none"],{cliDisplayName:"Priority",cliHideDescriptionInParent:true,cliDisplayDescription:"Set the permissions to 'everyone' for everyone, 'admin' for admin only, 'none' to disable or a custom discord role ID."})},
],cliDisplayName:"Permissions",cliDisplayDescription:"Manage all button & command permissions in the bot. (Visit docs for more info)"})},
{key:"messages",optional:false,priority:0,checker:new api.ODCheckerObjectStructure("opendiscord:system-permissions",{children:[
@@ -317,8 +347,10 @@ export const defaultGeneralStructure = new api.ODCheckerObjectStructure("opendis
{key:"renaming",optional:false,priority:0,checker:createMsgStructure("opendiscord:msg-renaming","Ticket Renamed")},
{key:"moving",optional:false,priority:0,checker:createMsgStructure("opendiscord:msg-moving","Ticket Moved")},
{key:"blacklisting",optional:false,priority:0,checker:createMsgStructure("opendiscord:msg-blacklisting","User Blacklisted")},
{key:"roleAdding",optional:false,priority:0,checker:createMsgStructure("opendiscord:msg-role-adding","Role Added")},
{key:"roleRemoving",optional:false,priority:0,checker:createMsgStructure("opendiscord:msg-role-removing","Role Removed")}
{key:"transferring",optional:false,priority:0,checker:createMsgStructure("opendiscord:msg-transferring","Ticket Transferred")},
{key:"topicChange",optional:false,priority:0,checker:createMsgStructure("opendiscord:msg-topic-change","Topic Changed")},
{key:"priorityChange",optional:false,priority:0,checker:createMsgStructure("opendiscord:msg-priority-change","Priority Changed")},
{key:"reactionRole",optional:false,priority:0,checker:createMsgStructure("opendiscord:msg-reaction-role","Reaction Role")},
],cliDisplayName:"Messages",cliDisplayDescription:"Manage all messages & DM's for each action of the bot. (Visit docs for more info)"})},
],cliDisplayName:"System",cliDisplayDescription:"Configure everything related to the ticket system."})}
],cliDisplayName:"General",cliDisplayDescription:"General settings for the bot."})
@@ -369,7 +401,7 @@ export const defaultOptionsStructure = new api.ODCheckerArrayStructure("opendisc
{key:"user",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:ticket-channel-claimed-user","user",false,[],{cliDisplayName:"User",cliDisplayDescription:"A discord user ID of the ticket claimer."})},
{key:"category",optional:false,priority:0,checker:new api.ODCheckerCustomStructure_DiscordId("opendiscord:ticket-channel-claimed-category","category",false,[],{cliDisplayName:"Category",cliDisplayDescription:"A discord category ID to move the ticket to."})}
],cliDisplayName:"Claimed Category",cliDisplayDescription:"A collection of a user ID and a category ID. The ticket will be moved to the category when this user claims the ticket."}),cliDisplayName:"Claimed Categories",cliDisplayDescription:"Add categories to move the ticket to when a user claims a ticket."})},
{key:"description",optional:false,priority:0,checker:new api.ODCheckerStringStructure("opendiscord:ticket-channel-description",{cliDisplayName:"Channel Description",cliDisplayDescription:"The description of the ticket channel. Visible in the discord client."})},
{key:"topic",optional:false,priority:0,checker:new api.ODCheckerStringStructure("opendiscord:ticket-channel-topic",{cliDisplayName:"Channel Topic",cliDisplayDescription:"The topic text of the ticket channel. Visible in the discord client when general.json 'channelTopic'.'showOptionTopic' is enabled."})},
],cliDisplayName:"Channel",cliDisplayDescription:"Manage all settings related to the ticket channel and categories."})},
//DM MESSAGE
@@ -415,6 +447,13 @@ export const defaultOptionsStructure = new api.ODCheckerArrayStructure("opendisc
{key:"globalMaximum",optional:false,priority:0,checker:new api.ODCheckerNumberStructure("opendiscord:ticket-limits-global",{zeroAllowed:false,negativeAllowed:false,floatAllowed:false,min:1,cliInitDefaultValue:10,cliDisplayName:"Global Maximum",cliDisplayDescription:"The maximum amount of tickets of this type/option that are able to exist in the server at the same time."})},
{key:"userMaximum",optional:false,priority:0,checker:new api.ODCheckerNumberStructure("opendiscord:ticket-limits-user",{zeroAllowed:false,negativeAllowed:false,floatAllowed:false,min:1,cliInitDefaultValue:3,cliDisplayName:"User Maximum",cliDisplayDescription:"The maximum amount of tickets of this type/option from a specific user that are able to exist in the server at the same time."})}
],cliDisplayName:"Option Limits",cliDisplayDescription:"Manage option-based limits for ticket creation to reduce the workload on your support team."}),cliDisplayName:"Limits",cliDisplayDescription:"Manage option-based limits for ticket creation to reduce the workload on your support team."})},
//SLOW MODE
{key:"slowMode",optional:false,priority:0,checker:new api.ODCheckerEnabledObjectStructure("opendiscord:ticket-slowmode",{property:"enabled",enabledValue:true,checker:new api.ODCheckerObjectStructure("opendiscord:ticket-limits",{children:[
{key:"enabled",optional:false,priority:0,checker:new api.ODCheckerBooleanStructure("opendiscord:ticket-slowmode-enabled",{cliDisplayName:"Enabled",cliDisplayDescription:"Enable/disable ticket slow mode."})},
{key:"slowModeSeconds",optional:false,priority:0,checker:new api.ODCheckerNumberStructure("opendiscord:ticket-slowmode-seconds",{zeroAllowed:false,negativeAllowed:false,floatAllowed:false,min:1,cliInitDefaultValue:20,cliDisplayName:"Slow Mode Seconds",cliDisplayDescription:"The amount of seconds users need to wait between sending messages."})},
],cliDisplayName:"Option Slow Mode",cliDisplayDescription:"Add slow mode to this ticket option to restrict the amount of message spam users can send."}),cliDisplayName:"Slow Mode",cliDisplayDescription:"Add slow mode to this ticket option to restrict the amount of message spam users can send."})},
],cliDisplayName:"Ticket Option",cliDisplayDescription:"Manage all ticket-specific settings of this option/type."})},
//WEBSITE