Skip to content

CLI › Transactions

Transactions

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

Permit Parameters and Enforcement Model

Every ATF transaction begins with a permit: a structured declaration of intent that describes what the transaction is allowed to do. Today, swap permits are the primary type. The model is extensible to other permit types in the future.

Where parameters are defined

Permit parameters can be supplied from several sources. When multiple sources are present, ATF uses the most explicit input as the source of truth:

  1. CLI flags (highest priority, e.g. --slippage-bps 50)
  2. Policy JSON file (referenced via --policy)
  3. Preset selection (e.g. --preset swap_small)
  4. Profile config (defaults set in the active profile)

Explicit CLI flags override policy file values, which override preset defaults, which override profile-level configuration.

What ATF enforces

  • Allowed mint pairs (input and output tokens)
  • Maximum amount and size bounds
  • Slippage bounds (basis points)
  • Protocol allowlist (e.g. Jupiter)
  • TTL and expiry on permits
  • Nonce and replay protection
  • Network constraints (devnet vs mainnet)
  • Deterministic receipt hashing and verification

What ATF does not do

  • Choose slippage for you
  • Choose token pairs on your behalf
  • Decide trade sizes
  • Custody your private keys
  • Auto-route trades or execute without developer intent

The developer defines intent. ATF enforces and proves it. You declare what your transaction should do, within what bounds, and for which tokens. ATF evaluates that intent against the active policy, produces a deterministic receipt, and gives you a verifiable proof that the rules were applied correctly. ATF never invents trade parameters or makes decisions on your behalf.

For a full glossary of swap permit parameters, see the Swap Permits guide →

Simulate

Run a deterministic firewall simulation with policy evaluation. The CLI calls the ATF API with your transaction payload, receives a policy decision, and optionally verifies receipt integrity.

Simulate with preset

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

Simulate with custom payload

npx @trucore/atf@1.5.1 simulate --payload ./my-tx.json --verify

Simulate, Verify, Execute

The recommended workflow for production-grade safety:

  1. Simulate the transaction against the ATF policy engine.
  2. Verify the receipt locally using --verify. The CLI recomputes the content hash and confirms it matches the server response.
  3. Execute only if the decision is ALLOWED and verification passes.

Full flow

npx @trucore/atf@1.5.1 simulate --preset swap_small --verify && npx @trucore/atf@1.5.1 tx send --receipt last

Sign

Sign a transaction with the wallet from your active profile.

Sign transaction

npx @trucore/atf@1.5.1 tx sign --payload ./my-tx.json

Send

Submit a signed transaction to the network.

Send transaction

npx @trucore/atf@1.5.1 tx send --signed ./signed-tx.json

Send using last receipt

npx @trucore/atf@1.5.1 tx send --receipt last

Check Status

Check confirmation status of a submitted transaction by signature.

Check status

npx @trucore/atf@1.5.1 tx status --sig 5UBb...xYz3
Transaction: 5UBb...xYz3
Status: confirmed
Confirmations: 31
Slot: 284,291,088
Block time: 2026-02-27T19:01:22Z

Available Presets

PresetDescription
swap_smallSmall token swap under policy limits.
swap_largeLarger swap that may trigger policy limits.
transferSimple SOL transfer with basic policy checks.

Common Flags

FlagDescription
--preset <name>Use a built-in test payload.
--payload <path>Path to a custom JSON transaction payload.
--verifyLocally verify receipt integrity after simulation.
--jsonOutput results as JSON for scripting.
--receipt lastReference the most recent simulation receipt.