igdmapps / igdm

Desktop application for Instagram DMs
MIT License
1.96k stars 406 forks source link

first message cannot be sent #1133

Open baptx opened 4 years ago

baptx commented 4 years ago

When trying to send a message to someone new I never messaged before, I can see this error when starting IGdm from the command line: (node:20880) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): ActionSpamError: This action was disabled due to block from instagram!

However, if I try to send the same message to the same person in the official Android app, using Android x86 in VirtualBox, it works correctly and then I can continue sending messages to this person in IGdm.

It looks like Instagram is trying to filter unauthorized clients when contacting someone new so I think this issue could be solved by sending the exact same HTTP request, like the official client is doing. This issue happened to me since several weeks only, so it is possible that the block happens only to some accounts flagged by Instagram. I am using a VPN but this did not cause any problem when using the official Instagram app with a VPN also.

Tested with IGdm-2.8.1-x86_64.AppImage on GNU/Linux (Ubuntu 19.04).

baptx commented 4 years ago

Now direct messages are blocked on the official Instagram app too, I don't know why it happened later than IGdm. By looking at the HTTP response of IGdm with mitmproxy, I can see that the block will expire in 1 week. It looks like Instagram started blocking VPN and proxy: https://github.com/timgrossmann/InstaPy/issues/5132 https://github.com/instagrambot/instabot/issues/1128 However I never used any automated script like InstaPy or instabot from my VPN or Instagram account.

baptx commented 4 years ago

I also noticed that when not using a VPN and sending a message to someone we already contacted, it can be blocked by the spam filter if it contains a link, even if it is not a spam link. The solution is to remove http:// or https:// before sending the link.

Update: It looks like the account is banned until we give feedback to Instagram and tell them why it is blocked by mistake. After reporting the problem using the web version (or the official mobile app with Android x86 in VirtualBox), the error message changes and says the block expires in 1 week. But after sending a few messages to new people without problem, it is blocked again and we have to report the problem a new time to be able to contact new people 1 week later. The error message contains JSON data with an item name feedback_url having the value repute/report_problem/ig_direct_v2_thread_create/ (or repute/report_problem/user_restriction_DIRECT_THREAD_CREATE_RESTRICT/ during the temporary 1-week block). Ideally, the feature to report a problem should be added to IGdm.

Update 2: Another solution is to log out and log in again but in this case we are only allowed to send 1 message to a new person every day approximately. I think when we see the first error message, it is better to wait 24 hours before sending a first message to another person, otherwise Instagram may change the 1-day ban to the 1-week ban.