App Script integration: What is really necessary?

Hi everyone,

I'm developing a small app for internal use only in my company.  We're still exploring so we're still with the free plan. I'm trying to figure out how to integrate App Scripts whit App Sheet in a consistent way through automations.

By now, the app uses AppSheet Database as datasource, but I had trouble fetching data using theSpreadsheetApp interface. Since i had no trouble using a classic excel-like sheet, and I can see the error Data provider 'google_tables' not allowed with the FREE plan in the AppInfo page, do i have trouble fetching data from AppSheet Database with SpreadsheetApp due to my subscription plan? If not, is there another way? Will upgrading to appsheet core solve this problem or it's not related at all?

And since i can do that with classic sheets, can i fetch data from multiple AppSheet Database in a single App script function?

thanks

 

 
Solved Solved
1 8 2,992
1 ACCEPTED SOLUTION

The SpreadsheetApp class is only for accessing GSheets from App Script, not for accessing ASDB. AFAIK, there is no way to access ASDB from an App Script.

View solution in original post

8 REPLIES 8

The SpreadsheetApp class is only for accessing GSheets from App Script, not for accessing ASDB. AFAIK, there is no way to access ASDB from an App Script.

Of course you can. You have to access it throw the Appsheet API of your App.

Generally speaking:

  • Google Apps Script provide means to interact with Google Workspace products, like Sheets, Drive, Gmail and others. It also serves as a js scripting environment to interact with external systems through API calls and manipulate responses and record them in a GWS product like sheets. 
      
  • AppSheet provides Apps Script integration in the sense that you can launch an Apps Script function and receive its return values through AppSheet's automation.
      
  • Apps Script does not currently provide Classes to interact directly with the new AppSheet Database. Yet, there's no need for that since your app can interact with Apps Script. 

So to answer your question, the SpreadsheetApp Class is for Google Sheets, and no, you cannot use it to interact with AppSheet Database, but you really do not need to.

Hoping to see this.

What if i want to use the data in ASDB in another webapp made with google appscript

I have an appsheet app for taking meeting notes. The meeting notes are stored as a field in the ASDB. When a new meeting is created, I want to automatically add TODOs in the "To-dos" table in the same ASDB and was looking to write an app script for that. Since app script does not have a connector to the ASDB, trying to see if there is another way to automate this. Any ideas? 

One way is to add it with the automation & action. Another way is to use action directly and to trigger it from the Meeting_Form's event action. No scripting is needed.

Figured out the solution (not pretty though!) with the help of this article: https://www.googlecloudcommunity.com/gc/Tips-Tricks/FAQ-add-row-per-value-in-EnumList/m-p/357133

Top Labels in this Space