Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.

ConnectApi.BinaryInput

Create a ConnectApi.BinaryInput object to attach files to feed items and comments, to add repository files, to create managed content, and to replace managed content variants.

The constructor is:

1ConnectApi.BinaryInput(blob, contentType, filename)

The constructor takes these arguments:

Argument Type Description Available Version
blob Blob Contents of the file to be used for input 28.0
contentType String MIME type description of the content, such as image/jpg 28.0
filename String File name with the file extension, such as UserPhoto.jpg 28.0