Zendesk Support placeholders reference Follow

Comments

79 comments

  • Avatar
    Sarah Sanders

    I'd like to control the output text when using the "satisfaction.positive_rating_url" placeholder.

    I know that you can control normal link content by formatting it like this:

    [Text you see](URL link)

    This doesn't work with the placeholder. Is there a way to accomplish this?

  • Avatar
    Nick Haines

    Hey Thor,

    Can you check to confirm that the "Subject" ticket field is set as "visible" for your End-Users? If it's not visible it'll default to using the first part of the ticket comment.

  • Avatar
    Charles Wood

    Please tell me there is a way to get the "received_at" into a trigger's payload. I don't see a placeholder.

  • Avatar
    Steve Lacey

    I attempted to hack away the comment timezone problem with the following Liquid, it's based on the assumption that comment created_at is recorded in the same timezone that ticket was – which I'm 98% sure isn't true (see https://support.zendesk.com/hc/en-us/community/posts/203413956-Timezone-information-for-Ticket-comments) but it seems to work in my experiments at least.

    {% capture offset %}
        {% assign offset_neg = ticket.created_at_with_timestamp | split: '-' | last %}
        {% assign offset_pos = ticket.created_at_with_timestamp | split: '+' | last %}
        {% if offset_neg contains 'T' %}
            +{{ offset_pos }}
        {% else %}
            -{{ offset_neg }}
        {% endif %}
    {% endcapture %}

    {% assign offset = offset | strip_newlines | replace: ' ', '' %}

    "created_at": "{{ comment.created_at_with_time | date: "%Y-%m-%dT%H:%M:%S" }}{{ offset }}"

  • Avatar
    Justin Graves (Edited )

    Fellow Zendeskers - I just posted a request to try to address some of the same needs as many users have stated in the comments here- namely how to format only a portion (in my case the message section) of an otherwise "unformatted" email template. I used your post here as an example of another Zendesk users with a similar need. I'm trying to drum up support to get the Zendesk developers moving on this idea so I'd like to have you look at my post and give it a thumbs up and leave a comment there so we can bolster the case and show the need for these features.

    Please take a look:

    https://support.zendesk.com/hc/en-us/community/posts/220847487-Add-a-placeholder-for-formatted-comment-values-maybe-comment-value-formatted-

  • Avatar
    Arnold Sanchez (Edited )

    would be great to have a placeholder that showed you, in a trigger based email, what the update to a ticket is as you see it in "show all events" - the most recent event(s).

  • Avatar
    it.konton

    Dont know if this has been mention but is there a placeholder to get access to visitor notes through Chat message?

  • Avatar
    Joel Hellman

    I had a support ticket about the Formatted comment data recently, and just wanted to clarify, if any one else tries this, that the formatted comment data objects - like ticket.comments_formatted - has no properties, so you cannot iterate or query it's properties with liquid markup, as you can with the comment data object like ticket.comments.

  • Avatar
    Andrew J

    Hello Mindaugas,

     

    Yes, though to display this effectively you need a bit of code... try modifying the following to suit your application.

     

    **CCs on this request:** {% if ticket.cc_names != empty %}

    {% capture ccedusers %}

    {% for cc in ticket.ccs %}
    {% unless forloop.last %}
    {{ cc.email | append: ', ' }}
    {% else %}
    {{ cc.email }}
    {% endunless %}
    {% endfor %}

    {% endcapture %}

    {{ ccedusers | strip_newlines }}

    {% else %}

    No CCs on this request

    {% endif %}
  • Avatar
    Thor

    Strange problem we cant solve... I have this in our "comment update" trigger:

    {{ticket.account}}: Ticket ({{ticket.id}}) Re: {{ticket.title}}

    For some reason in the subject line that customers receive from us, it puts the following:

    (Company name), (Ticket number), which is fine, but then it places the subject line and the body of the message all in the subject line, until the character limit is reached and it cuts it off.

    If I remove this from the subject line on that same trigger: Re: {{ticket.title}} it stops putting the subject and the body.

    Why is it not just putting the ticket title? Why is it also adding the whole body of the email in the subject line?

  • Avatar
    Tom Pagut

    {{ticket.latest_public_comment_formatted}} and {{ticket.public_comments_formatted} do not actually copy the formatting! My hyperlinks do not copy, spaces and paragraph breaks are removed and images do not appear inline. 

    I would like the follow-up messages created with this macro to be formatted exactly as I sent the original including links, images, and spacing.

    I have an open support ticket with Zendesk about this but I was wondering if anyone else has run into this problem?

  • Avatar
    Graeme Carmichael

    Elizabeth

    We can have some fun with Liquid to create a help centre link.

    Try this in a macro:

    • {{ticket.url | split:'/' | first }}/hc/
  • Avatar
    Rasmus Gregers Sørensen

    Are there any NPS placeholders?

  • Avatar
    Dinesh Korgaokar

    ticket.comments_formatted this placeholder hides the email address in the footer ticket details.

  • Avatar
    Ed Ball (Edited )

    Is there a placeholder for the Brand? We have been looking for one with no success. If the ticket has a brand and tickets come in with a brand, wouldn't there be a placeholder somewhere for it?

    Nevermind.. {{ticket.brand}}

  • Avatar
    Charles Wood

    It would be very helpful to get an enumeration of the various strings returned by "ticket.via".

    Also, it appears that an update from the agent interface returns the same "via" as an update from the API, making them indistinguishable in a trigger.

  • Avatar
    Michael Bialek

    Hi everybody!

     

    Is it possible to include a placeholder that displays the last public reply not from the requester of the original ticket?

     

    Thanks!

     

    Mike

  • Avatar
    Drew Wasson

    Is there a way to see historical events in a PlaceHolder?  For example, I send a mail when a certain type of ticket changes assignee.

    I know that it changed, and I can identify the new (current) assignee.  I'd like a way for the email I send to contain the previous ticket assignee.

     

    Thanks!

  • Avatar
    Tom H.

    It would be great if there was a way to create a placeholder for the cursor in text boxes. So, if I have a template the cursor will be placed in the right location to continue typing your reply. This would be useful, for example, with this type of simple macro...

    Hi {{ticket.requester.first_name}},

    {{cursor}}

    If you have any further questions please reply to this email, thanks.

    The above would place the cursor between the two lines of text so I can just start typing without having to move the cursor to the right location first. This would be especially useful with the Zendesk smartphone app. Also, it seems that the macros collapse more than two line-feeds into one, so, I also have to add extra line feeds into the template to separate the top and bottom line.

  • Avatar
    Jason Littrell

    In my Zendesk account, the "ticket.requester" placeholders are defaulting to the submitter's info on new tickets if the requester field hasn't been populated. For example, if I select a macro that uses the {{ticket.requester.first_name}} placeholder and I haven't populated the requester, the comment text will show "Jason". Is this happening with anyone else?

  • Avatar
    Samus (Edited )

    Not sure if the following information is correct.. I'm able to get attachments using ticket.latest_comment.attachments and unable to see them using ticket.latest_comment_formatted.attachments. I'm using this placeholder in a trigger json body.

    ticket.latest_comment The most recent comment (both public and private). Unformatted text. Does not include attachments. To return attachments, use ticket.latest_comment_formatted.
  • Hi!

    I'm trying to use satisfaction.rating_url, but it is not showing on the comment available placeholders... How do I use it on Macros?



  • Avatar
    Mike Edmonds (Edited )

    We use the ticketing system from a 3rd party application. We have fields like "source", "identifier", and "description". Is there a way to parse the values of these into a macro?

     

    Source : pem:1/1
    Identifier : null
    Raise Time : 2016-05-08T10:31:46.000Z
    Clear Time : null
    Description : Environment temperature above high threshold

  • Avatar
    Mark Hurty

    We created a macro to prepend ticket titles (subject) with {{ticket.group}}. It works as expected when applying that macro one ticket at a time. But when I applied the macro to a batch of tickets using the batch editing interface, the ticket is displayed as expected for agents (views show the title with the group name at the beginning) but our end users see the liquid string, not the name of the group. 

    Agents see:

    [SAT] Title of the ticket

    End users see:

    [{{ticket.group}}] Title of the ticket

    If I manually edit the title, removing the group name and then re-apply the macro to that ticket, everything works as expected.

    I am wondering if anyone has suggestions that would save me from having to manually re-edit every single ticket to resolve this issue?

    Thanks.

     

  • Avatar
    Jesus

    Good morning, 

    We are having problems with placeholder. Concretely with:

    ticket.latest_comment

    ticket.latest_comment_formatted

    Both placeholders don't return private message to our Agents (bug?). It would be helpful to have this information available.

    Regards, 

    Thanks.

  • Avatar
    Boris

    Earlier, {{target.cc}} was working even if CC was added during the current session of ticket editing. At present, it works only with CCs that have been added to the ticket before the current session. Which is not very convenient when using automation and adding CC during the same edit session.

    Please advise.

  • Avatar
    Piotr Szlazak

    @Travis:

    Can you try {{ ticket.requester.first_name | strip }} ?
    Check https://github.com/Shopify/liquid/wiki/Liquid-for-Designers for full guide.

    Regards,
    Piotr

  • Avatar
    Donato Dileo

    Hi all,

     

    I need you help for a request

    Basically I'm using Link Ticket App in the market place

    I need to set-up a target extention based on a HTTP URL

    https://mysite.zendesk.com/api/v2/tickets/{{ticket.ticket_field_12345678}}.json

    The problem is that in the ticket field {{ticket.ticket_field_12345678}} I've a string composed by "child_of:XY" where XY is the ticket number

    so Basically I need a trick in order to remove "child_of:" for the customer field during call JSON in order to have a right call and to have only the ticket number

    Is something that we can do? I hope that my question makes sense

    Thanks to all for any help

    D.

  • Avatar
    Manuel Nieto

    How about placeholder for submitter's location, country, IP?

     

  • Avatar
    Greg

    Thanks for catching that, Charles! I'll request an update to the article to fix this!

Please sign in to leave a comment.

Powered by Zendesk