TwitchReplyToMessage

Send a reply to a specific Twitch chat message

Signature

public void TwitchReplyToMessage(string message, string replyId, bool useBot = true, bool fallback = true)

Parameters

message
string required

Enter the message contents

replyId
string required

Enter the unique ID of the message to reply to

useBot
bool
Default:
True
  • true - Send the reply using your Twitch Bot account
  • false - Send the reply using your Twitch Broadcaster account
fallback
bool
Default:
True
  • true - (If bot bool is set to True), this is the same behaviour as if you had Bot as your preferred account.
  • false - (If bot bool is set to True), it will try to send using only the Bot account, and do nothing if it can't (i.e, not logged in).

Return Type

void

Example

using System;
public class CPHInline
{
    public bool Execute()
    {
        //Get message id to reply to
        CPH.TryGetArg("msgId",out string messageId);

        //Set message for reply
        string message = "This is a test reply.";

        //Send reply with bot account
        CPH.TwitchReplyToMessage(message, messageId, true, true); 
        return true;
    }
}