Skip to content

CLI Reference

ATF CLI Documentation

Install, run your first trade, explore advanced commands.

Pinned version: @trucore/atf@1.5.1

Install the CLI

Run directly with npx. No install needed.

npx @trucore/atf@1.5.1 trade

Try a protected trade

atf trade

When you run this: ATF evaluates a trade, shows the decision, and generates a receipt. No real transaction is submitted.

Run This First: Doctor

Run doctor to check your environment, RPC connectivity, and confirm the CLI is working.

Health check

npx @trucore/atf@1.5.1 doctor

If doctor passes, you are ready to simulate, sign, and verify. If something is wrong, doctor tells you exactly what to fix.

Full doctor reference →

Common Dev Flows

Devnet Burner

Switch your active profile to devnet and run test transactions safely.

Start burner

npx @trucore/atf@1.5.1 burner --network devnet

Full burner guide →

Helius RPC Setup

Configure a Helius RPC endpoint for reliable mainnet and devnet access.

Set RPC

npx @trucore/atf@1.5.1 rpc set --provider helius --api-key YOUR_KEY

Full RPC guide →

Simulate, Verify, Execute

The core ATF workflow: simulate a transaction, verify the receipt, then execute with confidence.

Full flow

npx @trucore/atf@1.5.1 simulate --preset swap_small --verify

Transaction reference →

RPC Ping

Quick latency check to confirm your RPC endpoint is reachable and responsive.

Ping

npx @trucore/atf@1.5.1 rpc ping

RPC reference →

Guides

Step-by-step walkthroughs for common workflows. Each guide includes prerequisites, copyable commands, expected outputs, and troubleshooting tips.

View all guides →

Command Reference

All ATF CLI commands grouped by category. Each command links to its detailed documentation page.

Environment

CommandDescription
atf doctorCheck your environment, RPC reachability, and CLI health.
atf whoamiShow active profile, wallet, and connection details.
atf lsList all configured profiles.
atf completionGenerate shell completion scripts for bash, zsh, or fish.

Profiles & Config

CommandDescription
atf profile createCreate a named configuration profile.
atf profile switchSwitch between profiles.
atf config setSet a configuration value for the active profile.
atf config getRead a configuration value.

Network

CommandDescription
atf rpc pingTest RPC endpoint latency and reachability.
atf rpc setConfigure a custom or Helius RPC endpoint.
atf burnerSwitch active profile to devnet for safe testing.

Transactions

CommandDescription
atf simulateRun a deterministic firewall simulation with policy evaluation.
atf tx signSign a transaction with the active wallet.
atf tx sendSubmit a signed transaction to the network.
atf tx statusCheck confirmation status of a submitted transaction.

Verification

CommandDescription
atf receipts verifyVerify receipt integrity locally via deterministic hash recomputation.
atf receipts listList locally cached receipts.

Deep Dive Pages

Each area of the CLI has a dedicated page with detailed examples, flags, and usage patterns.

Response Field Reference

Every simulation response contains these fields:

ok

Boolean. true when the request completed without errors.

verified

Boolean. true when the CLI confirmed receipt integrity locally.

decision

ALLOWED or BLOCKED. The deterministic policy outcome.

request_id

Unique identifier for this simulation request.

content_hash

Deterministic hash of the canonical response payload.

timestamp

ISO-8601 UTC timestamp when the decision was issued.

Verification Model

Every ATF decision produces a receipt. The receipt payload is serialized in a deterministic, canonical order so that anyone can recompute the same hash from the same fields.

When you pass --verify, the CLI re-serializes the response payload locally and compares the resulting digest to the content_hash returned by the server. If they match, integrity is confirmed.

No client secrets involved. The hash function and serialization rules are public. Any tool that follows the same canonical encoding can independently verify a receipt.

For a deeper look at what verification proves (and what it does not), see the Verification reference.

Example Simulation Output

{
  "ok": true,
  "verified": true,
  "decision": "ALLOWED",
  "request_id": "req_1234567890",
  "content_hash": "0xabc123...",
  "timestamp": "2026-02-27T18:42:11Z"
}

Receipt integrity verified locally via deterministic hashing.

Next Steps

  • Verification – understand what content_hash proves and how to use it in production.
  • Architecture – see what happens under the hood when the CLI calls ATF.
  • Security posture – review threat model, disclosure policy, and audit status.
  • CLI Guides – step-by-step walkthroughs for common workflows.

Wrong package name?

If you see npm ERR! 404 for @trucore/atf-cli, use the correct name: @trucore/atf

The published package is @trucore/atf. The binary is atf.