I'm using the rest api to query the data from an account:
Account/001234abcde and images attached to the account are stored like this:
I can see the image no problem from the browser if I'm currently authenticated in saleforce but the link does not work if I'm not authenticated and redirects me to the login page.
Is it possible to get the proper image data with the rest api without going through the above link? If not, how should images be uploaded to an account so that they can be retrieved easily using rest api?
Thanks to guy for the answer. Blob Retrieve is useful in this case. Here's the solution that I am using:
curl https://na1.salesforce.com/services/data/v20.0/sobjects/Attachment/00THEFILEID/body -H "Authorization: Bearer token"