ClientEdit - ResponseError: invalid parameter
JDittmerCOM opened this issue · comments
Justin Dittmer commented
Hi, when I try to change the client nickname, I keep getting the following error message.
node:internal/process/promises:246
triggerUncaughtException(err, true /* fromPromise */);
^
ResponseError: invalid parameter
at new Command (/home/Justin/MissionVBots/ts3Bot/node_modules/ts3-nodejs-library/lib/transport/Command.js:15:22)
at /home/Justin/MissionVBots/ts3Bot/node_modules/ts3-nodejs-library/lib/transport/TeamSpeakQuery.js:79:25
at new Promise (<anonymous>)
at TeamSpeakQuery.handleCommand (/home/Justin/MissionVBots/ts3Bot/node_modules/ts3-nodejs-library/lib/transport/TeamSpeakQuery.js:78:16)
at TeamSpeakQuery.execute (/home/Justin/MissionVBots/ts3Bot/node_modules/ts3-nodejs-library/lib/transport/TeamSpeakQuery.js:66:21)
at TeamSpeak.execute (/home/Justin/MissionVBots/ts3Bot/node_modules/ts3-nodejs-library/lib/TeamSpeak.js:391:31)
at TeamSpeak.clientEdit (/home/Justin/MissionVBots/ts3Bot/node_modules/ts3-nodejs-library/lib/TeamSpeak.js:1619:21)
at /home/Justin/MissionVBots/ts3Bot/index.js:257:13
at processTicksAndRejections (node:internal/process/task_queues:96:5) {
id: '1538',
msg: 'invalid parameter',
extraMsg: undefined,
failedPermid: undefined
}
However, I have no idea what could be the reason, since all the parameters are actually there, aren't they?
app.put('/client/editname', (req, res) => {
var identifier = req.body.identifier;
var name = req.body.name;
teamspeak.clientGetIds(identifier).then(clientInfo => {
teamspeak.clientEdit(clientInfo[0].clid, {'client_nickname': name});
res.json();
}).catch(error => res.json({ error: "Identifier falsch oder Client nicht Online" }))
});
Chiko commented
You are not suppose to change the Client's Nickname.
Please check the Interfaces for Teamspeak.clientEdit():
Justin Dittmer commented
So I can really only use the two properties?
I was of the opinion that I read that I could also change the nickname.
But well, ok, then I know. Thanks.
clientDescription?: string
clientIsTalker?: boolean