diff --git a/bor/README.md b/bor/README.md index 5a1c18267..75056af28 100644 --- a/bor/README.md +++ b/bor/README.md @@ -5,8 +5,10 @@ * [Preliminary terminology](#preliminary-terminology) * [Overview](#overview) * [How does it work](#how-does-it-work) -* [How to propose a span](#how-to-propose-a-span) + * [How to propose a span](#how-to-propose-a-span) * [Query commands](#query-commands) + + ## Preliminary terminology * A `side-transaction` is a normal heimdall transaction but the data with which the message is composed needs to be voted on by the validators since the data is obscure to the consensus protocol itself and it has no way of validating the data's correctness. @@ -89,7 +91,7 @@ newSpan := hmTypes.NewSpan( return k.AddNewSpan(ctx, newSpan) ``` -## How to propose a span +### How to propose a span A validator can leverage the CLI to propose a span like so : @@ -107,69 +109,57 @@ curl -X POST "localhost:1317/bor/propose-span?bor-chain-id=&start- One can run the following query commands from the bor module : -* `span` - Query the span corresponding to the given span id: +* `span` - Query the span corresponding to the given span id. +* `latest span` - Query the latest span. +* `params` - Fetch the parameters associated to bor module. +* `spanlist` - Fetch span list. +* `next-span-seed` - Query the seed for the next span. +* `propose-span` - Print the `propose-span` command. + +### CLI commands -via CLI ``` heimdallcli query bor span --span-id= ``` -via REST ``` -curl localhost:1317/bor/span/ +heimdallcli query bor latest-span ``` -* `latest span` - Query the latest span : - -via CLI ``` -heimdallcli query bor latest-span +heimdallcli query bor params ``` -via REST ``` -curl localhost:1317/bor/latest-span +heimdallcli query bor spanlist --page= --limit= ``` -* `params` - Fetch the parameters associated to bor module : - -via CLI ``` -heimdallcli query bor params +heimdallcli query bor next-span-seed ``` -via REST ``` -curl localhost:1317/bor/params +heimdallcli query bor propose-span --proposer --start-block --span-id --bor-chain-id ``` -* `spanlist` - Fetch span list : +### REST endpoints -via CLI ``` -heimdallcli query bor spanlist --page= --limit= +curl localhost:1317/bor/span/ ``` -* `next-span-seed` - Query the seed for the next span : - -via CLI ``` -heimdallcli query bor next-span-seed +curl localhost:1317/bor/latest-span ``` -via REST ``` -curl localhost:1317/bor/next-span-seed +curl localhost:1317/bor/params ``` -* `propose-span` - Print the `propose-span` command : - -via CLI ``` -heimdallcli query bor propose-span --proposer --start-block --span-id --bor-chain-id +curl localhost:1317/bor/next-span-seed ``` -via REST ``` curl "localhost:1317/bor/prepare-next-span?span_id=&start_block=&chain_id=""" ``` \ No newline at end of file