Using Query Strings in a webhook POST URL inside of a workflow


#1

Hello, I am trying to send dynamic contact data into a Webhook URL when a new contact gets added into the system. I am trying to use an API that they have provided to send data to their Salesforce CRM. Here is an example of what I have now:

http://exampleurl.com/d.ashx?&ckm_key=123123&first_name={{contact.firstname}}&last_name={{contact.lastname}}&email_address={{contact.email}}&desired_loan_amount={{contact.amount_requested}}&monthly_processing_volume={{contact.monthly_revenue}}&time_in_business={{contact.time_in_business}}

When I POST to it without any Hubspot values/Query strings in it, it posts with blank data. However, when I try to enter the URL in the workflow with query strings, Hubspot says that the Webhook URL is no longer valid.

Would something like this be possible?

Thank you,
Alex


#2

@AlexW You can’t use contact tokens inside the webhook. You can hard type in values for your query parameters if maybe they filled out a specific form for example. When the webhook is triggered you would see all of the contact information in the body of the POST call anyways so you shouldn’t have to put them into the query string.


#3

@pmanca Oh I see, could I see an example of what you mean by filling out values? Would the link look something like this: http://exampleurl.com/d.ashx?&ckm_key=123123&first_name=firstname

Using the internal values of the contact property?


#4

@AlexW RIght you can fill them in your self

http://exampleurl.com/d.ashx?&ckm_key=123123&first_name=Peter

this is more common for categories like

http://exampleurl.com/d.ashx?&ckm_key=123123&event_Type=form_submission


#5

@pmanca Right, but I want to take the data (such as first name and last name) from the contact that was enrolled in the workflow, and put it directly into the URL


#6

@AlexW You cannot do that within the HS workflow tool at the moment. You will have to pull that information from the body of the webhook.


#7

Yes I'm facing same type of issues. can you please reply on that


#8

Please send Any Examples related this.


#9

Hi @saurabh442,

This isn't currently possible with workflow webhooks. The contact JSON is included in the POST body of the webhook request, but it's not possible to further configure the request at this time.