Key 'error' not found in returned object

I am using an api call to a 3rd party system and I would like to capture the response. However depending of whether the api refers to a known object or not, the response varies.

If all good I will receive some attributes array element

If not then I receive an error element

I am trying to figure out how to store both values but the automation always fails because I will never get both. The full audit history message is:

"Errors": "Error: 'Set Column Values' Data action ''Set Column Values' Data action 'Action for Store result'' failed with exception 'Set Column Values' Data action 'Action for Store result' failed because field 'api.error' in table 'MyTable' could not be computed due to exception Error: Failed Webhook type translation: Key 'error' not found in returned object.",

I tried editing my Set Column Values to test if the return value [API Call].[error] is blank and just write a space if so but the problem appears to be relating to the recording of the return value itself. 

How can I work around this?

0 3 250
3 REPLIES 3

Are you referencing the Use return values from webhooks - AppSheet Help feature?

You could instead Use return values from Apps Script tasks - AppSheet Help and handle the type interpretation and any necessary conversion within Apps Script to reliably return consistent types to App Sheet..

Can I use Apps Script with non-Google services? I don't really know much about App Scripts as i never thought I would be using them

Yes. Using Apps Script is a typical technique for creating integrations between AppSheet apps and any other web service.

Top Labels in this Space