Hi, did someone experience "SSS_USAGE_LIMIT_EXCEED...
# suitescript
t
Hi, did someone experience "SSS_USAGE_LIMIT_EXCEEDED" error. After I receive response from api and I try to parse the response I get that error. Here is my code below.
var gapiUrl = '<https://maps.googleapis.com/maps/api/distancematrix/json?units=imperial&origins=>' + _fromLat_ + ',' + _fromLong_ + '&destinations=' + _toLat_ + ',' + _toLong_ + '&mode=fastest;car;traffic:enabled&key=zzzzzz--0 &language=en-EN&sensor=false';
var restResponse = <http://_https_.post|_https_.post>({
url: gapiUrl
});
var response = JSON.parse(restResponse.body);
if (restResponse.code == '200') {
return response.rows[0].elements[0].distance.text;
}
a
it should not cause any limit exceed, but I noticed you share the API key and that could lead to many requests if anyone use this key
t
Thanks @ahmed saeed moawoad elmasry. I conduct few enhancement on the script. I use .runpage on my search.create