def init(self):
        """Make a GET request to get the first csrf token and rhx_gis"""

        # try to emulate cookies consent
        self.cookie_jar.set_cookie(
            compat_cookiejar.Cookie(
                0, 'ig_cb', '1', None, False,
                'www.instagram.com', False, None, '/',
                False, False, None, True, None, None, {})
        )

        init_res = self._make_request(
            'https://www.instagram.com/', return_response=True, get_method=lambda: 'GET')
        init_res_content = self._read_response(init_res)
        self.logger.debug('RES BODY: {0!s}'.format(init_res_content))

        rhx_gis = self._extract_rhx_gis(init_res_content)
        self.rhx_gis = rhx_gis

        rollout_hash = self._extract_rollout_hash(init_res_content)
        if rollout_hash:
            self.rollout_hash = rollout_hash

        if not self.csrftoken:
            csrftoken = self._extract_csrftoken(init_res_content)
            self.init_csrftoken = csrftoken

        if not self.csrftoken:
            raise ClientError('Unable to get csrf from init request.')
        if not self.rhx_gis:
            raise ClientError('Unable to get rhx_gis from init request.')
        # required to avoid 403 when doing unauthenticated requests
        self.cookie_jar.set_cookie(
            compat_cookiejar.Cookie(
                0, 'ig_pr', '1', None, False,
                'www.instagram.com', False, None, '/',
                False, False, None, True, None, None, {})
        )
Make a GET request to get the first csrf token and rhx_gis
instagram_web_api/client.py