I tried to log in into a website using post requests in python by passing the username and password using the below code and it worked.
import requests
with requests.Session() as c:
url='http://testing-ground.scraping.pro/login?mode=login'
usr='admin'
pwd='12345'
c.get(url)
print(c.cookies)
login_data=dict(usr=usr,pwd=pwd)
res=c.post(url,data=login_data)
print(res)
page=c.get('http://testing-ground.scraping.pro/login?mode=welcome')
print(page.content)
Now,I want to try the same(log in to the same website using post requests) in lambda aws in python.I am a beginner to lambda,aws and have no idea how to proceed in lambda.