I can get the current phonetic month when doing a simple new Date() but for some reason when I try to reference data sent in a webhook, it doesn’t return any data… any thoughts on what’s going on here? The data being sent by the webhook is an ISO date as a string.
Hey @pford, just tried out the code that you shared and it works correctly for me. Could you perhaps share some more information about how you are sending input to the webhook and the value that you are passing?
Here’s my workflow in case it is helpful for you to debug
And here’s the GET request that I made using my browser: http://localhost:5678/webhook-test/04b7a852-cc78-4d85-b4bc-b83140634306?date=2011-09-05T14:48:00.000Z (might need edits depending on your workflow/how you are running n8n).
Thanks for testing this for me! I also was able to do it with this version of the ISO timestamp but for some reason the service I’m using is sending the ISO as this: "date": "2021-12-19T23:24:30 00:00" instead of the correct format and I think that may be the issue. I know I can use the Date & Time node to convert this, but I’m not sure what the format specifiers should be to correct the final format that is put into the Function node.