Developers » API methods » Messages » messages.setChatPhoto
Messagesmessages.setChatPhoto
Sets a previously-uploaded picture as the cover picture of a chat.
To upload the picture, use photos.getChatUploadServer.
This method can be called with a user token received in Standalone-app via Implicit Flow. Access rights required: messages.
This method can be called with a community token. Access rights required: messages.
Parameters
fileUpload URL from the response field returned by the photos.getChatUploadServer method upon successfully uploading an image.
string, required parameter
Result
Returns an object with the following fields:
  • message_id ID of the system message sent.
  • chat a chat object.
COMMENT: (1 of 1) Is the sample below correct? It looks like an error response, not a successful response.
Errors
22Upload error
925You are not admin of this chat
1160Original photo was changed
Global errors can occur while running. See their descriptions on this page.