Access to Google Doc via API with shared URL (AuthKey)?

Google Docs allows you to share a document only with a URL. The URL contains the key and authkey for document identification and access authorization. This allows anonymous access to anyone with a key.

I would like to access this type of shared document in the application. I looked at the API and did not see anything. It seems that this should be possible - since you can anonymously access such a document using a browser, why should the application not have access to the same document? Does anyone know if / how to do this?

+3
source share
3 answers

, 2017 ( ). Google, , . , .

https://docs.google.com/spreadsheets/d/[idwillbehere]/edit#gid=0

curl. , , , , .

curl -o /path/to/file/you/want/csv/to/go.csv 'https://docs.google.com/spreadsheet/ccc?key=[the-id-of-your-spreadsheet]&output=csv' -L

-L - , google csv, . -L curl , .

+2

URL- :

https://docs.google.com/feeds/download/<type>/Export?docID=<document_ID>&exportFormat=<format>

 -  -  -  -

  • HTML
  • TXT
  • ..
  • XLS
  • ...
  • JPEG
  • PNG
  • SVG

. Google Drive API https://developers.google.com/drive/manage-downloads

URL- Google PDF

https://docs.google.com/feeds/download/presentations/Export?docID=15HI6KUtc7dm1jZuk1JY022wxWMcYzz3CiC0dxokokak&exportFormat=pdf

+1
source

Source: https://habr.com/ru/post/1792301/


All Articles