Skip to content

Overview

View as Markdown

Use thru abi when your task is about ABI YAML files or ABI accounts, not program binaries.

  • you want to create, upgrade, finalize, close, or inspect an on-chain ABI account
  • you want to generate C, Rust, or TypeScript code from ABI YAML
  • you want to analyze ABI types, print layout IR, or preview generated helpers
  • you want to decode binary payloads against an ABI type
  • you need to flatten imports, prepare an ABI for publishing, or bundle dependencies for WASM-style consumers

Choose another family when:

  • you are deploying or upgrading binaries: Program
  • you are working with raw upload buffers: Uploader
  • you only need chain reads or transaction inspection: RPC or Transaction
CommandUse it forReadsWrites
thru abi account ...Manage on-chain ABI accounts.CLI config, ABI YAML, or ABI account address.Chain state and optional local YAML export.
thru abi codegen ...Generate typed client code from ABI YAML.ABI YAML files and imported dependencies.A generated source tree under an output directory.
thru abi analyze ...Inspect resolved types and preview helper output.ABI YAML files and imported dependencies.stdout only.
thru abi reflect ...Decode or validate binary payloads.ABI YAML files plus a binary data file.stdout JSON only.
thru abi flatten ...Collapse imports into one YAML file.ABI YAML files and imported dependencies.A flattened YAML file.
thru abi prep-for-publish ...Produce a publishable ABI YAML file.ABI YAML files and local imports.A publish-ready YAML file.
thru abi bundle ...Build a dependency manifest for tooling.ABI YAML files plus resolved imports.A JSON manifest file.
Terminal window
thru abi account create my_program ./program.abi.yaml
thru abi codegen --files ./program.abi.yaml --language typescript --output ./generated
thru abi reflect --abi-file ./program.abi.yaml --type-name TransferArgs --data-file ./payload.bin --pretty
  • The account subcommands are the only ABI commands here that mutate chain state.
  • The tooling commands are local file workflows, so they are safe to use before you publish anything on-chain.
  • The examples here use the thru abi ... form. The same tooling surface is also exposed by the standalone abi binary that lands with the same implementation.