Call automation form appscript

Hi,

API call can GET or POST to Appsheet tables but can we use it for calling BOT's?



0 2 116
2 REPLIES 2

You cannot call a bot directly.  However, when you add, update or delete through the API, Bots will be triggered as Data Change events.  For example, if you use the API to add 100 new rows to the app AND you have a Bot configured for ADDS on that data table,  that Bot will get triggered 100 times - once for each new row added.

I hope this helps!!

Thanks

It helped!

I have gone bit further and finally managed to complete my first API: POST script.

I was uploading images straight to google drive and updating path in my sheets and then calling API POST... that did not worked with Appsheet secure images process and was returning expiry before time of creation.

Example:

Image uploaded to Drive at 10:00am with path /images/image123.png

Appsheet secure link to image expiry 
https://www.appsheet.com/image/getimageurl?appName= [appname]&tableName=[tablename]&[filepath]&appVersion=123&expire=2024-10-23T09:15:04.9943044Z&signature=[random numbers]

The main idea was to minimize API usage by sending only the essential data, while using AppScript to handle uploading and managing the rest. The API would only be called to trigger Bots when necessary.


Little tip:

If you app has ticked all below 

Secure PDF access 
Secure Image access 
Require Image and File URL Signing  

Please make sure that image is sent through API so Appsheet can correctly assign expiry date and time to the image.

This is thus far I understood... eventually it works so Good Luck Everyone