Hi Team,
Am using webhook to invoke my API, Input JSON contains many token values (default - edit me). But these default tokens are not replaced with null value. No issues with brackets.
Thanks.
Hi Team,
Kindly find the details below,
Webhook request type is JSON, it contains default value as "edit me" for all the token. The webhook was working fine till 2nd Aug 2019 but from 3rd Aug2019 we faced issue in JSON as edit me are not replace as null.
Existing working json contains double code for token values, after the edit me issue tried both with/without double quote request. Still null is not replaced in both the cases.
Sample JSON request:
PersonId={{lead.Id:default=edit me}}&emailaddress="{{lead.Email Address:default=edit me}}"&FirstName="{{lead.First Name:default=edit me}}"&LastName= "{{lead.Last Name:default=edit me}}"
Sample webhook output request:
PersonId=123&emailaddress="abc@gmail.com"&FirstName="edit me"&LastName= "edit me"&FullName= ""&Company= "edit me"
Thanks.
That's not JSON.
It's form-URL-encoded with -- and this is very unusual, and generally wrong unless you've built a non-standard back end -- double-quoted values.
In any case, I'm not understanding your complaint. The output you show is exactly what you should expect if values are empty and you have included a default.
Thanks Sanford. Apologies for type, actually request type was Post, response type is JSON & request token encoding is Form-Url.
OK, while that describes the encoding more accurately, I still don't understand what you expect. {{some.token:default=edit me]} is designed to output the string "edit me" as a fallback.
While inserting token in template field, we are leaving default value as empty, it automatically set "edit me" as default value in template. Till august we didn't face this edit me issue, the empty value are returned from webhook as empty. but from 3rd Aug only we are getting this edit me value from market webhook.
The correct behavior is to show the fallback string. If you don't want the fallback, don't include it.
For as long as I can remember, inserting the token from the dropdown includes the fallback, so you have to delete it. This didn't start recently.
Hi Sanford,
To clarify, if I want to send an SMS that reads "Hi {{lead.First Name}}, blah blah blah" OR "Hi, blah blah blah"
and our webhook call reads;
username=[redacted]&password=[redacted]&builderid=1164&PhoneNumber={{lead.Mobile Phone Number}}&PhoneMessage=Hi%20{{lead.First Name:default=friend,}}%20{{my.SMS Message}}&lookup_value={{lead.ID}}&mask=0419114341&method=mt
Do I edit the {{lead.First Name:default=friend,}} script to remove the default=friend?
*side note: I have been informed by our webhook receiving agency to URL encode everything, so there are no format issues.
Yes, you would go back and edit the inserted token.
Hi,
so I ran a test through an email, which mirrors tha same function as the SMS. It looks like: Hi {{lead.First Name}}, and hits the inbox like: Hi ,
Is there a way to avoid that space while using first name token? Ideal output: an SMS that reads either Hi Sanford, OR, Hi,