Events
All Event Types

File Viewed

Overview

This event is published when a file is viewed through the sharing link generated by CloudFiles in Salesforce. The file sharing link can be obtained through CloudFiles widget in salesforce. The file-viewed event type can be used to filter this event. The corresponding Get Event Details flow action returns the File Viewed sub-type with useful information including file resource, record id, email, time spent, link and download status for further use.

How to use this Event ?

To use CloudFiles Events, you must first setup your flow as shown in the Intercepting CloudFiles Events article. This article will introduce you to the concepts of the event type as well as event details that are returned by the Get Event Details flow action.

Once you are familiar with these, you will understand how to interpret & use these as illustrated in the sections below.

Document image


Event Type For Decision Filter

Please use file-viewed as the type filter when selecting this event in the decision element in flow builder.

Output Fields From Get Event Details

The corresponding Get Event Details flow action returns the File Viewed sub-type with useful information including file resource, record id, email, time spent, link and download status for further use. Refer to the image below for a list of outputs and descriptions of the parameters returned in this sub-type.

Document image

  1. Link - Link contains "url" and "id" field in the form of a list.
  2. Resource - A Resource consists of drive id, name, id, path, library and the type of file that is being viewed.
  3. downloaded - It is a boolean to indicate whether the file in view is downloaded through the link or not.
  4. TimeSpent - Amount of time (in seconds) spent on the file which has been viewed.
  5. Email - Email through which the file is viewed.
  6. RecordId - Record Id of the record to which file belongs.