Join Scott Simpson for an in-depth discussion in this video Using external data from an API, part of Up and Running with Google Apps Script.
- It's really useful to be able to bring in…external data to your scripts.…Google already has some built-in spreadsheet functions,…such as the Google Finance function for stock prices.…But with a URL Fetch App class,…you can get data from any HTTP…or HTTPS API.…Let's take a brief look at this using the…API at openweathermap.org.…Here's the API column I'm going to make.…I'll copy this example…and I'll switch over to my script.…
Here, I'll set up a function to get some external data.…I'll call it function getInfo.…Then I'll set up a variable called Response…to get the output of the URL Fetch App's fetch method.…I just need the string one for this.…If you need to pass more advanced options back…to the API such as an API key,…you'll want to read up on the options…parameter in the documentation.…I'll replace this slug with…http://, and then I'll paste in our API call.…
I just want to make one change here.…This value here is the zipcode which,…if you're not from the United States,…is an area designation.…I'll put in 93013, which is the zipcode of…
First, learn how to use simple scripts to edit documents and spreadsheets, work with files in Drive, and find and send messages in Gmail. Then find out how to add custom functionality to your spreadsheets, and build user interface elements for your scripts, using menus, alerts, and dialogs. Finally, Scott shows how to share your work with others by publishing scripts as web apps.
- What is Google Apps Script?
- Understanding script types
- Logging and debugging your scripts
- Scripting common tasks
- Building custom spreadsheet functions
- Creating add-on functionality such as dialogs and sidebars
- Sharing your script as a web app