Using JSON Parser to Handle Keys With Periods

Recently, while building a recipe in Workato with an HTTP connector, I encountered JSON keys containing periods. This setup led to errors with invalid datapills. While the recipe ran, it generated empty data, creating blank rows instead of useful records.

Screenshot of Workato datapill warnings 'Please replace invalid datapill(s) for two input boxes

Initial Workaround: Hardcoding Keys

Using a ‘for each’ action, I could manually hardcode keys in formula mode:

Example of hardcoded keys in Workato formula mode

However, this solution didn’t support bulk actions, so I sought an alternative with Workato support.

The Solution: JSON Parser

Workato Support suggested using the JSON Parser with a modified JSON structure:

[Response | Step 4].to_s().gsub('.','').gsub('=>',':').gsub('nil','null')
JSON parser settings in Workato

With this setup, I could access bulk actions by taking the parsed response directly from the JSON parser step.