Files
sonr/docs/reference/commands/snrd_genesis_gentx.mdx
T

82 lines
5.7 KiB
Plaintext
Raw Normal View History

2025-10-03 14:45:52 -04:00
---
title: snrd genesis gentx
description: Generate a genesis transaction that creates a validator with a self-delegation,
---
## Usage
```shell
snrd genesis gentx [key_name] [amount] [flags]
```
## Flags
2026-09-02 16:53:38 -04:00
<TypeTable
type={{
"account-number": { type: "string", description: "The account number of the signing account (offline mode only)" },
"amount": { type: "string", description: "Amount of coins to bond" },
"aux": { type: "string", description: "aux signer data instead of sending a tx" },
"broadcast-mode": { type: "string", default: "sync", description: "Transaction broadcasting mode (sync|async)" },
"chain-id": { type: "string", description: "The network chain ID" },
"commission-max-change-rate": { type: "string", description: "The maximum commission change rate percentage (per day)" },
"commission-max-rate": { type: "string", description: "The maximum commission rate percentage" },
"commission-rate": { type: "string", description: "The initial commission rate percentage" },
"details": { type: "string", description: "The validator's (optional) details" },
"dry-run": { type: "string", description: "the --gas flag and perform a simulation of a transaction, but don't broadcast it (when enabled, the local Keybase is not accessible)" },
"fee-granter": { type: "string", description: "Fee granter grants fees for the transaction" },
"fee-payer": { type: "string", description: "Fee payer pays fees for the transaction instead of deducting from the signer" },
"fees": { type: "string", description: "Fees to pay along with transaction; eg: 10uatom" },
"from": { type: "string", description: "Name or address of private key with which to sign" },
"gas": { type: "string", default: "200000", description: "gas limit to set per-transaction; set to \"auto\" to calculate sufficient gas automatically. Note: \"auto\" option doesn't always report accurate results. Set a valid coin value to adjust the result. Can be used instead of \"fees\"." },
"gas-adjustment": { type: "float", default: "1", description: "adjustment factor to be multiplied against the estimate returned by the tx simulation; if the gas limit is set manually this flag is ignored" },
"gas-prices": { type: "string", description: "Gas prices in decimal format to determine the transaction fee (e.g. 0.1uatom)" },
"generate-only": { type: "string", description: "an unsigned transaction and write it to STDOUT (when enabled, the local Keybase only accessed when providing a key name)" },
"help": { type: "string", description: "for gentx" },
"home": { type: "string", default: "/Users/prad/.sonr", description: "The application home directory" },
"identity": { type: "string", description: "The (optional) identity signature (ex. UPort or Keybase)" },
"ip": { type: "string", default: "192.168.1.203", description: "The node's public P2P IP" },
"keyring-backend": { type: "string", default: "os", description: "Select keyring's backend (os|file|kwallet|pass|test|memory)" },
"keyring-dir": { type: "string", description: "The client Keyring directory; if omitted, the default 'home' directory will be used" },
"ledger": { type: "string", description: "a connected Ledger device" },
"min-self-delegation": { type: "string", description: "The minimum self delegation required on the validator" },
"moniker": { type: "string", description: "The validator's (optional) moniker" },
"node": { type: "string", default: "tcp://localhost:26657", description: "&lt;host&gt;:&lt;port&gt; to CometBFT rpc interface for this chain" },
"node-id": { type: "string", description: "The node's NodeID" },
"note": { type: "string", description: "Note to add a description to the transaction (previously --memo)" },
"offline": { type: "string", description: "mode (does not allow any online functionality)" },
"output-document": { type: "string", description: "Write the genesis transaction JSON document to the given file instead of the default location" },
"p2p-port": { type: "string", default: "26656", description: "The node's public P2P port" },
"pubkey": { type: "string", description: "The validator's Protobuf JSON encoded public key" },
"security-contact": { type: "string", description: "The validator's (optional) security contact email" },
"sequence": { type: "string", description: "The sequence number of the signing account (offline mode only)" },
"sign-mode": { type: "string", description: "Choose sign mode (direct|amino-json|direct-aux|textual), this is an advanced feature" },
"timeout-height": { type: "string", description: "Set a block timeout height to prevent the tx from being committed past a certain height" },
"tip": { type: "string", description: "Tip is the amount that is going to be transferred to the fee payer on the target chain. This flag is only valid when used with --aux, and is ignored if the target chain didn't enable the TipDecorator" },
"website": { type: "string", description: "The validator's (optional) website" },
"yes": { type: "string", description: "tx broadcasting prompt confirmation" },
}}
/>
2025-10-03 14:45:52 -04:00
## Global Flags
2026-09-02 16:53:38 -04:00
<TypeTable
type={{
"log_format": { type: "string", default: "plain", description: "The logging format (json|plain)" },
"log_level": { type: "string", default: "info", description: "The logging level (trace|debug|info|warn|error|fatal|panic|disabled or '*:&lt;level&gt;,&lt;key&gt;:&lt;level&gt;')" },
"log_no_color": { type: "string", description: "colored logs" },
"trace": { type: "string", description: "out full stack trace on errors" },
}}
/>
2025-10-03 14:45:52 -04:00
## Examples
### Generate genesis transaction
```shell
snrd genesis gentx alice 1000000snr --chain-id sonrtest_1-1
```
## See Also
2026-09-02 16:53:38 -04:00
- [snrd genesis](./snrd_genesis) - Parent command