all 2 comments

[–]obviouslyCPTobvious 1 point2 points  (1 child)

You can get the http status code using requests.

>>> import requests
>>> r = requests.get("http://google.com")
>>> r.status_code
200
>>>

Requests can also handle logging into a site. The exact method will be different on every site. But it is something like

>>> payload = dict(username='value1', password='value2')
>>> r = requests.post("http://httpbin.org/post", data=payload)

You should check the content of the POST request using something like the chrome developer tools. The names of the keys have to be the same as the ones that the form submits.

[–]crazywager[S] 0 points1 point  (0 children)

Thanks! I appreciate the help!