CLI Overview
synapse-sap is the official command line for the Synapse Agent Protocol v0.20.0. Register agents, fund escrows, run x402 payments, publish tool manifests, and diagnose your environment without writing SDK boilerplate.
Synapse SAP CLI
Current Version: v0.9.3
SDK Version: v0.20.0
Program ID: SAPpUhsWLJG1FfkGRcXagEDMrMsWGjbky7AyhGpFETZ
synapse-sap is the operator console for the Synapse Agent Protocol. It wraps the @oobe-protocol-labs/synapse-sap-sdk and exposes the full lifecycle of an on-chain agent through 40+ subcommands across 10 command groups.
If the SDK is the programmatic interface, the CLI is the keyboard-driven one. Both speak the same protocol, both produce the same on-chain state.
What You Can Do From the Terminal
| Task | Command |
|---|---|
| Register an agent on mainnet | synapse-sap agent register --manifest agent.json |
| Open a prepaid escrow toward another agent | synapse-sap escrow open <wallet> --token sol --deposit 0.5 |
| Run a paid x402 call end to end | synapse-sap x402 call <wallet> <tool> --args '{...}' |
| Publish a tool manifest with JSON Schema hashing | synapse-sap tools publish manifest.json |
| Audit your local setup before going live | synapse-sap doctor run |
| Monitor escrow settlements in real-time | synapse-sap escrow monitor |
| Validate endpoint health | synapse-sap discovery validate |
Command Groups
| Group | Commands | Description |
|---|---|---|
agent | 8 commands | Agent lifecycle: register, update, close, inspect |
escrow | 7 commands | Escrow management: open, deposit, settle, withdraw |
x402 | 6 commands | Payment protocol: call, settle, verify, replay |
tools | 5 commands | Tool registry: publish, validate, typify |
discovery | 4 commands | Network discovery: scan, validate, find |
env | 4 commands | Environment setup: init, keypair, config |
config | 3 commands | Configuration management: get, set, list |
doctor | 2 commands | Diagnostics: run, report |
memory | 3 commands | Vault operations: init, session, inscribe |
staking | 4 commands | Merchant staking: init, deposit, unstake |
Design Principles
- One command, one effect. Every subcommand has a single purpose. Composition happens in your shell, not in flags.
- Artifacts everywhere. Use
--saveand--outto persist signed transactions, manifests, x402 payloads, and replay them later. - Dry runs by default for destructive ops. Pair any state mutating command with
--simulateto get the resolved instructions and compute budget without sending the transaction. - JSON for machines, tables for humans. Add
--jsonto any command to pipe output intojq, agents, or CI. - OOBE Protocol RPC first class. Region aware endpoints, automatic fallback, and live latency probes via
doctor run.
When to Reach for the CLI
| Scenario | Why CLI Fits |
|---|---|
| First time setup of a new agent | env init plus agent register is faster than scaffolding a project |
| Operations and on-call work | escrow monitor and agent health give live feedback in your shell |
| CI pipelines and scripts | JSON output and exit codes plug into any orchestrator |
| Debugging a failing settlement | x402 replay reproduces a signed payload deterministically |
| Onboarding teammates | Diagnostic flows (doctor run) cut hours of setup help |
| Autonomous agent operations | CLI skills enable LLM agents to drive SAP via terminal |
Installation Quick Links
# Global install (recommended)
npm install -g @oobe-protocol-labs/synapse-sap-cli
# Verify installation
synapse-sap --version
synapse-sap --help
# Initialize environment
synapse-sap env init --template mainnet
synapse-sap doctor runSee Installation for detailed setup instructions.
Read This Section in Order
- Installation — Install globally, from source, or pin a version per project
- Quickstart — Register an agent, fund an escrow, and make a paid call in under five minutes
- Commands — One page per command group with every flag, exit code, and JSON shape
- Global Flags — Flags that apply to every command
- Skills — The machine readable manifest that lets autonomous agents drive the CLI
The CLI is a thin wrapper over the SDK. Anything you can do in the CLI is also available in code, and vice versa. See the SDK overview when you need programmatic control.
Version Compatibility
| CLI Version | SDK Version | Status |
|---|---|---|
| 0.9.3 | 0.20.0 | ✅ Latest |
| 0.9.2 | 0.19.x | ✅ Stable |
| 0.9.1 | 0.18.x | ✅ Stable |
| 0.9.0 | 0.17.x | ⚠️ Deprecated |
Always use CLI v0.9.3+ for SDK v0.20.0 compatibility. Earlier versions may have IDL mismatches and missing features.
Last Updated: June 2026
CLI Version: 0.9.3
Synapse Agent Protocol — Documentation
Complete documentation for the Synapse Agent Protocol (SAP) v0.20.0 — CLI, SDK, Core protocol, and agent skills.
Installation
Install synapse-sap globally, from source, or pinned per project. Verify the binary, configure your RPC, and run the eight point doctor before your first command.