Auto capitalize start of post_request

I have the following json format on my post_request which captures data from my webhook and feeds it to my system:
“first_name”: “{{steps.trigger.event.body.user_column_data[0].string_value}}”,
the trouble is that all the data coming through is all lower case and I’m hoping there’s a way in Pipe Dream where I can force the first character of each word to be upper case so instead of a first_name being posted as “john” it would be “John”.
Is this feature available somehow?
Thanks.

Hi @matthew-webfibre

First off, welcome to the Pipedream community. Happy to have you!

Yes, you can use the capitalize() method in lodash in a Node.js step to capitalize a specific word.

https://lodash.com/docs/4.17.15#capitalize

Here’s documentation on how to import NPM packages like lodash into Node.js code steps:

And how to export that transformed string from the code step for downstream steps to use:

You can watch the entire course here:

1 Like

Thank you so much!
I’ll take a look at getting this setup :slight_smile: