Skip to main content

Hi All,

I am trying to work on the request data in a downstream Python code zapier snippet. In the payload of webhook trigger, json comes as

{“K1”:”V1”, “K2”:{“K21”: “V2”, “K22”, “V3”}}.

Want to work on the entire value of key “K2” of payload, that is 

{“K21”: “V2”, “K22”, “V3”}

. But in the input data of ‘Setup action part’ in ‘Python code action’ there is no option for “K2”, the options are “K2 K21”, “K2 K22”. How to solve this.

 

Attaching screenshots for reference

Request data
Python code action

 

@paertools 

Try changing your trigger wehbook to a Catch RAW hook

Catch Hook Raw is unparsed data from the trigger app VS Catch Hook is parsed data from the trigger app. You can find more webhook help here: https://zapier.com/apps/webhook/help 

Once Zapier parses JSON its hard to rebuild it. There are two ways i’ve found you can rebuild raw json. 

1. Use an empty POST request step after the step you want to rebuild and send it to a catch raw hook trigger. This way works very well but sends it to another zap. 

2. Simple JSON structures (not nested arrays) can be rebuilt using a formatter step: