Google Sheets: is there an HTTP request feature?

Google spreadsheets have a cell function that allows me to make HTTP requests, like

Submit the contents of this cell to http://www.mysite.com/input or

GET XML at http://www.mysite.com/feed.xml

?

Or can I write a custom function that does this? Or is there a more traditional way of doing what I want to do? (using tables for working with the REST API)

+4
source share
1 answer

Use the Google Spreadsheet API to retrieve the contents of a cell on your website. Here you can find a simple example of extracting JSON feeds from a spreadsheet data API: https://developers.google.com/gdata/samples/spreadsheet_sample

Since this link may be ported due to a goole update here, a copy of the script element:

http://spreadsheets.google.com/feeds/feed/key/worksheet/public/basic?alt=json-in-script&callback=myFunc 

... where feed is the type of feed, key is the key of the table you want to receive, the worksheet is a positional or unique identifier for the worksheet, and myFunc is the name of your callback function, which is passed to the JSON object.

To get XML from a web resource, use the function: IMPORTXML (URL; XPath) , for example. importXML("http://www.example.com/feed.xml";"/path/inXML")

+1
source

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


All Articles