Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion crates/espresso/node/api/light-client.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ PATH = [
":payload-hash" = "TaggedBase64"
DOC = """
Fetch a leaf plus a proof of it's finality (a chain of leaves leading from that leaf to either a
chain of consecutive valid QCs or a known-finalized leaf).
chain of consecutive valid QCs, a finality certificate, or a known-finalized leaf).

`:height` and `:finalized`, if provided, must both be block numbers. If provided, `:finalized` must
be greater than `:height`.
Expand All @@ -27,8 +27,14 @@ to be finalized). This consists of a chain of valid leaves from the requested le
either
* a 2-chain of QCs (if the last leaf in the leaf chain is from HotShot >= 0.3)
* a 3-chain of QCs (if the last leaf in the leaf chain is from HotShot < 0.3)
* a certificate directly committing the last leaf in the chain (HotShot >= 0.6)
* the assumed `:finalized` leaf

The server bounds the number of leaves it will include in a single proof. The `:finalized` hint is
ignored if it is too far past the requested leaf for a bounded proof, or if a finality certificate
nearer the requested leaf yields a shorter proof; the proof instead ends in a QC chain or
certificate, which the client must verify against the appropriate quorum.

Returns
```json
{
Expand All @@ -47,6 +53,12 @@ Returns
"deciding_qc": QC
} | undefined,

// Finality proof for HotShot >= 0.6
"NewProtocol": {
"cert2": Certificate2,
"leaf_qc": QC
} | undefined,

// Leaf chain ends in assumed-finalized leaf.
"Assumption": {}
}
Expand Down
Loading
Loading