HeroPrompt
Back to docs
CLI Reference

CLI Configuration

How the HeroPrompt CLI stores and manages configuration.

Updated 2026-02-11

CLI Configuration

The HeroPrompt CLI stores all configuration in ~/.heroprompt/.

Directory Structure

text
~/.heroprompt/
├── config.json       # Auth token and user info
├── prompts/          # Synced prompts (by category/subcategory)
│   ├── productivity/
│   │   ├── excel/
│   │   └── word/
│   └── technology/
│       └── frontend/
└── skills/           # Synced Skills (by skill ID)
    └── mcp-server-builder/
        ├── skill.json
        └── steps/

Config File

config.json stores authentication state:

json
{
  "token": "hp_pat_...",
  "api_url": "https://heroprompt.store/api",
  "user_email": "you@example.com",
  "user_tier": "pro",
  "user_id": "abc-123",
  "token_created_at": "2026-02-11T10:00:00Z"
}

The config file is created with 0600 permissions (user-only readable) for security.

Custom API URL

Point the CLI at a different backend (e.g., local development):

bash
heroprompt login --token hp_pat_xxxxx --api-url http://localhost:8000/api

The custom URL is saved in config.json and used for all subsequent requests.

Personal Access Tokens

Tokens use the format hp_pat_ followed by 40-64 alphanumeric characters. They expire after 90 days by default.

Generate tokens in the Settings page under "Personal Access Tokens".

Token limits by tier:

TierMax Tokens
Free0
Starter1
Pro Kit3
Lifetime5

Resetting Configuration

To clear all config and start fresh:

bash
heroprompt logout

Or manually delete the directory:

bash
rm -rf ~/.heroprompt