Skip to content

Latest commit

 

History

History
53 lines (32 loc) · 1022 Bytes

cast-block.md

File metadata and controls

53 lines (32 loc) · 1022 Bytes

cast block

NAME

cast-block - Get information about a block.

SYNOPSIS

cast block [options] --block block

DESCRIPTION

Get information about a block.

If field is specified, then only the given field of the block is displayed.

OPTIONS

Query Options

-B block
--block block
    The block height you want to query at.

    Can be a block number, or any of the tags: earliest, latest or pending.

-f field
--field field
    If specified, only get the given field of the block.

{{#include ../common/display-options.md}}

RPC Options

{{#include ../common/rpc-url-option.md}}

{{#include common-options.md}}

EXAMPLES

  1. Get the latest block:

    cast block --block latest
  2. Get the hash of the latest block:

    cast block --block latest --field hash

SEE ALSO

cast, cast basefee, cast age