Apex
CloudFiles Client
Get Preview URL
to get the preview url for a file, you would have to use getpreviewurls method of the client class method definition as follows global static list\<string> getpreviewurls( list\<resource> resources, previewparams params, string library, string runas ) input parameters a list of resource docid\ mr7u7qdhigoasucpf nlr a custom type previewparams previewparams has a boolean allowdownload property string library string runas output list\<string> example list\<string> previewurls = new list\<string>(); cldfs previewparams test = new cldfs previewparams(); test allowdownload = true; previewurls = cldfs client getpreviewurls( new list\<cldfs resource>{ new cldfs resource( '001xxxxxxxxxxx', 'file', 'image png', 'library', 'driveid' ) }, test, 'library', 'integrationuser' );