I am trying to imitate a authenticated JSON request. I am using the Requests module to do so.
import requests
import json
url = "https://"
headers = {
'Host': 'example.com',
'content-type': 'application/json',
'Connection': 'keep-alive'
}
data = {
"asdsdsd": {
"AppName": "esdf",
"Language": "EN",
"fsef": [
{
"sfddf": [
{
"sdfsdfsdf": "sdfsdfsdf"
}
]
}
]
},
"sdfdf": {
"sdfsdf": "sdfsdfsdf"
}
}
r = requests.post(url, data=json.dumps(data), headers=headers ,verify=False)
How do i include the authenticated cookie into this.
Can I open this request using a browser(with the headers & data) then i would be able to use the authenticated cookie of the browser.
Is there any way to do this ?