permanently delete message for this id.

@param int $messageId

@return bool
322981
public function deleteForever($messageId)
    {
        $deleteMessage = $this->message->delete($messageId);
        if ($deleteMessage) {
            return true;
        }

        return false;
    }
288745
public function deleteSendedAll($messageId)
    {
        $result = $this->httpRaw(self::WECHAT_SENDED_ALL_DELETE_PREFIX, [
            'msgid' => $messageId
        ], [
            'access_token' => $this->getAccessToken()
        ]);
        return isset($result['errmsg']) && $result['errmsg'] == 'ok';
    }
362593
public function deleteByEntryId($entryId)
    {
        $entryId = (int) $entryId;
        if ($entryId >= 2) {
            $entry = $this->getByEntryId($entryId);
            if ($entry instanceof AcumulusEntry) {
                return $this->delete($entry);
            }
        }
        return true;
    }
1262688
public function deleteConversations($id)
    {
        $deleteConversation = $this->conversation->delete($id);
        if ($deleteConversation) {
            return $this->message->deleteMessages($id);
        }

        return false;
    }
678799
public function Delete($MessageID = '', $TransientKey = FALSE) {
      $this->Permission('Garden.Messages.Manage');
      $this->DeliveryType(DELIVERY_TYPE_BOOL);
      $Session = Gdn::Session();
      
      if ($TransientKey !== FALSE && $Session->ValidateTransientKey($TransientKey)) {
         $Message = $this->MessageModel->Delete(array('MessageID' => $MessageID));
         // Reset the message cache
         $this->MessageModel->SetMessageCache();
      }
      
      if ($this->_DeliveryType === DELIVERY_TYPE_ALL)
         Redirect('dashboard/message');

      $this->Render();      
   }
584013
def delete_message(self, id, remove):
        
        path = {}
        data = {}
        params = {}

        # REQUIRED - PATH - id
        """ID"""
        path["id"] = id

        # REQUIRED - remove
        """Array of message ids to be deleted"""
        data["remove"] = remove

        self.logger.debug("POST /api/v1/conversations/{id}/remove_messages with query params: {params} and form data: {data}".format(params=params, data=data, **path))
        return self.generic_request("POST", "/api/v1/conversations/{id}/remove_messages".format(**path), data=data, params=params, no_data=True)
513278
public function getSendAllStatus($messageId)
    {
        $result = $this->httpRaw(self::WECHAT_SEND_ALL_STATUS, [
            'msgid' => $messageId
        ], [
            'access_token' => $this->getAccessToken()
        ]);
        return isset($result['msg_status']) ? $result : false;
    }
488921
public function getMessage($messageId)
    {
        $rawMessage = $this->plivo->get_message(['record_id' => $messageId]);
        $incomingMessage = $this->createIncomingMessage();
        $this->processReceive($incomingMessage, $rawMessage);

        return $incomingMessage;
    }
940218
public function cancelSendArticles($messageId)
    {
        $result = $this->httpRaw(self::WECHAT_ARTICLES_SEND_CANCEL_URL . 'access_token=' . $this->getAccessToken(), [
            'msgid' => $messageId
        ]);
        isset($result['errmsg']) && $result['errmsg'] == 'ok';
    }
120912
public function delete(): void
    {
        // 'deleted' header changed, force to reload headers, would be better to set deleted flag to true on header
        $this->clearHeaders();

        if (!\imap_delete($this->resource->getStream(), $this->getNumber(), \FT_UID)) {
            throw new MessageDeleteException(\sprintf('Message "%s" cannot be deleted', $this->getNumber()));
        }
    }
1081882
public function delete_comment($commentid) {
        global $DB;
        if ($DB->record_exists('comments', array('id' => $commentid))) {
            $DB->delete_records('comments', array('id' => $commentid));
            return true;
        }
        return false;
    }
81113
public function deleteAction()
    {
        $file = (new CmsFileQuery)->findPk($this->id);
        if ($file && $file->delete()) {
            $this->getMessenger()->addMessage('messenger.file.deleted', true);
        }
        $this->getResponse()->redirect('cmsAdmin', 'file', 'index');
    }
343875
public function getSms($messageId)
    {
        $sms = $this->factory->createEmptySms();
        $sms->populate($messageId);

        return $sms;
    }
521249
public boolean markSent(MessageID messageID) {
        MessageInfo messageInfo =  sentMessages.remove(messageID);
        return messageInfo != null && messageInfo.toSelfDeliver;
    }
860204
public function deleteAction()
    {
        $contact = (new \Cms\Orm\CmsContactQuery)->findPk($this->id);
        if ($contact && $contact->delete()) {
            $this->getMessenger()->addMessage('messenger.contact.message.deleted', true);
        }
        $this->getResponse()->redirect('cmsAdmin', 'contact');
    }
924008
public function markAsRead(int $messageId)
    {
        $this->sql = 'update message set is_read = \'Y\' where id = ?';
        $this->bindValues[] = $messageId;

        return $this->execute();
    }
1181601
public function delete($messageId, $documentId = null)
    {
        return $this->diadocApi->delete($this->boxId, $messageId, $documentId);
    }