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

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.

Possible?

0 35 1,720
35 REPLIES 35

@Aaron_Moolb

Thatโ€™s possible with Scripting via invoking AppSheet API

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

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

@Simon_Robinson Didnโ€™t we have someone wanting this functionality?

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

@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โ€ฆ

@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.

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.

@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?

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

@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 levent@able3ventures.com for what kinda action you expect and I will share with that email address.

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?

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.

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

@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

@Henry_Scott
Use of AppSheet API need a PRO plan.

@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

@Henry_Scott
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.

Damn, I went Zapier to bypass the Business Plan fees and it seems I could still have achieved integration between Woocommerce and the App on Appsheet by using the Appsheet API with a 3rd party REST API services, on a standalone web-app, and use its URL as an endpoint URL in a webhook workflow. I assume need to use GAS for that?

@Henry_Scott correct

@LeventK, hmmm. Thanks as always

@Henry_Scott youโ€™re welcome, truly my pleasure

@LeventK, here is the Post and response from Appsheet that I will need a Business Subscription to use the REST API
Here was my Question:

Here is the response from @Phil

@LeventK, you mentioned a small demo app to @Aaron_Moolb in the thread above. You do not maybe want to share such a small demo up with us on this thread?

@Henry_Scott
Here is the sample app for your reference. Please click on your name on the Home screen.
[HOW IT WORKS]
Just add any record with name and valid email for testing. The record will automatically be saved as โ€œsubscribedโ€ as [STATUS]. On the Detail View, you will notice an UNSUBSCRIBE button. When you click that button, an email will be sent to the email address you have recorded, which contains a button in the body. Clicking that button, will invoke the AppSheet API and change the records [STATUS] as unsubscribed. Hope this was what you were requesting.


@LeventK. Completed my record with email, but I see the change does not allow syncing on the Community Sample App, so I did not recieve the email with the Unsubscribe button/link.

@Henry_Scott
Hmmmโ€ฆ You may have a right thereโ€ฆLet me check how I can let you to test thatโ€ฆMay be it might work if I add you as a user or co-author. Would you mind passing me your email for that purpose?

Thanks @Henry_Scott, will receive the notification shortly

Hello @Henry_Scott, you should have received the notification already. Can you confirm?

@LeventK. Got the link and installed it on my Device. Same challenge. Created my record and then on Sync Top right it gives me the โ€œSample Apps are protected from unauthorised data changesโ€

@Henry_Scott I will try something and get back to you.

@LeventK thanks. appreciate it

@Henry_Scott
I have send you an email regarding the issue.

@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

Top Labels in this Space