The Cloudsmith Developer Hub

Welcome to the Cloudsmith developer hub. You'll find comprehensive guides and documentation to help you start working with Cloudsmith as quickly as possible, as well as support if you get stuck. Let's jump right in!

Get Started    

Command-Line Interface

PyPI Version

The Cloudsmith Command Line Interface (CLI) is a Py2/Py3 text-based interface to the API. This allows users, machines and other services to access and integrate smoothly with Cloudsmith without requiring explicit plugins or tools. Be awesome. Automate Everything.

The following (very out of date) GIF demonstrates a small slice of the CLI - View the full video on YouTube:

CLI Demonstration

You can also read our blog article that introduced the first version of the CLI and the Cloudsmith RESTful API.


Please see the changelog for the list of changes by version. The current version is displayed in the PyPi badge at the top.


The CLI currently supports the following commands (and sub-commands):

  • check: Check rate limits and service status.
  • copy|cp: Copy a package to another repository.
  • delete|rm: Delete a package from a repository.
  • docs: Launch the help website in your browser.
  • entitlements|ents: Manage the entitlements for a repository.
    • create|new: Create a new entitlement in a repository.
    • delete|rm: Delete an entitlement from a repository.
    • list|ls: List entitlements for a repository.
    • refresh: Refresh an entitlement in a repository.
    • sync: Sync entitlements from another repository.
    • update|set: Update (patch) a entitlement in a repository.
  • help: Display the delightful help message and exit.
  • list|ls: List distros, packages, repos and entitlements.
    • distros: List available distributions.
    • entitlements: List entitlements for a repository.
    • packages: List packages for a repository.
    • repos: List repositories for a namespace (owner).
  • move|mv: Move (promote) a package to another repo.
  • push|upload: Push (upload) a new package to a repository.
    • deb: Push (upload) a new Deb package upstream.
    • maven: Push (upload) a new Maven package upstream.
    • python: Push (upload) a new Python package upstream.
    • raw: Push (upload) a new Raw package upstream.
    • rpm: Push (upload) a new Rpm package upstream.
    • ruby: Push (upload) a new Ruby package upstream.
    • vagrant: Push (upload) a new Vagrant package upstream.
  • resync: Resynchronise a package in a repository.
  • status: Get the synchronisation status for a package.
  • token: Retrieve your API authentication token/key.
  • whoami: Retrieve your current authentication status.


You can install the latest CLI application from:

The simplest way is to use pip, such as:

pip install --upgrade cloudsmith-cli

Or you can get the latest pre-release version from Cloudsmith:

pip install --upgrade cloudsmith-cli --extra-index-url=


There are two configuration files used by the CLI:

  • config.ini: For non-credentials configuration.
  • credentials.ini: For credentials (authentication) configuration.

By default, the CLI will look for these in the following locations:

  • The current working directory.
  • A directory called cloudsmith in the OS-defined application directory. For example:
    • Linux: $HOME/.config/cloudsmith
      • Windows: C:\Users\YourName\AppData\cloudsmith

Both configuration files use the simple INI format, such as:


Non-Credentials (config.ini)

See the default config in GitHub:

You can specify the following configuration options:

  • api_host: The API host to connect to.
  • api_proxy: The API proxy to connect through.
  • api_user_agent: The user agent to use for requests.

Credentials (credentials.ini)

See the default config in GitHub:

You can specify the following configuration options:

  • api_key: The API key for authenticating with the API.

Getting Your API Key

You'll need to provide authentication to Cloudsmith for any CLI actions that result in accessing private data or making changes to resources (such as pushing a new package to a repository)..

With the CLI this is simple to do. You can retrieve your API key using the cloudsmith token command:

cloudsmith token
Repeat for confirmation:

Note: Please ensure you use your email for the 'Login' prompt and not your user slug/identifier.

The resulting output looks something like:

Retrieving API token for '' ... OK
Your API token is: 1234567890abcdef1234567890abcdef

Once you have your API key you can then put this into your credentials.ini, use it as an environment variable export CLOUDSMITH_API_KEY=your_key_here or pass it to the CLI using the -k your_key_here flag.

For convenience the CLI will ask you if you want to install the default configuration files, complete with your API key, if they don't already exist. Say 'y' or 'yes' to create the configuration files.

If the configuration files already exist, you'll have to manually put the API key into the configuration files, but the CLI will print out their locations.


Note: All of the examples in this section are uploading to the lskillen user and the test repository. Please replace these with your own user/org and repository names.

Upload an Alpine Package

Assuming you have a package filename sed-1.0.3.x86_64.apk, representing sed 1.0.3, for the Alpine v3.8 distribution (which has a cloudsmith identifier of alpine/3.8):

cloudsmith push alpine lskillen/test/alpine sed-1.0.3.x86_64.apk

Upload a Debian Package

Assuming you have a package filename libxml2-2.9.4-2.x86_64.deb, representing libxml 2.9.4, for the Ubuntu 16.04 distribution (which has a cloudsmith identifier of ubuntu/xenial):

cloudsmith push deb lskillen/test/ubuntu/xenial libxml2-2.9.4-2.x86_64.deb

### Upload a RedHat Package

Assuming you have a package filename **libxml2-2.9.4-2.el5.x86_64.rpm**, representing **libxml 2.9.4**, for the **RedHat Enterprise 5.0** distribution (which has a cloudsmith identifier of **el/5**):

cloudsmith push rpm lskillen/test/el/5 libxml2-2.9.4-2.el5.x86_64.rpm

### Upload a Python Package

Assuming you have a package filename **boto3-1.4.4.py2.p3-none-any.whl**, representing **boto3 1.4.4**, for **Python 2/3**:

cloudsmith push python lskillen/test boto3-1.4.4.py2.p3-none-any.whl

### Upload a Ruby Package

Assuming you have a package filename **safe_yaml-1.0.4.gem**, representing **safe_yaml 1.0.4**, for **Ruby 2.3+**:

cloudsmith push ruby lskillen/test safe_yaml-1.0.4.gem

### Upload a Maven Package

Assuming you have a package filename **validation-api-1.0.0.GA.jar**, representing **validation-api 1.0.0**, for **Maven/Java**:

cloudsmith push maven lskillen/test validation-api-1.0.0.GA.jar --pom-file=validation-api-1.0.0.GA.pom

### Upload an Npm Package

Assuming you have a package filename **lodash-4.1.3.tgz**, representing **lodash 4.1.3** (and generated with `npm pack`):

cloudsmith push npm lskillen/test lodash-4.1.3.tgz

### Upload a Raw Package

Assuming you have a package filename ****, representing **packaged assets**:

cloudsmith push raw lskillen/test

### Upload a Vagrant Package

Assuming you have a package filename ****, representing a Vagrant image for the **Awesome OS** (fictional, probably):

cloudsmith push vagrant lskillen/test


Yes! Please do contribute, this is why we love open source. Please see CONTRIBUTING for contribution guidelines when making code changes or raising issues for bug reports, ideas, discussions and/or questions (i.e. help required).