问题
I would to post pictures and tag with frieds.
graph = facebook.GraphAPI(self.cfg['access_token'])
tags = [{"tag_uid": "1234567890", "x": 0, "y": 0}, {"tag_uid": "0001234567890", "x": 0, "y": 0}]
graph.put_photo(image=open(str(file), 'rb'), message='Pictures test', **{'tags': tags})
but i've this error
facebook.GraphAPIError: (#100) param tags must be an array.
回答1:
error solved with
tags = [{"tag_uid": "1234567890", "x": 0, "y": 0}]
graph.put_photo(image=open(str(file), 'rb'), message='Pictures test', **{'tags[0]': tags})
but tags NOT appear on the facebook wall
来源:https://stackoverflow.com/questions/41484589/tag-facebook-friends-python-sdk-graphapi-in-put-photo