Closed dappgbut closed 9 months ago
Will investigate and try to check whats going on.
I'll keep you updated
Okay, Thank you. I'll be looking foward to this issue.
Hello, after investigation, it seems like they have (again) silently changed how their endpoints work
It was previously ids_to_delete
, now it is uuids_to_delete
I'll keep you updated and try to push a fix soon.
Hello, I've pushed the following commit: https://github.com/realcoloride/node_characterai/commit/1a9c1a467110fe37ebff9d9c7726e9c0ea9e4e84
Which introduces fixes for deleting messages, rewrote the message bulk deleting to be more accurate & added uuids. Note: you now need to use message uuids instead of ids to delete specific messages.
Could you try it and tell me how it goes?
Hello, Sorry for the late response...
Thank you for the fixes!.. i'll try it soon in about a few hours when I got into my computer, and give you how it will goes...
Hello! Let me know. Make sure to clone the repo and replace it in the node_modules folder.
Hello, thank you for waiting...
I tried to do it outside of my chatbot code and separate the code into this:
const sessiontokenygy = "session token";
(async () => {
await characterai.authenticateWithToken(sessiontokenygy);
const characterId = "CharacterId";
const chat = await characterai.createOrContinueChat(characterId);
console.log("start deleting");
await chat.deleteMessagesBulk(2,false,false);
console.log("delete success");
})();
The console.log
returns two of them, but when i check on the character ai website, the messages didn't get deleted...
start deleting
delete success
Any suggestions for this?...
are you looking at the old or new interface? (chat/chat2, see url)
After a bit of research, the website version does all the message deleted... I've been using the mobile version all the time to check it by the way... where it's kinda buggy...
Sorry my bad... but i'm glad it's working now...
Thank you for your patience in dealing with this issue!! 😀
No problem. Again the fact you've seen new changes is because its on the new ui, synced to the mobile one, using websockets.
Hello there, i tried to delete a messages using
chat.deleteMessagesBulk()
but somehow it returns with no errors and on the website itself, the messages didn't get deletedHere is my code like (I recently making a chatbot using this package):
Maybe are there something wrong on my code? or it's from the package-side (I saw some old issue about
DeleteMessage
, Like issue #14) ?Any answers are appreciated, thank you.