Skip to content

dosya.dev from your terminal.

Upload, download, share, sync, and manage files without leaving the command line. Address files by path, mirror folders both ways, and script it all - built for CI/CD pipelines and power users.

1

Install

curl -fsSL https://api.dosya.dev/api/cli/install | sh
2

Authenticate

dosya auth login
3

Upload

dosya upload ./file.mp4

One command to install

Single native binary with zero dependencies. Available for macOS (Apple Silicon & Intel), Linux x64, and Windows x64.

# Install (auto-detects macOS or Linux)
$ curl -fsSL https://api.dosya.dev/api/cli/install | sh
Downloading dosya CLI (mac-arm64)...
dosya CLI installed successfully!

# Verify
$ dosya --version
dosya 1.0.8

Latest version: v1.0.8 · already installed? Run dosya upgrade

Login once, use everywhere

Your API key is stored securely in ~/.dosya/config.json with 0600 permissions. For CI/CD, use the DOSYA_API_KEY environment variable instead.

Authenticate
# Authenticate with your API key
$ dosya auth login
Enter API key: ••••••••••••••••
Authenticated as john@dosya.dev

# Or pass the key directly (useful for CI/CD)
$ dosya auth login --key dos_abc123

# Or use an environment variable
$ export DOSYA_API_KEY=dos_abc123

Everything you need

Every command supports --json for machine-readable output and --help for detailed usage.

dosya upload
# Upload a file to a workspace
$ dosya upload ./render-final.mp4 -w ws_abc123
render-final.mp4 [████████████████████████████████] 100% | 12.4 GB/12.4 GB | 245.0 MB/s
Uploaded: file_8xk2m9p4

# Upload an entire folder recursively
$ dosya upload ./project-assets/ -w ws_abc123 --recursive --parallel 5
Uploading 147 files...
Done. 147 uploaded, 0 failed.
dosya download
# Download a file (8 parallel connections by default)
$ dosya download file_8xk2m9p4 -o ./downloads/
File: render-final.mp4 (12.4 GB)
render-final.mp4 [████████████████████████████████] 100% | 12.4 GB/12.4 GB | 389.0 MB/s | 32s
Saved to ./downloads/render-final.mp4
Done. 12.4 GB written (8 connections).

# Use 16 connections for maximum speed
$ dosya download file_8xk2m9p4 -c 16

# Resume an interrupted download automatically
$ dosya download file_8xk2m9p4
Resuming download: 4.2 GB/12.4 GB already downloaded
dosya sync
# Two-way sync a local folder with a workspace folder
$ dosya sync add ~/Documents ws_abc123:Docs
Added sync pair a1b2c3: /Users/you/Documents <-> ws_abc123:Docs (two-way)

# Preview the plan, then run it
$ dosya sync run --dry-run
[a1b2c3] plan: 12 action(s)
  upload-new    designs/logo.svg
  download-new  notes/todo.md
$ dosya sync run
[a1b2c3] applied 12, 0 conflict(s), 0 failure(s)

# ...or keep it live
$ dosya sync watch
Watching /Users/you/Documents <-> ws_abc123 (two-way). Press Ctrl+C to stop.

# Backup-only: never let the cloud delete your local files
$ dosya sync add ~/Pictures ws_abc123:Photos --mode push-safe
dosya share
# Generate a share link
$ dosya share file_8xk2m9p4 --password "correct-horse" --expires 7d
https://dosya.dev/s/xK9m2pQ4
Expires: 4/24/2026

# Get JSON output for scripting
$ dosya share file_8xk2m9p4 --json
{
  "ok": true,
  "link": { "url": "https://dosya.dev/s/rT5n8wL2", ... }
}
dosya workspace / ls
# List workspaces
$ dosya workspace list
ID              NAME                    STORAGE
ws_abc123       Brand Campaign 2026     234.0 GB
ws_def456       Client Deliverables     12.0 GB
ws_ghi789       Research Data           1.20 TB

# List files in a workspace
$ dosya ls ws_abc123
NAME                    SIZE        MODIFIED    ID
render-final.mp4        12.4 GB     2h ago      file_8xk2m9p4
brand-guide.pdf         45.0 MB     1d ago      file_3mn7k2q9
assets/                 -           3d ago      fld_9xp4r2w1
dosya search / info / usage
# Search across files, folders and shares
$ dosya search "invoice"
Files:
NAME              SIZE       MODIFIED   ID
invoice-q3.pdf    240.0 KB   2h ago     file_8xk2m9p4

# Reference files by path - no ids required
$ dosya info reports/2026/invoice-q3.pdf
Name:      invoice-q3.pdf
Size:      240.0 KB
Version:   3
Shares:    1

