1

I'm trying to use https://[domain]/sfc/servlet.shepherd/version/download/ to download files (lightning files not attachments) from salesforce and it works sometimes and I can get it to work in postman be in some cases it returns a 200 status but the contents are the following:

"https://[domain]/ex/errorduringprocessing.jsp"

The weird thing is that I can produce this error in postman if I leave it for a while and try to execute the request without getting a new token so it seems to be related to the tokens somehow. Does anyone know why this might happen?

1

To get a blob (binary data), you can use the SObject Blob Retrieve rest API call. This would be the preferred mechanism for doing so. The other URI is meant for UI downloads, not API calls.

  • That's what I was looking for :) thanks! – Scott Morrison Apr 10 at 15:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.