Skip to content
Toby Crawley edited this page Mar 3, 2022 · 7 revisions

Deploy Tokens

To deploy to Clojars, you will need to authenticate yourself. Deployment authentication is done via your username and a Deploy Token.

Creation

To create a deploy token, visit https://clojars.org/tokens after logging in. This page will list existing tokens and allow you to create a new token. You just need to provide a name for the token. The name does not need to be unique. Once created, a token cannot be edited (other than to disable it).

Note: the new token value will only be presented once after creation, so be sure to copy it!

Scoping

By default, a deploy token can be used to deploy any artifact your user account has rights to deploy. However, deploy tokens can be scoped to only allow deploying a single artifact, or deploying any artifact within a group.

Note: you can't create a token that is scoped to a group or artifact before that group or artifact exists on Clojars - you will need to deploy with an unscoped token first to create the group & artifact.

Single Use

By default, a deploy token can be used any number of times. You have the option at creation time to mark the token as single-use. A single-use token can be used to deploy only one version of a project.

Expiration

By default, a deploy token never expires. You have the option to set an expiration time at creation time. After that time has passed, the deploy token can no longer be used.

Disabling

Tokens can be disabled on the token management page. Once disabled, a token cannot be re-enabled.

Usage

To use a deploy token, simply use it in place of your password when deploying. You will still need to provide your Clojars username as well.