Best answer

Cannot Send Variables To Twilio With Webhook

  • 24 January 2024
  • 18 replies
  • 116 views

Userlevel 1

I’m trying to setup a zap that takes information from a Google Sheet and then sends that to Twilio for the data to be referenced in a studio flow. The webhook successfully makes a call, but when on the call, none of the variables such as doctor or attorney are included.

 

Does anyone know how I can fix this? I’ve looked at about 15 guides and just can’t get it.

 

Also, the weird formatting on “Doctor”, “Attorney”, and “Address” is from another community post. I have tried the zap without those pieces surrounding the variable and gotten the same result. 

 

icon

Best answer by Troy Tessalone 25 January 2024, 18:42

View original

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

18 replies

Userlevel 7
Badge +14

Hi @ColinHickmon 

Check out this related topic that might provide guidance:

 

Try with just the mapped variable for each key value. (remove the other JSON)

 

Userlevel 1

I appreciate it! That guide was actually part of what helped me originally get this setup.

 

My issue though is that the variables are not being received, not that calls aren’t being made. The zap will trigger a call perfectly fine, it’s just not sending the other stuff.

Userlevel 7
Badge +14

@ColinHickmon 

Did you try this?

Try with just the mapped variable for each key value. (remove the other JSON)

 

Userlevel 1

Yeah I have and still couldn’t get it.

Userlevel 7
Badge +14

@ColinHickmon 

Check these Twilio resources:

https://www.twilio.com/docs/studio/rest-api/v2/execution

 

You likely will have to use a Custom Request (POST) so you can configure JSON.

 

{
"to": "+15558675310",
"from": "+15017122661",
"parameters": {
"name": "Zeke"
}
}

 

 

Userlevel 1

Will try that out later today. Appreciate your help!

Userlevel 7
Badge +14

@ColinHickmon 

You can validate the format of your JSON with this tool: https://jsonlint.com/

Userlevel 1

I keep getting this error when trying to run the custom webhoook:

 

Failed to create a request in Webhooks by Zapier

Missing required parameter To in the post body (HTTP Status Code: 400)

 

Here’s the data:

 

Userlevel 7
Badge +14

@ColinHickmon

Did you validate the JSON?

You can validate the format of your JSON with this tool: https://jsonlint.com/

 

You need to have commas after the first 2 parameters. (example)

{
"To": "+15558675310",
"From": "+15017122661",
"Parameters": {
"name": "value",
"email": "value",
"phone": "value"
}
}

 

Userlevel 1

Just checked and it says valid after adding the commas.

 

Still receiving the same error though.

Userlevel 7
Badge +14

@ColinHickmon 

Can you post an updated screenshots with how your full Zap step is configured?

Userlevel 7
Badge +14

@ColinHickmon

Also, try changing all the keys to be lower case or proper case.

 

To

From

Parameters

 

vs

 

to

from

parameters

Userlevel 1

Tried that one already and it didn’t fix it. Here’s the full flow. Very basic.

 

Userlevel 7
Badge +14

@ColinHickmon 

This still shows a mismatch in capitalization across the parameters.

Try changing parameters to Paramaters.

 

Userlevel 1

Fixed the capitalization error after the screenshot. Still not working 

Userlevel 7
Badge +14

@ColinHickmon 

I got this to work.

Use the regular POST. (not via Custom Request)

Configure your Parameters like this.

 

{"doctor": "value","address": "value","attorney": "value"}

 

 

 

Userlevel 1

YOU’RE THE MAN, TROY!!!!

Thanks so much for your help. Zapier better be paying you for all this lol

Userlevel 7
Badge +14

@ColinHickmon 

I’m just a Certified Zapier Expert, not a Zapier employee!