Skip to content

unpinChatMessage

Unpin a message in a chat.

Request

POST /:token/unpinchatmessage

Parameters

ParameterTypeRequiredDescription
chat_idInteger/StringYesUnique identifier for the target chat or username
message_idIntegerNoIdentifier of the message to unpin. If not specified, the most recent pinned message will be unpinned

Response

Returns Boolean true on success.

json
{
  "ok": true,
  "result": true
}

Error Codes

CodeDescription
400Bad request parameters
401Invalid token
403Bot does not have permission to perform this action
404Message does not exist or is not pinned