Ask or search…
⌃K
Links

Other Useful Commands

Commonly used Command Line Interface (CLI) scripts

Get versions

agd version
Sample Result
0.35.0-u11.0

Get verbose versions

agd version --long
Sample Result
name: agoriccosmos
server_name: agd
version: 0.35.0-u11.0
commit: 92b6cd724
build_tags: ledger
go: go version go1.20.8 linux/amd64
build_deps:
- filippo.io/[email protected]
- github.com/99designs/[email protected] => github.com/cosmos/[email protected]
- github.com/ChainSafe/[email protected]
- github.com/Workiva/[email protected]
- github.com/armon/[email protected]
- github.com/beorn7/[email protected]
- github.com/bgentry/[email protected]
- github.com/btcsuite/[email protected]
- github.com/cespare/xxhash/[email protected]
- github.com/coinbase/[email protected]
- github.com/confio/ics23/[email protected] => github.com/agoric-labs/cosmos-sdk/ics23/[email protected]
- github.com/cosmos/[email protected]
- github.com/cosmos/[email protected] => github.com/agoric-labs/[email protected]
- github.com/cosmos/[email protected]
- github.com/cosmos/[email protected]
- github.com/cosmos/ibc-go/[email protected]
- github.com/cosmos/[email protected]
- github.com/cosmos/[email protected]
- github.com/creachadair/[email protected]
- github.com/davecgh/[email protected]
- github.com/desertbit/[email protected]
- github.com/dvsekhvalnov/[email protected]
- github.com/felixge/[email protected]
- github.com/fsnotify/[email protected]
- github.com/go-kit/[email protected]
- github.com/go-kit/[email protected]
- github.com/go-logfmt/[email protected]
- github.com/godbus/[email protected]
- github.com/gogo/[email protected]
- github.com/gogo/[email protected] => github.com/regen-network/[email protected]
- github.com/golang/[email protected]
- github.com/golang/[email protected]
- github.com/google/[email protected]
- github.com/google/[email protected]
- github.com/gorilla/[email protected]
- github.com/gorilla/[email protected]
- github.com/gorilla/[email protected]
- github.com/grpc-ecosystem/[email protected]
- github.com/grpc-ecosystem/[email protected]
- github.com/gsterjov/[email protected]
- github.com/gtank/[email protected]
- github.com/gtank/[email protected]
- github.com/hashicorp/[email protected]
- github.com/hashicorp/[email protected]
- github.com/hashicorp/[email protected]
- github.com/hdevalence/[email protected]
- github.com/improbable-eng/[email protected]
- github.com/klauspost/[email protected]
- github.com/lib/[email protected]
- github.com/libp2p/[email protected]
- github.com/magiconair/[email protected]
- github.com/mattn/[email protected]
- github.com/mattn/[email protected]
- github.com/matttproud/[email protected]
- github.com/mimoo/[email protected]
- github.com/minio/[email protected]
- github.com/mitchellh/[email protected]
- github.com/mtibben/[email protected]
- github.com/pelletier/go-toml/[email protected]
- github.com/pkg/[email protected]
- github.com/pmezard/[email protected]
- github.com/prometheus/[email protected]
- github.com/prometheus/[email protected]
- github.com/prometheus/[email protected]
- github.com/prometheus/[email protected]
- github.com/rakyll/[email protected]
- github.com/rcrowley/[email protected]
- github.com/regen-network/[email protected]
- github.com/rs/[email protected]
- github.com/rs/[email protected]
- github.com/spf13/[email protected]
- github.com/spf13/[email protected]
- github.com/spf13/[email protected]
- github.com/spf13/[email protected]
- github.com/spf13/[email protected]
- github.com/spf13/[email protected]
- github.com/stretchr/[email protected]
- github.com/subosito/[email protected]
- github.com/syndtr/[email protected]
- github.com/tendermint/[email protected]
- github.com/tendermint/[email protected]
- github.com/tendermint/[email protected]
- github.com/tendermint/[email protected] => github.com/agoric-labs/[email protected]
- github.com/tendermint/[email protected]
- github.com/zondax/[email protected] => github.com/zondax/[email protected]
- golang.org/x/[email protected]
- golang.org/x/[email protected]
- golang.org/x/[email protected]
- golang.org/x/[email protected]
- golang.org/x/[email protected]
- golang.org/x/[email protected]
- google.golang.org/[email protected]
- google.golang.org/[email protected] => google.golang.org/[email protected]
- google.golang.org/[email protected]
- nhooyr.io/[email protected]
cosmos_sdk_version: v0.45.11

