Using Liquid Markup to A/B Test Your Triggers

14 Comments

  • Chris Stock
    Comment actions Permalink

    This is great - thanks for sharing Lance!

    1
  • Brett - Community Manager
    Comment actions Permalink

    I agree with Chris! This is awesome :)

    Thanks Lance!

    0
  • McCabe Tonna
    Comment actions Permalink

    I agree with everyone above - this is great

    1
  • McCabe Tonna
    Comment actions Permalink

    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
    Comment actions Permalink

    Excellent Write up Lance!

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

    1
  • Heather Rommel
    Comment actions Permalink

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

    0
  • Ash Divay
    Comment actions Permalink

    Hello,

     

    I am getting the following issue. can someone help ?

     

     

    0
  • Lance Conzett
    Comment actions Permalink

    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
    Comment actions Permalink

    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
    Comment actions Permalink

    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
    Comment actions Permalink

    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
    Comment actions Permalink

    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
    Comment actions Permalink

    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
    Comment actions Permalink

    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