Getting ticket attachment links from a webhook.

4 댓글

  • Greg Katechis
    Zendesk Developer Advocacy

    Hi Roar! If you're looking for the content_url, you'll want to use the ticket comments API and you'll see this returned in the payload:

    {
      "attachments": [
        {
          "content_type": "text/plain",
          "content_url": "https://company.zendesk.com/attachments/crash.log",
          "file_name": "crash.log",
          "id": 498483,
          "size": 2532,
          "thumbnails": []
        }
    ]...}
    0
  • Roar Amundsen

    Thanks for the reply.

    I tried that but it seems the webhook doesn`t see the formatting of the endpoint as valid yet.
    e.g I`ve tried:
    https://xxxx.zendesk.com/api/v2/tickets/ticket_id/{{comments}}.json
    https://xxxx.zendesk.com/api/v2/tickets/{ticket_id}/comments
    etc

    If I can point to the comment API, it would be great to have some pointers on how we should structure the json command to list the content_url. 

     

     

     

    0
  • Frederic D'hartoy

    Hi,

    I have the same request as Roar. I would like to send the url attachment file to an external ticketing system.

    How can I get the "content_url" for the attachments listed as a part of a ticket comment and send it ?

    How to I post the attachment url and wich endpoint do I use for the webhook? 

    Thank you in advance for your answer

    Frédéric d'Hartoy

    0
  • Tipene Hughes
    Zendesk Developer Advocacy

    Hey Frederic D'hartoy,

    Just to be sure I'm giving you the optimal solution here, can you explain your ideal workflow in a bit more detail? Webhooks are generally used as a way to send requests to external systems in response to activity on a ticket(s). If you're just wanting to gather data on a batch of tickets and send this to an external system, there are likely more suitable ways to do this instead of using webhooks.

    Look forward to hearing from you!

    Tipene

    0

댓글을 남기려면 로그인하세요.

Zendesk 제공