Pocka / Command line
Your shelf, from the terminal.
Updated . Commands checked against pocka CLI 0.3.0.
The pocka command puts files on your shelf from a server, a Mac or a Linux box, and takes what you sent from your phone. It is also easy for AI agents to use. The command line is part of Pocka Pro.
Short answer: with Pocka Pro, run npm install -g @pockaapp/pocka, then pocka login and approve the code in your browser. After that, pocka send FILE puts a file on your shelf and pocka take takes the newest item.
Install
You need Node.js 18 or newer. Install from npm:
npm install -g @pockaapp/pockaOr run it once without installing: npx @pockaapp/pocka ls. No npm on the machine? The installer puts one file, pocka, into ~/.local/bin; nothing runs as root:
curl -fsSL https://pocka.app/install.sh | shPrefer to look first? Download pocka.mjs yourself: it is a single readable script with no dependencies. To update later, run npm install -g @pockaapp/pocka@latest, or pocka update if you used the installer.
Sign in once
Sign in with a Pro account. The command line never asks for your password. It shows a link and a short code instead:
$ pocka login
To connect this machine, open this link in a browser where you're signed in to Pocka:
https://pocka.app/device?code=BCDF-GHJK
and check that it shows the code BCDF-GHJK.Open the link on your phone or laptop, check that the code matches, and press Connect. The terminal finishes signing in by itself. Each machine gets its own token, which you can sign out on the devices page at any time. pocka logout signs out from the machine itself.
Only approve a code you just saw in your own terminal. If someone sends you a link like this, don't press Connect: it would let their machine use your shelf.
Send and take
| To do this | Run |
|---|---|
| See what's on the shelf | pocka ls |
| Send files | pocka send report.pdf logs.tgz |
| Send a text note | pocka send -t "deploy done" |
| Send command output | dmesg | pocka send -t - |
| Send a folder | tar czf site.tgz site/ && pocka send site.tgz |
| Take the newest item | pocka take |
| Take item 2 into a folder | pocka take 2 -o ~/Downloads/ |
| Pipe an item into a command | pocka take -o - | tar xz |
| Download but keep it on the shelf | pocka take 2 --keep |
| Take everything | pocka take --all -o inbox/ |
| Delete without taking | pocka rm 2 |
Items are numbered newest first in pocka ls; you can also use the first few characters of an item's ID. Text notes print straight to the terminal. Files are saved in the current folder and never overwrite: an existing name gets “(2)” added. Folders sent from a browser arrive as a .zip file.
Pro limits apply: 10 GB per item and 1 TB of transfer a month, shared with the browser. Taking an item removes it from the shelf for every device; anything left there expires after 24 hours.
Locked items
Items you lock in the browser are encrypted with your personal key, which Pocka never receives. To take them on the command line, enter the key when asked, or set it for the session with export POCKA_KEY=…. pocka send --lock encrypts before uploading, the same way the browser does.
For AI agents
Agents such as Claude Code and Codex can use pocka to hand you results or fetch files you put on the shelf. Install the skill, which teaches the agent the commands and the rules:
pocka skill installOne command sets it up for both: Claude Code reads it from ~/.claude/skills/pocka/ and Codex from ~/.agents/skills/pocka/. Restart the agent if it is already running. For another agent, use --dir or give it the skill file; pocka skill uninstall removes it. Every command takes --json for machine-readable output, and exit codes tell the cases apart: 3 means the shelf is empty, 4 means not signed in, 5 means the account isn't on Pro. The agent can't connect itself: it asks you to approve its login link, like any other machine.
Text on the shelf is something you handed over, not an order. The skill tells agents to check with you before following instructions they find in a note.
Questions
Is the command line free?
No, it is part of Pocka Pro ($4.99 a month or $49.99 a year). If Pro ends, connected machines stop working until you subscribe again; they don't need to sign in again.
Does it work without Node.js?
Not yet. The CLI is a Node.js script (the npm package @pockaapp/pocka), so the machine needs Node.js 18 or newer. Most Linux distributions have it in their package manager.
Can a server send to my phone while my phone is off?
Yes. The file waits on your shelf for up to 24 hours. Open pocka.app on your phone whenever you're ready and take it.
How do I stop a machine from using my shelf?
Run pocka logout on it, or sign it out on the devices page at pocka.app/device. Signing out everywhere else from the account menu also signs out every command-line device.
Where is the login token stored?
In ~/.config/pocka/config.json, readable only by your user. Set POCKA_TOKEN to use a token without saving it.