Reference

CLI Reference

Evaluate actions, store facts, and manage your governance control plane from the terminal.

1Installation

npm (Node.js)

npm install -g @exogram/cli

pip (Python)

pip install exogram-cli

Homebrew (macOS)

brew install exogram/tap/exogram

Docker

docker pull exogram/cli:latest

Verify installation: exogram --version

2Quick Start

# Authenticate
$ exogram auth login --key sk_exo_your_key_here

# Store a fact
$ exogram store "Deployment requires 2FA approval" --source policy --tags security

# Evaluate an action
$ echo '{"action":"delete_user","target":"user_123"}' | exogram evaluate --stdin

# Search your ledger
$ exogram search "deployment policy"

3Command Reference

exogram auth login

Authenticate with your Exogram account. Opens browser for OAuth or accepts an API key directly.

Usage

exogram auth login [--key sk_exo_...]

Options

--keyProvide API key directly instead of browser OAuth
--profileSave credentials under a named profile (default: "default")

Example

$ exogram auth login
✓ Browser opened. Waiting for authentication...
✓ Authenticated as richard@exogram.ai
✓ API key saved to ~/.exogram/credentials
exogram evaluate

Evaluate a proposed action against your governance constraints. Returns PERMIT or DENY with a full rule trace.

Usage

exogram evaluate <payload.json> [--format json|table]

Options

<payload.json>Path to JSON file containing the action payload
--stdinRead payload from stdin (pipe-friendly)
--formatOutput format: json (default) or table
--dry-runEvaluate without creating an evaluation record

Example

$ exogram evaluate payload.json --format table
┌──────────────────────────────────┐
│ Verdict:  DENY                   │
│ Rule:     compute_execution_guard│
│ Latency:  0.07ms                 │
│ Hash:     sha256:a3f8...         │
│ Eval ID:  eval_abc123            │
└──────────────────────────────────┘
exogram commit

Commit a previously evaluated action. Requires a valid evaluation ID that has not expired.

Usage

exogram commit <evaluation_id>

Options

<evaluation_id>The evaluation ID returned from `evaluate`
--forceSkip confirmation prompt

Example

$ exogram commit eval_abc123
✓ State hash verified (no drift detected)
✓ Action committed to immutable ledger
  Record: action_xyz789
exogram store

Store a verified fact in the semantic ledger with automatic PII scrubbing and conflict detection.

Usage

exogram store "<content>" [--source <source>] [--tags <tags>]

Options

"<content>"The fact or claim to store
--sourceProvenance attribution (e.g., "planning-doc", "user-stated")
--tagsComma-separated tags for categorization
--confidenceConfidence score 0.0-1.0 (default: 0.9)
--lockLock this fact (cannot be contradicted without explicit unlock)

Example

$ exogram store "API rate limit is 300 RPM for Pro tier" --source docs --tags api,limits
✓ PII scan: clean
✓ Conflict check: no contradictions
✓ Stored: fact_def456
  Vector: embedded in namespace user_abc
exogram status

Check connection status, API health, and current account tier.

Usage

exogram status

Example

$ exogram status
Exogram CLI v1.2.0
  API:      https://api.exogram.ai ✓ healthy (0.07ms)
  Account:  richard@exogram.ai
  Tier:     Pro (50,000 evals/month)
  Used:     12,847 / 50,000 (25.7%)
  Profile:  default
exogram ledger list

List recent ledger entries with filtering and pagination.

Usage

exogram ledger list [--limit <n>] [--tag <tag>]

Options

--limitNumber of entries to show (default: 20)
--tagFilter by tag
--sinceShow entries after this date (ISO 8601)
--jsonOutput raw JSON

Example

$ exogram ledger list --limit 5 --tag api
Showing 5 of 23 entries tagged "api"
  fact_def456  API rate limit is 300 RPM...      2h ago   ●
  fact_ghi789  Webhook retry policy is 3x...     1d ago   ●
  ...
exogram init

Initialize Exogram in your project directory. Creates a .exogramrc config file.

Usage

exogram init [--ci]

Options

--ciGenerate CI/CD-optimized config (GitHub Actions, GitLab CI)

Example

$ exogram init
✓ Created .exogramrc
✓ Added to .gitignore
  
Configure your governance rules in .exogramrc

4Configuration (.exogramrc)

# .exogramrc — project-level Exogram configuration
# Generated by `exogram init`

[profile]
api_key_env = "EXOGRAM_API_KEY"    # Environment variable for API key
base_url = "https://api.exogram.ai" # API base URL

[defaults]
format = "table"                    # Default output format (json|table)
confidence = 0.9                    # Default confidence for stored facts
top_k = 5                           # Default search results count

[ci]
fail_on_deny = true                 # Exit code 1 if evaluation returns DENY
timeout = 5000                      # Request timeout in ms
retry = 3                           # Number of retries on failure

5CI/CD Integration

GitHub Actions

# .github/workflows/governance.yml
name: Exogram Governance Check
on: [push, pull_request]
jobs:
  evaluate:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - name: Install Exogram CLI
        run: npm install -g @exogram/cli
      - name: Evaluate deployment
        env:
          EXOGRAM_API_KEY: ${{ secrets.EXOGRAM_API_KEY }}
        run: |
          exogram evaluate deploy-payload.json --format json
          if [ $? -ne 0 ]; then
            echo "❌ Governance check failed"
            exit 1
          fi

GitLab CI

# .gitlab-ci.yml
governance-check:
  image: exogram/cli:latest
  script:
    - exogram auth login --key $EXOGRAM_API_KEY
    - exogram evaluate deploy-payload.json
  rules:
    - if: $CI_PIPELINE_SOURCE == "merge_request_event"

6Environment Variables

VariableDescriptionDefault
EXOGRAM_API_KEYAPI key for authentication
EXOGRAM_BASE_URLAPI base URLhttps://api.exogram.ai
EXOGRAM_PROFILENamed credential profiledefault
EXOGRAM_FORMATDefault output formatjson
EXOGRAM_TIMEOUTRequest timeout (ms)5000
EXOGRAM_NO_COLORDisable colored outputfalse

Ready to get started?

Install the CLI and evaluate your first action in under 2 minutes.