ChirpieDocs
CLI

CLI Overview

Install and authenticate the Chirpie command-line interface.

The Chirpie CLI lets you post, manage accounts, and handle API keys from your terminal.

Installation

npm install -g chirpie
yarn global add chirpie
pnpm add -g chirpie

Or use directly with npx:

npx chirpie post "Hello from the CLI!"

Authentication

chirpie login

This opens your browser, signs you in, and saves an API key to ~/.chirpie/config.json automatically.

Manual Key

chirpie auth --key chirpie_sk_YOUR_KEY

Or set the environment variable:

export CHIRPIE_API_KEY=chirpie_sk_YOUR_KEY

The CHIRPIE_API_KEY environment variable takes precedence over the config file.

Check Status

chirpie whoami

Logout

chirpie logout

Removes the config file at ~/.chirpie/config.json.

Config File

The CLI stores its config at ~/.chirpie/config.json with 0600 permissions (readable only by your user):

{
  "api_key": "chirpie_sk_...",
  "base_url": "https://chirpie.ai"
}

Confirmation Prompts

Commands that cannot be undone ask before they run: chirpie accounts disconnect <id>, which ends a connection and cancels that account's scheduled posts, and chirpie comments delete. In a script or any other non-interactive shell there is nobody to ask, so pass -y (--yes) or the command stops without doing anything.

chirpie accounts disconnect 550e8400-e29b-41d4-a716-446655440000 -y

IDs

Listings print a short ID, the first eight characters of the full one. Wherever a command takes an account, post, key or comment ID it accepts either: the short ID from chirpie accounts, chirpie posts, chirpie keys or chirpie comments list, or the full ID from --json. That covers -a and the keys of --config when posting, too. A group ID (chirpie posts --group) is the full one a multi-account post returned.

chirpie accounts disconnect 90208e20 -y
chirpie posts delete 2e7e8e95

A short ID is matched against your own accounts, posts, keys or comments, and it has to name exactly one of them. When it matches none, or more than one, the command stops without doing anything and says which, so type a few more characters or pass the full ID. A short post ID is looked up among your 1,000 most recent posts, and a short draft ID among your 1,000 most recent drafts. A short comment ID is looked up among a post's 1,000 most recent comments, so use the full ID for anything older.

Output Formats

All commands support --json for machine-readable output:

chirpie posts --json | jq '.[] | .id'

On a subcommand the flag works in either position, before or after the arguments:

chirpie accounts deactivate 550e8400-e29b-41d4-a716-446655440000 --json
chirpie accounts --json deactivate 550e8400-e29b-41d4-a716-446655440000

Without --json, output is formatted as human-readable tables and messages.

On this page