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.69k stars 1.47k forks source link

Photo uploaded without caption #1184

Closed antonis-papaioannou closed 4 years ago

antonis-papaioannou commented 4 years ago

Before submitting an issue, make sure you have:

Purpose of your issue?


Describe your issue

I try to post a photo with a caption. The photo is successfully uploaded but without the caption. My account is not blocked and i can edit the photo and add caption manually with my instagram application on my phone.

Digging into code I figured out that the upload of the photo request return 200 (as expected). Then the function configure_photo() (file api_photo.py) is called. The data appended to the send requests seems correct (See below. I removed the values of some fields for this post).

{"media_folder": "Instagram", "source_type": 4, "caption": "My caption with #tags and a @mention", "upload_id": "removed", "device": {"instagram_version": "105.0.0.18.119", "android_version": 24, "android_release": "7.0", "dpi": "640dpi", "resolution": "1440x2560", "manufacturer": "HUAWEI", "device": "LON-L29", "model": "HWLON", "cpu": "hi3660"}, "edits": {"crop_original_size": [866.0, 1080.0], "crop_center": [0.0, 0.0], "crop_zoom": 1.0}, "extra": {"source_width": 866, "source_height": 1080}, "_uuid": "<removed>", "_uid": "<removed", "_csrftoken": "removed"}

The above request returns (I removed the values of some fields for this post):

{'taken_at': <removed>, 'pk': <removed>, 'id': '<removed>', 'device_timestamp': 1577666296500, 'media_type': 1, 'code': 'removed', 'client_cache_key': 'removed', 'filter_type': 0, 'image_versions2': {'candidates': [{'width': 866, 'height': 1080, 'url': 'removed'}, {'width': 480, 'height': 598, 'url': 'removed'}]}, 'original_width': 866, 'original_height': 1080, 'user': {'pk': removed, 'username': 'removed', 'full_name': 'removed', 'is_private': False, 'profile_pic_url': 'removed', 'profile_pic_id': 'removed', 'has_anonymous_profile_picture': False, 'can_boost_post': True, 'can_see_organic_insights': True, 'show_insights_terms': False, 'reel_auto_archive': 'on', 'is_unpublished': False, 'allowed_commenter_type': 'any', 'can_see_primary_country_in_settings': False}, 'can_viewer_reshare': True, 'caption_is_edited': False, 'comment_likes_enabled': False, 'comment_threading_enabled': False, 'has_more_comments': False, 'max_num_visible_preview_comments': 2, 'preview_comments': [], 'can_view_more_preview_comments': False, 'comment_count': 0, 'boosted_status': 'not_boosted', 'photo_of_you': False, 'caption': None, 'fb_user_tags': {'in': []}, 'can_viewer_save': True, 'organic_tracking_token': 'removed'}

I'm not sure if the response is the expected one. In my opinion the interesting fields in reponse are: 'caption': None 'caption_is_edited': False,

Following the rules I have to mention that I use python 3.7.5

bruvv commented 4 years ago

Good post, did you search tho? https://github.com/instagrambot/instabot/issues/878

crosslink: https://github.com/instagrambot/instabot/issues/1058

antonis-papaioannou commented 4 years ago

I looked into those issues before posting. In #878 the account was blocked and the used was not able to post manually or using the "bot" (not my case). Issue #1058 is relevant but it has been marked as stale.

It seems that instagram detects user behaviour within sessions. The "user behaviour" from my phone is "normal" but the behaviour of my bot is detected as "automated" and that's the reason they "block" some features. I 'm trying to enrich the behaviour of my bot in order to mimic a human behaviour.

bruvv commented 4 years ago

I am closing this in favor of this post: https://github.com/instagrambot/instabot/issues/1194 please continu the ban discussion there Thanks for the issue btw!