Command line
Upload from the terminal with aktar
One command, one link: aktar upload report.pdf sends the file to your own bucket through the Aktar app and prints its URL, Markdown or full JSON. Made for scripts, CI jobs and editors like Typora.
npm install -g @getaktar/cli brew install getaktar/tap/aktar-cliOr try it without installing: npx @getaktar/cli upload file.png

Commands
-
aktar upload <file>…Uploads one or more files and prints one link per file, as each finishes.
-
--format markdownPrints Markdown, HTML or your custom template from Aktar instead of the plain URL.
-
--jsonPrints everything as JSON: URL, every format, object key, size and when the file expires.
-
-d --folder --expiresPicks a destination by name, uploads into a folder, or lets the bucket delete the file after 1, 7, 14 or 30 days.
-
--clipboardUploads the file or image on the clipboard.
-
--name coverUploads a single file under another name, which the destination's path template and Aktar's history use.
-
--qr aktar qrPrints a QR code under each link to open it on your phone.
aktar qrshows one for any link, or for an upload from history. -
"reused": trueWhen the same file is already in the bucket, Aktar hands back its link instead of uploading it again, and
aktarnotes it on stderr. -
aktar replaceWrites a new file over an upload and keeps its link, by upload ID, link or key. Needs Aktar for Mac 0.14.0 or Windows 0.7.0.
-
--short aktar shortPrints the short link from the destination's own link shortener.
aktar shortmakes one for an upload from history. Needs Aktar for Mac 0.17.0 or Windows 0.10.0. -
aktar mcp aktar skillLets AI agents like Claude, Cursor, VS Code and Codex upload, search your uploads and make links, as an MCP server or with an agent skill.
-
aktar loginSaves the token from Aktar's Settings, after checking it works.
-
status destinations historyShows the connection, your destinations, and a searchable upload history.
Set up in a minute
- In Aktar for Mac or Windows, open Settings > Integrations and turn on Allow local connections.
- Copy the token shown there.
- Run
aktar loginand paste it. That's it:aktar uploadnow uses the destination selected in Aktar.
Typora images, on your own bucket
Set aktar as Typora's custom image uploader and every image you paste into a document is uploaded to your bucket, with the link written into the Markdown.
Set up TyporaMade for scripts
Links go to standard output, one per line, and everything else to standard error, so URL=$(aktar upload build.zip) just works. --json gives you the full details, and the exit code tells you what happened. In CI, set AKTAR_TOKEN instead of logging in.
| Exit code | |
|---|---|
0 | Everything was uploaded |
1 | At least one upload failed; the others went through |
2 | Bad arguments or a missing file; nothing was uploaded |
3 | Aktar isn't reachable, the token is wrong, or the app on the port couldn't prove it's Aktar |
Your keys stay in Aktar
The CLI never sees your storage credentials. It sends files to the Aktar app on 127.0.0.1, which uploads them with the keys in your Keychain or Credential Manager.
Aktar's local API is off until you turn it on, never accepts connections from other computers, and every request needs your token. The CLI keeps it in a file only you can read, and checks the app on the port really is Aktar before sending it.
Requirements
- Aktar for Mac 0.18.0 or Aktar for Windows 0.11.0 or later, with at least one destination (aktar 0.5.0 and earlier work with Aktar for Mac 0.4.0 or later)
- Node.js 18 or later (Homebrew installs it for you)
- Reusing links of files already uploaded: Aktar for Mac 0.10.0 or Aktar for Windows 0.3.0
-
aktar replace: aktar 0.3.0 and Aktar for Mac 0.14.0 or Windows 0.7.0 -
aktar mcpandaktar skill: aktar 0.4.0 - Short links: aktar 0.5.0 and Aktar for Mac 0.17.0 or Windows 0.10.0
- Open source (MIT) on GitHub
Questions
Does the CLI work without the Aktar app?
No. It's a remote control for the app: Aktar keeps the storage keys and does the uploading, so it has to be running with Allow local connections on. That's also why the CLI never needs your access keys.
Can I use it in CI or on a server?
Only where Aktar runs, since the CLI talks to it on the same machine. For a Mac or Windows build agent that works well; on a Linux server, use your provider's own CLI.
Which storage does it support?
Everything Aktar does: Amazon S3, Cloudflare R2, Backblaze B2, DigitalOcean Spaces, MinIO and any S3-compatible service. See the setup guides.
Can Claude, Cursor or other AI agents use it?
Yes. aktar mcp is an MCP server: add it with claude mcp add aktar -- aktar mcp --root ~/Projects (or the JSON config in the docs) and your agent can upload files, search your uploads and make temporary links. --root is the folder it may upload from, secrets like SSH keys and .env files are never uploaded, --allow-replace lets it replace a file keeping its link, and --read-only leaves out everything that writes. For agents without MCP, aktar skill prints a skill that teaches them the CLI.
Where is the token stored?
In ~/.config/aktar/cli.json on a Mac (%APPDATA%\aktar\cli.json on Windows), readable only by your user. aktar logout removes it, and regenerating the token in Aktar disconnects every client.