Check Status

curl 127.0.0.1:14457/status
Sample Result
{
"jsonrpc": "2.0",
"id": -1,
"result": {
"node_info": {
"protocol_version": {
"p2p": "8",
"block": "11",
"app": "0"
},
"id": "c1dc9...79475",
"listen_addr": "[YOUR IP]:14456",
"network": "agoric-emerynet-8",
"version": "0.34.23",
"channels": "40202122233038606100",
"moniker": "test-agoric-main",
"other": {
"tx_index": "off",
"rpc_address": "tcp://0.0.0.0:14457"
}
},
"sync_info": {
"latest_block_hash": "3F63FE8700D15ACB46612931AD9B3DA40270B0A379A17462059207A813D6645D",
"latest_app_hash": "C015C46B7AFFA73145FC7D3E55383B2DFF9833556B5075AC99C1E3843CB9474C",
"latest_block_height": "1593488",
"latest_block_time": "2023-09-20T13:46:01.199410173Z",
"earliest_block_hash": "88977C1347A93816EEFCE8631C92A4C4D712F133B0EDA352382304F3E9E9CED4",
"earliest_app_hash": "A2233ED992002D5937FAC5297EF0B2BE1888BAB2D1FE5EACCE0059865ED3AFBD",
"earliest_block_height": "1561001",
"earliest_block_time": "2023-09-18T10:46:48.032799174Z",
"catching_up": false
},
"validator_info": {
"address": "1BC85D8C37872D47B99011E4EE321FE74E99CE40",
"pub_key": {
"type": "tendermint/PubKeyEd25519",
"value": "mf7zJ6VZOe6Rryf/hUnLa/pS9vLJS+zAZzM63W1xNqE="
},
"voting_power": "0"
}
}
}

Alternate command

agd status --node tcp://127.0.0.1:14457
Sample Result
{"NodeInfo":{"protocol_version":{"p2p":"8","block":"11","app":"0"},"id":"c1dc9...79475","listen_addr":"[YOUR IP]:14456","network":"agoric-emerynet-8","version":"0.34.23","channels":"40202122233038606100","moniker":"test-agoric-main","other":{"tx_index":"off","rpc_address":"tcp://0.0.0.0:14457"}},"SyncInfo":{"latest_block_hash":"2FDBBEBAC19CACD31B37B1480949658DBA2FC668EE1F594EFB573FC6A0DF8D47","latest_app_hash":"82A84446E478F94296C5CB6B2FAC55D77F372F991246E6081E2EE7E845B81392","latest_block_height":"1593541","latest_block_time":"2023-09-20T13:50:59.984302065Z","earliest_block_hash":"88977C1347A93816EEFCE8631C92A4C4D712F133B0EDA352382304F3E9E9CED4","earliest_app_hash":"A2233ED992002D5937FAC5297EF0B2BE1888BAB2D1FE5EACCE0059865ED3AFBD","earliest_block_height":"1561001","earliest_block_time":"2023-09-18T10:46:48.032799174Z","catching_up":false},"ValidatorInfo":{"Address":"D8C37.....FE74E","PubKey":{"type":"tendermint/PubKeyEd25519","value":"ryf9v.....="},"VotingPower":"0"}}
​

Get blocks

