v5

latestOpenAPI 3.1.0raw.githubusercontent.com2026-06-167122208.0 KB
api_tokens

get_token

Retrieve your API token programmatically. Authenticate with your packagecloud account email address (as the basic-auth username) and password (as the basic-auth password); be sure to URL-encode the username and password if you embed them in the URL.

Example request:

curl "https://hi%40hi.com:Asdd45VvaarT4591@packagecloud.io/api/v1/token.json"
get/api/v1/token.json

Response

APIToken A JSON hash mapping the key token to your API token.

tokenstring

Your packagecloud API token, used for HTTP basic authentication on subsequent requests.

Example response

{
  "token": "f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0"
}