The Prompting Company CLI gives you terminal access to your workspace, organizations, and simulation workflows.
The binary name is:
Prerequisites
- macOS, Linux, or Windows
amd64 or arm64
Install
macOS and Linux
Install the latest stable release:
curl -fsSL https://cli.promptingco.com/install.sh | bash
After install, confirm the binary is available:
Windows
Install with winget:
winget install promptingcompany.tpc
Or install with Scoop after adding The Prompting Company bucket:
scoop bucket add promptingcompany https://github.com/promptingcompany/scoop-bucket
scoop install tpc
PowerShell is also supported:
irm https://cli.promptingco.com/install.ps1 | iex
If your execution policy blocks the installer, run this first in the same
PowerShell session:
Set-ExecutionPolicy -Scope Process Bypass
Manual fallback:
-
Download the latest
tpc_<version>_windows_amd64.zip or
tpc_<version>_windows_arm64.zip from
https://cli.promptingco.com/tpc/<version>/.
-
Extract
tpc.exe.
-
Move
tpc.exe to a directory on PATH, or add the new directory to PATH
through System Properties -> Environment Variables -> Path.
-
Open a new PowerShell or cmd session, then verify the install:
Update
Check whether a newer CLI build is available:
Upgrade the installed binary in place:
Install a specific version
Install a pinned version:
TPC_VERSION=0.1.0-alpha.1 curl -fsSL https://cli.promptingco.com/install.sh | bash
Install from a release channel:
TPC_CHANNEL=alpha curl -fsSL https://cli.promptingco.com/install.sh | bash
Login
Authenticate with browser-based device flow:
The CLI uses the OAuth bearer path described in the
API authentication guide.
The flow is:
tpc requests a device code.
- Your browser opens.
- You sign in to The Prompting Company.
- You approve the CLI.
- The CLI stores your session locally.
After login, verify your session:
Logout when needed:
Non-interactive authentication
For CI, scripts, and other headless environments where browser login is not available, the CLI reads credentials from environment variables. Two schemes are supported and they map to different request headers:
| Variable | Header sent | Use for |
|---|
TPC_API_TOKEN | Authorization: Bearer <token> | OAuth bearer tokens — for example, the session token issued by tpc auth login. |
TPC_API_KEY | x-api-key: <key> | API keys created via the dashboard. See API authentication for how to create one. |
# OAuth bearer token
export TPC_API_TOKEN="your-bearer-token"
tpc auth whoami
# API key
export TPC_API_KEY="your-api-key"
tpc auth whoami
If both TPC_API_TOKEN and TPC_API_KEY are set, the CLI uses TPC_API_TOKEN and prints a warning to stderr.
When neither variable is set, the CLI falls back to the session created by tpc auth login.
Organizations
List organizations available to your account:
Switch the saved active organization:
tpc org switch prompting-co
Common commands
# Show current auth state
tpc auth whoami
# Show installed CLI version
tpc version
tpc --version
# Check for updates
tpc update --check
# Install latest update
tpc update
# List organizations
tpc org list
# Switch active organization
tpc org switch prompting-co
# List pages for the active product
tpc product switch my-product
tpc site page list
# Show simulation command help
tpc sim help
# Show environment list help without requiring auth
tpc env list -h
# List simulation environments
tpc env list
Site pages
Manage pages for the active product from the terminal. Every command is scoped to the active organization and product stored in local CLI config, and every JSON response includes the resolved scope.
Run tpc org switch <org-slug> and tpc product switch <product-slug> before any tpc site page command, or the CLI will refuse with guidance.
List pages for the active product:
Filter the list (search, status, path prefix, pagination, sort):
tpc site page list \
--query pricing \
--status published \
--path-prefix blog/ \
--page 2 --page-size 10 \
--order-by createdAt --order-dir asc
Create a page from inline markdown:
tpc site page create \
--slug blog/hello-world \
--title "Hello" \
--content "# Hello"
Create a page from a local markdown file:
tpc site page create \
--slug docs/install \
--title "Install" \
--content-file ./install.md
Update page fields (only the flags you pass are changed):
tpc site page update page_123 --title "Updated title"
tpc site page update page_123 --content-file ./page.md --status published
Pass an empty string to clear an optional field:
tpc site page update page_123 --redirect-url ""
tpc site page update page_123 --content ""
Soft-delete one or more pages:
tpc site page delete page_123
tpc site page delete page_123 page_456
Every command also supports --format json for scripting:
tpc site page list --format json
Simulation environment commands
Create a simulation environment:
tpc sim env create \
--name "My Environment" \
--agent-config '{"harness":"claude","model":"claude-sonnet-4-6"}'
Create an environment with task links and schedule:
tpc sim env create \
--name "Test Env" \
--agent-config @examples/agent-config.json \
--task-ids task_123,task_456 \
--schedule 7d
Installer URL
The public installer is served from:
https://cli.promptingco.com/install.sh
https://cli.promptingco.com/install.ps1
Troubleshooting
tpc command not found
- Open a new shell after installation.
- Check whether the installer added the binary directory to your
PATH.
- Run the installer again and watch for shell profile update instructions.
- On Windows,
PATH changes only apply to new PowerShell or cmd sessions.
Login completes in the browser but CLI does not update
- Retry
tpc auth login
- complete the device flow in the same machine where the CLI is running
- check whether your browser blocked the callback or redirected into a stale session
Update does not find a release
- run
tpc update --check
- confirm you are on the expected channel or pinned version
- if you installed a prerelease, make sure that prerelease metadata exists
Next step
Once installed and authenticated, you can move into product and simulation workflows from the terminal.