Run any custom javascript serverside (IFTTT Pro + Dynalist API)

Ideally dynalist would convert all conversational date inputs like !(today) to the correct date !(2020-10-29) serverside, but it doesn’t. So I found a way to do it with IFTTT Pro.

Now I yell “HEY GOOGLE TODAY IM GOING TO THE BEACH” (or tomorrow, etc), and thanks to the magic of smartwatches and google home minis, it’s instantly in my Google Calendar.
image

HOW do you enjoy this? IFTTT Pro. It’s $1.99/mo (until oct 31???) then jumps to $10/mo so be quick.

Here’s the IFTTT Filter Code:

let today = new Date().toISOString().slice(0, 10);

let varText = '!(' + today + ') ' + GoogleAssistant.voiceTriggerWithOneTextIngredient.TextField;

let varBody = '{"token":"tktktktktktktktktktktktktoekn","content":"' + varText + '"}';

MakerWebhooks.makeWebRequest.setBody(varBody);

If you don’t know how to connect IFTTT to the Dynalist API, refer to this post for instructions: [Tutorial] Add to multiple inboxes! via any voice assistant! [IFTTT Webhooks]

If you’re good at javascript the possibilities are endless for manipulating inputs to dynalist. And since it’s serverside it will work on all your devices.

Couldn’t you use a text replacement tool like AutoHotkey or TextExpander?

That’d work for my computer, but I mainly use voice input, on my Google Home and Google Assistant smartwatch. The date picker is fine for when I’m at my computer. I’ll edit my post to clarify.

UPDATE: I figured it out. I’ve changed this from a question to a Solution post.