Python Forum

Full Version: Is it possible to grab a table off a webpage you are already logged into?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
So we have a support company we submit issue to and on a weekly basis we have to login to their site and review any issues we currently have open with them.. Right now we only have 7, so the list is small, but during the holidays we had in the 50's on the list.. and copying and pasting from their webpage was not very clean..

So i tried this and got a SSL error:

import requests
from bs4 import BeautifulSoup
import pandas as pd

url = 'https://website.com/cases?view=team-cases'

page = requests.get(url)
Error:
SSLError: HTTPSConnectionPool(host='https://website.com/', port=443): Max retries exceeded with url: /cases?view=team-cases (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1129)')))
So my questions are, since we have to login to the site to view the cases, is it possible to just run a python script against a page i already have open and im logged into? Or do i have to do the login from the script in order to make this work?

If i have to do it from the script, is there a good example of doing a login to site from python using requests? I found a few, but so far those 2 or 3 i tried, im not getting logged in, i get other errors, but at the moment, the above is the attempt im working with..