A
A
apiwi2020-09-11 13:01:46
Python
apiwi, 2020-09-11 13:01:46

How to create a bot that changes status in a VK group?

There is a group of its own VK, you need to change its status with the help of a bot, I know for this you need either an application or for my personal account to log in and change the status. I can't do it at all. Various errors are given with the Acces token, please provide an example to create. Thank you.
status.set

Этот метод можно вызвать с ключом доступа пользователя, полученным в Standalone-приложении через Implicit Flow. Требуются права доступа: status.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
U
UberPool, 2020-09-11
@UberPool

Perfectly working code below.

import vk
token = 'user token'
session = vk.Session(access_token=token)
api = vk.API(session ,v='5.92', lang='ru')
api.status.set(text='kavo',group_id=<id сообщества положительное число>)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question