Using Liquid Markup to A/B Test Your Triggers

14 Comments

  • Chris Stock
    Community Moderator

    This is great - thanks for sharing Lance!

    2
  • Brett Bowser
    Zendesk Community Team

    I agree with Chris! This is awesome :)

    Thanks Lance!

    1
  • McCabe Tonna
    Community Moderator

    I agree with everyone above - this is great

    1
  • McCabe Tonna
    Community Moderator

    I'm getting a

    {"error":"Unprocessable Entity","message":"Server could not parse JSON"}

     

    Any insight?

     

    also it's an HTTP target not HTML target.. i assume thats correct

    1
  • Kaloyan Todorov

    Excellent Write up Lance!

    Not only about the clever tip but also of your writing style and engaging information delivery.

    2
  • Heather Rommel
    Community Moderator

    I can't wait to try this. Fantastic tip!

    0
  • Ash Divay

    Hello,

     

    I am getting the following issue. can someone help ?

     

     

    0
  • Lance Conzett

    Ash Divay Good question! You can ignore that error message, the JSON target is trying to validate your code as JavaScript rather than Liquid. As long as the JavaScript between the {% when %} lines is valid, you're good.

    2
  • Chris DiGiacomo

    Lance Conzett

    I'm having some trouble getting this to add additional tags.

     

    When creating the HTTP target, I replace subdomain with my own subdomain, correct?
    https://subdomain.zendesk.com/api/v2/tickets/update_many.json?ids={{ticket.id}}


    It may be that I am not enabling basic authentication - is that required?


    0
  • Lance Conzett

    Chris DiGiacomo Yes, you'll replace the subdomain with your own ZD subdomain. And you do need to enable auth and enter your username and password in order to pass an API call to Zendesk that updates a ticket.

    0
  • Chris DiGiacomo

    Thank you Lance Conzett

    I enabled auth - how will I know that the API call is passed? Will successful sends update on the extensions page?

    I'm still not getting additional tags on created tickets. Maybe it is because I'm using google connector to authenticate?

    0
  • Ash Divay

    Lance Conzett - Thanks for this great info, But now i seem to be having the same issue as McCabe Tonna above.

    See his post here

     

    Thanks

    Ash

     

    0
  • Lance Conzett

    Ash Divay McCabe Tonna Sounds like you might have some special characters in your JSON body. That's particularly common when using something like Notepad that changes your quotation marks to curly quotes (rather than straight quotes).

    I'd recommend reviewing the characters in your JSON and adjusting as needed.

    1
  • Arthur Mori

    Lance Conzett is correct, the Unprocessable Entity error was caused by a malformed JSON. It seems the copy and pasting of the JSON example from this article replaced the quotation marks with 

    instead of

    "
    0

Please sign in to leave a comment.

Powered by Zendesk