How can I write a python script that accesses a specific google sheets document. I want to be able to iterate over the rows in the sheet.
user
The following code is needed to iterate and read from the selected sheets:

          if re.search(log_RE, title):
            rangeName = title + '!A:Z'
            sheet_id = sheet.get("properties", {}).get("sheetId", 0)
            request = service.spreadsheets().values().get(spreadsheetId=spreadsheetId, range=rangeName)
            response = request.execute()

So, the spreadsheet is read with the get, giving it the spreadsheedId and the sheet name, which is part of the range.
assistant