AttachmentSettings

9 Jul 20261 minute to read

Represents settings for managing file attachments in the AI Assist View.
Includes configuration for URLs, file types, and size limitations.

Properties

allowedFileTypes string

Specifies the allowed file types for attachments.

Defaults to ’’

attachmentTemplate string|function|JSX.Element|HTMLElement

Specifies a custom template for rendering attachments in footer and assistview.
Accepts a string or function to define the HTML structure or rendering logic for attachments (e.g., thumbnails, icons, file metadata).
If not provided, the default attachments will be rendered.

Defaults to ’’

maxFileSize number

Specifies the maximum file size allowed for attachments in bytes.

Defaults to 2000000

maximumCount number

Specifies the maximum number of attachments allowed per prompt.
Limits the number of files that can be uploaded and attached to a single prompt.
Must be a positive integer.

Defaults to 10

removeUrl string

Specifies the URL to remove the files from the server.

Defaults to ’’

saveUrl string

Specifies the URL to save the uploaded files.

Defaults to ’’

Events

attachmentClick EmitType<AttachmentClickEventArgs>

Event raised when a attachment item is clicked in the assistview component either before sending or after the attachment is sent.