python - Post images through yampy -
i can post message in yammer when itry post image
import yampy access_token = 'access_token_id' attachment = 'c:\\users\\userdir\\desktop\\picture.png' yammer = yampy.yammer(access_token=access_token) yammer.client.post('/messages', body="testing_please_ignore", group_id=123233, broadcast=true, attachment1=attachment)
i got following error
traceback (most recent call last): file "c:\users\userdir\workspace_new\challenges\yammer.py", line 30, in <module> attachment1='c:\\users\\userdir\\desktop\\desktop\\logo.png') file "c:\python27\lib\site-packages\yampy\client.py", line 51, in post return self._request("post", path, **kwargs) file "c:\python27\lib\site-packages\yampy\client.py", line 77, in _request return self._parse_response(response) file "c:\python27\lib\site-packages\yampy\client.py", line 94, in _parse_response raise self._exception_for_response(response) yampy.errors.responseerror: 500 error: internal server error
i going through following documentation https://developer.yammer.com/docs/messages-json-post
can 1 ?
Comments
Post a Comment