Home python message ID in the interview vk_api

message ID in the interview vk_api

Author

Date

Category

I write a bot on vk_api. There was a problem that when sending a message, a non-unique message ID of the message is returned to the conversation, while in private messages everything is fine. For example

test = vk_api.messages.send (peer_id = peer_id, message = "test")

Test value will be a number – message ID If it comes to personal messages, but it is started if the message is sent to the conversation. I tried to write everything without libraries on clean requests, in response the server gives JSON

{'responce': 0}

What can this problem be related and how to solve it (MB even through the crutch, but better more or less adequately


Answer 1

VKontakte API has closed the opportunity to receive message ID for conversations. Read the following materials:

  1. API for chat bots>1. Community>1.2. Adding bots in conversations
  2. Roadmap>Restriction Messages API

Costlome is: Save the message history in the database, lead your message ID or limit your bot and answers to his messages.

Programmers, Start Your Engines!

Why spend time searching for the correct question and then entering your answer when you can find it in a second? That's what CompuTicket is all about! Here you'll find thousands of questions and answers from hundreds of computer languages.

Recent questions