TGFS Config Generator

Generate your TGFS configuration file with this interactive form
Telegram
API Credentials
Get API Keys
Private File Channels & Metadata

Configure one or more private channels to store files. Each channel needs both a channel ID and metadata configuration to maintain the directory structure.

Valid directory name for metadata

The metadata will be maintained in a json file pinned in the file channel. Every directory operation reuploads and updates the pinned file.

⚠️ NEVER delete the pinned file AND NEVER manually pin any message.

Bot Tokens
@BotFather

TGFS
Users
JWT
Server

WebDAV server will be at http://0.0.0.0:1900/webdav

TGFS server will be at http://0.0.0.0:1900 (Used in the Telegram Mini App).


SFTP (Optional)

Serves the same file tree over SFTP, next to WebDAV, using the same users and the same readonly flags. SSH cannot share the HTTP port, so it needs a port of its own.


Redundancy (Optional)

RAID-1-style mirroring: every file uploaded to a channel is also copied to its mirror channel(s) via server-side message forwarding, so your data survives a channel getting banned or deleted. Configure the mirror channel IDs per channel above once enabled. Enabling this later is fine — the backfill task (Manager API: POST /redundancy/backfill/<channel-name>) mirrors all pre-existing files without re-uploading them.

Tip: with redundancy enabled, the GitHub Repository metadata type is recommended — the directory structure then survives even the loss of all channels.


Encryption (Optional)

At-rest encryption with AES-256-GCM. When enabled, every file is encrypted client-side before being uploaded; the Telegram channel only ever sees ciphertext plus a public per-file salt.


Transfer Performance (Optional)

How file bytes are moved to and from Telegram. Every setting has a default that matches the behaviour you get without this block, so leave it off unless you want to tune something.

Generated Configuration
telegram:
  api_id: ''
  api_hash: ''
  lib: telethon
  bot:
    session_file: bot.session
    tokens: []
  private_file_channel: []
tgfs:
  users:
    user:
      password: password
  jwt:
    secret: ''
    algorithm: HS256
    life: 604800
  metadata: {}
  server:
    host: 0.0.0.0
    port: 1900
  encryption:
    enabled: false
    encrypt_names: false
    master_salt_file: master.salt
    chunk_size: 65536