mirror of
https://github.com/jlengrand/openapi-generator.git
synced 2026-05-18 08:31:20 +00:00
Allow to set cookie in python(3) API constructor.
This commit is contained in:
@@ -45,13 +45,13 @@ class ApiClient(object):
|
||||
:param header_value: a header value to pass when making calls to the API
|
||||
"""
|
||||
def __init__(self, host=Configuration().host,
|
||||
header_name=None, header_value=None):
|
||||
header_name=None, header_value=None, cookie=None):
|
||||
|
||||
self.default_headers = {}
|
||||
if header_name is not None:
|
||||
self.default_headers[header_name] = header_value
|
||||
self.host = host
|
||||
self.cookie = None
|
||||
self.cookie = cookie
|
||||
# Set default User-Agent.
|
||||
self.user_agent = 'Python-Swagger'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user