Skip to main content
cops auth login walks you through a series of prompts to configure a named profile. Each profile stores the base URLs and credentials for one or more Atlassian Data Center products. After saving, the new profile is automatically set as the active profile.

Usage

cops auth login
This command takes no flags. All input is collected interactively.

Interactive wizard

The wizard prompts for:
  1. Profile name — a short identifier you choose (e.g. dc-prod, staging). If a profile with this name already exists, it is overwritten.
  2. For each product (jira, confluence, bitbucket, bamboo) — whether to configure it, and if so:
    • Base URL (e.g. https://jira.example.com)
    • Auth type: bearer (default) or basic
    • Credentials for the chosen auth type
Example session:
Profile name (e.g. dc-prod): dc-prod
Configure jira? (y/n): y
  jira base URL (e.g. https://jira.company.com): https://jira.example.com
  jira auth type [bearer/basic] (default: bearer): bearer
  jira PAT/token: ••••••••
Configure confluence? (y/n): y
  confluence base URL (e.g. https://confluence.company.com): https://confluence.example.com
  confluence auth type [bearer/basic] (default: bearer): basic
  confluence username: svc-account
  confluence token/password: ••••••••
Configure bitbucket? (y/n): y
  bitbucket base URL (e.g. https://bitbucket.company.com): https://bitbucket.example.com
  bitbucket auth type [bearer/basic] (default: bearer): bearer
  bitbucket PAT/token: ••••••••
Configure bamboo? (y/n): n
Saved profile 'dc-prod' and set as current.
You can skip any product by entering n. Only the products you configure will have entries in the saved profile.

Auth types

Sends your Personal Access Token in the Authorization: Bearer <pat> header.This is the recommended auth type for Atlassian Data Center. Generate a PAT in your Atlassian product under Profile > Personal Access Tokens.
{
  "baseUrl": "https://jira.example.com",
  "authType": "bearer",
  "pat": "<your-pat>"
}
Sends your username and token as a Base64-encoded Authorization: Basic <base64(username:token)> header.Use basic auth when your instance does not support PATs or when you need to authenticate with a service account username and password.
{
  "baseUrl": "https://jira.example.com",
  "authType": "basic",
  "username": "service-account",
  "token": "<password-or-token>"
}

Where credentials are stored

Profiles are saved to a single config.json file:
PlatformPath
Linux / macOS~/.config/cops/config.json
Windows%APPDATA%\cops\config.json
On Linux and macOS, cops sets the file permissions to 0600 (owner read/write only) every time it writes the config.
Do not commit config.json to version control. It stores credentials in plain text. See Security for guidance on PAT rotation and access restriction.

cops auth profiles

List all configured profiles and see which is active.

cops auth use

Switch the active profile.

Auth profiles guide

In-depth guide to profile structure and management.

Security

PAT rotation, file permissions, and credential hygiene.

Build docs developers (and LLMs) love