I want to unset an existing date field in Airtable, I tried sending {{ null }} and it doesn’t work.
Invalid input for 'last_run' [item 0]
'last_run' expects a dateTime but we got ' '
Consider using DateTime.fromFormat to work with custom date formats.
I poked around at this a bit more and noticed that part of the problem is n8n being “helpful” and validating the date value before sending it to Airtable. I could sorta hack around that with an expression that makes the validation happy with a real date, but then sends a different value to the Airtable API like: {{ (new Error().stack.toString().indexOf('validate')) ? $now : null }}
The second part of the problem is that there doesn’t seem to be anything you can send to the Airtable API to represent a blank or null date value (contrary to what this suggests. Tried null, 'null', '', ' ', -1, 0, and various other things not worth mentioning, with the typecast option off, and with the typecast option on (which converts most things to the current time, so still not reset/blank/null).
One other idea I had but didn’t try is to add an Airtable trigger to match a “special” date value and overwrite it on the Airtable server end.
As far as I can tell, the “answer” for doing this in n8n is that it is not possible. Assuming your application has logic that depends on a null/blank value in a date field, you may just need to include || theDate == someSpecialValue