Answer the question
In order to leave comments, you need to log in
Why am I not getting json object?
Hello!
After loading the image, json
the -object with the fields server
, photo
, , should come out hash
, but only this came out:
what could be the matter?
here is the code:
myFile = vk.photos.getWallUploadServer(group_id=10040025, upload_url = {'photo': open(r'P70912-223105.jpg', 'rb')})
print(myFile)
Answer the question
In order to leave comments, you need to log in
How to learn to work with the VK API:
https://vk.com/dev/photos.getWallUploadServer :
Returns the server address for uploading a photo to a user's or community's wall.
After a successful upload, you can save the photo using the photos.saveWallPhoto method .
Parameters :group_id
ID of the community on whose wall you want to upload a photo (without the minus sign).
integer
Result :
Upon successful execution returns an object with fieldsupload_url
,album_id
,user_id
.
1. We get the address where we will upload the photo (GET request)
2. We save the photo (POST request)
What kind of library is this (import at the beginning of the python file, what is written)? Give me a link to github.com.
myFile = vk.photos.getWallUploadServer
Or self-written?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question