ohld / igbot

🐙 Free scripts, bots and Python API wrapper. Get free followers with our auto like, auto follow and other scripts!
https://hikerapi.com/p/N2P6iqiM
Apache License 2.0
4.72k stars 1.47k forks source link

[error 400] send_photo direct #1290

Open whykot opened 4 years ago

whykot commented 4 years ago

Example file

bot.send_photo('nick','1.jpg')

Describe the bug

i'm to send direct photo - error challenge_required

Log

2020-02-13 12:34:19,090 - DEBUG - POST to endpoint: direct_v2/threads/broadcast/upload_photo/ returned response: <Response [400]>
2020-02-13 12:34:19,091 - DEBUG - Responsecode indicates error; response content: b'{"message": "challenge_required", "challenge": {"url": "https://i.instagram.com/challenge/?challenge_node_id=17908474183409402", "api_path": "/challenge/?challenge_node_id=17908474183409402", "hide_webview_header": true, "lock": true, "logout": false, "native_flow": true}, "status": "fail"}'
2020-02-13 12:34:19,091 - ERROR - Request returns 400 error!
2020-02-13 12:34:19,091 - INFO - Instagram's error message: challenge_required
2020-02-13 12:34:19,092 - INFO - Instagram's error message: {}
2020-02-13 12:34:19,092 - INFO - Message to ['nick'] wasn't sent
2020-02-13 12:34:19,093 - DEBUG - Saving Checkpoint file to: .checkpoint

Version

Python version (python -v): 3.8.1 OS: MacOS

bruvv commented 4 years ago

Post the log file saved in the log folder.

whykot commented 4 years ago
> 2020-02-14 18:01:39,602 - instabot version: 0.107.0 (bot) - INFO - Instabot version: 0.107.0 Started
> 2020-02-14 18:01:47,439 - instabot version: 0.107.0 (api_login) - INFO - PRE-LOGIN FLOW!... 
> 2020-02-14 18:02:05,176 - instabot version: 0.107.0 (api) - ERROR - Request returns 400 error!
> 2020-02-14 18:02:05,177 - instabot version: 0.107.0 (api) - INFO - Instagram's error message: challenge_required
> 2020-02-14 18:02:05,177 - instabot version: 0.107.0 (api) - INFO - Error type: checkpoint_challenge_required
> 2020-02-14 18:02:05,177 - instabot version: 0.107.0 (api) - INFO - Checkpoint challenge required...
> 2020-02-14 18:02:55,550 - instabot version: 0.107.0 (api) - INFO - Logged-in successfully as 'whykot_3dprint'!
> 2020-02-14 18:02:55,552 - instabot version: 0.107.0 (api_login) - INFO - LOGIN FLOW! Just logged-in: True
> 2020-02-14 18:03:31,696 - instabot version: 0.107.0 (bot_direct) - ERROR - File base/img/insta_1.jpg is not found
> 2020-02-14 18:04:02,684 - instabot version: 0.107.0 (api) - ERROR - Request returns 400 error!
> 2020-02-14 18:04:02,686 - instabot version: 0.107.0 (api) - INFO - Instagram's error message: challenge_required
> 2020-02-14 18:04:02,687 - instabot version: 0.107.0 (api) - INFO - Instagram's error message: {}
> 2020-02-14 18:04:02,687 - instabot version: 0.107.0 (bot_direct) - INFO - Message to ['3572342056'] wasn't sent
> 2020-02-14 18:04:17,403 - instabot version: 0.107.0 (bot) - INFO - Total requests: 26
adam-ristov commented 4 years ago

Im getting the same result when attempting to use the send_photo, except the file location error part