Answer the question
In order to leave comments, you need to log in
How to create vk api poll in python?
The official documentation says that add_answers is json data, which
is probably why it doesn't work. Correct the code please
import vk_api
vk_session = vk_api.VkApi('логин', 'пароль')
vk_session.auth()
vk = vk_session.get_api()
print(vk.polls.create(question='test', add_answers= [{'text':'test1'}]))
Answer the question
In order to leave comments, you need to log in
When did the list turn into json ?
create(question='test', add_answers=json.dumps({'text':'test1'}))
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question