Rooms messages reactions send

Open in

Use the ably rooms messages reactions send command to send a reaction to a message in a chat room.

Synopsis

ably rooms messages reactions send <room-name> <message-serial> <reaction> [options]

Arguments

room-name
Required

The name of the chat room containing the message.

message-serial
Required

The serial identifier of the message to react to.

reaction
Required

The emoji reaction to send.

Options

--type

The type of reaction. Options are unique, distinct, or multiple.

--count

The number of reactions to send. Only applicable when --type is set to multiple.

--client-id

A client ID to use when sending the reaction.

--json

Output results as compact JSON. Mutually exclusive with --pretty-json.

--pretty-json

Output results in formatted JSON. Mutually exclusive with --json.

--verbose | -v

Enable verbose logging. Can be combined with --json or --pretty-json.

Examples

Send a reaction to a message:

ably rooms messages reactions send my-room "msg-serial" "thumbsup"

Send a reaction with a specific type:

ably rooms messages reactions send my-room "msg-serial" "heart" --type unique

Send multiple reactions:

ably rooms messages reactions send my-room "msg-serial" "clap" --type multiple --count 5

Send a reaction using an API key environment variable:

ABLY_API_KEY="YOUR_API_KEY" ably rooms messages reactions send my-room "msg-serial" heart

Send a reaction and output the result in JSON format:

ably rooms messages reactions send my-room "msg-serial" thumbsup --json

See also

  • Rooms — Explore all ably rooms commands.
  • CLI reference — Full list of available commands.