curl 127.0.0.1:14457/block
Sample Result
{
"jsonrpc": "2.0",
"id": -1,
"result": {
"block_id": {
"hash": "5517185459DEBC6DF23036633880CDBBA3D0C7BE98CB790998A1044837FC57FD",
"parts": {
"total": 1,
"hash": "C6BE9FDE049965BA497A5528A27C1111083463D4EFD5DD1948BA2DE870863E1F"
}
},
"block": {
"header": {
"version": {
"block": "11"
},
"chain_id": "agoric-emerynet-8",
"height": "1593572",
"time": "2023-09-20T13:53:54.757278946Z",
"last_block_id": {
"hash": "F6467A2C8FF8A03FB6AD816CD3B245B3CA4C0B596CC6976A64171165423A27F3",
"parts": {
"total": 1,
"hash": "532E25A50F0C597E6E6999E1194B548B1D4CC2DBAEA5F01BFCC683B550945F01"
}
},
"last_commit_hash": "F4C457FD41CE675E8A8B637371F18801F1B5BC310F5036ABA22ADE6E7DA5DC4B",
"data_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"validators_hash": "562C689D73C5E3A7B0A99837C2ACDD2022724550309D37689F604239C084BA37",
"next_validators_hash": "562C689D73C5E3A7B0A99837C2ACDD2022724550309D37689F604239C084BA37",
"consensus_hash": "048091BC7DDC283F77BFBF91D73C44DA58C3DF8A9CBC867405D8B7F3DAADA22F",
"app_hash": "DD4AC43F5788C9925DDF2DD03EACBAC8FD365AF193D8196471562D2618FBFDB9",
"last_results_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"evidence_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855",
"proposer_address": "F7A60CFAD351A7BA96B19EC9852EC56158C7DB9E"
},
"data": {
"txs": []
},
"evidence": {
"evidence": []
},
"last_commit": {
"height": "1593571",
"round": 0,
"block_id": {
"hash": "F6467A2C8FF8A03FB6AD816CD3B245B3CA4C0B596CC6976A64171165423A27F3",
"parts": {
"total": 1,
"hash": "532E25A50F0C597E6E6999E1194B548B1D4CC2DBAEA5F01BFCC683B550945F01"
}
},
"signatures": [
{
"block_id_flag": 2,
"validator_address": "1E1B939E6D3CCFC7FD2F832A837BEEC5507C0BA4",
"timestamp": "2023-09-20T13:53:54.707731802Z",
"signature": "IMtUVu7AQGcppQgnO/LsvQZda2Xa2w91OsazYwHZgfTTSs7VLu6UETCU5Sdi0wHjyC2L4bvMpCHHhSnuvH4aBQ=="
},
{
"block_id_flag": 2,
"validator_address": "BC086C7F34A3361CB75F07A882E6A7751C6E1DA8",
"timestamp": "2023-09-20T13:53:54.761948725Z",
"signature": "5yeugdn6bRqbHUu85iRHSCTaXWZe/IaD2IRHY1i6LDPzdaToZwzXwqGXJM81DxPiLKpUWcxktFrrPcwfHsR/AA=="
},
{
"block_id_flag": 2,
"validator_address": "61D286818CD671A60767040E8167724183E575EA",
"timestamp": "2023-09-20T13:53:54.811383357Z",
"signature": "+uo2hSKe12WLuSRxa8kTHnbYyRSJySk2gZVVFwgOQEk3b/+9tYYhfiRQcatCnI7XI6rcIoe73V5rPAPA4lx1Aw=="
},
{
"block_id_flag": 2,
"validator_address": "D881537CD07CB0383645F44CAA8D7D67E1E32CEA",
"timestamp": "2023-09-20T13:53:54.757278946Z",
"signature": "4Ckiq4O05v/922IzH5A9CiH3fH2ej78QBgSyAnnix+X24KViSLwp+njrl3KaGSRJfc6jG5VL7qs0FoT7d5G9AA=="
},
{
"block_id_flag": 2,
"validator_address": "3B8515F62E2D6B6A2EC65B47B302800AA9F2687B",
"timestamp": "2023-09-20T13:53:54.757120554Z",
"signature": "4933OvOOOWKSN8qsmuC2MXZbhVyXzGw9Z+uPpHCpcQdxIQe+M4bNkIdH1984R3lZUiLDJg9Nn5biEgwzWOHqAA=="
},
{
"block_id_flag": 2,
"validator_address": "D9C01AE1781B5058DA209E75C3E163042FE92D95",
"timestamp": "2023-09-20T13:53:54.764057653Z",
"signature": "WliMYK8UgxSDMOu7/6sSIrO91cO6m/TKyHSoVjvdEtPu6+qgWsvhostHBO5Q0guNYOLGiq56LYrSMlM0YjHvBA=="
},
{
"block_id_flag": 2,
"validator_address": "FECC261776772111BA28A274452E2890E6DC11E9",
"timestamp": "2023-09-20T13:53:54.767356668Z",
"signature": "yulIvPWVWXp7LNuVfnOy5dCGCVr1EoHmfo6k74tBulKJZgkv5suvmjf2e8advfIya/DfzGcdtqA25s4iA3ZvAg=="
},
{
"block_id_flag": 2,
"validator_address": "702A308B424D3EA957B5033FA804CE1F3B5DA65B",
"timestamp": "2023-09-20T13:53:54.692037796Z",
"signature": "xHyn4V4hutWGfxidZaJGVgesUwnuUoPcQXk6d7tsxkrkHTYh5Ks7+60LotNZsbKvnXs0OLnSmTRg8GvTttrTAw=="
},
{
"block_id_flag": 2,
"validator_address": "F7A60CFAD351A7BA96B19EC9852EC56158C7DB9E",
"timestamp": "2023-09-20T13:53:54.700243422Z",
"signature": "AewisZPB4Y/1QU6MBSJe0/4cMy5DHob1KaiWfvIeOHFEVuRo54Ceo5wHiUBsIeBB7vPLLUGvo4xxZKVb7sqmAQ=="
},
{
"block_id_flag": 2,
"validator_address": "44D286E368B0C5A31859933048748F9ED470EB43",
"timestamp": "2023-09-20T13:53:54.762645467Z",
"signature": "rbNaX9USil2w3q5lg5WtVDjuQOuNQckHMznjBxKyPNSq7sIUF0lKPa61UWVZtK46VQthEzjlc1BOLRJEDnWIAw=="
},
{
"block_id_flag": 2,
"validator_address": "0308A6C41EE7379790C9C1109FE994DF5CBA64D8",
"timestamp": "2023-09-20T13:53:54.672654831Z",
"signature": "ZFynkxAb8qlbTWb5Q02qPV2EHsitweqr3jr3Pu/w4AFcbQyoCqLvGK3jv2w6zaSdF6MkWyxLEexpkXAnGIkiBg=="
},
{
"block_id_flag": 2,
"validator_address": "B5835B919A83A689D47A9BB2146359C0E74F59E3",
"timestamp": "2023-09-20T13:53:54.695710515Z",
"signature": "ZBfcfuCS/7lbsOyZnEb+6Kp409bKA9iogkWr6+fNJ7RzjjbSLRLx5902pta7sUvt3SorV1s7zSbfIz+PfglhAQ=="
},
{
"block_id_flag": 2,
"validator_address": "2568CC579BDF51F750054294D73524E41E922F5E",
"timestamp": "2023-09-20T13:53:54.710460987Z",
"signature": "NELagNFWYQYgu3tuDAk1Qa13PEDXMJfZCy45F6WxE684SHnkOpEpQTcOj7S6UgJyv8xHw0XYiWGQ3w/geeazBQ=="
},
{
"block_id_flag": 2,
"validator_address": "7B886A33C4EFCEE08E178A3D8DC7D5FA0DAF6962",
"timestamp": "2023-09-20T13:53:54.750807509Z",
"signature": "9aUp6B7Ow96TUC16BRnmwI8ZqzoQSV4N9d5aInl6V1FmfL60WNxaADbUOKbg9mU0lgNrK6CvShXFiPu6MmEuBw=="
},
{
"block_id_flag": 2,
"validator_address": "48E2B3E17D81A4EC7D9C46C74BC23969A0B2EED7",
"timestamp": "2023-09-20T13:53:54.757326127Z",
"signature": "JATYvbO3d65LAm4HdwTzWU3KegWWz1+v8PM0Rv1B2E519cNvRIm8X5U0aYio+vcHxyM5zfXTPAVKOFrxuBSvAw=="
},
{
"block_id_flag": 2,
"validator_address": "8B1C388FCB7C55286384648597F3282AE9F78DF8",
"timestamp": "2023-09-20T13:53:54.756357379Z",
"signature": "jYsJartEo6FVgTgYoOoN5ItASSesfbmaebmBX7ZRcEcVZSMfrdPC8MYwtZIgz0qOOaMDoELrzadktVmGACZLBQ=="
},
{
"block_id_flag": 2,
"validator_address": "EFE53120F79431764A1ED2CEF83376777AE39F72",
"timestamp": "2023-09-20T13:53:54.670612355Z",
"signature": "67B6z+EgWOrNB3qqIQsyv9zIG9Pe3fl/r5+d7RlplAGRIaqzfZa6rnrBwWhhGuY4JidnaNyXY3QvxIl/ulYzDw=="
},
{
"block_id_flag": 2,
"validator_address": "C9FBAB74B9902E404996420CC7A3A77F1E77AF2A",
"timestamp": "2023-09-20T13:53:54.75908408Z",
"signature": "NUnYNVWTR+ewyo9uChFdlsQXO6n996H6Wwo4txMOxScxMUOvVkkEhSNfybeqRLE0106V0Zba0IcIbeHOnvwpAA=="
},
{
"block_id_flag": 2,
"validator_address": "ED1B3F31A99CD520C565DDB6A88405A388B7984F",
"timestamp": "2023-09-20T13:53:54.683925215Z",
"signature": "x9dL9W4bSii5mHqfD+CVzF8nE8W924k/DS1Ob/HPBK2z24v5KbEohwGniVm1/LJ1jU6C29anASWy2rr807MiAQ=="
},
{
"block_id_flag": 2,
"validator_address": "DC9901FAEF22ECEA45B6A4CF5BDAA2DB5D458B18",
"timestamp": "2023-09-20T13:53:54.67625943Z",
"signature": "RMaejS2V90p9qJVg6ou7S0h9WCvOzdG96wP99ZGz1o/y4ml32JQQSQ48d6fXHsqTb8ZVTgQ+CDiiD7yE6yN+Cg=="
},
{
"block_id_flag": 2,
"validator_address": "0EB137A895EC55B7C0BD1CBF2743DB3BD6FAB497",
"timestamp": "2023-09-20T13:53:54.852257213Z",
"signature": "IZfR8w8Qx+RsUy0x3DVjAJaW6bdfds+NRuGHWpGqmBHMqvHPqhRpasmQ9JojYG780hANKyXexPFYv7naw/ryDg=="
},
{
"block_id_flag": 2,
"validator_address": "969B20BC44DC432D55C051054A0E91CD2B0842A6",
"timestamp": "2023-09-20T13:53:54.747491699Z",
"signature": "BJLEm+yGdiKD3duAGeBkQmrzWdxagtFfzbEaJBG4cLmUAkzlpVZzJD71YlCfObX5k604nw6Y/Tx9sP/5gXlXCg=="
}
]
}
}
}
}

