Documentation Index
Fetch the complete documentation index at: https://mintlify.com/sceyt/sceyt-chat-android-uikit/llms.txt
Use this file to discover all available pages before exploring further.
AttachmentInteractor provides all operations for browsing, loading, and managing message attachments within a channel. It is accessible via SceytChatUIKit.chatUIFacade.attachmentInteractor. Use it to implement media galleries, file browsers, voice-message lists, and link-preview feeds — each filtered by attachment type. Paginated methods return a Flow<PaginationResponse<AttachmentWithUserData>>, which emits locally cached results first and then updates from the server. Utility methods handle file checksum deduplication, link preview fetching, and transfer-state tracking.
Package: com.sceyt.chatuikit.persistence.interactor
Paginating Attachments
Loads attachments older than
lastAttachmentId (backward pagination). Each emission contains an AttachmentWithUserData list, pairing the attachment with its sender’s profile data.Loads attachments newer than
lastAttachmentId (forward pagination). Use this when implementing a media viewer that allows navigating towards more recent files.Loads attachments surrounding a specific
attachmentId. Useful for opening a media viewer at a particular item and needing context items on both sides for swipe navigation.Updating Attachment Metadata
Synchronises the local database record’s attachment ID and message ID fields after the server has confirmed a message send. Called internally by the send pipeline; you should not need to call this directly.
Updates the upload or download transfer state for an attachment identified by its parent message’s transaction ID. The UIKit calls this internally to persist progress, completion, or error states.
Updates the local file path, file size, and metadata for an attachment in the database after a post-processing step (e.g. transcoding or resizing).
File Deduplication
Computes or retrieves the checksum data for a local file path. When
SceytChatUIKitConfig.preventDuplicateAttachmentUpload is true, this is used to detect if the file has already been uploaded and reuse the existing URL.Link Previews
Fetches Open Graph and other preview metadata for the given URL. The result is cached locally so subsequent calls for the same URL are served from the database.
Inserts or updates a
LinkPreviewDetails record in the local database. Use this to pre-populate the cache with server-provided or externally fetched preview data.