Sinch Node.js SDK - v1.6.0
    Preparing search index...

    Interface MessagesCommand

    Plays one or more messages on the call. Multiple messages in the array are played sequentially in order. This is a non-blocking command — the next command in the sequence executes immediately while messages play in parallel. Playback outcomes are handled via the events property. The onFinish event can be used to run a command after all messages complete.

    interface MessagesCommand {
        command: "messages";
        events?: MessageEvents;
        messages: Message[];
        messagesName?: string;
    }
    Index

    Properties

    command: "messages"

    Command to play a message on the channel

    events?: MessageEvents

    MessageEvents

    messages: Message[]

    Ordered list of messages to play.

    messagesName?: string

    Name of the message for identification and reference within the call session. This name is used to uniquely identify the message and must be unique within the current call session. This name can be referenced in other commands (e.g., stopMessages) to control this specific message.