Receive chat whispers via mIRC

Hello,
Ive browsed quite a bit to find out how to receive whispers via my bot to no avail. Either the information is outdated, or since im self taught I get lost reading Klingon.

I have a currency system that I run in several channels and it works great. Some of the streamers however, now that they have grown quite large, are having me reduce what they consider spam, typically in initializing a command or receiving the response.

I have successfully been able to whisper a user their currency via PRIVMSG which is easy and awesome now that the chat servers have been moved, but I have not been able to figure out how to receive a whisper.

My goal is that a user can whisper the bot, and the bot reply via whisper the currency.

Currently i have the user enter in standard chat a command, and then the bot whispers, but with 250+ users, once the first person initiates the currency command, its followed by 10+ other users initiating the same command, which has become annoying for the streamer.

Any help would be much appreciated, and keep in mind, im not fluent in Klingon!

I have attempted using
/CAP REQ :twitch.tv/tags
/CAP REQ :twitch.tv/commands
to no avail.

An example for an incoming whisper is this:

@badges=;color=#D2691E;display-name=FreddyOriginal;emotes=;message-id=27;thread-id=37468248_47772503;turbo=0;user-id=37468248;user-type= :freddyoriginal!freddyoriginal@freddyoriginal.tmi.twitch.tv WHISPER freddybot :test

So the format is like

[tags] :[sender]![sender]@[sender].tmi.twitch.tv WHISPER [recipient] :[message]

You just have to handle it accordingly

1 Like

If i was receiving that i could then determine how to handle it, but i get nothing whatsoever. I am not connected to the group chat because it seems to me it was moved to the regular server, as i can SEND whispers from it, is the RECIEVE on a different server by chance? Possibly there is a setting within mIRC that is blocking the whisper from showing in the status window? Is it even supposed to come through the status window, or possibly directly from #jtv like hosts do? No clue what im doing wrong here.

Itā€™s better to post your relevant listening code, as more often than not thereā€™s somebody here who has written a bot in the language youā€™re using and can help troubleshoot the exact issue location. There was a mirc script floating around to parse twitch chat messages + whispers a while ago, not sure where it went, but itā€™s probably available via search.

listening code? i have none, because i have not received anything i have no clue on how to handle the incoming message, i planned to explore that once i receive a whisper.

language = msl

output code =
/raw PRIVMSG #jtv :/w XuserX XmessageX
produces in the status window
[05/26 16:05] -> Server: PRIVMSG #jtv :/w almightysoul this is a test
recieved via twitch website whisper to almightysoul ā€œthis is a testā€

server connection =
irc.chat.twitch.tv
port 6667

current caps =
/CAP REQ :twitch.tv/membership
/CAP REQ :twitch.tv/tags
/CAP REQ :twitch.tv/commands

Send messages to lower case channel names. Instead of XuserX try xuserx

i assumed it would be apparent that that is what im doing, sending is working fine, receiving is what im trying to accomplish

/raw PRIVMSG #jtv :/w almightysoul this is a test
produces in the status window
[05/26 16:05] -> Server: PRIVMSG #jtv :/w almightysoul this is a test
recieved via twitch website whisper to almightysoul ā€œthis is a testā€

Try this, itā€™s the second result of searching ā€˜mircā€™ in the forum search.

this particular discussion is how to capture a message that is sent (received) by the console. I am not getting anything in the console. This is what i am trying to accomplish. If i can receive the code specified

<- @color=#FF4500;display-name=arcRox;emotes=;subscriber=0;turbo=0;user-type=mod;user_type=mod :arcrox!arcrox@arcrox.tmi.twitch.tv PRIVMSG #nutribot :123test

i can then capture and work with it.

but, and i repeat, I am only able to send ( -> ) not receive as shown in this post ( <- )

Iā€™ll ask the silly question, you donā€™t have whispers blocked from accounts you donā€™t follow? I know, silly question, but asking anyway :slight_smile:

thank you for asking, no i do not, was an interesting question, as i had set up the bot account and never checked the default, but no, i have nothing blocked. I spoke with a dev friend of mine, whom i wish had more time for personal ventures and he referenced a ā€œraw loggerā€. could this be what was previously mentioned as ā€œlistening codeā€? would this potentially make a difference? all the references ive seen mention a whisper coming right through to the status window, with no mention of a logger.

Typing ā€œ/debug @rawā€ into mIRC will open a new window called @raw that will show you all the incoming server messages including whispers.

I havenā€™t done anything with whispers yet myself, as my bot hasnā€™t needed it, but I did some research on this a few months ago, and at the time, I believe there was a different cluster of servers for whispers than from normal chat (I think the ā€œgroupā€ chat servers?).

But I think this all changed since the switch to AWS. Can anyone else on this thread confirm/deny?

If thatā€™s not it, I also have a link to this thread for whitelisting a bot account for whispers, to avoid being spam filtered. The thread ends with a link to a form for submitting accounts.

Good luck!

I can confirm group chat is now part of AWS, so thereā€™s no need for a separate connection just to get whispers or group chat to work

Have you done it like this? /raw CAP REQ :twitch.tv/tags twitch.tv/commands

Hooray! i was able to receive an incoming whisper!! Thank you for your post!! Now to determine what to do and how to handle it!!

My suggestion would be to use the recently implemented ON PARSELINE event to work with the raw data. You can type ā€œ/help on parselineā€ into mIRC to get more information on it. Good luck! :slight_smile:

1 Like

@Almightysoul Please explain how you were able to accomplish listening to whispers. I am able to send them but have no idea how to recieve them even what is said above is a little confusing to me. I am trying to recieve whispers using PircBot.

Sorry, i failed to report once my problem was solved. Thanks to this forum, heres the process.
i have the following cap requests enabled
/CAP REQ :twitch.tv/membership
/CAP REQ :twitch.tv/tags
/CAP REQ :twitch.tv/commands

then, this command opens a new debug window that the whispers will come through on.

/debug @raw

i have yet to try to analyze the information that comes through in this window.

As a side-note, you can combine all the CAP REQ commands into one: CAP REQ :twitch.tv/membership twitch.tv/tags twitch.tv/commands

1 Like