Apex
CloudFiles Client
Share With Community User
the share with community user action enables explicit sharing of resources with experience cloud pages or directly with users/groups via the content library widget using apex before proceeding, we assume you have reviewed the share with community user docid 30fg5 yf3wy4nckk3keei flow action global static list\<attachment> shareresources( list\<types shareresourceinput> shareresourceinputs, string library, string runas ) parameters shareresourceinputs list of types shareresourceinput docid\ b00reduo lxljoymixvsf library type of library(example sharepoint ) you can get this value from content library docid\ wtj62wux2a6hgfwvpm4ij runas runas, usually this would be a static value integrationuser return type list of attachment docid 7vdkfats tonll2jilgsg objects example list\<cldfs types shareresourceinput> shareresourceinputs = new list\<cldfs types shareresourceinput> { new cldfs types shareresourceinput( '01kehakuxvid7nmslzingkuxgq3sit75cm', 'file', '001dl00000wonj3qab', 'b!njbtpq z5uejtfrj f24xeqqlpud8vtfsg7gbcrxjepiun9bkb 7qbdptqhvd cp' ) }; list\<cldfs attachment> attachments = cldfs client shareresources( shareresourceinputs, 'sharepoint', 'integrationuser' );