pi-onecli-extension
OneCLI gateway integration for pi
Package details
Install pi-onecli-extension from npm and Pi will load the resources declared by the package manifest.
$ pi install npm:pi-onecli-extension- Package
pi-onecli-extension- Version
0.2.0- Published
- Apr 30, 2026
- Downloads
- not available
- Author
- krzyzanowskim
- License
- MIT
- Types
- extension
- Size
- 22.5 KB
- Dependencies
- 0 dependencies · 2 peers
Pi manifest JSON
{
"extensions": [
"./index.ts"
]
}Security note
Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.
README
pi-onecli-extension
OneCLI gateway integration for pi.
OneCLI is a credential and policy layer for AI agents. This extension helps pi run safely with the OneCLI gateway so pi can call external APIs without seeing raw API keys.
Features
onecli_gateway_statustool for non-sensitive gateway status.onecli_clitool for safe read-only OneCLI operations andonecli run --dry-runchecks./oneclicommand:/onecli status/onecli doctor/onecli refresh-skill/onecli launch [pi args...]
- Dynamic
onecli-gatewayskill generation whenonecliis installed or gateway env is active. - Active OneCLI guidance in pi's system prompt only when gateway env is detected.
- Guardrail that blocks model-initiated bash attempts to print
HTTPS_PROXY,HTTP_PROXY,PROXY_AUTH, orONECLI_API_KEY.
Install from a local checkout
pi install /path/to/pi-onecli-extension
Or test for one run without installing:
pi -e /path/to/pi-onecli-extension
Install from GitHub
After publishing this folder to GitHub:
pi install https://github.com/krzyzanowskim/pi-onecli-extension
Install from npm
After publishing to npm:
pi install npm:pi-onecli-extension
OneCLI setup
Install and authenticate OneCLI:
curl -fsSL https://www.onecli.sh/cli/install | sh
onecli auth login --api-key oc_...
Launch pi through OneCLI so pi and its tools inherit gateway proxy variables:
onecli run -- pi
# or continue the latest pi session
onecli run -- pi -c
Usage in pi
Reload after installing or editing:
/reload
Check status:
/onecli status
/onecli doctor
Show relaunch instructions:
/onecli launch pi -c
Security notes
This extension intentionally avoids printing proxy URLs, OneCLI API keys, and proxy auth material. The onecli_cli tool only exposes safe status/list/dry-run operations. It does not support creating, updating, deleting, or reading secret values.