Use the AppSheet Apps Script Examples Project
Quick start
Copy the sample project as a starting point for your own Apps Script project.
- Open the sample project:
Open Sample Project
- Copy the project.
What does this sample project do?
This project has many different functions to help you get started, you can modify and mix-and-match these depending on your workflow.
Function Name
Description
sayHello
Logs a message to the console
createCalendarEvent
Adds an event to the default calendar with the provided start and end times
createDoc
Creates a Google Doc
createSheet
Creates a Google Sheet
createSlideDeck
Creates a Google Slide
shareFile
Shares a Google Drive file with an email
sendAnEmail
Sends an email
createAndSendDocument
Creates a Google Doc and send an email with it as an attachment
How to test from Apps Script
You can test executing the function from the Apps Script by clicking Run or Debug at the top of the editor:
[画像:Run and debug in Apps Script editor]
Since it runs the function without setting arguments, you'll need to add default arguments. For example, instead of function sayHello(msg) change it to be function sayHello(msg="Test message").
The first time you do this, you'll need to authorize scopes the script needs.
Next steps
After you have it set up, you can follow the instructions in Call Apps Script from automation to set up the task and bot inside AppSheet.