Skip to content

Session ID login failed: Expecting value: line 1 column 1 (char 0) #2377

@Sajjad-Taghinezhad

Description

@Sajjad-Taghinezhad

Describe the bug
Login wiht browser session id is not working

To Reproduce
use function like self.client.login_by_sessionid(self.session_id)

Traceback
It says session id expired, but my browser was working with it correctly.
I did intercept the traffic, and found out Instagram API returns an error about "unsupported version".
Instagram response:

{"message":"challenge_required","challenge":{"url":"https://i.instagram.com/web/unsupported_version/","api_path":"/challenge/","hide_webview_header":false,"lock":true,"logout":false,"native_flow":false,"flow_render_type":4},"status":"fail"}

Expected behavior
Should login to Instagram

Screenshots
I've added the response of the GET request to the "/api/v1/users/8*****8/info/?is_prefetch=false&entry_point=self_profile&from_module=self_profile&is_app_start=False"

Desktop (please complete the following information):

  • OS: Mac OS Tahoe 26.2
  • Python version 3.11.14
  • instagrapi version 2.2.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions