I want to start a requests.Session()
and add a cookie before starting the first request. I expected to have a cookie argument or something similar to do this
def session_start()
self.session = requests.Session(cookies=['session-id', 'xxx'])
def req1():
self.session.get('example.org')
def req2():
self.session.get('example2.org')
but this wont work, I only can provide cookies
in the .get()
method. Do I need to do a "dummy request" in session_start() or is there a way to prepare the cookie before starting the actual request?