You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/app/instagram_service/services.py", line 142, in account_task
self.__direct_threads(
File "/app/instagram_service/services.py", line 179, in __direct_threads
threads_chunk, cursor = self.client.direct_threads_chunk(
File "/usr/local/lib/python3.10/site-packages/instagrapi/mixins/direct.py", line 151, in direct_threads_chunk
result = self.private_request("direct_v2/inbox/", params=params)
File "/app/instagram_service/insta_wrapper.py", line 71, in private_request
raise e
File "/app/instagram_service/insta_wrapper.py", line 54, in private_request
self._send_private_request(endpoint, **kwargs)
File "/app/instagram_service/insta_wrapper.py", line 227, in _send_private_request
raise UnknownError(**last_json)
instagrapi.exceptions.UnknownError: Denied in DEFCON mode
Desktop (please complete the following information):
OS: [e.g. Ubuntu 21.04]
Python version [e.g. 3.10]
instagrapi version [e.g. 2.1.1]
The text was updated successfully, but these errors were encountered:
I tried playing around to see what would fix this and - even though I have no idea why - the removal of the param "fetch_reason": "cold_start" fixes this. PR created
Describe the bug
When trying to get a list of direct threads, an error appears.
Traceback
Traceback (most recent call last):
File "/app/instagram_service/insta_wrapper.py", line 138, in _send_private_request
response.raise_for_status()
File "/usr/local/lib/python3.10/site-packages/requests/models.py", line 1021, in raise_for_status
raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://i.instagram.com/api/v1/direct_v2/inbox/?visual_message_return_type=unseen&thread_message_limit=2&persistentBadging=true&limit=20&is_prefetching=false&fetch_reason=manual_refresh&folder=0
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/app/instagram_service/services.py", line 142, in account_task
self.__direct_threads(
File "/app/instagram_service/services.py", line 179, in __direct_threads
threads_chunk, cursor = self.client.direct_threads_chunk(
File "/usr/local/lib/python3.10/site-packages/instagrapi/mixins/direct.py", line 151, in direct_threads_chunk
result = self.private_request("direct_v2/inbox/", params=params)
File "/app/instagram_service/insta_wrapper.py", line 71, in private_request
raise e
File "/app/instagram_service/insta_wrapper.py", line 54, in private_request
self._send_private_request(endpoint, **kwargs)
File "/app/instagram_service/insta_wrapper.py", line 227, in _send_private_request
raise UnknownError(**last_json)
instagrapi.exceptions.UnknownError: Denied in DEFCON mode
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: