-
Notifications
You must be signed in to change notification settings - Fork 0
Attachments Formats and Filenames
Unspool is intentionally format-agnostic. The browser does not contain an allowlist that rejects unfamiliar extensions.
The TDLib mapping layer recognizes media delivered as:
- document;
- audio or music;
- voice message;
- video;
- video note;
- animation;
- photo or image;
- sticker;
- another supported message-content representation.
Music sent through Telegram's music UI is still mapped as an attachment. A FLAC music item is not excluded merely because it was not sent with the generic file button.
AttachmentFilename.resolve uses this precedence:
- the original filename from the Telegram media object;
- a usable filename from Telegram's file representation;
- a neutral deterministic fallback when Telegram supplies neither.
The fallback format is:
unnamed-<media-kind>-<message-id>.<preferred-extension>
The extension is omitted when it is unknown. This fallback is not presented as
an original filename: the domain value records whether its provenance is
telegramOriginal, telegramFile, or generated.
Unspool never synthesizes a filename from:
- music artist;
- track title;
- album;
- caption;
- embedded tags;
- chat title.
That rule matters because metadata can be edited independently from the file and can destroy the uploader's naming scheme.
The original filename is preserved exactly at the domain boundary, including case and Unicode. Before placement, the destination layer rejects names that are unsafe as a single macOS path component. It does not silently sanitize an unsafe Telegram name into a different name.
The chat title may be sanitized for the optional directory name because that directory is an organizational container, not the attachment's filename.
Every row uses the same neutral thumbnail component. It displays the final filename extension in uppercase:
FLACLRCPNGMOV- any other available extension
If the filename has no extension, the badge displays FILE. Media artwork and
image thumbnails are intentionally not mixed into this component, keeping
rows stable across file types.
Categories help browsing; they do not control eligibility:
- Audio
- Video
- Images
- Documents
- Other
Known extensions are classified first. When an extension is unknown, the TDLib media kind provides the category. This means an unfamiliar extension remains visible even when the app cannot classify it more specifically.
An attachment identity combines the Telegram chat ID, message ID, and file ID. Eligibility can be:
-
eligible; -
alreadyDownloaded; -
queued; -
unavailable.
The original filename is never used as the identity because different Telegram files can legitimately share one name.
Unspool is an independent project and is not affiliated with Telegram. Repository · Privacy · Security · MIT License
- Getting Started
- Detailed Telegram Setup
- Feature Overview
- Chats and History
- Attachments and Filenames
- Search and Selection
- Download Workflow
- Conflicts and Recovery
- Download History
- Settings
- Accessibility
- Troubleshooting
- Detailed Troubleshooting and FAQ
- Privacy and Security
- Detailed Security Model
- TDLib Integration
- Persistence
- Concurrency and Errors
- Glossary