# Your folder tree and storage at a glance
$ dosya usage
Plan:    pro
Storage: 234.0 GB / 1.0 TB  (23%)
dosya star / trash / versions
# Favourite the things you reach for most
$ dosya star reports/invoice-q3.pdf
Starred 1 item(s).

# Deletions go to the trash - and come back
$ dosya rm old-draft.pdf
Deleted 1 item(s) (recoverable).
$ dosya trash restore old-draft.pdf
Restored 1 file(s).

# Every file keeps a version history
$ dosya upload invoice-q4.pdf --version-of invoice-q3.pdf
$ dosya versions invoice-q3.pdf
invoice-q3.pdf - current version 4
VERSION  SIZE       UPLOADER   CREATED
4 *      241.0 KB   you        just now
3        240.0 KB   you        2h ago
dosya mv / rm / member
# Create a new workspace
$ dosya workspace create --name "Q3 Campaign"
Created workspace: Q3 Campaign (ws_new789)

# Invite a team member
$ dosya member invite --email alice@company.com --role Admin -w ws_abc123
Invited alice@company.com as Admin

# Move, copy and make folders - by path, no ids needed
$ dosya mkdir releases/2026
Created releases/2026/ (fld_9xp4r2w1)
$ dosya mv render-final.mp4 releases/2026
Moved 1 item(s).
$ dosya cp brand-guide.pdf releases/2026
Copied to brand-guide.pdf (file_3mn7k2q9)

# Delete (goes to the trash, recoverable)
$ dosya rm old-draft.pdf
Deleted 1 item(s) (recoverable).

Automate with pipelines

Use the DOSYA_API_KEY env var for non-interactive auth. Combine --json and --quiet for clean scripting.

GitHub Actions
# .github/workflows/deploy.yml
- name: Upload build artifacts
  env:
    DOSYA_API_KEY: ${{ secrets.DOSYA_API_KEY }}
  run: |
    dosya upload ./dist/ -w ${{ vars.WORKSPACE_ID }} \
      --recursive --parallel 5 --json --quiet

Tab completion for every shell

Complete commands, subcommands, flags, and file paths with the Tab key.

Shell completion
# Bash
$ dosya completion bash >> ~/.bashrc

# Zsh
$ dosya completion zsh >> ~/.zshrc

# Fish
$ dosya completion fish > ~/.config/fish/completions/dosya.fish

Full reference

All commands
dosya auth login Authenticate with API key
dosya auth logout Clear stored credentials
dosya upload <file> Upload a file or folder (--version-of for a new version)
dosya download <file> Download a file (parallel, resumable); --zip for many
dosya ls [workspace] List files (--query to filter)
dosya search <query> Search files, folders and shares
dosya info <file> Show file metadata (alias: stat)
dosya tree [path] Print the folder tree
dosya usage Show storage usage and quota (alias: df)
dosya mkdir <path> Create a folder (nested paths ok)
dosya cp <file> <folder> Copy a file into a folder
dosya mv <target...> <dest> Move or rename files or folders (bulk)
dosya rm <target...> Delete files or folders (bulk, recoverable)
dosya star / unstar / starred Manage favourites
dosya trash list|restore|empty List, restore or empty the trash
dosya versions <file> List or restore file versions
dosya share <file> Create a share link
dosya share list|revoke|email|bundle Manage share links
dosya sync add|run|watch Bidirectional folder sync
dosya workspace list List all workspaces
dosya workspace create Create a new workspace
dosya workspace delete <id> Delete a workspace
dosya member list List workspace members
dosya member invite Invite a member
dosya whoami Show current user info
dosya config get [key] Show config value
dosya config set <key> <value> Set a config value
dosya config path Show config file location
dosya completion <shell> Generate shell completion script
dosya upgrade Upgrade CLI to latest version
dosya uninstall Remove CLI binary and config
dosya --version Show CLI version
Global flags
--json -j Machine-readable JSON output
--quiet -q Suppress non-essential output
--key <key> -k API key (overrides stored key and env var)
--workspace <id> -w Workspace ID
--debug Verbose diagnostic output and stack traces
--no-color Disable colors and unicode characters
--connections <num> -c Parallel download connections (default: 8)
--timeout <sec> Request timeout in seconds
--version -v Show CLI version
--help -h Show help (works per command too)
Environment variables
DOSYA_API_KEY API key for authentication (same as --key flag)
XDG_CONFIG_HOME Override config directory (default: ~/.dosya/)
Exit codes
0 Success
1 General error (server error, operation failed)
2 Invalid usage (missing arguments, unknown flags)
3 Authentication error (invalid or expired API key)
4 Network error (timeout, no connection)
130 Interrupted (Ctrl+C)

Install and start uploading

One command to install, one command to authenticate, one command to upload. That simple.

Free tier includes 5 GB storage and full CLI access.