Agent file sharing enables agents and bots to share files with consumers. At this phase, photos and certain file types can be shared via Web Messaging, Apple Messages for Business, and WhatsApp Business. In the future, more file formats will be supported.
Agents will now be able to share files with consumers to answer questions that can be better explained using images. For example, a screenshot for tech support or a product photo for sales uses cases.
Agents can share:
- Photos: Reference photos or photos of any product to visually guide consumers with product awareness, steps on how to use the product, or review comments of a product. They can also share photos in a resolved conversation to resume the conversation with the consumer. Consumers can tap on the photo to view it full screen or share it through the default app on their device.
- Files: Agents can also share files to provide consumers with information such as mortgage documents, product catalog, or transaction details as requested by consumers. The agent can also share files in a resolved conversation to resume the conversation with the consumer. Consumers can download files through the picker application to a location on their device (internal or external).
The iOS SDK supports previewing all the supported file types on the device as per the iOS operating system by double-clicking on the thumbnail image.
When the agent shares any supported file type from LiveEngage, if the consumer isn't within the conversation view, they get a notification from the customer app only if the push notification is enabled. Otherwise, when the consumer returns to the conversation screen, a thumbnail for the photo or file appears in the conversation window.
Supported formats
- PNG
- JPG/JPEG
- GIF (non-animated) — previewed as a static image only
- PDF
- DOCX
- PPTX
- XLSX
Photo and file sizes
- Thumbnail — 30 KB (base64-encoded)
- SDKs prior to v3.8: The max upload size allowed is 3 MB.
Notes and limitations
- For SDKs prior to v4.1: File sharing is one-way only (from agent-to-consumer, but not vice versa) and available for the Mobile Message SDK only.For SDKs prior to v3.8: Photo sharing is one-way only (from consumer-to-agent, but not vice versa) and available for the Mobile Message SDK only.
- If an attempt to view a photo or file is unsuccessful, an error icon covers the thumbnail. Upon retry, the file attempts to download again. Retry can be attempted as many times as possible (in case of a poor network) until the file is downloaded successfully.
- The consumer can return to a resolved conversation to view the photos, as long as the photos are part of the conversation history.
- If an agent sends an unsupported file, a message displays indicating the file type shared with the consumer is not supported, and the agent should retry sending a supported file format. On the consumer side, they see an empty message with no content.
- For authenticated users, backgrounding the app while loading the photo does not get interrupted.
- For unauthenticated sessions, consumers must tap the photo again with each visit because the history gets cleared when a session expires or logs the consumer out.
Enabling the feature
To enable “Agent file sharing” capability on your LivePerson Conversational Cloud account, please contact your LivePerson account team.
Night Vision setting
To enable the agent file sharing capability, brands have to enable the feature via Night Vision. Click on the Night Vision icon in the top right corner (the blue icon). From there, Go to the visitor's tab > Agent Workspace configuration > File Sharing:
Click on file sharing and enable the feature:
Consumer-side configuration
To display the attachment icon in the consumer window, select the ‘Menu elements’ dropdown in the Engagement window studio, and check the box that says ‘Send image' (Messaging only). The campaign must be republished for the icon to be displayed.
Permissions
The agent file sharing capability is permission-based. New permissions have been added to both agent and agent manager profiles: “Send files to consumers from the local file browser.”
The permission is off by default. Additional permissions have been added as well in regards to custom widgets. This permission is covered more in-depth below.
Using file sharing
A new attachment icon has been added above the agent’s input message area:
The icon will be visible only to users with the appropriate permission.
If the channel from which the conversation was initiated does not support receiving files, the icon will be greyed out and will not be clickable. In this phase, the icon will be visible only in Web Messaging conversations.
Clicking on the attachment icon will open the agent local file browser dialog:
The list of files presented will be filtered to present only supported file types (“Custom files”): JPEG, JPG, PNG, GIF, PDF, DOCx, XLSx, and PPTx.
When the agent chooses a photo, a preview of the photo will be presented and the agent will be able to add a caption and send the photo.
The file will appear in the transcript:
There is no preview available for files, only photos.
Agents will be able to download the file from the transcript.
Once clicking on the file it will be opened in full-page mode:
Agents will be able to keep writing in the input area while the file browser dialog is open and navigate to other conversations. While the image is being loaded, the agent will be able to send additional messages. They will also be able to move to another conversation window while the loading process continues.
The consumer will receive the file as part of the conversation. When the consumer clicks on the file, it will pop up for a full-screen view.
File storage, retention, and encryption
- Files are hosted by LivePerson.
- Files will undergo sanitation by LivePerson (to check they are not malicious).
- Files retention is set to 13 months.
- GDPR: Files will be deleted from LivePerson’s storage in case of consumer’s right-to-be-forgotten request.
- Files are encrypted at rest.
This solution is not PCI compliance certified.
File Sanitation
When uploading or when receiving a file, it will be processed by a service called "MetaDefender" for sanitation. MetaDefender accomplishes various functions:
Prevent Attacks without Relying on Detection
MetaDefender deep content disarm and reconstruction capabilities do not rely on detection. The service assumes all files could be infected and rebuilds their content using a secure and efficient process. It guarantees the output of safe and usable files by rebuilding a new file from scratch and discarding the original. Deep content disarms and reconstruction (Deep CDR) is extremely effective in preventing targeted attacks, ransomware, and other types of known and unknown malware threats.
Highest Threat Detection with Multiscanning
MetaDefender multiscanning uses multiple anti-malware engines to provide superior detection rates of known and unknown threats and delivers extremely fast malware outbreak prevention. MetaDefender customers can simultaneously leverage the combined threat prevention capabilities to query more than 30 anti-malware engines using both signature heuristic scanning and machine learning capabilities.
Detect Vulnerable Software Before Installation
All applications contain vulnerabilities of different degrees of severity that threat actors can exploit. Our file-based vulnerability assessment of binaries and installers detects known vulnerabilities within files and application vulnerabilities in software programs before they are installed on endpoint devices, including IoT devices. MetaDefender supports vulnerability detection for over 1 million files and over 20,000 applications.
Photo resizing
Before uploading a photo, it will be resized so that the longer dimension of the image will be set to 800 pixels.
To set a different pixels value, please contact your LivePerson account team.
APIs
Agent Custom Widget SDK
A new ‘Send File’ command has been added to the Agent Custom Widget SDK, allowing brands to send files to consumers. The file needs to be provided as a File object or Blob object.
Once the command is sent, the preview of the file will be displayed, allowing the agent to add a caption, send, or cancel.
For this to be enabled, the user must have the following privileges enabled:
“Send files to consumers from custom widgets” (off by default)
Agent Node SDK
Bots will have the capability to send files as well. For further details and examples, please visit the Agent Node SDK Git repo: File Sharing Bot
Limitations and clarifications
- Supported file types: JPEG, JPG, PNG, GIF, PDF, DOCx, XLSx, PPTx.
- The capability is currently supported only on Web Messaging, Apple Messages for Business, and WhatsApp Business.
- The file size will be limited to 5MB.
- Authenticated consumers who receive a file from an agent over the web will see an empty line in the native app if the file was sent without a caption or only the caption.
Web experience:
App experience:
- The permissions to use the feature will be presented once the feature has been enabled by the account team. However, the feature will only be usable after it has been turned on in the account settings.
- If a conversation was resumed and then closed, file sharing will be disabled as a way to resume the conversation again (the agent will not be able to send a file to the conversation).
- Custom widgets cannot send a file as a way to resume a conversation.
- Animated gifs are not supported (will be sent as a static gif).
How photo and file sharing works
Step 1. Set app permissions
- Set photo library privacy settings:
- Key: NSPhotoLibraryUsageDescription
- Value: "A message that tells the user why the app is requesting access to the user's photo library."
- Supported on iOS 11 and newer. Use if not sharing photos from consumer to agent.
- Important: The user must explicitly grant permission for your app to access Photos. Prepare your app for this requirement by providing justification strings. The justification string is a localizable message that you add to your app's Info.plist file to tell the user why your app needs access to the user's photo library. For more details, see Requesting Authorization to Access Photos.
- Set camera privacy settings:
- Key: NSCameraUsageDescription
- Value: "Camera Privacy Setting for Conversational Cloud Mobile App Messaging SDK for iOS"
- iOS supports the preview of file types per iOS operating system and requires some configurations to be enabled within the Host App's plist file. Enabling supports file sharing, and the export and saving of photos.
- Key: UIFileSharingEnabled: Application supports iTunes file sharing
- Value: YES
- Key: LSSupportsOpeningDocumentsInPlace: Supports opening documents in place
- If this functionality is important to your user flow, enable at the user's risk. If you enable this setting, the consumer can save documents or photos to a directory belonging to the host app. However, we recommend not enabling this feature due to a current limitation within the LivePerson SDK, the SQL files are also made public if this setting is enabled.
Step 2. Enable or disable flags within the SDK's LPConfig.swift for file and photo sharing.
Update the boolean value for file/photo sharing feature from agents to consumers to desired setting:
LPConfig.defaultConfiguration.fileSharingFromAgent
By default, the value is set to true.
Update the boolean value for file/photo sharing feature from consumers to agents to desired setting:
LPConfig.defaultConfiguration.fileSharingFromConsumer
By default, the value is set to false.
Contact your Account Team to have the features enabled on your account.
Step 3. Change the settings
- // photosLPConfig.defaultConfiguration.maxNumberOfSavedFilesOnDisk// document filesLPConfig.defaultConfiguration.maxNumberOfSavedDocumentsOnDiskThe default is 20. If exceeding the max value of photos or files, the SDK deletes the oldest downloaded file.
- LPConfig.defaultConfiguration.photosharingMenuBackgroundColor
- LPConfig.defaultConfiguration.photosharingMenuButtonsTextColor
- LPConfig.defaultConfiguration.photosharingMenuButtonsBackgroundColor
- LPConfig.defaultConfiguration.photosharingMenuButtonsTintColor
- Window Mode:The UIDocumentationInteractionController adopts applicable branding customizations that have been set, for example:View Controller Mode:Your custom applicable navigation bar traits apply to the UIDocumentationInteractionController.
- conversationNavigationBackgroundColor sets the NavController tint color with translucence set to false.
- conversationNavigationTintColor colors the L & R bar buttons as well as the title color.
The color, font selections and other customizations of the message bubbles for file and photo sharing from agents adhere to the remoteUserBubble configurations. For the messages containing photos being shared from consumer to agent can be configured via the userBubble customizations.
You've finished with the capabilities. Let's move on to the operational considerations for this stage. Click here to proceed.