Osman
Osman
DIAdiscord.js - Imagine an app
Created by Osman on 9/6/2023 in #djs-questions
embeds[0].description[BASE_TYPE_REQUIRED]: This field is required V14
embeds[0].description[BASE_TYPE_REQUIRED]: This field is required
at handleErrors (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\@discordjs\rest\dist\index.js:687:13)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async SequentialHandler.runRequest (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\@discordjs\rest\dist\index.js:1072:23)
at async SequentialHandler.queueRequest (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\@discordjs\rest\dist\index.js:913:14)
at async _REST.request (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\@discordjs\rest\dist\index.js:1218:22)
at async TextChannel.send (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\discord.js\src\structures\interfaces\TextBasedChannel.js:162:15)
at async Object.callback (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\src\commands\moderation\ban.js:111:15)
at async module.exports (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\src\events\interactionCreate\handleCommands.js:62:5)
at async Client.<anonymous> (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\src\handlers\eventHandler.js:16:9) {
requestBody: {
files: [],
json: {
content: undefined,
tts: false,
nonce: undefined,
embeds: [Array],
components: undefined,
username: undefined,
avatar_url: undefined,
allowed_mentions: undefined,
flags: undefined,
message_reference: undefined,
attachments: undefined,
sticker_ids: undefined,
thread_name: undefined
}
},
rawError: {
message: 'Invalid Form Body',
code: 50035,
errors: { embeds: [Object] }
},
code: 50035,
status: 400,
method: 'POST',
url: 'https://discord.com/api/v10/channels/1147844987371913286/messages'
}
embeds[0].description[BASE_TYPE_REQUIRED]: This field is required
at handleErrors (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\@discordjs\rest\dist\index.js:687:13)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async SequentialHandler.runRequest (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\@discordjs\rest\dist\index.js:1072:23)
at async SequentialHandler.queueRequest (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\@discordjs\rest\dist\index.js:913:14)
at async _REST.request (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\@discordjs\rest\dist\index.js:1218:22)
at async TextChannel.send (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\node_modules\discord.js\src\structures\interfaces\TextBasedChannel.js:162:15)
at async Object.callback (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\src\commands\moderation\ban.js:111:15)
at async module.exports (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\src\events\interactionCreate\handleCommands.js:62:5)
at async Client.<anonymous> (C:\Users\Odin\Documents\GitHub\HeeSanDiscordJS\src\handlers\eventHandler.js:16:9) {
requestBody: {
files: [],
json: {
content: undefined,
tts: false,
nonce: undefined,
embeds: [Array],
components: undefined,
username: undefined,
avatar_url: undefined,
allowed_mentions: undefined,
flags: undefined,
message_reference: undefined,
attachments: undefined,
sticker_ids: undefined,
thread_name: undefined
}
},
rawError: {
message: 'Invalid Form Body',
code: 50035,
errors: { embeds: [Object] }
},
code: 50035,
status: 400,
method: 'POST',
url: 'https://discord.com/api/v10/channels/1147844987371913286/messages'
}
8 replies
DIAdiscord.js - Imagine an app
Created by Osman on 9/6/2023 in #djs-questions
embeds[0].description[BASE_TYPE_REQUIRED]: This field is required V14
There was an error when banning: DiscordAPIError[50035]: Invalid Form Body
embeds[0].description[BASE_TYPE_REQUIRED]: This field is required
There was an error when banning: DiscordAPIError[50035]: Invalid Form Body
embeds[0].description[BASE_TYPE_REQUIRED]: This field is required
Is all I get. How can I "improve" my error logging?
8 replies
DIAdiscord.js - Imagine an app
Created by Osman on 9/6/2023 in #djs-questions
embeds[0].description[BASE_TYPE_REQUIRED]: This field is required V14
stack trace?
8 replies
DIAdiscord.js - Imagine an app
Created by Osman on 9/6/2023 in #djs-questions
embeds[0].description[BASE_TYPE_REQUIRED]: This field is required V14
const banEmbed = {
"content": "",
"tts": false,
"embeds": [
{
"title": banCaseCounter + ` | BAN | ${targetUserTag}`,
"description": "User has been banned.",
"color": 2326507,
"fields": [
{
"name": "User",
"value": targetUserTag,
"inline": true
},
{
"name": "Moderator",
"value": interaction.user.tag,
"inline": true
},
{
"name": "Reason",
"value": reason,
"inline": true
}
],
"footer": {
"text": `ID: ${targetUserId}`,
},
"timestamp": new Date()
}
],
"components": [],
"actions": {}
};
const banEmbed = {
"content": "",
"tts": false,
"embeds": [
{
"title": banCaseCounter + ` | BAN | ${targetUserTag}`,
"description": "User has been banned.",
"color": 2326507,
"fields": [
{
"name": "User",
"value": targetUserTag,
"inline": true
},
{
"name": "Moderator",
"value": interaction.user.tag,
"inline": true
},
{
"name": "Reason",
"value": reason,
"inline": true
}
],
"footer": {
"text": `ID: ${targetUserId}`,
},
"timestamp": new Date()
}
],
"components": [],
"actions": {}
};
8 replies
DIAdiscord.js - Imagine an app
Created by Osman on 9/6/2023 in #djs-questions
embeds[0].description[BASE_TYPE_REQUIRED]: This field is required V14
Full error : There was an error when banning: DiscordAPIError[50035]: Invalid Form Body embeds[0].description[BASE_TYPE_REQUIRED]: This field is required
8 replies