Files
Nexumi/apps/bot/src/modules/tempvoice/command-definitions.ts
smueller a583db7a15 Add giveaway, ticket, self-role, starboard, and suggestion features to the bot
- Introduced new models in the Prisma schema for giveaways, tickets, self-role panels, starboard configurations, and suggestions, enhancing the bot's functionality.
- Implemented job handling for self-role expiration and ticket management, improving user experience.
- Updated command localization to support new features in both German and English.
- Enhanced the job processing system to include dedicated workers for managing tickets and self-role expirations.
- Documented the new features and their setup processes in PHASE-TRACKING.md for clarity on implementation steps.
2026-07-22 13:08:37 +02:00

65 lines
2.7 KiB
TypeScript

import { ChannelType } from 'discord.js';
import { applyCommandDescription, applyOptionDescription } from '@nexumi/shared';
import { SlashCommandBuilder } from 'discord.js';
export const voiceCommandData = applyCommandDescription(
new SlashCommandBuilder()
.setName('voice')
.addSubcommand((s) =>
applyCommandDescription(s.setName('setup'), 'tempvoice.setup.description')
.addChannelOption((o) =>
applyOptionDescription(
o.setName('hub_channel').addChannelTypes(ChannelType.GuildVoice).setRequired(true),
'tempvoice.setup.options.hub_channel'
)
)
.addChannelOption((o) =>
applyOptionDescription(
o.setName('category').addChannelTypes(ChannelType.GuildCategory).setRequired(true),
'tempvoice.setup.options.category'
)
)
.addStringOption((o) =>
applyOptionDescription(o.setName('default_name'), 'tempvoice.setup.options.default_name')
)
.addIntegerOption((o) =>
applyOptionDescription(
o.setName('limit').setMinValue(0).setMaxValue(99),
'tempvoice.setup.options.limit'
)
)
)
.addSubcommand((s) =>
applyCommandDescription(s.setName('rename'), 'tempvoice.rename.description')
.addStringOption((o) =>
applyOptionDescription(o.setName('name').setRequired(true), 'tempvoice.rename.options.name')
)
)
.addSubcommand((s) =>
applyCommandDescription(s.setName('limit'), 'tempvoice.limit.description')
.addIntegerOption((o) =>
applyOptionDescription(
o.setName('limit').setRequired(true).setMinValue(0).setMaxValue(99),
'tempvoice.limit.options.limit'
)
)
)
.addSubcommand((s) => applyCommandDescription(s.setName('lock'), 'tempvoice.lock.description'))
.addSubcommand((s) => applyCommandDescription(s.setName('hide'), 'tempvoice.hide.description'))
.addSubcommand((s) =>
applyCommandDescription(s.setName('kick'), 'tempvoice.kick.description')
.addUserOption((o) =>
applyOptionDescription(o.setName('user').setRequired(true), 'tempvoice.kick.options.user')
)
)
.addSubcommand((s) =>
applyCommandDescription(s.setName('transfer'), 'tempvoice.transfer.description')
.addUserOption((o) =>
applyOptionDescription(o.setName('user').setRequired(true), 'tempvoice.transfer.options.user')
)
)
.addSubcommand((s) => applyCommandDescription(s.setName('claim'), 'tempvoice.claim.description'))
.addSubcommand((s) => applyCommandDescription(s.setName('panel'), 'tempvoice.panel.description')),
'tempvoice.description'
);