D
D
Dmitry2017-03-06 15:52:24
Python
Dmitry, 2017-03-06 15:52:24

How to post news on facebook using python?

Tell me how to post news with a photo on facebook, I read fb api and can’t find examples and documentation in python

Answer the question

In order to leave comments, you need to log in

3 answer(s)
D
Dmitry, 2017-03-08
@ipatov_dn

import requests

access_token = 'ваш токен'

data = [
  ('url', 'https://www.facebook.com/images/fb_icon_325x325.png'), # url вашей фотографии
  ('caption', 'Test text'), # любой ваш текст который хотите публиковать
  ('access_token', access_token), # ну и токен куда мы без него
]

fb=requests.post('https://graph.facebook.com/me/photos', data=data)

the only token that I managed to get at this stage is given for a day bkdk thank you if you help me get it automatically

A
Axian Ltd., 2017-03-06
@AxianLTD

Yes you are mocking https://github.com/mobolic/facebook-sdk

M
Maxim, 2017-03-07
@maximkv25

How to post multiple photos on facebook wall?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question