gen client exposes the read-side of the network: every JSON-RPC query method has a matching subcommand. This page covers the pure read commands. For balance and transfer commands that move tokens, see Sending transfers. For activation build/sign/submit and tracing, see Working with activations.
All gen client commands accept the global --rpc-url <URL> (-s), --header <NAME=VALUE>, and --json (-j) flags. JSON mode emits a single envelope:
ok is false, a code field is set (for example TransportError), and error carries the message. Use --json for any scripted consumption; text mode is for humans.
Accounts
gen client get-account
Fetch the components installed on an account and its owner.
--account <ACCOUNT>: bech32mGvmAccount(grd@HRP).
Balances (read-only)
gen client balance and gen client balances are documented with the rest of the balance and transfer surface in Sending transfers. They are listed here for completeness:
gen client balancequeries a single token contract for a wallet or account.gen client balancesreturns every routed balance for a wallet or account.
--wallet <NAME> (a local wallet) or --account <ACCOUNT> (any on-chain account). If neither is supplied, the active wallet is used.
Blocks
gen client get-current-block-index
Return the latest finalized block index known to the RPC unit. Useful for picking a valid_until_block when building activations.
u64 precision in JSON.
gen client get-block
Return the aggregated closed block at a given index.
--block-index <INDEX>: block index as a decimal integer.
Contracts
gen client get-contract
Return contract metadata and all component ABIs for a deployed contract.
--contract <CONTRACT>: deployed contract identifier (bech32m,grd@HRP). This is the identifier printed bygen client deploy.
gen client get-abi-by-contract-id
Return only the ABIs (no metadata) for a deployed contract. Useful when you just need to look up function signatures.
--contract <CONTRACT>: deployed contract identifier.
--output-file <PATH>: write the pretty-printed ABI JSON to a file. Without--json, stdout shows only a confirmation line instead of dumping the full ABI; with--json, the ABI is in both stdout and the file.
gen client get-abi-by-contract-code-id
Same shape as get-abi-by-contract-id, but takes a contract code ID, not a deployed contract ID. This is the identifier returned by gen client push before you deploy.
--contract-code-id <CONTRACT_CODE_ID>: code ID frompushoutput.
--output-file flag as get-abi-by-contract-id.
Components
gen client get-component
Return the ABI and owner for a single component instance on a specific entity.
--gvm-component-id <COMPONENT_ID>: the component ID. Short form is two comma-separated bech32m parts (grd@<entity+index>,grd@<contract>); full form is four parts (grd@<entity+index>,grd@<contract>,grd@<contract_code_id>,grd@<component_type_index>).
view, build-activation, get-storage-at). The full form pins a specific contract code and component type; use it when you need to disambiguate versions.
gen client view
Execute a read-only call against a component. No state changes; no signature required.
--component-id <COMPONENT_ID>: target component ID (short or full form, as forget-component).--method <METHOD>: contract method name.
--params <JSON_OBJECT>: method parameters as a JSON object keyed by parameter name.
view is the read counterpart to build-activation + submit-activation: the parameter encoding is identical, but no activation is built and no signature is required.
gen client get-storage-at
Return the raw storage value for a component at a specific 32-byte key.
--gvm-component-id <COMPONENT_ID>: target component ID.--storage-key <KEY>: 32-byte storage key as0x-prefixed hex (64 characters).
null if the key is unset. This is a low-level escape hatch: prefer view against a contract method when one exists.
Traces
gen client get-trace
Return every activation ID that participated in a trace. A trace groups the original activation with every continuation it produced across entities. See Traces for the concept.
--trace-id <0x...>: trace ID (128 hex characters,0x-prefixed).
gen client get-activation --activation-id <id> on each ID. See Working with activations for the full pattern.
Output formatting for scripts
Use--json and pipe through jq for any non-interactive use. The envelope shape is stable across commands, so the same script pattern works everywhere:
See also
- Sending transfers:
balance,balances,transfer, andfaucet. - Working with activations: build, sign, submit, simulate, and inspect activations.
- JSON-RPC API: the RPC methods these commands wrap, with parameter and response schemas.

