terminal://docs.cli
[ DOCUMENTATION ]

CLI

Manage your publishing queue from the terminal. The blurt CLI wraps the HTTP API — works against any Blurt server, local or remote.

Installation

The CLI lives in the cli/ directory of the Blurt repository:

git clone https://github.com/fberrez/blurt.sh.git
cd blurt.sh/cli
bundle install

Configuration

The CLI reads credentials in priority order: flags > environment variables > config file.

Environment variables

export BLURT_API_URL=http://localhost:3000   # default
export BLURT_API_KEY=your-secret-key

Config file

Credentials can also be stored in ~/.config/blurt/config.yml:

api_url: https://your-vps.com
api_key: your-secret-key

The config file is created with 0600 permissions (owner-only) to protect your API key.

Per-command flags

Override the URL or key for a single command:

blurt status --api-url https://your-vps.com --api-key your-key

Commands

Command Auth Description
blurt status No Show server health, queue counts, and configured platforms
blurt queue Yes List queued posts
blurt version No Print CLI version

blurt status

Check server health and queue overview. Does not require authentication (uses the /api/health endpoint).

$ blurt status

Blurt Status

  Server:     http://localhost:3000 (ok)
  Queue:      3 pending
  Sent:       42 total
  Failed:     1 total
  Platforms:  bluesky, mastodon, linkedin (3/6 configured)
  Worker:     connected (polling every 60s)

blurt queue

List posts in the queue. Requires BLURT_API_KEY.

$ blurt queue

3 post(s):

  FILENAME            PLATFORMS           STATUS  SCHEDULED
  hello.md            bluesky, mastodon   queue   —
  big-announce.md     bluesky, linkedin   queue   2026-04-01T09:00:00Z
  devto-article.md    devto               queue   —

Filter by status or platform:

# Show sent posts only
blurt queue --status sent

# Show failed posts for bluesky
blurt queue --status failed --platform bluesky

# Show everything
blurt queue --status all

How it works

The CLI is a thin client that talks to the Blurt HTTP API. It does not import Rails models or access the filesystem directly. This means it works against any Blurt server — your local dev server, a remote VPS, or a Docker container.

blurt CLI  ---->  HTTP API (localhost:3000 or remote)  ---->  Blurt engine

Built with Thor and Faraday.