Download unpublished Google spreadsheet as CSV

后端 未结 5 1155
既然无缘
既然无缘 2020-12-08 21:38

I have a Google spreadsheet that has not been made public, but just available to anyone that has the access link. Though I can access the data in CSV format from my browser

5条回答
  •  长情又很酷
    2020-12-08 22:21

    Now I can answer questions, so I will leave it answered for good (pasting from my previous comment).

    My problem was that I was not storing the cookie correctly. At the time, I was using a Python program to try to download this. This fixed the problem I was reporting:

    # Cookie management 
    opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(CookieJar())) 
    csv_data =  csv.reader(opener.open(url))
    

提交回复
热议问题