L
L
LXSTVAYNE2020-07-14 14:08:13
Python
LXSTVAYNE, 2020-07-14 14:08:13

How to upload an image to a VK wall using vk api python?

What am I doing wrong ?
5f0d91ec0a1a4817431814.png

Answer the question

In order to leave comments, you need to log in

1 answer(s)
Y
yamudaqq, 2020-07-14
@lxstvayne

result = response.text
you assigned a text value to the result variable, so the string cannot have the keys ['photo'], ['server'], and so on. you can change to result = response
either

vk.photos.saveWallPhoto(group_id = group_id, photo = response['photo'], server = response['server'], hash = response['hash'])

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question