Calling appsheet api from python to update rows

Hi,

I want to run python script to update rows in appsheet but couldn’t able to get right format to call appsheet API. Can someone help on this? I tried below code but getting 500 response code.

import requests
response = requests.post(“https://api.appsheet.com/api/v2/apps/{f1f63558-ce36-44ce-abf1-d7c56d2290ea}/tables/{TEST_213}/Action?applicationAccessKey=<APP_ACCESS_KEY>”)
print(response.status_code)

Try the following:
1 - Create a Script file in your Google Drive (in it you can create the functions you want in JavaScript language.
2 - Bard (IA) tells me that from GoogleScript you can call a function in Python by:
# my_function.py
def my_function(x):
print(x + 10)

# script.gs
import my_function
my_function(10)

3-From AppSheet create a bot that calls the Script

@JSO I need help to create the script. Can you please help on that part.

Try the following:
1 - Go to Google Drive
2 - Choose the option New (or more, as presented to you)

3-Select Google Apps Script.

4-An editor will open for you to write the function that you will have to call later from AppSheet.

5- From there, it is about using JavaScript and the Google API.

1 Like

Remove the brackets {}

Manage apps using the AppSheet API - AppSheet Help

1 Like