Zendesk attachments download API Issue

8 Kommentare

  • Brett Bowser
    Zendesk Community Team

    Hey Hari,

    I'm going to bring this into a ticket so our Customer Advocacy team can look into this further.

    You'll receive an email shortly stating your ticket ha been created.


  • Stoyan Kerchev

    I try to download a Zendesk (attachment in comment) file from another server (java spring). I try with different libraries and web client and the result is that I am redirected to the external URL:
    My target is:

    contentUrl=https://{some host}/attachments/token/J248aV63dm57p2g6mq24eG5mj/?name=test.PDF

    The result is: 

    You are being
    <a href="https://p17.{another host}/attachment/10385409/J248a...">

    OR something like:

    sun.net.www.protocol.https.DelegateHttpsURLConnection:https://p17.{another host}/attachment/10385409/J248aV6...
    response code = 403

    For the target host, I have credentials. Requests to retrieve a ticket or comment work correctly.
    Also when I try to download the same file from Postman or Insomnia, I don't have a problem.
    The file is downloaded with a redirect to the other host. And error 403 does not appear.

    Give me advice on how I can avoid 403 on the external host.

  • Dwight Bussman
    Zendesk Team Member

    Greetings Stoyan,

    There was briefly a bug that impacted host-mapped instances of Zendesk wherein the content_url attribute contained the non-hostmapped address for the attachment. This issue should no longer be present. If you're still seeing unexpected behavior when attempting to download the attachment from the content_url, please contact our support team as documented here for a closer look.


    Dwight B. | Customer Advocate

    Zendesk Experience Research Panel

  • Chad Daley


    I'm having the same issue as above, receiving a 403 error due to a redirect that happens when I try to download attachments via the API.

    My target is:

    content_url: https:// {some host} /attachments/token/eiQfD5NA505H0HL8KvCPW8FRw/?name=Vendor+Registration+Form+%28EMEA%29.pdf

    And then I get redirected to:

    sun.net.www.protocol.https.DelegateHttpsURLConnection: https://p23. {another host} /attachment/2075089/eiQfD5NA505H0HL8...

    Server returned HTTP response code: 403

    Any help would be greatly appreciated.


  • Cheeny Aban
    Zendesk Customer Advocate

    Hi Chad,

    Our Customer Support may need to take a closer look into your account. I can see that a ticket is already created, rest assured that our team will get back to you regarding this.


  • Jim Tyminski

    I am having the exact same issue.  Downloading the content_url is producing an htm file containing the same redirect as above.  Please help!  Thanks!

  • Stoyan Kerchev

    A change of the REST client worked for me.

    Try testing with other clients available in the language you write in and see if it can explicitly configure the client with something similar to:

  • Jim Tyminski

    Cheeny Aban Any info on this?  It's a real problem and needs a solution, please.


Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.

Powered by Zendesk