WebChat File Upload
Note
An Enterprise license or higher is required to access these features.
Note
Introduced in DC2023.01
This feature adds the ability to upload attachments as a WebChat user.
Important
This functionality is not the same as the agent side upload.
An end user first selects files to send in the WebChat UI from the native file picker of the device or platform they are on. At this point the files are considered "pending" and have not been actually sent yet, though they have been saved in the WebChatAttachment table in the database. In this pending state the files are linked to the conversation. At this point the end user can decide to remove a file from the pending attachments, which results in the file being deleted from the database.
When an end user is ready with the file selection, they can send the attachments with or without an accompanying message. At the this point the attachments aren't considered "pending" anymore and are linked to a message object in the database instead of the conversation. After sending a message the attachments have the same structure as the existing DialogueManager attachments (e.g. email).
The attachments are added to the DialogueMessageResponse object (e.g. response for the GetDialogue endpoint).
There are some restrictions in place that can be configured using the below settings.
How to enable
The following SharePoint settings have been added to the Plugin Settings for the WebChatDialogueProvider2.
Name | Scope | Value | Description |
---|---|---|---|
CustomerAllowedToUpload | WebChatDialogueProvider2 |
defaults to false |
Allows the customer to upload when true |
UploadMaxFiles | WebChatDialogueProvider2 |
defaults to 0 |
Indicates the maximum number of files the customer is allowed to upload for one message Note Please ensure that the value you enter for this setting is a positive number. Values of 0, empty, or negative numbers will not work as expected. |
UploadMaxFileSizeInMB | WebChatDialogueProvider2 |
defaults to 0 |
Indicates the maximum file size in MB the customer is allowed to upload in one action (POST) Note Please ensure that the value you enter for this setting is a positive number. Values of 0, empty, or negative numbers will not work as expected. |
UploadAllowedFileTypes | WebChatDialogueProvider2 |
Example: .txt(new line).jpg Defaults to '.txt .pdf .docx .doc .gif .png .jpeg .jpg' |
Indicates the allowed extensions for the files, the customer is allowed to upload. (multiple values separated by newline) |
Set CustomerAllowedToUpload to true, UploadMaxFiles and UploadMaxFileSizeInMB to a positive number in order to allow the customer to upload any files.