Get block height

curl -s 127.0.0.1:14457/block | jq -r .result.block.header.height
Sample Result
1593586

Count Connected Peers

To look for number of peers
curl -s 127.0.0.1:14457/net_info | jq .result.n_peers
Sample Results
"17"

Connected Peers IP addresses

curl -s 127.0.0.1:14457/net_info | jq .result.peers | grep remote
Sample Results
"remote_ip": "63.229.234.75"
"remote_ip": "38.242.156.28"
"remote_ip": "95.214.54.27"
"remote_ip": "141.94.138.48"
"remote_ip": "208.88.251.50"
"remote_ip": "5.9.81.187"
"remote_ip": "70.58.17.174"
"remote_ip": "195.201.108.152"
"remote_ip": "178.23.126.84"
"remote_ip": "54.203.15.32"
"remote_ip": "65.109.23.238"
"remote_ip": "65.109.23.114"
"remote_ip": "34.171.162.87"
"remote_ip": "65.108.226.183"
"remote_ip": "38.109.200.33"
"remote_ip": "65.109.68.190"
"remote_ip": "116.202.231.58"

Check Consensus State

curl -s 127.0.0.1:14457/consensus_state \
| jq '.result.round_state.height_vote_set[0].prevotes_bit_array'
Sample Results
"BA{22:______________________} 0/3007 = 0.00"

Pre-vote

curl localhost:26657/consensus_state \
| jq '.result.round_state.height_vote_set[0].prevotes[]' \
| grep 'Vote{' \
| grep <first 6 characters of validator address>
Last modified 3mo ago