Skip to main content

I an trying to use Pick off a Child Key but when I use the syntax as below it doesn’t work:

This is a subset of the payload

dataacontact]

{:id=>"61d8326f88d0cd60e710e5e7", :first_name=>"TEST FIRST NAME AAABB", :last_name=>"TEST LAST NAME", 

and I an adding “contact” as the key

Hi @AgriZap 

Good question.

Can you post screenshots with the format of the full data payload received by the Zap trigger?


 


@AgriZap 

Have you tried: dataacontact]


Yes - with the same result

 


@AgriZap 

You may need a Code step as Step 2 in the Zap to convert the JSON for dataacontact].

 

EXAMPLE

INPUT + CODE

 

OUTPUT

 


If I do above for a RAW hook I am required to pick from the fields available in the right hand box of Input Data - so when I do that I get this

Failed to create a run javascript in Code by Zapier

SyntaxError: Unexpected token y in JSON at position 1

 

 

This is the code

let Contact = JSON.parse(inputData.RAW); output = ={Contact}];

 

If I do it for a Catch Hook I also have to do this and choose the Contact field - I also get the same error


I actually got it to work - I had to change the format of the First Zap Webhook step


Hey @AgriZap so glad to hear this! Are you able to elaborate on the format change you made to help others that may be experiencing a similar issue? Let us know!