Skip to main content

I have an automation set up so that when a new survey response from Delighted is submitted, a new record is sent to our Airtable with that response, and other automations take over.

Previously, we had it set up such that Zapier’s Utility tool and Text Formatter tool would parse responses from the open ended text questions on our survey and pipe them into specific fields on our Airtable. Since Delighted sends the data payload over as one long text string for these responses, we used a combination of string.split and util.lineitem_to_string_v2 to parse the responses and separate the output into two different text fields on Airtable, `Feedback` and `Thank You`. Even if one response was null, the automation would still assign the correct output to the appropriate field. As of yesterday though, we came across instances where if `Feedback` was answered, but `Thank You` wasn’t, the text for feedback was being input into `Thank You` which was then sent via another automation to an email address of a user. 

Wondering if there was something that changed or if someone can help me set it up so that it can work again properly? Thank you! 

Hey! This is normal behaviour. You will need to handle this with a code-step, because Zapier is skipping the blank value, which you need to handle yourself.

 

Here’s how I did this in a previous zap (sending so you can see the logic - But this code is very specific to the JSON response I got)

 

const content = await rawResponse.json().then((data) => {
function ColumnPair(columnName, columnValue) {
(this.columnName = columnName), (this.columnValue = columnValue);
}
let combined = e];

var columns = data.Result.Customfields;

for (var i = 0; i < columns.length; i++) {
if (columnsli].ColumnValue.length < 1) {
columnsli].ColumnValue = 'n/a';
} else {
columnsli].ColumnValue;
}
}

 


Thanks! I was actually trying to avoid coding as I’m not familiar with JSON. However, I was able to get this working again by testing with a full record and now all partially filled responses are mapping to the correct fields. 


Great! Thanks for the update