Apex
CloudFiles Client

Create Attachments

This method can be used to create attachments using Apex.

Apex


Parameters

  1. attachmentInputs- List of Types.CreateAttachmentInput
  2. library- Type of library. Example - sharepoint. You can get this value from Content Library
  3. runAs - Email Id of the user on whom behalf the function should run. If you want to run the action as automation user, supply integrationUser

Return Type

List of Attachment objects

Example

To link a folder in SharePoint to a salesforce record

Apex