Can I have a DeepLink sent via email to run a...

(Aaron Moolb) #1

Can I have a DeepLink sent via email to run an action on a certain row?

I have an order table with an Approved column. I also have an action to set that column to TRUE. When I submit the order for approval to a manager, I want a link inside the email body that he can tap on and it runs the action to approve that order without opening the app.


(Levent KULAÇOĞLU) #2


That’s possible with Scripting via invoking AppSheet API

(Aaron Moolb) #3

@Levent_KULACOGLU Does the script go into the GoogleAppScript section of the spreadsheet or is it in the app somewhere?

(Levent KULAÇOĞLU) #4

@Aaron_Moolb got your email, thnx. TTY next week possibly. Will be in touch.

(Green Gorilla) #5

@Simon_Robinson Didn’t we have someone wanting this functionality?

(Levent KULAÇOĞLU) #6

The script shall be in the gSheet as a container associated with a hidden HTML source. Then it’s possible to place a button inside the email and when user clicks the button, a JS routine will send a doGet() command to the HTML source that’s binded to the Google Apps Script project which will make a UrlFetchApp call to the AppSheet API

(Aaron Moolb) #7

@Levent_KULACOGLU This is awesome news…except that my JS language writing skills are beginner. Is there a sample of the InvokeAction JS that I can copy/past but just replace the AppName and Action Name and/or the API key?

Then, do I need to create an image for the email body or will AppSheet auto generate the action button based on the action name as depicted by the app?

Thanks for your help on this…

(Levent KULAÇOĞLU) #8

@Aaron_Moolb no need to create an action button as you will be doing/simulating this with a PATCH/UPDATE command thru the AppSheet API. There is no any InvokeAction code that you can copy, as this is a design based issue and you have to create it yourself. You can either put an HTML button inside the email which will execute a JS snippet to call a doGet(e) function in your GAS project or create an HTML link directly to the HTML namespace of your GAS project.

(Aaron Moolb) #9

This is great info…thank you.

Is anyone in the community doing this? I am a very quick learner and just need to see an example of what is being used so I know that format.

(Levent KULAÇOĞLU) #10

@Aaron_Moolb we can gladly help if you want but we are very tight in terms of schedule right at the moment because of contracted Client projects. My partner @Bellave_Jayaram is also extremely novice with scripting and API calls. What’s your urgency on this?

(Aaron Moolb) #11

@Levent_KULACOGLU None at all…it would be very helpful but I dont want to take away from other projects.

(Levent KULAÇOĞLU) #12

@Aaron_Moolb I’ll be fully occupied with a SQL project with my other partner @Aleksi_Alkio next week, don’t take it as a strong promise but in a free slot I will try to prepare a small demo app for you. Just drop me a line at for what kinda action you expect and I will share with that email address.

(Aaron Moolb) #13

@Levent_KULACOGLU Thank you. I just sent you an email. I will be grateful whenever you can get to it. I will followup in a couple of weeks

(Fabian Weller) #14

I need exactly the same thing. A button in an Email Body that is changing the status of a row.
Is your sample App public?

(Levent Kulacoglu) #15

Hello @Fabian
The app is not public as it contains personal API information. I can explain the methodology but you need to change the API headers with your own info.

(Fabian Weller) #16

OK I see. I would really like to learn ho to do this. Can you help me?

(Henry Scott) #17

@LeventK would this require a Business Subcription on Appsheet to interface with the API?
If yes then a bummer.
But the value must just be set in the Google Sheet so the GAS that is invoked is changing a value in a row in the Google Sheet that when next time a sync happens in Appsheet the App will have the value .
There must be a standard GAS that one can use as an example?
Apologies if I am over simplifying with my limited coding capabilities :slight_smile:

(Levent Kulacoglu) #18

Use of AppSheet API need a PRO plan.

(Henry Scott) #19

@LeventK I get confused between the Appsheet API and the REST API.
I though the same thing, because the REST API is on a Business Plan.
Help me with determining the difference. Not a developer :slight_smile:

(Levent Kulacoglu) #20

AppSheet API is a RESTful API service already. “RESTful API” in the Business Plan is something different completely (though I have no any idea what’s the content of it really). But with the PRO plan, you can invoke AppSheet API with a webhook workflow. For 3rd party REST API services, you can create a standalone web-app, and use its URL as an endpoint URL in a webhook workflow.