Why is this not working pleas help me,
// commands/transcript.js
const { SlashCommandBuilder, AttachmentBuilder, EmbedBuilder,ApplicationIntegrationType,InteractionContextType } = require('discord.js');
const { loadResponses } = require('../utils/dataHandler');
const { logToChannel } = require('../utils/logger');
const { createTranscript } = require('discord-html-transcripts');
module.exports = {
data: new SlashCommandBuilder()
.setName('transcript')
.setDescription('Generate a transcript of the last 1,000 messages in this channel.')
.setIntegrationTypes(ApplicationIntegrationType.UserInstall, ApplicationIntegrationType.GuildInstall)
.setContexts(InteractionContextType.Guild, InteractionContextType.PrivateChannel),
5 Replies
- What's your exact discord.js
npm list discord.js
and node node -v
version?
- Not a discord.js issue? Check out #other-js-ts.
- Consider reading #how-to-get-help to improve your question!
- Explain what exactly your issue is.
- Post the full error stack trace, not just the top part!
- Show your code!
- Issue solved? Press the button!├─┬ [email protected]
│ └── [email protected] deduped
└── [email protected]
node version : v20.11.1
it aint making commands in the dms
Your
setContexts
doesn't have BotDM
, so it won't show in bot's dm
Also I am not sure why this command is available to User installs and private channels, bot's can only fetch messages of channels they have access to.cant it like make
transcript of the dm ?
Bot's DM, yeah. Not private channels (i. e other's dm, group dm). User Apps do not get access to channel messages except those that are provided with the interaction (i.e, in case of Message context menu command);