Cannot filter the row return from appshet API

I have a function below running with google script to retrieve appsheet data via API call.

Everything works, however, I am unable to filter the data. What ever I do with selector, the appsheet API still return all the row, even when I intentionally makes some mistake in Filter query.

Can anybody help me out please.

function appSheetAPI(){
param={'appKey':'my-app-key',
               'appId':'my-app-Id',
              'table':'TripNames',
              'selector':' Filter(TripNames, [Currency Unit] = "KRW"), true)'
}
 
  var url = "https://api.appsheet.com/api/v2/apps/"+param.appId+
            "/tables/" + param.table+"/Action";
  var data = {
      "Action": "Find",
      "Properties": {},
      "Selector" : param.selector
}
resp = UrlFetchApp.fetch(url,{'method' : 'post','contentType': 'application/json',
  'headers':{'ApplicationAccessKey': param.appKey},
  'payload' : JSON.stringify(data)})
console.log(resp.toString());
 }
Solved Solved
0 7 366
1 ACCEPTED SOLUTION

7 REPLIES 7
Top Labels in this Space