0

I have the following use case

Opportunity O has five attachments namely (A1,A2,A3,A4,A5). Each of these attachments are to be sent to different external REST webservices.

In my experience previously, I have integrated object data via JSON deserializing/serializing and sending it to endpoints via HTTP calls.

But I am not sure how to send a file to an external webservice.

Is this even possible ?

1 Answer 1

1

Use the SObject Blob Retrieve resource to retrieve blob data for a given record.

The following example retrieves the blob data for an Attachment record. The Attachment can be associated with a Case, Campaign, or other object that allows attachments.

Example for retrieving blob body for an Attachment record

curl https://na1.salesforce.com/services/data/v20.0/sobjects/Attachment/001D000000INjVe/body -H "Authorization: Bearer token"

Attachment body content is returned in binary form. Note that the response content type will not be JSON or XML since the returned data is binary.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .