Skip to content
Download Beeper

Remove a reaction

$client->chats->messages->reactions->delete(string reactionKey, string chatID, string messageID): ReactionDeleteResponse
DELETE/v1/chats/{chatID}/messages/{messageID}/reactions/{reactionKey}

Remove the reaction added by the authenticated user from an existing message.

ParametersExpand Collapse
chatID: string

Chat ID. Input routes also accept the local chat ID from this installation when available.

messageID: string

Message ID.

reactionKey: string

Reaction key to remove (emoji, shortcode, or custom emoji key)

ReturnsExpand Collapse
string chatID

Chat ID. Input routes also accept the local chat ID from this installation when available.

string messageID

Message ID.

string reactionKey

Reaction key that was removed.

true success

Always true. Indicates the reaction removal was queued; failures return an error response.

Remove a reaction

<?php

require_once dirname(__DIR__) . '/vendor/autoload.php';

$client = new Client(accessToken: 'My Access Token');

$reaction = $client->chats->messages->reactions->delete(
  'x', chatID: '!NCdzlIaMjZUmvmvyHU:beeper.com', messageID: '1343993'
);

var_dump($reaction);
{
  "chatID": "!whatsapp_15550101002:ba_EvYDBBsZbRQAy3UOSWqG0LuTVkc.local-whatsapp.localhost",
  "messageID": "1343993",
  "reactionKey": "❤️",
  "success": true
}
Returns Examples
{
  "chatID": "!whatsapp_15550101002:ba_EvYDBBsZbRQAy3UOSWqG0LuTVkc.local-whatsapp.localhost",
  "messageID": "1343993",
  "reactionKey": "❤️",
  "success": true
}