CLI
Installation

Installation

The Pinarkive CLI lets you upload files, pin CIDs, list uploads, remove pins, share encrypted files, and more from the terminal. It targets the Pinarkive API v3 and uses the official @pinarkive/pinarkive-sdk-ts (opens in a new tab) for all API calls.

Run with npx (no install)

npx pinarkive upload file.png

No global install required. Use npx pinarkive for any command.

Global install (recommended)

Install the wrapper package to get the latest CLI version:

npm install -g pinarkive

Then run:

pinarkive login
pinarkive upload file.png
pinarkive files

The pinarkive package is a lightweight wrapper that installs @pinarkive/pinarkive-cli (opens in a new tab) and exposes the pinarkive command. You always get the latest CLI without specifying the scoped package name.

Install a specific CLI version

To pin a specific version of the CLI (e.g. 1.0.2):

npm install -g @pinarkive/pinarkive-cli

Use @pinarkive/pinarkive-cli@1.0.2 for a fixed version.

Configuration and authentication

Most commands require an API key. Use pinarkive login to save it locally:

pinarkive login

You'll be prompted for your API key. It is stored in:

  • macOS / Linux: ~/.pinarkive/config.json
  • Windows: %USERPROFILE%\.pinarkive\config.json

The config file contains only { "apiKey": "<your_key>" }. If you're not logged in, the CLI will show: "Not authenticated. Run: pinarkive login".

Get an API key: Pinarkive dashboard (opens in a new tab) or POST https://api.pinarkive.com/api/v3/tokens/generate with scopes such as files:read, files:write, files:delete, cluster:read.

Global options

Available on any command:

ShortLongDescription
-V--versionShow CLI version
-h--helpShow help for the command (or global help if no command)

Next steps

  • Commands — Full list of commands and usage